Rollup merge of #148613 - androm3da:bcain/hex_lld, r=JonathanBrouwer,Noratrieb
Switch hexagon targets to rust-lld lld is a great choice for a default linker.
This commit is contained in:
commit
2fe368d2d1
4 changed files with 15 additions and 0 deletions
|
|
@ -8,6 +8,7 @@ pub(crate) fn target() -> Target {
|
|||
base.features = "-small-data,+hvx-length128b".into();
|
||||
|
||||
base.has_rpath = true;
|
||||
base.linker = Some("rust-lld".into());
|
||||
base.linker_flavor = LinkerFlavor::Unix(Cc::Yes);
|
||||
|
||||
base.c_enum_min_bits = Some(8);
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@ pub(crate) fn target() -> Target {
|
|||
max_atomic_width: Some(32),
|
||||
emit_debug_gdb_scripts: false,
|
||||
c_enum_min_bits: Some(8),
|
||||
linker: Some("rust-lld".into()),
|
||||
..Default::default()
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -39,6 +39,12 @@ dynamically linked executables.
|
|||
# /opt/clang+llvm-18.1.0-cross-hexagon-unknown-linux-musl/x86_64-linux-gnu/bin/qemu-hexagon -L /opt/clang+llvm-18.1.0-cross-hexagon-unknown-linux-musl/x86_64-linux-gnu/target/hexagon-unknown-linux-musl/usr/ ./hello
|
||||
```
|
||||
|
||||
## Linking
|
||||
|
||||
This target selects `rust-lld` by default. Another option to use is
|
||||
[eld](https://github.com/qualcomm/eld), which is also provided with
|
||||
the opensource hexagon toolchain and the Hexagon SDK.
|
||||
|
||||
## Building the target
|
||||
Because it is Tier 3, rust does not yet ship pre-compiled artifacts for this
|
||||
target.
|
||||
|
|
|
|||
|
|
@ -25,6 +25,13 @@ Functions marked `extern "C"` use the [Hexagon architecture calling convention](
|
|||
|
||||
This target generates PIC ELF binaries.
|
||||
|
||||
## Linking
|
||||
|
||||
This target selects `rust-lld` by default. Another option to use is
|
||||
[eld](https://github.com/qualcomm/eld), which is also provided with
|
||||
[the opensource hexagon toolchain](https://github.com/quic/toolchain_for_hexagon)
|
||||
and the Hexagon SDK.
|
||||
|
||||
## Building the target
|
||||
|
||||
You can build Rust with support for the target by adding it to the `target`
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue