about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/Linker.cpp
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2024-02-29 20:50:03 +0100
committerGitHub <noreply@github.com>2024-02-29 20:50:03 +0100
commit509972089b1365fefc6fe0512b3cc0f9d661adc5 (patch)
treec15a637a3965a4450eee13ad48eaafd884300e67 /compiler/rustc_llvm/llvm-wrapper/Linker.cpp
parentdd4ecd1cf4a59650747e7aeabaed9b24656fc88a (diff)
parent646e8e729168d95dbb65ee2d27cd00d2f0ece846 (diff)
downloadrust-509972089b1365fefc6fe0512b3cc0f9d661adc5.tar.gz
rust-509972089b1365fefc6fe0512b3cc0f9d661adc5.zip
Rollup merge of #121464 - alexcrichton:fix-wasm64, r=wesleywiser
rustc: Fix wasm64 metadata object files

It looks like LLD will detect object files being either 32 or 64-bit depending on any memory present. LLD will additionally reject 32-bit objects during a 64-bit link. Previously metadata objects did not have any memories in them which led LLD to conclude they were 32-bit objects which broke 64-bit targets for wasm.

This commit fixes this by ensuring that for 64-bit targets there's a memory object present to get LLD to detect it's a 64-bit target. Additionally this commit moves away from a hand-crafted wasm encoder to the `wasm-encoder` crate on crates.io as the complexity grows for the generated object file.

Closes #121460
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/Linker.cpp')
0 files changed, 0 insertions, 0 deletions