authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2024-07-21 14:33:22+02:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2024-07-21 22:38:30+02:00
log84e9aec13f0c0bd5e30286493dfdf9fb7665aaf1
treed072d27f1792d6f7452ae89062150f7988b0d7af
parentdb8bc4770c37470e8807c21571d483e3a73f9f69
signaturebadge-check Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

std.Target: Add comments for deliberately omitted/removed LLVM tags.


1 files changed, 21 insertions(+), 0 deletions(-)

lib/std/Target.zig+21
...@@ -63,6 +63,11 @@ pub const Os = struct {...@@ -63,6 +63,11 @@ pub const Os = struct {
63 illumos,63 illumos,
64 other,64 other,
6565
66 // LLVM tags deliberately omitted:
67 // - kfreebsd
68 // - darwin
69 // - nacl
70
66 pub inline fn isDarwin(tag: Tag) bool {71 pub inline fn isDarwin(tag: Tag) bool {
67 return switch (tag) {72 return switch (tag) {
68 .ios, .macos, .watchos, .tvos, .visionos => true,73 .ios, .macos, .watchos, .tvos, .visionos => true,
...@@ -653,6 +658,10 @@ pub const Abi = enum {...@@ -653,6 +658,10 @@ pub const Abi = enum {
653 amplification,658 amplification,
654 ohos,659 ohos,
655660
661 // LLVM tags deliberately omitted:
662 // - gnuf64
663 // - coreclr
664
656 pub fn default(arch: Cpu.Arch, os: Os) Abi {665 pub fn default(arch: Cpu.Arch, os: Os) Abi {
657 return if (arch.isWasm()) .musl else switch (os.tag) {666 return if (arch.isWasm()) .musl else switch (os.tag) {
658 .freestanding,667 .freestanding,
...@@ -1021,6 +1030,18 @@ pub const Cpu = struct {...@@ -1021,6 +1030,18 @@ pub const Cpu = struct {
1021 ve,1030 ve,
1022 spu_2,1031 spu_2,
10231032
1033 // LLVM tags deliberately omitted:
1034 // - r600
1035 // - le32
1036 // - le64
1037 // - amdil
1038 // - amdil64
1039 // - hsail
1040 // - hsail64
1041 // - shave
1042 // - renderscript32
1043 // - renderscript64
1044
1024 pub inline fn isX86(arch: Arch) bool {1045 pub inline fn isX86(arch: Arch) bool {
1025 return switch (arch) {1046 return switch (arch) {
1026 .x86, .x86_64 => true,1047 .x86, .x86_64 => true,