[PATCH] D59278: [WebAssembly] Apply data relocations at runtime in shared objects

Sam Clegg via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 14 08:56:30 PDT 2019


sbc100 marked an inline comment as done.
sbc100 added inline comments.


================
Comment at: lld/wasm/InputChunks.cpp:296
+// not known at static link time.
+void InputSegment::generateRelocationCode(raw_ostream &OS) const {
+  int32_t SegmentVA = OutputSeg->StartVA + OutputSegmentOffset;
----------------
ruiu wrote:
> Instead of creating a table for the run-time loader to fix these addresses, do we generate code in the linker to do it as part of process initialization? 
Yes.   And only for the data section.  The keeps the dynamic linker very simple avoids the need to spec an ABI for runtime relocations.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59278/new/

https://reviews.llvm.org/D59278





More information about the llvm-commits mailing list