hanchenye-llvm-project/lld/test/wasm
Thomas Lively f6f4f84378 [WebAssembly] Target features section
Summary:
Implements a new target features section in assembly and object files
that records what features are used, required, and disallowed in
WebAssembly objects. The linker uses this information to ensure that
all objects participating in a link are feature-compatible and records
the set of used features in the output binary for use by optimizers
and other tools later in the toolchain.

The "atomics" feature is always required or disallowed to prevent
linking code with stripped atomics into multithreaded binaries. Other
features are marked used if they are enabled globally or on any
function in a module.

Future CLs will add linker flags for ignoring feature compatibility
checks and for specifying the set of allowed features, implement using
the presence of the "atomics" feature to control the type of memory
and segments in the linked binary, and add front-end flags for
relaxing the linkage policy for atomics.

Reviewers: aheejin, sbc100, dschuff

Subscribers: jgravelle-google, hiraditya, sunfish, mgrang, jfb, jdoerfert, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D59173

llvm-svn: 356610
2019-03-20 20:26:45 +00:00
..
Inputs [WebAssembly] Target features section 2019-03-20 20:26:45 +00:00
lto [WebAssembly] LTO: Don't include bitcode-only symbols in the symtab 2019-03-07 02:43:19 +00:00
alias.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
archive-export.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
archive-weak-undefined.ll [WebAssembly] Refactor handling of weak undefined functions. NFC. 2019-02-07 22:42:16 +00:00
archive.ll [WebAssembly] Changed objdump output to offsets instead of indices. 2019-01-17 18:30:35 +00:00
call-indirect.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
comdats.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
compress-relocs.ll [WebAssembly] Add --[no]-export-dynamic to replace --export-default 2018-09-27 21:06:25 +00:00
conflict.test [WebAssembly] Check function signatures by default 2018-05-05 01:23:07 +00:00
custom-sections.ll [WebAssembly] Remove final -wasm component of target triple. NFC. 2018-05-10 17:59:41 +00:00
cxx-mangling.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
data-layout.ll [WebAssembly] Update MC for bulk memory 2019-02-19 22:56:19 +00:00
data-segment-merging.ll [WebAssembly] Group rodata into a single output segment 2018-08-08 18:02:55 +00:00
debug-removed-fn.ll [WebAssembly] Move .debug_line section address of dead function outside section range 2018-09-24 23:50:55 +00:00
debuginfo.test Update for an llvm-dwarfdump change in output 2018-12-12 18:46:43 +00:00
demangle.ll [WebAssembly] Don't error when --undefined symbols are not found 2018-08-04 00:04:06 +00:00
driver.ll [WebAssembly] Remove final -wasm component of target triple. NFC. 2018-05-10 17:59:41 +00:00
entry-signature.ll [WebAssembly] Allow signautre of entry function to be flexible 2018-05-14 23:01:16 +00:00
entry.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
event-section.ll [WebAssembly] Add support for the event section 2018-12-08 06:17:43 +00:00
export-all.ll [WebAssembly] Don't error when --undefined symbols are not found 2018-08-04 00:04:06 +00:00
export-table.test [WebAssembly] Instruction renaming 2019-01-08 06:25:55 +00:00
export.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
fatal-warnings.ll [WebAssembly] Use wasm-ld rather than lld with -flavor in tests. NFC. 2019-02-05 16:53:33 +00:00
function-imports-first.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
function-imports.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
function-index.test [WebAssembly] Check function signatures by default 2018-05-05 01:23:07 +00:00
gc-imports.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
gc-sections.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
import-memory.test [WebAssembly] Support creation and import of shared memories 2018-11-06 17:59:32 +00:00
import-module.ll [WebAssembly] Support imports from custom module names 2019-02-01 02:29:57 +00:00
import-names.ll [WebAssembly] Fix imported function symbol names that differ from their import names in the .o format 2019-02-07 22:00:48 +00:00
import-table.test [WebAssembly] Instruction renaming 2019-01-08 06:25:55 +00:00
init-fini-gc.ll [WebAssembly] Fix crash when __wasm_call_ctor is GCd in programs containing static init/fini 2019-03-02 04:55:02 +00:00
init-fini.ll [WebAssembly] Test change after disabling MachineBlockPlacement 2019-03-05 20:36:20 +00:00
invalid-stack-size.test [WebAssembly] Check function signatures by default 2018-05-05 01:23:07 +00:00
lit.local.cfg
load-undefined.test [WebAssembly] Don't error when --undefined symbols are not found 2018-08-04 00:04:06 +00:00
local-symbols.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
locals-duplicate.test [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
many-functions.ll [WebAssembly] Update MC for bulk memory 2019-02-19 22:56:19 +00:00
reloc-addend.ll [WebAssembly] Update relocation naming to match llvm change. NFC. 2019-02-04 17:49:33 +00:00
relocatable.ll [WebAssembly] Update MC for bulk memory 2019-02-19 22:56:19 +00:00
responsefile.test Fix wasm responsefile lld test on Windows 2018-06-14 19:59:22 +00:00
shared-needed.ll [WebAssembly] Improve support for "needed" list in dylink section 2019-03-13 21:29:20 +00:00
shared.ll [WebAssembly] Error on R_WASM_MEMORY_ADDR relocations against undefined data symbols. 2019-03-16 01:18:12 +00:00
signature-mismatch-export.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
signature-mismatch-weak.ll [WebAssembly] Remove duplicate function. NFC. 2018-11-01 01:08:37 +00:00
signature-mismatch.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
stack-first.test [WebAssembly] Check function signatures by default 2018-05-05 01:23:07 +00:00
stack-pointer.ll [WebAssembly] Update relocation naming to match llvm change. NFC. 2019-02-04 17:49:33 +00:00
strip-all.test [WedAssembly] Add -s and -S alias for --strip-all and --strip-debug 2018-10-31 19:30:43 +00:00
strip-debug.test [WedAssembly] Add -s and -S alias for --strip-all and --strip-debug 2018-10-31 19:30:43 +00:00
symbol-type-mismatch.ll [WebAssembly] Update to match llvm changes 2018-05-14 22:42:33 +00:00
target-feature-disallowed.yaml [WebAssembly] Target features section 2019-03-20 20:26:45 +00:00
target-feature-required.yaml [WebAssembly] Target features section 2019-03-20 20:26:45 +00:00
target-feature-used.yaml [WebAssembly] Target features section 2019-03-20 20:26:45 +00:00
trace-symbol.ll [WebAssembly] Implement --trace and --trace-symbol 2019-02-06 02:35:18 +00:00
trace.test [wasm-ld] Fix wasm trace test to use %t for temporary files. 2019-02-06 04:49:46 +00:00
undefined-data.ll [WebAssembly] Error on R_WASM_MEMORY_ADDR relocations against undefined data symbols. 2019-03-16 01:18:12 +00:00
undefined-entry.test [WebAssembly] Don't error when --undefined symbols are not found 2018-08-04 00:04:06 +00:00
undefined-weak-call.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
undefined.ll [WebAssembly] Don't error when --undefined symbols are not found 2018-08-04 00:04:06 +00:00
version.ll [WebAssembly] Remove final -wasm component of target triple. NFC. 2018-05-10 17:59:41 +00:00
visibility-hidden.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
weak-alias-overide.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
weak-alias.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
weak-symbols.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
weak-undefined.ll [WebAssebmly] Allow __wasm_call_ctors to be GC'ed 2019-03-01 22:35:47 +00:00
whole-archive.test [WebAssembly] Add support for --whole-archive. 2018-07-23 23:51:19 +00:00