Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion compiler/rustc_target/src/spec/abi_map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ impl AbiMap {
Arch::RiscV32 | Arch::RiscV64 => ArchKind::Riscv,
Arch::X86 => ArchKind::X86,
Arch::X86_64 => ArchKind::X86_64,
Arch::LoongArch64 => ArchKind::LoongArch64,
_ => ArchKind::Other,
};

Expand Down Expand Up @@ -108,7 +109,10 @@ impl AbiMap {

(ExternAbi::EfiApi, ArchKind::Arm(..)) => CanonAbi::Arm(ArmCall::Aapcs),
(ExternAbi::EfiApi, ArchKind::X86_64) => CanonAbi::X86(X86Call::Win64),
(ExternAbi::EfiApi, ArchKind::Aarch64 | ArchKind::Riscv | ArchKind::X86) => CanonAbi::C,
(
ExternAbi::EfiApi,
ArchKind::Aarch64 | ArchKind::Riscv | ArchKind::X86 | ArchKind::LoongArch64,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why only LoongArch64? Isn't LoongArch32 the same?

) => CanonAbi::C,
(ExternAbi::EfiApi, _) => return AbiMapping::Invalid,

/* arm */
Expand Down Expand Up @@ -201,6 +205,7 @@ enum ArchKind {
Riscv,
X86,
X86_64,
LoongArch64,
/// Architectures which don't need other considerations for ABI lowering
Other,
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should support be added in InlineAsmClobberAbi::parse as well?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, that was intentionally not done in #111499, so I'm unsure here?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Expand Down
Loading