authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-05-22 03:53:00+02:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-05-22 18:41:03+02:00
log038c0783d4dd11d6a79c6d5aa750f1c755847671
tree7948398dd86691dd9ef15ab374d743e84d55b5b4
parent8930bdfeb63e47901d4a1de5f1d28f56c88f2026
signaturebadge-check Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

std.Target: only make v9 the baseline for sparc-linux

NetBSD supports older models, for example.

1 files changed, 4 insertions(+), 1 deletions(-)

lib/std/Target.zig+4-1
...@@ -2087,7 +2087,10 @@ pub const Cpu = struct {...@@ -2087,7 +2087,10 @@ pub const Cpu = struct {
2087 .riscv32, .riscv32be => &riscv.cpu.baseline_rv32,2087 .riscv32, .riscv32be => &riscv.cpu.baseline_rv32,
2088 .riscv64, .riscv64be => &riscv.cpu.baseline_rv64,2088 .riscv64, .riscv64be => &riscv.cpu.baseline_rv64,
2089 .s390x => &s390x.cpu.arch11,2089 .s390x => &s390x.cpu.arch11,
2090 .sparc => &sparc.cpu.v9, // glibc does not work with 'plain' v8.2090 .sparc => switch (os.tag) {
2091 .linux => &sparc.cpu.v9, // glibc does not work with 'plain' v8.
2092 else => generic(arch),
2093 },
2091 .sparc64 => &sparc.cpu.ultrasparc,2094 .sparc64 => &sparc.cpu.ultrasparc,
2092 .x86 => &x86.cpu.pentium4,2095 .x86 => &x86.cpu.pentium4,
2093 .x86_64 => switch (os.tag) {2096 .x86_64 => switch (os.tag) {