about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm
diff options
context:
space:
mode:
authorNicholas Bishop <nbishop@nbishop.net>2025-02-09 15:04:38 -0500
committerNicholas Bishop <nbishop@nbishop.net>2025-02-09 15:20:29 -0500
commit9da96a65e1c20a99a644be70661bfdb7bfb5b23d (patch)
tree558bc19ef5229539963e4b4dc85a4fb101d803a1 /compiler/rustc_codegen_llvm
parent124cc92199ffa924f6b4c7cc819a85b65e0c3984 (diff)
downloadrust-9da96a65e1c20a99a644be70661bfdb7bfb5b23d.tar.gz
rust-9da96a65e1c20a99a644be70661bfdb7bfb5b23d.zip
Disable DWARF in linker options for i686-unknown-uefi
This fixes an lld warning:
> warning: linker stderr: rust-lld: section name .debug_frame is longer
> than 8 characters and will use a non-standard string table

See https://reviews.llvm.org/D69594 for details of where the warning was
added.

This warning only occurs with the i686 UEFI target, not x86_64 or
aarch64. The x86_64 target uses an LLVM target of
`x86_64-unknown-windows` and aarch64 uses `aarch64-unknown-windows`, but
i686 uses `i686-unknown-windows-gnu` (note the `-gnu`). See comments in
`i686_unknown_uefi.rs` for details of why.

The `.debug_frame` section should not actually be needed; UEFI targets
provide a separate PDB file for debugging. Disable DWARF (and by
extension the `.debug_frame` section) by passing `/DEBUG:NODWARF` to lld.

Tested with:
export RUSTC_LOG=rustc_codegen_ssa::back::link=info
cargo +stage1 build --release --target i686-unknown-uefi
Diffstat (limited to 'compiler/rustc_codegen_llvm')
0 files changed, 0 insertions, 0 deletions