From b5861193e072ba6780730a559f2b879378b8587f Mon Sep 17 00:00:00 2001 From: Meghan Denny Date: Thu, 28 Jul 2022 13:47:29 -0700 Subject: [PATCH] std: rename std.Target.systemz to .s390x --- CMakeLists.txt | 2 +- lib/std/target.zig | 10 +++++----- lib/std/target/{systemz.zig => s390x.zig} | 0 tools/update_cpu_features.zig | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) rename lib/std/target/{systemz.zig => s390x.zig} (100%) diff --git a/CMakeLists.txt b/CMakeLists.txt index ffbf12dbc0..96d10f1e83 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -670,7 +670,7 @@ set(ZIG_STAGE2_SOURCES "${CMAKE_SOURCE_DIR}/lib/std/target/powerpc.zig" "${CMAKE_SOURCE_DIR}/lib/std/target/riscv.zig" "${CMAKE_SOURCE_DIR}/lib/std/target/sparc.zig" - "${CMAKE_SOURCE_DIR}/lib/std/target/systemz.zig" + "${CMAKE_SOURCE_DIR}/lib/std/target/s390x.zig" "${CMAKE_SOURCE_DIR}/lib/std/target/wasm.zig" "${CMAKE_SOURCE_DIR}/lib/std/target/x86.zig" "${CMAKE_SOURCE_DIR}/lib/std/Thread.zig" diff --git a/lib/std/target.zig b/lib/std/target.zig index f026b0da21..d15eae7dc5 100644 --- a/lib/std/target.zig +++ b/lib/std/target.zig @@ -453,7 +453,7 @@ pub const Target = struct { pub const riscv = @import("target/riscv.zig"); pub const sparc = @import("target/sparc.zig"); pub const spirv = @import("target/spirv.zig"); - pub const systemz = @import("target/systemz.zig"); + pub const s390x = @import("target/s390x.zig"); pub const ve = @import("target/ve.zig"); pub const wasm = @import("target/wasm.zig"); pub const x86 = @import("target/x86.zig"); @@ -1178,7 +1178,7 @@ pub const Target = struct { .amdgcn => "amdgpu", .riscv32, .riscv64 => "riscv", .sparc, .sparc64, .sparcel => "sparc", - .s390x => "systemz", + .s390x => "s390x", .i386, .x86_64 => "x86", .nvptx, .nvptx64 => "nvptx", .wasm32, .wasm64 => "wasm", @@ -1202,7 +1202,7 @@ pub const Target = struct { .riscv32, .riscv64 => &riscv.all_features, .sparc, .sparc64, .sparcel => &sparc.all_features, .spirv32, .spirv64 => &spirv.all_features, - .s390x => &systemz.all_features, + .s390x => &s390x.all_features, .i386, .x86_64 => &x86.all_features, .nvptx, .nvptx64 => &nvptx.all_features, .ve => &ve.all_features, @@ -1226,7 +1226,7 @@ pub const Target = struct { .amdgcn => comptime allCpusFromDecls(amdgpu.cpu), .riscv32, .riscv64 => comptime allCpusFromDecls(riscv.cpu), .sparc, .sparc64, .sparcel => comptime allCpusFromDecls(sparc.cpu), - .s390x => comptime allCpusFromDecls(systemz.cpu), + .s390x => comptime allCpusFromDecls(s390x.cpu), .i386, .x86_64 => comptime allCpusFromDecls(x86.cpu), .nvptx, .nvptx64 => comptime allCpusFromDecls(nvptx.cpu), .ve => comptime allCpusFromDecls(ve.cpu), @@ -1287,7 +1287,7 @@ pub const Target = struct { .riscv64 => &riscv.cpu.generic_rv64, .sparc, .sparcel => &sparc.cpu.generic, .sparc64 => &sparc.cpu.v9, // 64-bit SPARC needs v9 as the baseline - .s390x => &systemz.cpu.generic, + .s390x => &s390x.cpu.generic, .i386 => &x86.cpu.i386, .x86_64 => &x86.cpu.x86_64, .nvptx, .nvptx64 => &nvptx.cpu.sm_20, diff --git a/lib/std/target/systemz.zig b/lib/std/target/s390x.zig similarity index 100% rename from lib/std/target/systemz.zig rename to lib/std/target/s390x.zig diff --git a/tools/update_cpu_features.zig b/tools/update_cpu_features.zig index 3757b56743..c43799d280 100644 --- a/tools/update_cpu_features.zig +++ b/tools/update_cpu_features.zig @@ -793,7 +793,7 @@ const llvm_targets = [_]LlvmTarget{ .td_name = "Sparc.td", }, .{ - .zig_name = "systemz", + .zig_name = "s390x", .llvm_name = "SystemZ", .td_name = "SystemZ.td", },