d0911786c9
Merge pull request #22397 from Techatrix/type-safe-ast
...
improve type safety of std.zig.Ast
2025-03-12 02:22:41 +00:00
982c500be5
Merge pull request #23188 from jacobly0/fix-23143
...
x86_64: fix crashes with symbols
2025-03-11 16:11:09 -04:00
423907c270
Sema: fix handling of @This()
on opaques
...
Resolves : #22869
2025-03-11 13:13:52 +00:00
cff90e3ae0
x86_64: implement select of register mask
2025-03-10 10:38:33 -04:00
8e0a4ca4b3
Enable compiler-rt tests for wasm32-wasi
...
I think the underlying issue was the same as
https://github.com/ziglang/zig/issues/13258 and that has a work-around in
LLVM 19 (see https://github.com/llvm/llvm-project/issues/58557 ).
Fixes #15325
2025-03-10 06:15:12 +01:00
539f3effd3
Merge pull request #21933 from kcbanner/comptime_nan_comparison
...
Fix float vector comparisons with signed zero and NaN, add test coverage
2025-03-09 15:06:25 -04:00
0bce4a4e05
Sema: handle generated tag enums in union field order check
...
Fixes #23059
The "note: enum field here" now references the field in the base union type rather than crashing.
2025-03-08 14:29:20 -05:00
5c57e90ffb
test: Disable test-elf-ld-script-path-error
for now.
...
https://github.com/ziglang/zig/issues/23125
2025-03-08 07:04:27 +01:00
de9c889a0e
aro_translate_c: fix ast lowering of continue node
...
fixes #22601
2025-03-07 22:20:35 +01:00
144d69b571
test: add comptime memoization tests for bit-for-bit float equality
2025-03-04 23:31:12 -05:00
8eefc4c5c2
test: skip the float vector cmp tests on failing targets
2025-03-04 23:31:08 -05:00
79460d4a3e
Remove uses of deprecated callconv aliases
2025-03-05 03:01:43 +00:00
c76f451abc
Merge pull request #22979 from mlugg/remove-legacy-coercions
...
Sema: remove legacy coercion
2025-03-03 22:18:28 +00:00
501e84a96a
incremental: invalidate namespace dependencies when a name changes visibility
...
We could have more fine-grained dependencies here, but I think this is
fine for now.
2025-03-03 22:18:02 +00:00
71d0d4bbfe
test: separate out float vector tests and skip them on unsupported backends
2025-03-03 15:35:07 -05:00
981f84157c
Value: fix comparison of NaN in compareHeteroAdvanaced
...
Sema: fix equality comparison of signed zeroes and NaN in compareScalar
tests: add test coverage for vector float comparisons
2025-03-03 15:35:07 -05:00
a6525c1762
Merge pull request #22529 from xtexx/x86-64/shl-sat-int
...
ci / x86_64-linux-debug (push) Waiting to run
ci / x86_64-linux-release (push) Waiting to run
ci / aarch64-linux-debug (push) Waiting to run
ci / aarch64-linux-release (push) Waiting to run
ci / x86_64-macos-release (push) Waiting to run
ci / aarch64-macos-debug (push) Waiting to run
ci / aarch64-macos-release (push) Waiting to run
ci / x86_64-windows-debug (push) Waiting to run
ci / x86_64-windows-release (push) Waiting to run
x86_64: Implement integer saturating left shifting codegen
2025-03-02 02:51:36 -05:00
1da909a1e2
x86_64: add behavior tests for saturating shift left
...
Co-authored-by: Jacob Young <jacobly0@users.noreply.github.com>
Signed-off-by: Bingwu Zhang <xtex@aosc.io>
2025-03-02 10:30:43 +08:00
4e32193de3
x86_64: implement integer saturating left shifting codegen
...
Simliarly to shl_with_overflow, we first SHL/SAL the integer, then
SHR/SAR it back to compare if overflow happens.
If overflow happened, set result to the upper limit to make it saturating.
Bug: #17645
Co-authored-by: Jacob Young <jacobly0@users.noreply.github.com>
Signed-off-by: Bingwu Zhang <xtex@aosc.io>
2025-03-02 10:30:32 +08:00
50b40c9621
x86_64: rewrite wrapping add/sub
2025-03-01 16:29:22 -05:00
6b6c1b1b0e
Revert "Merge pull request #22898 from kristoff-it/deprecated-proposal"
...
This reverts commit dea72d15da4fba909dc3ccb2e9dc5286372ac023, reversing
changes made to ab381933c87bcc744058d25a876cfdc0d23fc674.
The changeset does not work as advertised and does not have sufficient
test coverage.
Reopens #22822
2025-02-28 01:37:10 -08:00
f74a856d84
reword deprecated error slightly
...
"found" -> "reached" to match "reached unreachable code"
2025-02-26 14:41:33 -05:00
7c2649f89d
langref: fix whitespace
2025-02-26 14:41:33 -05:00
25790e95f1
@deprecated
: remove per-module flag in Build
...
This implementation looks at the builder of each
module in the build graph instead of storing a
boolean for each module.
2025-02-26 14:41:33 -05:00
c75fdd96d2
@deprecated
: add tests
2025-02-26 14:41:33 -05:00
c45dcd013b
Merge pull request #22488 from Rexicon226/ubsan-rt
...
implement a ubsan runtime for better error messages
2025-02-26 03:08:36 -05:00
3aaf394249
test: remove dependencies on legacy coercion
2025-02-26 00:17:09 +00:00
84da520c44
Sema: remove legacy coercion
...
This was meant to be removed in #21817 , but was somehow missed.
2025-02-26 00:17:09 +00:00
3fcb4408a5
AstGen: improve 'file cannot be a tuple' source location
...
Instead of just reporting this on token 0, report it on the first
tuple-like field.
2025-02-25 22:28:47 +00:00
ca83f52fd9
ubsan: update wording
2025-02-25 11:22:33 -08:00
44d3b5a6e4
build: add comments explaining why we disable ubsan
2025-02-25 11:22:33 -08:00
35b9db3b15
correct some bugs
2025-02-25 11:22:33 -08:00
aec0f9b3e7
test: skip failing tests with spirv-vulkan
2025-02-24 19:39:42 +01:00
181a89e728
build: add spirv to test matrix
...
Signed-off-by: Ali Cheraghi <alichraghi@proton.me>
2025-02-24 19:12:38 +01:00
5e20e9b449
Sema: allow @ptrCast
of slices changing the length
...
Also, refactor `Sema.ptrCastFull` to not be a horrifying hellscape.
2025-02-23 08:28:58 +00:00
220f80e71d
Dwarf: fix lowering of comptime-only optional pointer null
values
...
Closes #22974
2025-02-22 22:47:32 -05:00
84aac8b6c7
Type: resolve union tag type before checking for runtime bits
2025-02-22 22:22:55 -05:00
eb3c7f5706
zig build fmt
2025-02-22 17:09:20 -08:00
b6a1fdd3fa
tests: disable failing tests
...
These were previously incremental tests, so weren't running. They didn't
*need* to be incremental. They worked under the old runner because of
how it directly integrated with the compiler so tracked error messages
differently.
2025-02-23 00:52:50 +00:00
a3b3a33d7a
cases: remove old incremental case system
...
We now run incremental tests with `tools/incr-check.zig` (with the
actual cases being in `test/incremental/`).
2025-02-23 00:52:50 +00:00
b25d93e7d9
stage2-wasm: implement switch_dispatch + handle > 32 bit integers in switches
...
Updated solution is future proof for arbitary size integer handling for both strategies .br_table lowering if switch case is dense, .br_if base jump table if values are too sparse.
2025-02-22 18:34:00 -05:00
61b69a418d
Merge pull request #22659 from ifreund/linker-script-fix
...
link: fix ambiguous names in linker scripts
2025-02-22 18:18:24 -05:00
36fc2d2607
AstGen: make layout specifiers on opaque containers a compile error
2025-02-22 17:21:34 -05:00
f87b443af1
link.MachO: Add support for the -x flag (discard local symbols).
...
This can also be extended to ELF later as it means roughly the same thing there.
This addresses the main issue in #21721 but as I don't have a macOS machine to
do further testing on, I can't confirm whether zig cc is able to pass the entire
cgo test suite after this commit. It can, however, cross-compile a basic program
that uses cgo to x86_64-macos-none which previously failed due to lack of -x
support. Unlike previously, the resulting symbol table does not contain local
symbols (such as C static functions).
I believe this satisfies the related donor bounty: https://ziglang.org/news/second-donor-bounty
2025-02-22 06:35:19 +01:00
a7467b9bb2
Merge pull request #22941 from Techatrix/config-header
...
std.Build.Step.ConfigHeader: improve handling of autoconf style headers
2025-02-22 00:25:09 -05:00
300cb4881f
x86_64: rewrite scalar @bitReverse
2025-02-22 00:05:47 -05:00
fc7a0c4878
Sema: Fix fnptr alignment safety checks to account for potential ISA tag.
...
As seen on e.g. Arm/Thumb and MIPS (MIPS16/microMIPS).
Fixes #22888 .
2025-02-22 04:12:46 +01:00
a8d3760c5b
added compile_error test coverage for issue 17166
2025-02-21 07:00:37 +01:00
253e641ea3
test: Disable packet timeout for debugger tests.
...
On my machine, the defaults are 5 seconds (LLDB) and 2 seconds (GDB). These are
too low on the CI machines during high load, and the CI system itself already
enforces a timeout on jobs anyway, so just disable the timeout altogether.
2025-02-20 21:39:54 +01:00
dbc886fd04
translate-c: fix division and modulo of >8-bit stdint.h types in macros
...
Broke in c616141241047d6d6c811d43f644eb1b7d2b26ce and e64eef366c68592f6daf063a8b8f85b8626a1598
2025-02-20 13:33:59 +02:00