diff options
author | Sam Clegg <sbc@chromium.org> | 2017-09-19 23:00:57 +0000 |
---|---|---|
committer | Sam Clegg <sbc@chromium.org> | 2017-09-19 23:00:57 +0000 |
commit | b292c259665df700442f47f430d0e4b4edd818cb (patch) | |
tree | 9f1cdf736c1460806311eca8b11e7bd436192b4a /llvm/include/llvm/BinaryFormat/Wasm.h | |
parent | 15fccf00097dd5b07710539fb4e3ff68c50f44de (diff) | |
download | bcm5719-llvm-b292c259665df700442f47f430d0e4b4edd818cb.tar.gz bcm5719-llvm-b292c259665df700442f47f430d0e4b4edd818cb.zip |
[WebAssembly] Add support for naming wasm data segments
Add adds support for naming data segments. This is useful
useful linkers so that they can merge similar sections.
Differential Revision: https://reviews.llvm.org/D37886
llvm-svn: 313692
Diffstat (limited to 'llvm/include/llvm/BinaryFormat/Wasm.h')
-rw-r--r-- | llvm/include/llvm/BinaryFormat/Wasm.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/include/llvm/BinaryFormat/Wasm.h b/llvm/include/llvm/BinaryFormat/Wasm.h index 23e30b7a868..53a812b2777 100644 --- a/llvm/include/llvm/BinaryFormat/Wasm.h +++ b/llvm/include/llvm/BinaryFormat/Wasm.h @@ -97,6 +97,7 @@ struct WasmDataSegment { uint32_t MemoryIndex; WasmInitExpr Offset; ArrayRef<uint8_t> Content; + StringRef Name; }; struct WasmElemSegment { @@ -184,6 +185,7 @@ enum : unsigned { WASM_SYMBOL_INFO = 0x2, WASM_DATA_SIZE = 0x3, WASM_DATA_ALIGNMENT = 0x4, + WASM_SEGMENT_NAMES = 0x5, }; enum : unsigned { |