[PATCH] D95005: Revert "[WebAssembly] call_indirect issues table number relocs"
Sam Clegg via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 19 14:36:30 PST 2021
sbc100 created this revision.
Herald added subscribers: wingo, ecnelises, arphaman, sunfish, hiraditya, jgravelle-google, dschuff.
sbc100 requested review of this revision.
Herald added subscribers: llvm-commits, aheejin.
Herald added a project: LLVM.
This reverts commit 418df4a6ab35d343cc0f2608c90a73dd9b8d0ab1 <https://reviews.llvm.org/rG418df4a6ab35d343cc0f2608c90a73dd9b8d0ab1>.
This change broke emscripten tests, I believe because it started
generating 5-byte a wide table index in the call_indirect instruction.
Neither v8 nor wabt seem to be able to handle that. The spec
currently says that this is single 0x0 byte and:
"In future versions of WebAssembly, the zero byte occurring in the
encoding of the call_indirectcall_indirect instruction may be used to
index additional tables."
So we need to revisit this change. For backwards compat I guess
we need to guarantee that __indirect_function_table is always at
address zero. We could also consider making this a single-byte
relocation with and assert if have more than 127 tables (for now).
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D95005
Files:
lld/test/wasm/call-indirect.ll
lld/test/wasm/compress-relocs.ll
lld/test/wasm/shared.ll
llvm/lib/MC/WasmObjectWriter.cpp
llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp
llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyInstPrinter.cpp
llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCTargetDesc.h
llvm/lib/Target/WebAssembly/WebAssemblyFastISel.cpp
llvm/lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
llvm/lib/Target/WebAssembly/WebAssemblyInstrCall.td
llvm/lib/Target/WebAssembly/WebAssemblyMCInstLower.cpp
llvm/test/CodeGen/WebAssembly/function-pointer64.ll
llvm/test/CodeGen/WebAssembly/multivalue.ll
llvm/test/MC/WebAssembly/basic-assembly.s
llvm/test/MC/WebAssembly/call-indirect-relocs.s
llvm/test/MC/WebAssembly/reloc-code.ll
llvm/test/MC/WebAssembly/tail-call-encodings.s
llvm/test/MC/WebAssembly/type-index.s
llvm/test/MC/WebAssembly/weak-alias.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D95005.317698.patch
Type: text/x-patch
Size: 28180 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210119/bc606ac0/attachment-0001.bin>
More information about the llvm-commits
mailing list