summaryrefslogtreecommitdiffstats
path: root/llvm/include/llvm/BinaryFormat/Wasm.h
diff options
context:
space:
mode:
authorSam Clegg <sbc@chromium.org>2017-09-20 19:03:35 +0000
committerSam Clegg <sbc@chromium.org>2017-09-20 19:03:35 +0000
commitd95ed959d8ab270808aeec8b31f06140e68834ea (patch)
tree989216a22660bb777d0fcff71cbc4540067b80ed /llvm/include/llvm/BinaryFormat/Wasm.h
parent01a409520b39946bd4c7e86f83bc2d01d8c839d4 (diff)
downloadbcm5719-llvm-d95ed959d8ab270808aeec8b31f06140e68834ea.tar.gz
bcm5719-llvm-d95ed959d8ab270808aeec8b31f06140e68834ea.zip
Reland "[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: 313795
Diffstat (limited to 'llvm/include/llvm/BinaryFormat/Wasm.h')
-rw-r--r--llvm/include/llvm/BinaryFormat/Wasm.h2
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 {
OpenPOWER on IntegriCloud