Add riscv32 imafc bare metal target
- riscv32imac-unknown-none-elf - Add platform support docs for rv32
This commit is contained in:
parent
1670ff64bf
commit
1a7b610da3
11 changed files with 71 additions and 4 deletions
|
@ -1637,6 +1637,7 @@ supported_targets! {
|
|||
("riscv32imc-esp-espidf", riscv32imc_esp_espidf),
|
||||
("riscv32imac-esp-espidf", riscv32imac_esp_espidf),
|
||||
("riscv32imac-unknown-none-elf", riscv32imac_unknown_none_elf),
|
||||
("riscv32imafc-unknown-none-elf", riscv32imafc_unknown_none_elf),
|
||||
("riscv32imac-unknown-xous-elf", riscv32imac_unknown_xous_elf),
|
||||
("riscv32gc-unknown-linux-gnu", riscv32gc_unknown_linux_gnu),
|
||||
("riscv32gc-unknown-linux-musl", riscv32gc_unknown_linux_musl),
|
||||
|
|
|
@ -0,0 +1,24 @@
|
|||
use crate::spec::{Cc, LinkerFlavor, Lld, PanicStrategy, RelocModel, Target, TargetOptions};
|
||||
|
||||
pub fn target() -> Target {
|
||||
Target {
|
||||
data_layout: "e-m:e-p:32:32-i64:64-n32-S128".into(),
|
||||
llvm_target: "riscv32".into(),
|
||||
pointer_width: 32,
|
||||
arch: "riscv32".into(),
|
||||
|
||||
options: TargetOptions {
|
||||
linker_flavor: LinkerFlavor::Gnu(Cc::No, Lld::Yes),
|
||||
linker: Some("rust-lld".into()),
|
||||
cpu: "generic-rv32".into(),
|
||||
max_atomic_width: Some(32),
|
||||
llvm_abiname: "ilp32f".into(),
|
||||
features: "+m,+a,+c,+f".into(),
|
||||
panic_strategy: PanicStrategy::Abort,
|
||||
relocation_model: RelocModel::Static,
|
||||
emit_debug_gdb_scripts: false,
|
||||
eh_frame_header: false,
|
||||
..Default::default()
|
||||
},
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue