[PATCH] D95661: [yaml2obj][wasm] Support numeric relocation type
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 28 20:52:49 PST 2021
MaskRay created this revision.
MaskRay added a reviewer: sbc100.
Herald added subscribers: sunfish, hiraditya.
MaskRay requested review of this revision.
Herald added subscribers: llvm-commits, aheejin.
Herald added a project: LLVM.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D95661
Files:
llvm/lib/ObjectYAML/WasmYAML.cpp
llvm/test/ObjectYAML/wasm/event_section.yaml
Index: llvm/test/ObjectYAML/wasm/event_section.yaml
===================================================================
--- llvm/test/ObjectYAML/wasm/event_section.yaml
+++ llvm/test/ObjectYAML/wasm/event_section.yaml
@@ -27,6 +27,9 @@
- Type: R_WASM_EVENT_INDEX_LEB
Index: 1
Offset: 0x00000006
+ - Type: 10
+ Index: 1
+ Offset: 0x00000006
Functions:
- Index: 0
Locals:
@@ -74,6 +77,9 @@
# CHECK-NEXT: - Type: R_WASM_EVENT_INDEX_LEB
# CHECK-NEXT: Index: 1
# CHECK-NEXT: Offset: 0x6
+# CHECK-NEXT: - Type: R_WASM_EVENT_INDEX_LEB
+# CHECK-NEXT: Index: 1
+# CHECK-NEXT: Offset: 0x6
# CHECK-NEXT: Functions:
# CHECK-NEXT: - Index: 0
# CHECK-NEXT: Locals:
Index: llvm/lib/ObjectYAML/WasmYAML.cpp
===================================================================
--- llvm/lib/ObjectYAML/WasmYAML.cpp
+++ llvm/lib/ObjectYAML/WasmYAML.cpp
@@ -614,6 +614,7 @@
#define WASM_RELOC(name, value) IO.enumCase(Type, #name, wasm::name);
#include "llvm/BinaryFormat/WasmRelocs.def"
#undef WASM_RELOC
+ IO.enumFallback<Hex32>(Type);
}
} // end namespace yaml
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D95661.320039.patch
Type: text/x-patch
Size: 1324 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210129/f3fbb28b/attachment.bin>
More information about the llvm-commits
mailing list