Jakub Konka
1cae41bbbb
macho: clean up array of supported platforms and versions
2023-08-29 12:14:57 +02:00
Jakub Konka
1b01715a73
link: remove unused darwin_sdk_version field
2023-08-29 12:02:58 +02:00
Jakub Konka
3ece3f83f3
macho: clean up helpers for std.SemanticVersion <-> Apple version formatting
2023-08-29 12:00:25 +02:00
Jakub Konka
2e28ab153c
macho: parse platform info from each object file into Platform struct
2023-08-29 11:45:03 +02:00
Jakub Konka
ec03619dcf
macho: make MachO.requiresCodeSignature accept link.Options
2023-08-29 11:40:20 +02:00
Jakub Konka
052984c5ae
macho: remove MachO.requiresThunks as it is obsolete
2023-08-29 11:40:20 +02:00
Jakub Konka
2473ccc335
macho: create an explicit error set for parse functions
2023-08-29 11:40:20 +02:00
Jakub Konka
1820aed786
macho: convert log.err when CPU arch is mismatched into actual errors
2023-08-29 11:40:20 +02:00
Jakub Konka
68dc1a3e3f
macho: report symbol collision as compiler error
2023-08-29 11:40:20 +02:00
Jakub Konka
0f02a1fcb0
macho: fix 32bit compilation issues
2023-08-29 11:40:20 +02:00
Jakub Konka
8330065a99
macho: report undefined via compiler errors in incremental driver
2023-08-29 11:40:20 +02:00
Jakub Konka
8d1ca8ce7b
macho: swap sectname with segname typo when allocating sections
2023-08-29 11:40:20 +02:00
Jakub Konka
700b1e38ce
macho: fix overalignment of stubs on aarch64
2023-08-29 11:40:20 +02:00
Jakub Konka
0353bfd55e
macho: fix a few regressions in incremental codepath
2023-08-29 11:40:20 +02:00
Jakub Konka
5eb6c81d07
macho: fix invalid alignment of stubs for x86_64
2023-08-29 11:40:20 +02:00
Jakub Konka
9d62ebc0ce
macho: fix compilation issues
2023-08-29 11:40:20 +02:00
Jakub Konka
2c68fb3d7c
macho: merge Zld state with MachO state
2023-08-29 11:40:18 +02:00
Jakub Konka
42e0850d78
macho: save indexes to all sections of interest
2023-08-29 11:39:35 +02:00
Jakub Konka
84853c5c56
macho: unify resolving globals
2023-08-29 11:39:35 +02:00
Jakub Konka
7f6973fbae
macho: unify segment handling
2023-08-29 11:39:35 +02:00
Jakub Konka
d17867939e
macho: unify writeLinkeditSegmentData func
2023-08-29 11:39:35 +02:00
Jakub Konka
7f74b3562d
macho: unify creating atoms
2023-08-29 11:39:35 +02:00
Jakub Konka
ef0d35e00c
macho: unify allocating special symbols
2023-08-29 11:39:35 +02:00
Jakub Konka
664b983518
macho: unify writeSegmentHeaders func
2023-08-29 11:39:35 +02:00
Jakub Konka
b2773cd712
macho: move initSection into MachO from Zld
2023-08-29 11:39:34 +02:00
Jakub Konka
180979ee41
macho: move getOutputSection into Atom
2023-08-29 11:39:34 +02:00
Jakub Konka
f29d9ec61c
macho: unify entry point handling
2023-08-29 11:39:34 +02:00
Jakub Konka
b2af2dc8b7
macho: move symbol resolver into zld driver's state
2023-08-29 11:39:34 +02:00
Jakub Konka
19afd794d0
macho: remove dead code
2023-08-29 11:39:34 +02:00
Jakub Konka
e54f286c3b
macho: assert every global is extern in incremental context
2023-08-29 11:39:34 +02:00
Jakub Konka
e9ad9e04c9
macho: collect bind data by scanning atoms directly in objects
2023-08-29 11:39:34 +02:00
Jakub Konka
7c11355556
macho: collect rebase data by scanning atoms directly in objects
2023-08-29 11:39:34 +02:00
Jakub Konka
bf5c35145d
macho: remove dead code
2023-08-29 11:39:34 +02:00
Jakub Konka
4b934b1f78
macho: use TableSection for stub entries in zld driver
...
Write thunks separately from other atoms - this can still be improved
by not using atoms at all, but one thing at a time.
2023-08-29 11:39:34 +02:00
Jakub Konka
ee02517bce
macho: remove obsolete function createDyldStubBinderGotAtom
2023-08-29 11:39:34 +02:00
Jakub Konka
5750620715
macho: use TableSection for TLV pointer entries in zld driver
2023-08-29 11:39:34 +02:00
Jakub Konka
04e93dd265
macho: use TableSection for GOT entries in zld driver
2023-08-29 11:39:34 +02:00
Jakub Konka
837114f019
macho: change dyld_private_sym_index to dyld_private_atom_index in zld
2023-08-29 11:39:34 +02:00
Jakub Konka
da9e7e498a
macho: unify Atom concept between drivers
2023-08-29 11:39:34 +02:00
Jakub Konka
85f2df5050
macho: unify more of the linker state
2023-08-29 11:39:34 +02:00
Jakub Konka
e1e0ccb0c7
macho: unify Section concept across drivers
2023-08-29 11:39:34 +02:00
Jakub Konka
05c9d6c00b
macho: add simple error reporting for misc errors
2023-08-29 11:39:34 +02:00
Jakub Konka
7b282dffe6
macho: unify concept of SymbolWithLoc across drivers
2023-08-29 11:39:34 +02:00
Jakub Konka
702bcfecf5
macho: simplify input file parsing for both drivers
2023-08-29 11:39:34 +02:00
Jakub Konka
69193a4ae4
macho: remove page_size field as it can be computed when and where required
2023-08-29 11:39:34 +02:00
Jakub Konka
e6891b2422
macho: remove dead code
2023-08-29 11:39:34 +02:00
Jakub Konka
3b2b9fcbc5
darwin: move inference of SDK version into the linker
...
`std.zig.system.darwin.getSdk` now pulls only the SDK path
so we execute a child process only once and not twice as it was
until now since we parse the SDK version directly from the pulled path.
This is actually how `ld64` does it too.
2023-08-29 06:43:41 +02:00
Jacob Young
c429bb5d2f
llvm/cbe: support slice in @prefetch
...
Closes #16967
2023-08-28 19:04:53 -07:00
Jay Petacat
26b03ca823
std: Move TailQueue alias to correct namespace
...
This fixes a mistake in PR #16996 .
2023-08-28 17:41:37 -07:00
mlugg
b8e6c42688
compiler: provide result type for @memset value
...
Resolves : #16986
2023-08-28 12:33:36 -07:00