1616 Commits

Author SHA1 Message Date
Veikka Tuominen
7d75c3d3b8 llvm: ensure returned undef is 0xaa bytes when runtime safety is enabled
Closes #13178
2024-01-29 17:35:07 -08:00
Jakub Konka
060406a526 macho: ensure we zero-out regions after copying them over
This is to ensure that the loader correctly zeroes-out zerofill
sections when mapping them. For context, Apple's loader dyld
will map the regions where any zerofill would theoretically reside
as belonging to zerofill section.
2024-01-24 12:34:42 +01:00
Jakub Konka
3a6410959c macho: actually lower TLS variables 2024-01-24 12:34:42 +01:00
Jakub Konka
5c4db4e578 x86_64: emit MachO TLV sequence 2024-01-24 12:34:42 +01:00
Jakub Konka
080ad94249 x86_64: save TLS to stack for MachO 2024-01-24 12:34:42 +01:00
Jakub Konka
5c951cd211 macho: again fix symbol index dereference in codegen wrt ZigObject 2024-01-24 12:34:41 +01:00
Jakub Konka
a8629fb850 macho: fix symbol index dereference in codegen wrt ZigObject
This is incredibly confusing and I really need to simplify it.
Elf also possesses this shortcoming so once I get Coff up to speed
it should hopefully become clear on how to refactor this.
2024-01-24 12:34:41 +01:00
Jakub Konka
a79a038e61 codegen: implement more missing bits 2024-01-24 12:34:41 +01:00
Jakub Konka
96cc9fafbf codegen: re-implement enough of codegen to error out instead panic 2024-01-24 12:34:41 +01:00
Jakub Konka
dd0addab1f macho: get the ball rolling! 2024-01-24 12:34:38 +01:00
joachimschmidt557
f12ec02bd7 stage2 AArch64: get empty file compiling again 2024-01-08 23:53:24 -08:00
Andrew Kelley
2047a6b82d fix remaining compile errors except one 2024-01-01 17:51:20 -07:00
Andrew Kelley
48d5861f92 fix more compilation errors introduced by this branch 2024-01-01 17:51:20 -07:00
Andrew Kelley
c49957dbe8 fix a round of compile errors caused by this branch 2024-01-01 17:51:19 -07:00
Andrew Kelley
bc4d2b646d compiler: update references to target 2024-01-01 17:51:19 -07:00
Andrew Kelley
f5ddef1e45 update references to module (to be renamed to zcu) 2024-01-01 17:51:19 -07:00
Andrew Kelley
9a48a5ab07 compiler: update references to single_threaded 2024-01-01 17:51:19 -07:00
Andrew Kelley
5a6a1f8a8a linker: update target references 2024-01-01 17:51:19 -07:00
Andrew Kelley
2be36c5b8d linker: update references to module 2024-01-01 17:51:19 -07:00
Veikka Tuominen
69195d0cd4 AstGen: add error for using inline loops in comptime only scopes 2023-12-08 16:54:32 -08:00
Jacob Young
c70c333594 x86_64: fix packed struct field reuse 2023-12-04 13:31:54 -05:00
Jacob Young
bdb6546a8f x86_64: fix vector comparisions 2023-12-04 13:09:13 -05:00
Jacob Young
50993a8f08 x86_64: implement more operations on vectors with 1-bit elements 2023-12-04 01:29:07 -05:00
Jacob Young
485e20884c x86_64: implement movement for pointer vectors 2023-12-03 23:07:50 -05:00
Jacob Young
7c85ea65ba x86_64: "implement" aggregate_init for vectors 2023-12-03 13:55:31 -05:00
Jacob Young
e00f1397e3 x86_64: implement some todos 2023-12-03 10:24:03 -05:00
Jacob Young
014833b61f x86_64: implement more compliant vectors 2023-12-03 10:22:06 -05:00
Jacob Young
917b4ad5e0 x86_64: implement more atomic ops 2023-12-03 10:22:06 -05:00
Jacob Young
daf91ed8d1 Air: use typesafe Air.Inst.Index
I need some indices for a thing...
2023-12-03 02:05:06 -08:00
Jacob Young
bf5ab54510 test: test with -fstrip and fix failures
Closes #17513
2023-12-01 04:34:50 +00:00
Meghan Denny
2549de80b2 move Module.Decl.Index and Module.Namespace.Index to InternPool 2023-11-26 02:24:40 -05:00
Techatrix
18608223ef convert toType and toValue to Type.fromInterned and Value.fromInterned 2023-11-25 04:09:53 -05:00
Jacob Young
115ec25f2e x86_64: optimize compile time of mnemonic_to_encodings_map
Remove all comptime sorts, making it compile 3x faster.
2023-11-23 04:38:31 -05:00
mlugg
b355893438
compiler: correct unnecessary uses of 'var' 2023-11-19 11:11:49 +00:00
Jacob Young
0c6cb8d8c8 x86_64: actually track state during @divFloor of i128
Closes #17998
2023-11-14 22:50:05 -05:00
Jacob Young
80b73e3e8f x86_64: resolve tlv references on first use and spill to the stack
This avoids any arbitrary memory operand possibly clobbering rax and
sometime rdi with no warning.
2023-11-12 18:12:41 -05:00
Jakub Konka
3d3153c58e x86_64: use .rax for local exec as prescribed by the spec 2023-11-12 18:12:41 -05:00
Jakub Konka
c6833e6273 x86_64: remove unreachable Elf prong 2023-11-12 18:12:41 -05:00
Jakub Konka
575c29e5c4 elf: set symbol flags such as needs_zig_got in ZigObject 2023-11-12 18:12:41 -05:00
Jakub Konka
412519dd49 x86_64: seems like we will need to keep track of rax and reserve rax+rdi for TLS 2023-11-12 18:12:41 -05:00
Jakub Konka
984c598590 x86_64: emit TLS local dynamic model when PIC 2023-11-12 18:12:41 -05:00
Jakub Konka
1afc6917f5 x86_64: get something going for the local exec model 2023-11-12 18:12:41 -05:00
Jacob Young
2eeb735822 Dwarf: improve x86_64 backend debug info
Closes #17811
2023-11-12 03:21:52 -05:00
Jacob Young
e387d30b26 x86_64: fix signed not of more than 64 bits 2023-11-08 08:49:34 -05:00
Jacob Young
8f2aa72af7 x86_64: fix optional comparison 2023-11-08 07:24:48 -05:00
kcbanner
1acb6a53d0
wasm: support rendering unions using their backing type if they have no defined tag type 2023-11-07 00:49:39 +00:00
Jacob Young
9ced27dace x86_64: fix passing register-sized payload as non-reigster-sized union
Closes #17885
2023-11-06 14:11:31 -05:00
Jacob Young
8311fac7e8 x86_64: fix indirect return of f80 2023-11-05 06:09:06 -05:00
Jacob Young
803ea10107 x86_64: fix tracking during br 2023-11-05 06:08:06 -05:00
Jakub Konka
f24ceec35a
Merge pull request #17844 from ziglang/elf-object
elf: handle emitting relocatables and static libraries - humble beginnings
2023-11-04 20:58:15 +01:00