authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-09-07 01:05:33+02:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2026-09-07 01:29:52+02:00
logf283057bee8874a497908f420c7853606d5c98d2
treecb4e72affb01e208d0229b1be047c7f432005138
parent4eb24f4f8e2e6f226cced6f3691d8e5a9f7de7ac
signature Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

std.os.linux: add HWCAP constants for riscv


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

lib/std/os/linux.zig+9
...@@ -878,6 +878,15 @@ pub const HWCAP = switch (native_arch) {...@@ -878,6 +878,15 @@ pub const HWCAP = switch (native_arch) {
878 pub const ARCH_2_07 = 1 << 31;878 pub const ARCH_2_07 = 1 << 31;
879 };879 };
880 },880 },
881 .riscv32, .riscv64 => struct {
882 pub const ISA_A = 1 << 0;
883 pub const ISA_C = 1 << 2;
884 pub const ISA_D = 1 << 3;
885 pub const ISA_F = 1 << 5;
886 pub const ISA_I = 1 << 8;
887 pub const ISA_M = 1 << 12;
888 pub const ISA_V = 1 << 21;
889 },
881 .s390x => struct {890 .s390x => struct {
882 pub const ESAN3 = 1 << 0;891 pub const ESAN3 = 1 << 0;
883 pub const ZARCH = 1 << 1;892 pub const ZARCH = 1 << 1;