[PATCH] D43940: [WebAssembly] Reorder reloc sections to come between symtab and name
Nicholas Wilson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 5 05:01:37 PST 2018
This revision was not accepted when it landed; it landed in state "Needs Review".
This revision was automatically updated to reflect the committed changes.
Closed by commit rL326694: [WebAssembly] Reorder reloc sections to come between symtab and name (authored by ncw, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D43940?vs=136767&id=136975#toc
Repository:
rL LLVM
https://reviews.llvm.org/D43940
Files:
llvm/trunk/lib/MC/WasmObjectWriter.cpp
llvm/trunk/test/Object/Inputs/trivial-object-test.wasm
llvm/trunk/test/tools/llvm-objdump/Inputs/trivial.obj.wasm
llvm/trunk/test/tools/llvm-objdump/wasm.txt
llvm/trunk/test/tools/llvm-readobj/Inputs/trivial.obj.wasm
llvm/trunk/test/tools/llvm-readobj/sections.test
Index: llvm/trunk/lib/MC/WasmObjectWriter.cpp
===================================================================
--- llvm/trunk/lib/MC/WasmObjectWriter.cpp
+++ llvm/trunk/lib/MC/WasmObjectWriter.cpp
@@ -1307,9 +1307,9 @@
writeElemSection(TableElems);
writeCodeSection(Asm, Layout, Functions);
writeDataSection();
+ writeLinkingMetaDataSection(SymbolInfos, InitFuncs, Comdats);
writeCodeRelocSection();
writeDataRelocSection();
- writeLinkingMetaDataSection(SymbolInfos, InitFuncs, Comdats);
// TODO: Translate the .comment section to the output.
// TODO: Translate debug sections to the output.
Index: llvm/trunk/test/tools/llvm-readobj/sections.test
===================================================================
--- llvm/trunk/test/tools/llvm-readobj/sections.test
+++ llvm/trunk/test/tools/llvm-readobj/sections.test
@@ -528,14 +528,14 @@
WASM-NEXT: }
WASM-NEXT: Section {
WASM-NEXT: Type: CUSTOM (0x0)
-WASM-NEXT: Size: 23
+WASM-NEXT: Size: 65
WASM-NEXT: Offset: 191
-WASM-NEXT: Name: reloc.CODE
+WASM-NEXT: Name: linking
WASM-NEXT: }
WASM-NEXT: Section {
WASM-NEXT: Type: CUSTOM (0x0)
-WASM-NEXT: Size: 65
-WASM-NEXT: Offset: 220
-WASM-NEXT: Name: linking
+WASM-NEXT: Size: 23
+WASM-NEXT: Offset: 262
+WASM-NEXT: Name: reloc.CODE
WASM-NEXT: }
WASM-NEXT: ]
Index: llvm/trunk/test/tools/llvm-objdump/wasm.txt
===================================================================
--- llvm/trunk/test/tools/llvm-objdump/wasm.txt
+++ llvm/trunk/test/tools/llvm-objdump/wasm.txt
@@ -7,8 +7,8 @@
# CHECK-NEXT: 2 FUNCTION 00000002 0000000000000000
# CHECK-NEXT: 3 CODE 00000019 0000000000000000 TEXT
# CHECK-NEXT: 4 DATA 0000001c 0000000000000000 DATA
-# CHECK-NEXT: 5 reloc.CODE 00000017 0000000000000000
-# CHECK-NEXT: 6 linking 00000055 0000000000000000
+# CHECK-NEXT: 5 linking 00000055 0000000000000000
+# CHECK-NEXT: 6 reloc.CODE 00000017 0000000000000000
# RUN: llvm-objdump -p %p/Inputs/trivial.obj.wasm | FileCheck %s -check-prefix CHECK-HEADER
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D43940.136975.patch
Type: text/x-patch
Size: 2107 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180305/d8dc1c02/attachment.bin>
More information about the llvm-commits
mailing list