Rollup merge of #132354 - koute:master, r=workingjubilee
Add `lp64e` RISC-V ABI This PR adds support for the `lp64e` RISC-V ABI, which is the 64-bit equivalent of the `ilp32e` ABI that is already supported. For reference, this ABI was originally added to LLVM in [this PR](https://reviews.llvm.org/D70401).
This commit is contained in:
commit
6b96a7944a
@ -325,7 +325,8 @@ pub(crate) fn create_object_file(sess: &Session) -> Option<write::Object<'static
|
||||
"" | "ilp32" | "lp64" => (),
|
||||
"ilp32f" | "lp64f" => e_flags |= elf::EF_RISCV_FLOAT_ABI_SINGLE,
|
||||
"ilp32d" | "lp64d" => e_flags |= elf::EF_RISCV_FLOAT_ABI_DOUBLE,
|
||||
"ilp32e" => e_flags |= elf::EF_RISCV_RVE,
|
||||
// Note that the `lp64e` is still unstable as it's not (yet) part of the ELF psABI.
|
||||
"ilp32e" | "lp64e" => e_flags |= elf::EF_RISCV_RVE,
|
||||
_ => bug!("unknown RISC-V ABI name"),
|
||||
}
|
||||
|
||||
|
@ -165,7 +165,8 @@ fn check_consistency(&self) {
|
||||
assert_matches!(&*self.llvm_abiname, "ilp32" | "ilp32f" | "ilp32d" | "ilp32e")
|
||||
}
|
||||
"riscv64" => {
|
||||
assert_matches!(&*self.llvm_abiname, "lp64" | "lp64f" | "lp64d" | "lp64q")
|
||||
// Note that the `lp64e` is still unstable as it's not (yet) part of the ELF psABI.
|
||||
assert_matches!(&*self.llvm_abiname, "lp64" | "lp64f" | "lp64d" | "lp64q" | "lp64e")
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user