authorgravatar for michael.dusan@gmail.comMichael Dusan <michael.dusan@gmail.com> 2021-05-24 10:51:02-04:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2021-05-24 13:38:47-04:00
log8cebbc352ab7ec324891fec222f317f02aba45d7
tree0069ed8ecff5459268ba1a075abba96705216c18
parent1dc7764f2ddc2f3bd78f96017fd2dd2227280055

housekeeping: builtin.arch → builtin.cpu.arch


6 files changed, 9 insertions(+), 9 deletions(-)

lib/std/c/minix.zig+1-1
......@@ -13,7 +13,7 @@ pub const pthread_cond_t = extern struct {
1313const __SIZEOF_PTHREAD_COND_T = 48;
1414const __SIZEOF_PTHREAD_MUTEX_T = switch (builtin.abi) {
1515 .musl, .musleabi, .musleabihf => if (@sizeOf(usize) == 8) 40 else 24,
16 .gnu, .gnuabin32, .gnuabi64, .gnueabi, .gnueabihf, .gnux32 => switch (builtin.arch) {
16 .gnu, .gnuabin32, .gnuabi64, .gnueabi, .gnueabihf, .gnux32 => switch (builtin.cpu.arch) {
1717 .aarch64 => 48,
1818 .x86_64 => if (builtin.abi == .gnux32) 40 else 32,
1919 .mips64, .powerpc64, .powerpc64le, .sparcv9 => 40,
lib/std/c/netbsd.zig+3-3
......@@ -56,7 +56,7 @@ pub const pthread_cond_t = extern struct {
5656
5757pub const pthread_rwlock_t = extern struct {
5858 ptr_magic: c_uint = 0x99990009,
59 ptr_interlock: switch (std.builtin.arch) {
59 ptr_interlock: switch (std.builtin.cpu.arch) {
6060 .aarch64, .sparc, .x86_64, .i386 => u8,
6161 .arm, .powerpc => c_int,
6262 else => unreachable,
......@@ -70,7 +70,7 @@ pub const pthread_rwlock_t = extern struct {
7070 ptr_private: ?*c_void = null,
7171};
7272
73const pthread_spin_t = switch (builtin.arch) {
73const pthread_spin_t = switch (builtin.cpu.arch) {
7474 .aarch64, .aarch64_be, .aarch64_32 => u8,
7575 .mips, .mipsel, .mips64, .mips64el => u32,
7676 .powerpc, .powerpc64, .powerpc64le => i32,
......@@ -81,7 +81,7 @@ const pthread_spin_t = switch (builtin.arch) {
8181 else => @compileError("undefined pthread_spin_t for this arch"),
8282};
8383
84const padded_pthread_spin_t = switch (builtin.arch) {
84const padded_pthread_spin_t = switch (builtin.cpu.arch) {
8585 .i386, .x86_64 => u32,
8686 .sparc, .sparcel, .sparcv9 => u32,
8787 else => pthread_spin_t,
lib/std/os/bits/haiku.zig+1-1
......@@ -858,7 +858,7 @@ pub const EOWNERDEAD = 96; // Previous owner died
858858
859859pub const ELAST = 96; // Must be equal largest errno
860860
861pub const MINSIGSTKSZ = switch (builtin.arch) {
861pub const MINSIGSTKSZ = switch (builtin.cpu.arch) {
862862 .i386, .x86_64 => 2048,
863863 .arm, .aarch64 => 4096,
864864 else => @compileError("MINSIGSTKSZ not defined for this architecture"),
lib/std/os/bits/netbsd.zig+1-1
......@@ -841,7 +841,7 @@ pub const ucontext_t = extern struct {
841841 stack: stack_t,
842842 mcontext: mcontext_t,
843843 __pad: [
844 switch (builtin.arch) {
844 switch (builtin.cpu.arch) {
845845 .i386 => 4,
846846 .mips, .mipsel, .mips64, .mips64el => 14,
847847 .arm, .armeb, .thumb, .thumbeb => 1,
lib/std/os/linux/bpf/kern.zig+1-1
......@@ -5,7 +5,7 @@
55// and substantial portions of the software.
66const std = @import("../../../std.zig");
77
8const in_bpf_program = switch (std.builtin.arch) {
8const in_bpf_program = switch (std.builtin.cpu.arch) {
99 .bpfel, .bpfeb => true,
1010 else => false,
1111};
lib/std/os/linux/start_pie.zig+2-2
......@@ -9,7 +9,7 @@ const R_ARM_RELATIVE = 23;
99const R_AARCH64_RELATIVE = 1027;
1010const R_RISCV_RELATIVE = 3;
1111
12const ARCH_RELATIVE_RELOC = switch (builtin.arch) {
12const ARCH_RELATIVE_RELOC = switch (builtin.cpu.arch) {
1313 .i386 => R_386_RELATIVE,
1414 .x86_64 => R_AMD64_RELATIVE,
1515 .arm => R_ARM_RELATIVE,
......@@ -21,7 +21,7 @@ const ARCH_RELATIVE_RELOC = switch (builtin.arch) {
2121// Just a convoluted (but necessary) way to obtain the address of the _DYNAMIC[]
2222// vector as PC-relative so that we can use it before any relocation is applied
2323fn getDynamicSymbol() [*]elf.Dyn {
24 const addr = switch (builtin.arch) {
24 const addr = switch (builtin.cpu.arch) {
2525 .i386 => asm volatile (
2626 \\ .weak _DYNAMIC
2727 \\ .hidden _DYNAMIC