Jakub Konka
24126f5382
elf: simplify output section tracking for symbols
2024-07-30 10:00:50 +02:00
Jakub Konka
c575e3daa4
elf: resolve COMDATs in more parallel-friendly way
2024-07-30 10:00:50 +02:00
Jakub Konka
fa09276510
test/link/elf: test COMDAT elimination
2024-07-30 10:00:50 +02:00
Jakub Konka
58defeeaa6
macho: test section$end$ boundary symbol handling
2024-07-28 06:59:21 +02:00
Jakub Konka
34f34dbe32
macho: reinstate duplicate definition checking
2024-07-18 09:13:09 +02:00
Jakub Konka
e117e05768
macho: ensure we always name decls like LLVM to avoid confusion
2024-07-18 09:13:08 +02:00
Jakub Konka
91de8dc8ab
macho: fix unresolved symbols error reporting
2024-07-18 09:13:08 +02:00
Jakub Konka
f9fbd6302f
macho: test TLS in Zig with x86_64 backend
2024-07-18 09:13:08 +02:00
Krzysztof Wolicki
45c77931c2
Change deprecated b.host to b.graph.host in tests and Zig's build.zig
2024-06-13 10:49:06 -04:00
Pat Tullmann
ed795a907d
target.zig: Constrain aarch64 to glibc version 2.17 or later
...
Had constrained the `aarch64_be` target, but not `aarch64`. This
constraint is necessary because earlier versions of glibc do not support
the aarch64 architecture.
Also, skip unsupported test cases.
2024-06-06 09:36:16 -07:00
Pat Tullmann
8bee879fc2
test/link/glibc_compat: Add C test case for glibc versions
...
glibc_runtime_check.c is a simple test case that exercises glibc functions
that might smoke out linking problems with Zig's C compiler. The
build.zig compiles it against a variety of glibc versions.
Also document and test glibc v2.2.5 (from 2002) as the oldest working
glibc target for C binaries.
2024-06-06 09:36:16 -07:00
Jakub Konka
19f41d390f
test/link/macho: add symbol stabs smoke test
2024-05-24 22:43:23 +02:00
Jakub Konka
d31eb744ce
link/macho: fix 32bit build
2024-05-23 12:04:17 +02:00
Jakub Konka
78b441e8de
test/link/macho: test merge literals on x86_64
2024-05-23 12:04:17 +02:00
Jakub Konka
03d0a68356
test/link/macho: clean up merge literals tests on aarch64
2024-05-23 12:04:17 +02:00
Jakub Konka
28d08dd8a6
link/macho: test merging literals targeting ObjC
2024-05-23 12:04:17 +02:00
Jakub Konka
8fc0c7dce1
link/macho: apply fixes to deduping logic
...
* test non-ObjC literal deduping logic
2024-05-23 12:04:17 +02:00
Jakub Konka
d78968c1b5
test/link: actually run tests requiring symlinks on non-Win
...
Fixes regression introduced by 5d5e89aa8d
Turns out since landing that PR we haven't run any tests requiring
symlinks or any Apple SDK on a macOS host. Not great.
2024-05-22 14:59:32 +02:00
daurnimator
497f37ce92
test/link/glibc_compat: fix incorrect strlcpy result
2024-04-28 22:03:08 -07:00
Jakub Konka
66253e5b51
link/elf: populate current Zig version in .comment; test
2024-04-20 23:36:42 +02:00
Jakub Konka
bc0d84be0b
test/link/elf: add merge strings test for -r mode
2024-04-20 23:36:42 +02:00
Jakub Konka
342235e5eb
test/link/elf: enhance merge strings tests
2024-04-20 23:36:42 +02:00
Jakub Konka
457d84f45a
link/elf: remove link.link.build as unused; add some merge strings tests
2024-04-20 23:36:42 +02:00
Andrew Kelley
b30ad74908
remove deprecated LazyPath.path union tag
2024-04-11 14:02:47 -07:00
Carl Åstholm
5d5e89aa8d
Promote linker test cases to packages
2024-04-07 16:05:54 -07:00
Andrew Kelley
8c94950c24
fix compilation failures found by CI
2024-03-19 16:18:18 -07:00
Jakub Konka
d565c5dfcd
macho: fix a sad typo in calculating the address of a TLV pointer
2024-03-15 08:17:10 +01:00
Jakub Konka
7ba2453b8e
test/link/elf: do not check for $thunk in thunks tests for now
...
Andrew and I have discovered that on Linux max peak rss value
is taken to be `max(build_runner, test_suite)` and since the thunks
test emit a huge binary, we will easily exceed the declared maximum
for any of the test suites. This can be worked around for now by not
checking for $thunk symbols in this test since it doesn't really
yield any additional information; however ideally we would implement
per-thread local temp arena that can be freed.
2024-03-13 08:25:38 +01:00
Jakub Konka
faa4bdb017
elf+aarch64: fix off-by-one in converging on groups interleaved with thunks
2024-03-12 13:16:11 +01:00
Jakub Konka
b1bd3825f8
test/link/macho: remove redundant 'macho-' prefix from case names
2024-03-12 13:16:11 +01:00
Jakub Konka
b1eba5a996
elf+aarch64: actually write out thunks, and add a proper link test
2024-03-12 13:16:11 +01:00
Tristan Ross
c260b4c753
std.builtin: make global linkage fields lowercase
2024-03-11 07:09:10 -07:00
Jakub Konka
1a6b2e84ac
test/link/elf: remove pie hack due to QEMU bug that is now fixed
2024-03-10 10:39:31 +01:00
Jakub Konka
b7b63855d0
test/link/elf: enable tests for aarch64 cpu arch
2024-03-09 19:26:26 +01:00
Luuk de Gram
196ba706a0
wasm: gc fixes and re-enable linker tests
...
Certain symbols were left unmarked, meaning they would not be emit into
the final binary incorrectly. We now mark the synthetic symbols to ensure
they are emit as they are already created under the circumstance they're
needed for. This also re-enables disabled tests that were left disabled
in a previous merge conflict.
Lastly, this adds the shared-memory test to the test harnass as it was
previously forgotten and therefore regressed.
2024-02-29 15:24:08 +01:00
Jakub Konka
ddb33baa11
test/link/elf: test static linking C riscv64-musl
2024-02-21 23:08:29 +01:00
Jakub Konka
55dadc3d85
test/link/elf: test static linking C aarch64-musl
2024-02-21 22:40:03 +01:00
Jakub Konka
d12c8db642
Merge pull request #18875 from ziglang/macho-zo-dwarf
...
macho: emit DWARF for ZigObject relocatable
2024-02-09 23:12:04 +01:00
Tristan Ross
2a3e601f77
test.link.macho: fix for non-x86 and arm architectures
...
This fix is requires to make the build runner even compile when building
Zig on architectures like RISC-V.
2024-02-09 17:49:53 +02:00
Jakub Konka
925273bcc8
macho: align memory size with file size when emitting relocatable
2024-02-09 00:20:11 +01:00
Jakub Konka
7388534590
test/link/macho: more self-hosted tests
2024-02-08 23:51:30 +01:00
Jakub Konka
7fb9df3fab
test/link/macho: -fstrip is no longer needed for self-hosted
2024-02-08 22:15:00 +01:00
Jakub Konka
ca86dc61dd
test/link/macho: test for signals only when running on the host
2024-02-03 19:36:52 +01:00
Jakub Konka
4ebd0036fd
test/link/macho: add some smoke tests for self-hosted MachO
2024-02-03 17:57:35 +01:00
Jakub Konka
92deebcd66
cli+build: handle -ObjC flag and route it to MachO linker
2024-02-02 22:00:16 +01:00
Jakub Konka
f63f4508d2
macho: fix parsing versions from TBDs if parsed as floats
2024-01-30 20:56:20 +01:00
Jakub Konka
b8490c05c1
macho: improve weak-ref symbols handling
2024-01-30 13:56:08 +01:00
Jakub Konka
d726538494
test/link/macho: ensure we do not run testStackSize on foreign host
2024-01-24 12:34:42 +01:00
Jakub Konka
03b33b0f01
test/link/macho: migrate all tests to the new test matrix
2024-01-24 12:34:40 +01:00
Jakub Konka
2b3ac3e82f
test/link/macho: upgrade tbdv3 test
2024-01-24 12:34:40 +01:00