26020 Commits

Author SHA1 Message Date
Jakub Konka
e72fd185e0 elf: skip writing out zerofill atoms to file 2023-09-30 00:52:10 +02:00
Jakub Konka
6c50ad6e9f elf: set sh_size to 0 for nobit sections in collision detection
`SHT_NOBITS` sections take no file space after all.
2023-09-29 22:37:59 +02:00
Jakub Konka
e5e6984652 elf: dump state for debugging after writing it all out 2023-09-29 22:29:06 +02:00
Jakub Konka
5381bfd348 elf: fix setting st_value of _end synthetic symbol 2023-09-29 22:18:38 +02:00
Jakub Konka
8e90b41ae0 elf: set shdr/phdr file size before growing in VM 2023-09-29 21:43:01 +02:00
Jakub Konka
304d38e844 elf: simplify logic for growing non-alloc sections 2023-09-29 20:35:28 +02:00
Jakub Konka
0524a3c83d elf: fix calculating current allocated section size when growing alloc sections 2023-09-29 19:06:02 +02:00
Jakub Konka
04a7051c4b elf: fix 32bit build 2023-09-28 21:42:09 +02:00
Jakub Konka
cdd4dbfe32 test: add x86_64-linux-musl-no-lld as a test target 2023-09-28 19:28:06 +02:00
Jakub Konka
89c2151a97 elf: move logic for extracing atom's code into input files 2023-09-28 18:35:26 +02:00
Jakub Konka
91f2e66bf9 elf: test TLS in static programs 2023-09-28 15:13:35 +02:00
Jakub Konka
785bd270ed elf: correctly allocate TLS segment 2023-09-28 14:59:09 +02:00
Jakub Konka
af00ac53b5 elf: report fatal linker error for unhandled relocation types 2023-09-28 14:06:12 +02:00
Jakub Konka
a63ce5a37c elf: allocate .tdata and .tbss sections 2023-09-28 13:29:04 +02:00
Jakub Konka
22127a8792 elf: pre-allocate TLS load segment and PT_TLS phdr 2023-09-28 12:06:21 +02:00
Jakub Konka
42011a8249 elf: remove explicit load segment alloc - we can replicate programmatically now 2023-09-28 11:46:40 +02:00
Jakub Konka
df285949f7 elf: do not assume segments laid out in increasing order in VM space 2023-09-28 08:47:58 +02:00
Jakub Konka
8f90dbba55 elf: fix typo in selecting larger addrspace for load segments 2023-09-27 20:05:46 +02:00
Jakub Konka
8b7255c22a elf: hint allocateSegment where to put the segment at 2023-09-27 19:41:59 +02:00
Jakub Konka
111349f83c elf: do not update globals not defined by the object 2023-09-27 19:22:57 +02:00
Jakub Konka
85132965f4 elf: use new error reporting API 2023-09-27 16:40:51 +02:00
Jakub Konka
09863fc970 elf: emit fatal linker error if we run out of VM space with self-hosted backends 2023-09-27 15:07:05 +02:00
Jakub Konka
e178580d86 elf: pre-allocate large VM capacity per segment 2023-09-27 10:00:20 +02:00
Jakub Konka
1200a5a240 elf: allow expanding segments in virtual memory 2023-09-27 09:59:59 +02:00
Ryan Liptak
de4d1ea250 Add myself as a code owner of /src/resinator/ 2023-09-26 23:08:34 -07:00
Jakub Konka
7a43f45908
Merge pull request #17284 from ziglang/elf-tests
elf: link against musl libc, add ELF test harness, dynamically allocate misc SHF_ALLOC sections
2023-09-27 07:39:58 +02:00
Kai Jellinghaus
d1e39b6914 Add new fields to io_sqring_offsets & io_cqring_offsets
`user_addr`s were introduced in `03d89a2` ([github link](03d89a2de2) which was shipped in v6.5
`flags` was introduced even earlier
2023-09-26 18:16:36 -07:00
Jay Petacat
37398ed2a5 std: Reactivate skipped tests w.r.t. llvm/llvm-project#55522 2023-09-27 01:37:25 +03:00
LinuxUserGD
ceaae42e90 Add '--compress-debug-sections=zstd' 2023-09-26 14:18:01 -07:00
Chris Burgess
1c726bcb32
std.http: add identity to content encodings (#16493)
Some servers will respond with the identity encoding, meaning no
encoding, especially when responding to range-get requests. Adding the
identity encoding stops the header parser from failing when it
encounters this.
2023-09-26 17:16:40 -04:00
Andrew Kelley
5d907171e2
Merge pull request #17152 from mikdusan/macos-sdk
macos SDK updates and enhancements
2023-09-26 13:16:07 -07:00
Phil Richards
15ce965252
define _WIN32_WINNT for windows compilations based on target minver (#17224) 2023-09-26 15:25:08 -04:00
Jakub Konka
e30f396b73 elf: properly close the output file when linking 2023-09-26 21:07:47 +02:00
Jakub Konka
7617486f1d elf: skip running exe on foreign hosts 2023-09-26 21:07:47 +02:00
Jakub Konka
b01b972999 elf: test linking against empty C object 2023-09-26 21:07:47 +02:00
Jakub Konka
eb497c50e3 elf: dynamically allocate remaining alloc sections (and segments) 2023-09-26 21:07:47 +02:00
Jakub Konka
5e617e4b0c elf: put libc on the linker line if requested 2023-09-26 21:07:47 +02:00
Jakub Konka
e7c6dfde3d elf: do not try to create LlvmObject if module is null 2023-09-26 21:07:47 +02:00
Jakub Konka
8abfb3559a elf: test statically linking libc 2023-09-26 21:07:47 +02:00
Jakub Konka
aac04b4a5a elf: port some of zld's test harness 2023-09-26 21:07:47 +02:00
Michael Dusan
0c8bf405eb
kubkon review changes: 4
- fix `darwin_sdk_layout.?` with null checks
2023-09-26 07:51:32 -04:00
Veikka Tuominen
f4c884617f
Merge pull request #17215 from kcbanner/read_from_memory_union
sema: add support for unions in readFromMemory and writeToMemory
2023-09-26 11:16:03 +03:00
Michael Dusan
ebd0776b28
kubkon review changes: 3
- make vendored settings failure unreachable
- rename field `darwinSdkLayout` → `darwin_sdk_layout`
- make `darwin_sdk_layout` optional
2023-09-25 17:07:41 -04:00
Michael Dusan
f6877fbc49
kubkon review changes: 2
- drop --verbose-link printing until ready to put in driver frontend
2023-09-25 15:53:05 -04:00
Michael Dusan
9357973912
kubkon review changes: 1
general:
- rename `DarwinSdkLayout` → `DarwinSdkLayout`
- drop `DarwinSdkLayout.installation` (not needed for darwin)
- document struct

inferSdkVersion:
- use explicit allocator
- avoid trying to infer SDK ver from vendored path
2023-09-25 15:53:05 -04:00
Michael Dusan
50f2d79582
macos: update libc names for darwin
- dropped incorrect names
- added list of names found in the SDKs
- ios, tvos and watchos filesystems are case-sensitive
2023-09-25 15:53:05 -04:00
Michael Dusan
5d6521d281
macos: better SDK version detection
SDK version detection:
- read SDKSettings.json before inferral from SDK path
- vendored libc: add SDKSettings.json for SDK version info

resolveLibSystem:
- adjust search order to { search_dirs, { sysroot or vendored }}
- previous search order was { sysroot, search_dirs, vendored }
2023-09-25 15:53:05 -04:00
Michael Dusan
15fd7cd154
macos: vendored libc: combine headers: part 2
- update include dirs to use combined dir
- use one libSystem.tbd (drop use of libSystem.VERSION.tbd)
- update canBuildLibC to check for minimum os version only
2023-09-25 15:53:05 -04:00
Michael Dusan
52e8354926
macos: vendored libc: combine headers: part 1
- combine *-macos-* → any-macos-any
- SDK headers as a single tree support targeting multiple arch/versions
- bump to SDK 14.0 (release candidate)
2023-09-25 15:53:05 -04:00
Michael Dusan
f3ff0b6e6d
macos: discontinue redundant search/link for libc 2023-09-25 15:53:04 -04:00