Skip to content

Commit 179a6e6

Browse files
authored
Merge pull request #20708 from alexrp/target-cleanup-2
`std.Target`: Remove more dead architecture tags.
2 parents 956ba8f + be98413 commit 179a6e6

File tree

8 files changed

+32
-199
lines changed

8 files changed

+32
-199
lines changed

lib/compiler/aro/aro/target.zig

+2-36
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ pub fn intMaxType(target: std.Target) Type {
1717
.riscv64,
1818
.powerpc64,
1919
.powerpc64le,
20-
.tce,
21-
.tcele,
2220
.ve,
2321
=> return .{ .specifier = .long },
2422

@@ -54,8 +52,6 @@ pub fn intPtrType(target: std.Target) Type {
5452
.riscv32,
5553
.xcore,
5654
.hexagon,
57-
.tce,
58-
.tcele,
5955
.m68k,
6056
.spir,
6157
.spirv32,
@@ -153,7 +149,7 @@ pub fn isTlsSupported(target: std.Target) bool {
153149
return supported;
154150
}
155151
return switch (target.cpu.arch) {
156-
.tce, .tcele, .bpfel, .bpfeb, .msp430, .nvptx, .nvptx64, .x86, .arm, .armeb, .thumb, .thumbeb => false,
152+
.bpfel, .bpfeb, .msp430, .nvptx, .nvptx64, .x86, .arm, .armeb, .thumb, .thumbeb => false,
157153
else => true,
158154
};
159155
}
@@ -470,25 +466,18 @@ pub fn get32BitArchVariant(target: std.Target) ?std.Target {
470466
.mipsel,
471467
.powerpc,
472468
.powerpcle,
473-
.r600,
474469
.riscv32,
475470
.sparc,
476471
.sparcel,
477-
.tce,
478-
.tcele,
479472
.thumb,
480473
.thumbeb,
481474
.x86,
482475
.xcore,
483476
.nvptx,
484-
.amdil,
485-
.hsail,
486477
.spir,
487478
.kalimba,
488-
.shave,
489479
.lanai,
490480
.wasm32,
491-
.renderscript32,
492481
.aarch64_32,
493482
.spirv32,
494483
.loongarch32,
@@ -498,13 +487,10 @@ pub fn get32BitArchVariant(target: std.Target) ?std.Target {
498487

499488
.aarch64 => copy.cpu.arch = .arm,
500489
.aarch64_be => copy.cpu.arch = .armeb,
501-
.amdil64 => copy.cpu.arch = .amdil,
502490
.nvptx64 => copy.cpu.arch = .nvptx,
503491
.wasm64 => copy.cpu.arch = .wasm32,
504-
.hsail64 => copy.cpu.arch = .hsail,
505492
.spir64 => copy.cpu.arch = .spir,
506493
.spirv64 => copy.cpu.arch = .spirv32,
507-
.renderscript64 => copy.cpu.arch = .renderscript32,
508494
.loongarch64 => copy.cpu.arch = .loongarch32,
509495
.mips64 => copy.cpu.arch = .mips,
510496
.mips64el => copy.cpu.arch = .mipsel,
@@ -529,12 +515,8 @@ pub fn get64BitArchVariant(target: std.Target) ?std.Target {
529515
.lanai,
530516
.m68k,
531517
.msp430,
532-
.r600,
533-
.shave,
534518
.sparcel,
535519
.spu_2,
536-
.tce,
537-
.tcele,
538520
.xcore,
539521
.xtensa,
540522
=> return null,
@@ -544,13 +526,10 @@ pub fn get64BitArchVariant(target: std.Target) ?std.Target {
544526
.amdgcn,
545527
.bpfeb,
546528
.bpfel,
547-
.amdil64,
548529
.nvptx64,
549530
.wasm64,
550-
.hsail64,
551531
.spir64,
552532
.spirv64,
553-
.renderscript64,
554533
.loongarch64,
555534
.mips64,
556535
.mips64el,
@@ -564,17 +543,14 @@ pub fn get64BitArchVariant(target: std.Target) ?std.Target {
564543
=> {}, // Already 64 bit
565544

566545
.aarch64_32 => copy.cpu.arch = .aarch64,
567-
.amdil => copy.cpu.arch = .amdil64,
568546
.arm => copy.cpu.arch = .aarch64,
569547
.armeb => copy.cpu.arch = .aarch64_be,
570-
.hsail => copy.cpu.arch = .hsail64,
571548
.loongarch32 => copy.cpu.arch = .loongarch64,
572549
.mips => copy.cpu.arch = .mips64,
573550
.mipsel => copy.cpu.arch = .mips64el,
574551
.nvptx => copy.cpu.arch = .nvptx64,
575552
.powerpc => copy.cpu.arch = .powerpc64,
576553
.powerpcle => copy.cpu.arch = .powerpc64le,
577-
.renderscript32 => copy.cpu.arch = .renderscript64,
578554
.riscv32 => copy.cpu.arch = .riscv64,
579555
.sparc => copy.cpu.arch = .sparc64,
580556
.spir => copy.cpu.arch = .spir64,
@@ -620,16 +596,13 @@ pub fn toLLVMTriple(target: std.Target, buf: []u8) []const u8 {
620596
.powerpcle => "powerpcle",
621597
.powerpc64 => "powerpc64",
622598
.powerpc64le => "powerpc64le",
623-
.r600 => "r600",
624599
.amdgcn => "amdgcn",
625600
.riscv32 => "riscv32",
626601
.riscv64 => "riscv64",
627602
.sparc => "sparc",
628603
.sparc64 => "sparc64",
629604
.sparcel => "sparcel",
630605
.s390x => "s390x",
631-
.tce => "tce",
632-
.tcele => "tcele",
633606
.thumb => "thumb",
634607
.thumbeb => "thumbeb",
635608
.x86 => "i386",
@@ -638,21 +611,14 @@ pub fn toLLVMTriple(target: std.Target, buf: []u8) []const u8 {
638611
.xtensa => "xtensa",
639612
.nvptx => "nvptx",
640613
.nvptx64 => "nvptx64",
641-
.amdil => "amdil",
642-
.amdil64 => "amdil64",
643-
.hsail => "hsail",
644-
.hsail64 => "hsail64",
645614
.spir => "spir",
646615
.spir64 => "spir64",
647616
.spirv32 => "spirv32",
648617
.spirv64 => "spirv64",
649618
.kalimba => "kalimba",
650-
.shave => "shave",
651619
.lanai => "lanai",
652620
.wasm32 => "wasm32",
653621
.wasm64 => "wasm64",
654-
.renderscript32 => "renderscript32",
655-
.renderscript64 => "renderscript64",
656622
.ve => "ve",
657623
// Note: spu_2 is not supported in LLVM; this is the Zig arch name
658624
.spu_2 => "spu_2",
@@ -668,7 +634,7 @@ pub fn toLLVMTriple(target: std.Target, buf: []u8) []const u8 {
668634
.freebsd => "freebsd",
669635
.fuchsia => "fuchsia",
670636
.linux => "linux",
671-
.lv2 => "lv2",
637+
.ps3 => "lv2",
672638
.netbsd => "netbsd",
673639
.openbsd => "openbsd",
674640
.solaris => "solaris",

0 commit comments

Comments
 (0)