Jacob Young
16d31ceed5
x86_64: fix reduce evaluation order
...
Closes #37197
2026-10-13 09:47:51 +02:00
Alex Rønne Petersen
7a7b944ef8
std.Target: remove hermit OS tag
...
Hermit is a unikernel with no stable syscall ABI; you must link its syscall
library statically to perform syscalls. Due to the way the project's build
system works, that means using Rust/Cargo. As such, it makes essentially zero
sense for Zig to support this target.
2026-10-12 14:35:23 +02:00
Guy Fischman
070276d8f1
compiler: add x86_64, aarch64, riscv, and loongarch preserve_most calling convention support
2026-10-12 10:49:23 +02:00
Alex Rønne Petersen
993c758456
Merge pull request 'Elf2: more SPARC relocations' ( #37191 ) from alexrp/zig:elf2-sparc into master
...
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/37191
2026-10-12 10:26:39 +02:00
Giuseppe Cesarano
4ed10da2cf
Fixed x86_64-SysV ABI when registers are exhausted ( #36615 )
...
Fixes the original bug and another class (?) of bugs that I found while reading the file.
In some places where `iterateParamTypes` was called and when the `sret` return strategy was used, the `llvm.index` wasn't incremented. This index was also used to determine whether the lowering for composed types should be `.byref` or `.multiple_llvm_types`.
The missing increments caused the mismatch in the original bug report.
The second issue that this PR addresses is the use of `llvm_index` to select the lowering for such composed types. Basically, a function with 7 or more floats would cause the `llvm_index` to grow to 7. The following check would then trigger: `if (it.llvm_index + classes_len > 6) {...}`, forcing the lowering to `.byref`.
The problem is that if the 8th argument would have fitted in the GPRs (or even the FPU registers), this lowering would be incorrect.
Closes #36581
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/36615
Reviewed-by: Andrew Kelley <andrew@ziglang.org >
2026-10-12 09:35:39 +02:00
Alex Rønne Petersen
d4984092a3
test: add sparc64-openbsd-none to module tests
2026-10-11 15:00:50 +02:00
Alex Rønne Petersen
38c1536b96
test-standalone: respect -Dskip-non-native in cross-compiling tests
...
closes https://github.com/ziglang/zig/issues/25471
2026-10-10 08:36:08 +02:00
Alex Rønne Petersen
93316d6e61
std.zig.target: move isNative() here from test harness
2026-10-10 08:36:08 +02:00
Alex Rønne Petersen
03422925b1
test-standalone: resurrect tsan test
...
closes https://github.com/ziglang/zig/issues/25471
2026-10-10 08:36:08 +02:00
Alex Rønne Petersen
40cde789f7
test-standalone: remove some dead #ifdefs in c_compiler
2026-10-10 08:36:08 +02:00
Alex Rønne Petersen
1b2f003f06
test: move issue_7030 from test-standalone simple cases to test-cases
2026-10-10 08:36:08 +02:00
Alex Rønne Petersen
4fb39f82c2
test: move some test-standalone simple tests to test-cases
2026-10-10 08:36:08 +02:00
Alex Rønne Petersen
40a50f5e2c
test: move issue_12706 from test-standalone to test-c-abi
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
47a2437afb
test-standalone: remove strip_struct_init
...
We have stripped variants in the module test matrix, and I don't think the test
code here provides useful coverage on its own.
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
03d537b303
test-standalone: remove issue_5825
...
This doesn't provide any coverage we don't already have in various other places.
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
c3cb062d03
test-standalone: remove issue_339
...
I don't think this provides any useful coverage nowadays.
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
a3fe5cb793
test-standalone: remove zerolength_check
...
We don't need this anymore since our baseline CPU model for wasm is lime1.
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
cc410eaf34
test-standalone: remove compiler_rt_panic
...
It's not obvious to me what this was testing and it wasn't properly hooked up
to the test_step anyway.
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
41ca6e8657
test-standalone: remove issue_9402 from simple
...
I do not think we need to add tests like this whenever new functions are added
to MinGW-w64. We have plans for more sophisticated C ABI tooling.
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
5514aa95fa
test-standalone: remove stale comment in simple
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
562f265d39
test-standalone: remove orphan has_basename.zig in dirname
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
c3ee048475
test-cases: remove hello_world.zig
...
Covered by test/standalone/simple/hello_world/*.
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
78dbc6fab8
test: move strip_empty_loop from test-standalone to test-behavior
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
d7061f3378
test: move empty_global_error_set from test-standalone to test-cases
2026-10-10 08:36:07 +02:00
Alex Rønne Petersen
72388e28e4
test: remove orphan gen_h.zig
2026-10-10 08:36:07 +02:00
Andrew Kelley
0fd39f9e92
Merge pull request 'AstGen: increment baseline when inside backing tag' ( #37074 ) from sinon/zig:astgen-offset-fix into master
...
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/37074
Reviewed-by: Andrew Kelley <andrew@ziglang.org >
2026-10-10 08:28:33 +02:00
Andrew Kelley
2556cae454
Merge pull request 'default to LLVM and ReleaseSafe for fuzzing' ( #36108 ) from gooncreeper/zig:fuzzing-default-llvm into master
...
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/36108
Reviewed-by: Andrew Kelley <andrew@ziglang.org >
2026-10-10 02:30:34 +02:00
pentuppup
f46b6501a2
AstGen: give result type to slice by length sentinel
2026-10-10 00:27:07 +02:00
pentuppup
85c863e348
Sema: fix array sentinel being discarded when coerced to slice
2026-10-10 00:22:23 +02:00
Andrew Kelley
4a7f1339ac
Merge pull request 'InternPool: inherit captures from owner union in generated enums' ( #37043 ) from pentuppup/zig:push-srptskmumtto into master
...
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/37043
Reviewed-by: Andrew Kelley <andrew@ziglang.org >
2026-10-10 00:20:25 +02:00
David Rubin
6ec81be545
Sema: account for inlined blocks in comptime break
2026-10-10 00:18:27 +02:00
David Rubin
09eb81de8b
AstGen: increment baseline when inside backing tag
2026-10-09 10:15:11 +02:00
Kendall Condon
aa8c774e0f
allow standardOptimizeOption to return null
...
In order to allow the compiler to default to ReleaseSafe when compiling
for fuzzing, Build.standardOptimizeOption has been changed to return an
optional value.
2026-10-09 10:14:16 +02:00
Kendall Condon
7287181ff5
AstGen: add missing cursor restores
2026-10-09 10:09:42 +02:00
Kendall Condon
9195b36a6c
AstGen: move error capture asserts outside loop
2026-10-09 10:09:42 +02:00
Kendall Condon
b7b6d66675
AstGen: properly advance cursor for decl qualifiers
...
Reorders the parsing code so the expressions are parsed in the same
order as in source and removes unnecessary cursor restores when parsing
function qualifiers.
2026-10-09 10:09:42 +02:00
Alex Rønne Petersen
35accc06ed
test: don't claim compatibility for 32-bit RISC-V on 64-bit RISC-V
2026-10-09 09:33:50 +02:00
Alex Rønne Petersen
40a0d70b81
test: don't claim compatibility for 32-bit ARM on AArch64
2026-10-09 09:26:33 +02:00
Alex Rønne Petersen
f587d753d1
test: remove max_rss special cases
2026-10-08 13:53:06 +02:00
Alex Rønne Petersen
25a375d358
test: don't compare aarch64/arm feature sets in isNative()
...
They are distinct families with their own feature bits.
2026-10-08 13:52:53 +02:00
Alex Rønne Petersen
5e96f6e102
test: refactor compatible32bitArch() -> supportedCompatArch()
...
Also fix some inaccuracies in it.
2026-10-08 13:52:53 +02:00
Jacob Young
54a25d8256
Type: fix vector size mismatch vs clang
...
This operation used to be implied by the old incorrect alignment
calculation, but seems to apply even when the alignment is saturated.
Closes #37110
2026-10-08 01:15:20 +02:00
Alex Rønne Petersen
1ce5af228f
test-libc-nsz: disable expl.c
...
Fails with LLVM 23:
========= expected this stdout: =========
========= but found: ====================
/home/alexrp/Sources/libc-test/src/math/special/expl.h:38: bad fp exception: RN expl(-0x1p+14)=0x0p+0, want INEXACT|UNDERFLOW got 0
/home/alexrp/Sources/libc-test/src/math/special/expl.h:38: RN expl(-0x1p+14) want 0x0p+0 got 0x1p-16384 ulperr 2305843009213693952.000 = 0x1p+61 + -0x0p+0
2026-10-07 00:30:52 +02:00
Alex Rønne Petersen
b2456e5d07
test-libc-nsz: disable logb[f,l].c
...
Fails with LLVM 23:
========= expected this stdout: =========
========= but found: ====================
/home/alexrp/Sources/libc-test/src/math/special/logbf.h:1: bad fp exception: RN logbf(0x0p+0)=-inf, want DIVBYZERO got 0
/home/alexrp/Sources/libc-test/src/math/special/logbf.h:2: bad fp exception: RN logbf(-0x0p+0)=-inf, want DIVBYZERO got 0
2026-10-07 00:30:52 +02:00
Alex Rønne Petersen
19413602e0
test-libc-nsz: include target triple in run step name
2026-10-07 00:30:52 +02:00
Alex Rønne Petersen
854f444fc2
test: add riscv64-hurd-gnu to llvm_targets
2026-10-07 00:30:52 +02:00
Alex Rønne Petersen
8c06a8dc8f
compiler: add loongarch(32,64)_preserve_none calling convention support
2026-10-07 00:30:52 +02:00
Alex Rønne Petersen
e4ad3e963e
test-behavior: re-enable float vector cmp tests on powerpc64
2026-10-07 00:30:52 +02:00
Alex Rønne Petersen
02488d96d6
test: re-enable stack protector for compiler-rt and libc tests on non-PowerPC
...
PowerPC is still affected by https://github.com/llvm/llvm-project/issues/195561 .
closes https://codeberg.org/ziglang/zig/issues/31702
2026-10-07 00:30:52 +02:00
Alex Rønne Petersen
4bf080551c
Revert "llvm: workaround crash on large inline memset"
...
This reverts commit 84c2d809ec .
closes https://codeberg.org/ziglang/zig/issues/31701
2026-10-07 00:30:52 +02:00