diff options
author | Sam Clegg <sbc@chromium.org> | 2017-11-30 22:34:58 +0000 |
---|---|---|
committer | Sam Clegg <sbc@chromium.org> | 2017-11-30 22:34:58 +0000 |
commit | 9138b7b0059521d6dabbc26362e00eaa69a6aec8 (patch) | |
tree | 70e2f8184231bfa0d4d3666b382f6307355c5c0e /llvm/include/llvm/BinaryFormat/Wasm.h | |
parent | f71964a1847427d1f89562de81a05b4a01939905 (diff) | |
download | bcm5719-llvm-9138b7b0059521d6dabbc26362e00eaa69a6aec8.tar.gz bcm5719-llvm-9138b7b0059521d6dabbc26362e00eaa69a6aec8.zip |
Add visibility flag to Wasm symbol flags
The LLVM "hidden" flag needs to be passed through the Wasm
intermediate objects in order for the linker to apply
it to the final Wasm object.
The corresponding change in LLD is here: https://github.com/WebAssembly/lld/pull/14
Patch by Nicholas Wilson
Differential Revision: https://reviews.llvm.org/D40442
llvm-svn: 319488
Diffstat (limited to 'llvm/include/llvm/BinaryFormat/Wasm.h')
-rw-r--r-- | llvm/include/llvm/BinaryFormat/Wasm.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/include/llvm/BinaryFormat/Wasm.h b/llvm/include/llvm/BinaryFormat/Wasm.h index 26475c27df3..f3a58026ed7 100644 --- a/llvm/include/llvm/BinaryFormat/Wasm.h +++ b/llvm/include/llvm/BinaryFormat/Wasm.h @@ -190,11 +190,15 @@ enum : unsigned { }; const unsigned WASM_SYMBOL_BINDING_MASK = 0x3; +const unsigned WASM_SYMBOL_VISIBILITY_MASK = 0x4; enum : unsigned { WASM_SYMBOL_BINDING_GLOBAL = 0x0, WASM_SYMBOL_BINDING_WEAK = 0x1, WASM_SYMBOL_BINDING_LOCAL = 0x2, + + WASM_SYMBOL_VISIBILITY_DEFAULT = 0x0, + WASM_SYMBOL_VISIBILITY_HIDDEN = 0x4, }; #define WASM_RELOC(name, value) name = value, |