Commit Graph

13266 Commits

Author SHA1 Message Date
Alex Rønne Petersen c792ebfee2 std.start: add microblaze support 2025-10-23 09:27:17 +02:00
Alex Rønne Petersen 252e1fd7ec std.start: add alpha support 2025-10-23 09:27:17 +02:00
Alex Rønne Petersen 340d6ce1bf std.builtin: move AddressSpace.Context to std.Target.AddressSpaceContext
This type has nothing to do with the language.
2025-10-23 09:27:17 +02:00
Alex Rønne Petersen af1d777b27 std.builtin: add CallingConvention.sh_interrupt
Only supported in CBE.
2025-10-23 09:27:17 +02:00
Alex Rønne Petersen 4fa453ce20 std.builtin: add CallingConvention.microblaze_interrupt
Only supported in CBE.
2025-10-23 09:27:17 +02:00
Alex Rønne Petersen abf40caeb7 std.builtin: add CallingConvention.msp430_interrupt
Supported by LLVM and CBE.
2025-10-23 09:27:17 +02:00
Alex Rønne Petersen beb507a1ed std.builtin: add CallingConvention.x86_64_x32
This was forgotten during the refactoring of std.builtin.CallingConvention. It
mirrors mips64_n32 for MIPS.
2025-10-23 09:27:17 +02:00
Alex Rønne Petersen a1441943e4 std.Target: add stackGrowth() function 2025-10-23 09:27:17 +02:00
Alex Rønne Petersen ee72f06f47 std.Target: add tags and info for alpha, hppa, microblaze, sh 2025-10-23 09:27:17 +02:00
Alex Rønne Petersen c55e83eab1 std.Target: xtensa defaults to windowed ABI 2025-10-23 09:27:17 +02:00
Alex Rønne Petersen 3e2daa509a std.Target: add arceb and xtensaeb Cpu.Arch tags 2025-10-23 09:27:17 +02:00
Alex Rønne Petersen dda05b29c0 std.Target: fix cMaxIntAlignment() for a few architectures 2025-10-23 09:27:17 +02:00
Alex Rønne Petersen 45b80f2e41 std.Target: fix cTypePreferredAlignment() for arc 2025-10-23 09:27:17 +02:00
Alex Rønne Petersen 862e674758 std.Target: remove bogus hosted avr/msp430 prongs in cTypeBitSize()
These are microcontroller architectures; none of the OSs in the outer switch
run on them.
2025-10-23 09:27:17 +02:00
Alex Rønne Petersen 022dcbc37a std.Target.DynamicLinker: recognize standard hexagon-linux-musl path 2025-10-23 09:27:16 +02:00
Alex Rønne Petersen a7f085f0d7 std.Target: fix cCallingConvention() to pick mips64_n32 for muslabin32 2025-10-23 09:27:16 +02:00
Alex Rønne Petersen 0e15b2ac10 std.Target: handle some more cases in toCoffMachine() 2025-10-22 17:28:19 +02:00
Alex Rønne Petersen 362a44a122 std.Target: better Abi.default() behavior for arc and xtensa 2025-10-22 17:28:19 +02:00
Alex Rønne Petersen e8d060e5f5 std.Target: update lists of omitted LLVM tags 2025-10-22 17:28:19 +02:00
Justus Klausecker a027fa8b8c std.mem.Allocator: fix resize doc comment 2025-10-22 11:41:16 +02:00
Wim de With 8d4b5662cd std.{c,posix}: add getgid and getegid 2025-10-21 06:10:41 +02:00
Alex Rønne Petersen dbf9c7b548 compiler: add support for arc_interrupt calling convention
Only for use with the C backend at the moment.
2025-10-19 22:27:19 +02:00
Wim de With 49eea79ec2 std.os.linux: add pivot_root syscall 2025-10-19 22:24:24 +02:00
Wim de With 5442e06632 std.os.linux: add setns syscall 2025-10-19 22:24:24 +02:00
Alex Rønne Petersen 031b0d6063 glibc: change library link order to prefer libc.so symbols
Also avoid resolving symbols in libraries that were later removed if possible.

closes #24347
2025-10-19 11:50:32 +02:00
Alex Rønne Petersen 328b121240 Merge pull request #25627 from alexrp/qemu-10.1.1-patched
`ci`: switch to patched QEMU 10.1.1.1
2025-10-19 11:50:23 +02:00
Alex Rønne Petersen 38caa4902f Merge pull request #25623 from alexrp/or1k
Add `or1k-linux` support (via CBE)
2025-10-19 11:50:06 +02:00
GasInfinity 1bca158c6e fix(std): don't add the default _start and panic in homebrew targets
* even if std supported those targets, they're not posixy to be in that codepath.
2025-10-18 23:54:27 +02:00
Alex Rønne Petersen 08014589e2 std.atomic: define cache line size for or1k 2025-10-18 22:27:35 +02:00
Alex Rønne Petersen 49cd0e6f7c std.debug: fix frame pointer unwinding on or1k 2025-10-18 22:27:35 +02:00
Alex Rønne Petersen 5e57ed9fda std.Thread: implement freeAndExit() for or1k 2025-10-18 22:27:35 +02:00
Alex Rønne Petersen 562b88f7b1 std.heap: define min/max page size for or1k-linux 2025-10-18 22:27:35 +02:00
Alex Rønne Petersen c571840e71 std.os.linux: add or1k arch bits 2025-10-18 22:27:35 +02:00
Alex Rønne Petersen 35e819aac8 std.os.linux.tls: implement or1k support 2025-10-18 22:27:35 +02:00
Alex Rønne Petersen e646c47f67 std.pie: add or1k support 2025-10-18 22:27:34 +02:00
Alex Rønne Petersen 2d5cdfcfc2 std.start: align stack pointer according to ARC v3 ABI 2025-10-18 22:26:52 +02:00
Alex Rønne Petersen 0d2d51dd8c std.start: add or1k support 2025-10-18 22:26:52 +02:00
Alex Rønne Petersen afc6e88413 zig.h: add or1k support 2025-10-18 22:26:52 +02:00
Alex Rønne Petersen 6bf5b7f2b4 Merge pull request #25622 from alexrp/inline-asm-fixes
`std`: some miscellaneous inline asm fixes for mips, mips64, mipsn32, and x32
2025-10-18 22:26:09 +02:00
Alex Rønne Petersen 653a191965 Revert "std.Thread: disable test on armeb in addition to thumbeb"
This reverts commit a73f246b29.
2025-10-18 20:50:19 +02:00
Alex Rønne Petersen 1466401c15 Merge pull request #25614 from squeek502/windows-rename-delete
windows: Always try using POSIX_SEMANTICS/etc for rename/delete
2025-10-18 20:45:22 +02:00
Alex Rønne Petersen 3585f79f44 std.os.linux: remove syscall7() on mips64/mipsn32
I'm not sure why this was here, but this is only a thing on O32, not N32/N64.
2025-10-18 14:01:41 +02:00
Alex Rønne Petersen 5e3c313366 std.pie: fix getDynamicSymbol() for mipsn32 2025-10-18 12:13:41 +02:00
Alex Rønne Petersen 2305527342 std.start: fix _start for mipsn32
This is more similar to O32 than N64.
2025-10-18 12:11:27 +02:00
Alex Rønne Petersen adcfdce6be std.Thread: fix some issues in x86_64/x32 inline asm
Wrong syscall on x32; return exit code 0 instead of 1 on both.

ref https://github.com/ziglang/zig/issues/22189
2025-10-18 11:36:26 +02:00
Alex Rønne Petersen e59f2995a5 std.Thread: fix inline asm for mipsn32
This was using the mips64 syscalls.

ref https://github.com/ziglang/zig/issues/22189
2025-10-18 11:36:02 +02:00
Alex Rønne Petersen 842de66db8 std.os.linux: fix some issues in x32 inline asm
ref https://github.com/ziglang/zig/issues/22189
2025-10-18 11:16:31 +02:00
Alex Rønne Petersen f3eacec226 std.os.linux: fix some issues in mipsn32 inline asm
ref https://github.com/ziglang/zig/issues/22189
2025-10-18 11:16:31 +02:00
Alex Rønne Petersen b8d776928a std: make all MIPS inline asm safe for MIPS I
MIPS I has load hazards so we need to insert nops in a few places. This is not a
problem for MIPS II and later.

While doing this, I also touched up all the inline asm to use ABI register
aliases and a consistent formatting convention. Also fixed a few places that
didn't properly check if the syscall return value should be negated.
2025-10-18 11:16:31 +02:00
Alex Rønne Petersen f3da54f53c std.Target: move Cpu.supportsAddressSpace() up to here
This allows us to rule out support for certain address spaces based on the OS.
This commit is just a refactor, however, and doesn't actually make use of that
opportunity yet.
2025-10-18 11:13:28 +02:00