mirror of
https://github.com/ziglang/zig.git
synced 2026-01-02 19:43:29 +00:00
std.Target: Fix ptrBitWidth_cpu_abi() for sparc32.
CPU feature set has nothing to do with ABI choice; the pointer bit width is determined only by looking at the choice of sparc vs sparc64.
This commit is contained in:
parent
ab154be7f0
commit
db8f00e277
@ -1852,6 +1852,7 @@ pub fn ptrBitWidth_cpu_abi(cpu: Cpu, abi: Abi) u16 {
|
||||
.kalimba,
|
||||
.lanai,
|
||||
.wasm32,
|
||||
.sparc,
|
||||
.spirv32,
|
||||
.loongarch32,
|
||||
.xtensa,
|
||||
@ -1878,8 +1879,6 @@ pub fn ptrBitWidth_cpu_abi(cpu: Cpu, abi: Abi) u16 {
|
||||
.loongarch64,
|
||||
=> 64,
|
||||
|
||||
.sparc => if (std.Target.sparc.featureSetHas(cpu.features, .v9)) 64 else 32,
|
||||
|
||||
.spirv => @panic("TODO what should this value be?"),
|
||||
};
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user