pub enum Arch {
Show 15 variants
X86,
X86_64,
Aarch64,
Arm,
Riscv32,
Riscv64,
Wasm32,
PowerPc,
PowerPc64,
S390x,
Mips,
Mips64,
Sparc,
Sparc64,
LoongArch64,
}Expand description
The architecture family a triple names.
Only the ones TargetModel::from_triple accepts are here. The variant
decides the __x86_64__-style predefined macros, whether __int128
exists, and — for Arm — the signedness of wchar_t.
Variants§
X86
32-bit x86: i386, i486, i586, i686.
X86_64
x86-64, the x32 ABI included.
Aarch64
64-bit Arm.
Arm
32-bit Arm, thumb* included.
Riscv32
32-bit RISC-V.
Riscv64
64-bit RISC-V.
Wasm32
32-bit WebAssembly.
PowerPc
32-bit PowerPC.
PowerPc64
64-bit PowerPC, big and little endian.
S390x
IBM z/Architecture.
Mips
32-bit MIPS.
Mips64
64-bit MIPS, the n64 ABI.
Sparc
32-bit SPARC.
Sparc64
64-bit SPARC.
LoongArch64
64-bit LoongArch.
Implementations§
Source§impl Arch
impl Arch
Sourcepub fn as_str(self) -> &'static str
pub fn as_str(self) -> &'static str
The name used in diagnostics and in the documentation table.
Sourcepub fn macros(self) -> &'static [(&'static str, &'static str)]
pub fn macros(self) -> &'static [(&'static str, &'static str)]
The __x86_64__-style macros this architecture predefines, each with
the value it is given.
Deliberately short. A program that tests for something not here sees a
0 in an #if, which is what C written for an unfamiliar compiler
expects; a macro claimed wrongly sends it down a path built on an
extension this crate does not have.