Commit Graph

38432 Commits

Author SHA1 Message Date
Krzysztof Wolicki 964cc8047e stage1: update zig1.wasm
Using wasm-opt version 118.

Signed-off-by: Matthew Lugg <mlugg@mlugg.co.uk>
2026-05-27 10:02:51 +01:00
Krzysztof Wolicki 5ed8e9324e Sema: generate new struct-of-arrays style values in zirTypeInfo 2026-05-27 09:19:51 +01:00
Siddharth Sinha 284ab0ad86 std.Io.Uring: handle ReadOnlyFileSystem in dirOpenDir and dirRealPathFile
f4eecf8d7d added ROFS handling to openat but missed these two read-only
callers, breaking compilation of any Io.Evented program.
2026-05-27 09:42:02 +02:00
Alex Rønne Petersen 333724ff77 Maker.Step.Run: set WASMTIME_BACKTRACE_DETAILS=1 by default for Wasmtime
Similar in spirit to what we do with WINEDEBUG when using Wine, i.e. provide
more helpful defaults.
2026-05-27 07:52:49 +02:00
Alex Rønne Petersen fba9a28a67 ci: bump timeout for aarch64-freebsd and aarch64-netbsd by 1 hour 2026-05-27 03:16:06 +02:00
Alex Rønne Petersen 0a22dae4a7 ci: only run aarch64-freebsd and aarch64-netbsd on master pushes for now 2026-05-27 03:15:30 +02:00
zacoons be7065f7f5 std.Io: fix openSocketPosix ignoring ip6_only option 2026-05-27 03:12:49 +02:00
Andrew Kelley d0c6ed189b Maker: fix Target deserialization
more disciplined Target / Query separation even though they're both
serialized in the same struct
2026-05-27 03:04:31 +02:00
Alan Cocanour 9c56550931 Respect environment variable preference for color in all zig commands
This makes all commands in the zig executable that support color
output respect the user's preference for color output based on the
NO_COLOR and CLICOLOR_FORCE environment variables. Setting color
preference via command line option still overrides preferences set via
environment variables.
2026-05-26 17:56:40 -07:00
Alex Rønne Petersen 3852c8eae4 Revert "test: add x86-freebsd to the module test matrix"
This reverts commit 7451f5d117.

https://codeberg.org/ziglang/zig/actions/runs/3954/jobs/16/attempt/1
2026-05-27 02:34:30 +02:00
pentuppup e4512531d5 fix some missed errors from build system rework 2026-05-27 02:18:25 +02:00
Andrew Kelley 4d56c66362 Merge pull request 'Maker: memory usage optimizations' (#35471) from build-runner-process into master
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/35471
2026-05-27 00:48:11 +02:00
Alex Rønne Petersen 7451f5d117 test: add x86-freebsd to the module test matrix
While it's not supported as a native install architecture anymore, it's still a
supported compatibility target.
2026-05-27 00:28:44 +02:00
Alex Rønne Petersen 197ba11787 std.debug.SelfInfo.Elf: update lists of supported architectures 2026-05-27 00:28:15 +02:00
Alex Rønne Petersen 5c64311fab std.debug.cpu_context: add mcontext_t for x86-freebsd 2026-05-27 00:28:00 +02:00
Alex Rønne Petersen 833c6d9792 std.debug.cpu_context: add missing align(16) on x86_64-freebsd mcontext_t 2026-05-27 00:28:00 +02:00
Alex Rønne Petersen 6aa6a07955 std.debug.cpu_context: add mcontext_t for hppa-linux and hppa64-linux 2026-05-27 00:28:00 +02:00
Alex Rønne Petersen 12790e69a7 std.debug.cpu_context: add mcontext_t for hppa-netbsd 2026-05-27 00:27:06 +02:00
Alex Rønne Petersen 7d5e400911 std.debug.cpu_context: sheb-openbsd doesn't exist 2026-05-26 23:30:48 +02:00
Alex Rønne Petersen f3a7a4c5e2 Merge pull request 'NetBSD 11.0 cross libc support' (#35464) from alexrp/zig:netbsd-11 into master
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/35464
2026-05-26 20:55:53 +02:00
Carl Åstholm fc3406a961 std.debug.Pdb: deduplicate inline source locations
Previously, if the same inline function was called multiple times
by the same caller, the inline function's frame would be repeated
multiple times, once for each prior call.
2026-05-26 20:37:09 +02:00
Andrew Kelley 456b2ec07a forgejo: update the bug template 2026-05-26 11:04:23 -07:00
Jacob Young 5940f65503 lldb: update for upcoming hash map rename 2026-05-26 19:32:01 +02:00
Andrew Kelley e966d0c385 Merge PR 'Fix build script compilation when usize is u32' (#32060)
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/32060
Reviewed-by: Andrew Kelley <andrew@ziglang.org>
2026-05-26 09:54:03 -07:00
Andrew Kelley fd63f57cd8 build system: update more usize to u64 for maxrss
makes the build system compile on 32 bit systems

bonus, also fix incorrectly passing advanced debug options to the maker
process which doesn't care about them
2026-05-26 09:50:48 -07:00
Sertonix 7228dc0ef9 langref: fix compilation if usize is u32 2026-05-26 09:43:40 -07:00
Sertonix 8455563ed8 Fix build script compilation when usize is u32
On 32-bit systems usize is not u64 but it was assumed in multiple places
of the build script.

Sometimes using u64 instead of usize since available and used memory can
exceed usize on 32-bit systems (just like totalSystemMemory)

Example errors:

lib/compiler/build_runner.zig:508:26: error: expected type 'usize', found 'u64'
        .available_rss = max_rss,
                         ^~~~~~~
lib/compiler/build_runner.zig:508:26: note: unsigned 32-bit int cannot represent all possible unsigned 64-bit values
referenced by:
    callMain [inlined]: lib/std/start.zig:699:88
    callMainWithArgs [inlined]: lib/std/start.zig:638:20
    posixCallMainAndExit: lib/std/start.zig:590:38
    2 reference(s) hidden; use '-freference-trace=5' to see all references
lib/std/Build/WebServer.zig:849:38: error: expected type 'usize', found 'u64'
    const buf = gpa.realloc(old_buf, new_len) catch @panic("out of memory");
                                     ^~~~~~~
lib/std/Build/WebServer.zig:849:38: note: unsigned 32-bit int cannot represent all possible unsigned 64-bit values
lib/std/mem/Allocator.zig:399:58: note: parameter type declared here
pub fn realloc(self: Allocator, old_mem: anytype, new_n: usize) Error!@TypeOf(old_mem) {
                                                         ^~~~~
build.zig:548:10: error: type 'usize' cannot represent integer value '9300000000'
        .max_rss = 9_300_000_000,
        ~^~~~~~~~~~~~~~~~~~~~~~~
build.zig:778:10: error: type 'usize' cannot represent integer value '8000000000'
        .max_rss = 8_000_000_000,
        ~^~~~~~~~~~~~~~~~~~~~~~~
2026-05-26 09:43:39 -07:00
Andrew Kelley 33680ced58 CI: switch which script gets --maker-opt=Debug 2026-05-26 09:03:34 -07:00
Andrew Kelley 29df938c22 zig build: add "first time setup" to progress node
when building the maker, so that users who freshly downloaded zig don't
worry that it will take this long every time they run zig build
2026-05-26 09:03:34 -07:00
Andrew Kelley 349053e322 Maker: memory usage optimizations
- choose smp_allocator depending on optimization mode
- organize the globals
- avoid pessimistically allocating failed command string
- recover the PkgConfig memory
- recover the memory from captureChildProcess
- make Step.result_stderr gpa-owned so it doesn't leak when a step that
  fails with stderr is re-run
- recover memory from evalZigTest and evalGeneric child process stdio
  streams
2026-05-26 09:03:34 -07:00
Andrew Kelley 0ff175b69e Merge pull request 'zig build: separate the maker process from the configurer process' (#35428) from build-runner-process into master
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/35428
2026-05-26 18:00:16 +02:00
Alex Rønne Petersen a6275ad16f test: add riscv32-netbsd-none and riscv64-netbsd-none to module test matrix 2026-05-26 15:40:42 +02:00
Alex Rønne Petersen 0b4132b7a7 test: add riscv32-netbsd-none and riscv64-netbsd-none to llvm_targets 2026-05-26 15:40:42 +02:00
Alex Rønne Petersen 6ed30064d3 std.debug.cpu_context: add mcontext_t for riscv32-netbsd and riscv64-netbsd 2026-05-26 15:40:42 +02:00
Alex Rønne Petersen 7c2efe5000 std.zig.target: add riscv32-netbsd-none and riscv64-netbsd-none 2026-05-26 15:40:42 +02:00
Alex Rønne Petersen b2dd1469da std.Target: add dynamic linker path for riscv32-netbsd and riscv64-netbsd 2026-05-26 15:40:42 +02:00
Alex Rønne Petersen 912dd0b451 std.Target: bump max NetBSD version to 11.0 2026-05-26 15:40:42 +02:00
Alex Rønne Petersen 1e2bac6153 libc: update NetBSD headers to 11.0 2026-05-26 15:40:40 +02:00
Huang Zhichao c84f0f49d6 std.os.linux: fix dirfd type in mknodat() 2026-05-26 20:49:56 +08:00
Alex Rønne Petersen 0511b3cc9b libc: update NetBSD abilists to 11.0 2026-05-26 14:35:39 +02:00
Alex Rønne Petersen dbfeb07a17 libc: update NetBSD crt0 to 11.0 2026-05-26 14:35:39 +02:00
Alex Rønne Petersen 66bcba6b9d drop powerpc-netbsd-eabi target support
Turns out this target is very poorly supported upstream and doesn't even build
in NetBSD 11, so let's not pretend to support it.
2026-05-26 14:35:23 +02:00
mlugg 8086ae1769 Merge pull request 'Elf2: more enhancements' (#35447) from elf2 into master
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/35447
2026-05-26 13:13:55 +02:00
Alex Rønne Petersen 11bb8ab9b3 Merge pull request 'std: initial xtensa-linux-none port' (#35463) from alexrp/zig:xtensa-linux into master
Reviewed-on: https://codeberg.org/ziglang/zig/pulls/35463
2026-05-26 12:35:37 +02:00
Alex Rønne Petersen 84a100b3e0 std.os: no longer require libc for xtensa-linux
Not that any of our vendored libcs support xtensa anyway.
2026-05-26 08:11:04 +02:00
Alex Rønne Petersen b0bda2d744 std.Thread: implement LinuxThreadImpl.freeAndExit() for xtensa 2026-05-26 08:11:04 +02:00
Alex Rønne Petersen ecc47695ef std.os.linux: add xtensa arch bits
closes https://codeberg.org/ziglang/zig/issues/30947
2026-05-26 08:11:04 +02:00
Alex Rønne Petersen 0142405f86 std.os.linux.tls: add xtensa support 2026-05-26 08:11:04 +02:00
Alex Rønne Petersen a6ab353532 std.pie: add xtensa support
This might need more work to handle the DT_XTENSA_GOT_LOC_{OFF,SZ} insanity,
but this is at least a start.
2026-05-26 08:11:04 +02:00
Alex Rønne Petersen 5143239e2b std.start: add xtensa support 2026-05-26 08:11:04 +02:00