gingerBill
6bca1475ed
Convert procedures_to_generate to a queue
2025-09-19 14:15:25 +01:00
gingerBill
1e0902677f
Multithread min dep set by removing the set itself
2025-09-10 17:29:11 +01:00
gingerBill
bb4bc316a4
for in string16; Support string16 across core
2025-08-02 12:20:35 +01:00
Laytan Laats
f94fc992d7
fix swizzle in for in statement
...
Fixes #1730
2025-06-02 20:30:48 +02:00
Laytan Laats
c35a45e823
fix global and static any
...
Fixes #4627
2025-05-17 16:49:30 +02:00
tf2spi
2f636886a5
Add debug info for labels ( #4385 )
...
* Emit label debug info w/o location
* Insert debug label call
* Slight refactor for later fix
* Improve debug labels for block statements
* Improve debug info with for loops
* Generate label lbBlocks w/ debug
* Lightly refactor lb_add_debug_label
* Revise comments, add null check assertion
* Use LLVM-C API for debug labels
* Prefer C DILabel API for POSIX, fallback to CPP
* Use version check for LLVM-C DILabel
2025-05-15 22:11:06 +02:00
Lucas Perlind
46e0c7ad74
Cleanup
2025-05-07 11:30:58 +10:00
Lucas Perlind
83bc2d3c4a
Add asan support for various allocators
2025-05-06 14:55:50 +10:00
Barinzaya
9284ebb5e8
Add missing cast to global/static var alignments.
2025-04-24 14:35:00 -04:00
Barinzaya
b41a776027
Correctly align global and static variables.
...
This can be important if matrices or SIMD vectors are being used in
global or static variables, as otherwise it may result in crashes due to
aligned instructions accessing misaligned variables.
2025-04-24 14:21:21 -04:00
gingerBill
fe040d1bbd
Propagate @(link_section=<string>) to nested declarations
2025-04-08 11:36:53 +01:00
gingerBill
168a41ba2c
Fix #4803
2025-03-07 10:33:41 +00:00
Barinzaya
ef83f2115a
Implemented #reverse for for in bit_set.
2025-03-02 16:24:18 -05:00
Barinzaya
36d5e09419
Re-implemented for on bit_sets to use CTZ.
...
This solution is both faster at run-time and a simpler implementation
than the original solution, which required separate cases for enums and
ranges.
2025-02-28 06:51:14 -05:00
gingerBill
46a8991d0f
Canonicalize generated procedures
2025-02-24 14:19:02 +00:00
gingerBill
99d91ccd31
Work on making name mangling deterministic
2025-02-17 11:32:49 +00:00
gingerBill
328d893cb5
#unroll(N) for
2025-01-10 12:22:18 +00:00
gingerBill
7b334d2bd9
Add #branch_location
2025-01-01 17:26:15 +00:00
Laytan Laats
fa39d87f88
properly keep track of current scope for debugging
...
Fixes #4519
2024-11-27 20:55:48 +01:00
bobsayshilol
e67692b066
Avoid member access through nullptr in debug
...
If |result_count| is 0 then |results| will be a nullptr and hence the
access |results->Tuple| is undefined behaviour. There's already an
early return in the 0 branch so move that to be the first thing so that
we can guarantee that it's not a nullptr.
Note that technically we take the address of the result so it's not
actually dereferencing it, however UBSan doesn't care about that.
2024-10-27 22:02:34 +00:00
Laytan Laats
da1e09c95d
check packed load and set alignment on all loads, not just lb_emit_load
2024-10-25 15:23:15 +02:00
Laytan
722b638e2c
"fix" #4169 , looks like llvm 14 bug
2024-08-31 19:40:05 +02:00
gingerBill
476030dd28
Fix #4156
2024-08-31 13:51:35 +01:00
gingerBill
2a0785037b
Fix switch val in ptr
2024-08-19 12:19:45 +01:00
gingerBill
95c3b8a8de
Move assert to else branch
2024-08-18 22:45:26 +01:00
Laytan Laats
99aa0d3a35
fix type switching over internal pointer union
...
Fixes #3947
2024-08-12 00:02:05 +02:00
gingerBill
5cefab8229
Fix case: in type switch issue
2024-07-15 13:22:50 +01:00
gingerBill
d78ff0be52
Fix lb_store_type_case_implicit
2024-07-04 13:20:36 +01:00
gingerBill
bea47db495
Allow @(rodata) on @(static) variables
2024-06-06 15:20:47 +01:00
gingerBill
e05315831f
Fix #3586
2024-05-14 00:18:38 +01:00
gingerBill
393e4a9db6
Generalize Odin call-based "iterators" to work with more than 2-values: for x, y, z, w in iterate(&it)
...
It has an artificial limitation of 100 values because if you need for than that, you're doing something wrong.
2024-04-27 09:53:02 +01:00
gingerBill
b862691d75
Support for in with bit_set
2024-04-01 13:08:07 +01:00
gingerBill
effc71ca43
Fix case: bug with by-ref unions
2024-03-18 12:20:53 +00:00
gingerBill
5107bdc06b
Make lb_type_info use a procedure to load the global value
2024-02-27 15:45:53 +00:00
Laytan Laats
1fc256dd90
Fix divergent proc call in defer
...
Fixes #3216
Fixes #2985
2024-02-21 19:43:34 +01:00
gingerBill
c12eb3ec93
Improve returning a struct directly for certain ABIs; reuse the temp callee return struct memory when needed
2023-11-24 11:44:20 +00:00
gingerBill
65206fe33e
Go through loads of TODOs
2023-08-01 11:39:04 +01:00
gingerBill
62031c24a2
Add extra mutex guards around module value access
2023-07-07 23:35:16 +01:00
gingerBill
ea00619c3b
for &e, i in array and for k, &v in map (alternative to passing the iterable by pointer)
2023-06-26 15:20:40 +01:00
gingerBill
4c17e2e97e
Merge pull request #2552 from jcmoyer/fix-2466
...
Use compound literal storage for ValueDecl lvals
2023-06-08 12:34:40 +01:00
gingerBill
2bc5e0ebd7
Fix non-constant compound literals of slices
2023-06-07 00:10:39 +01:00
gingerBill
4a75a1e839
Merge branch 'master' into separate-int-word-sizes
2023-06-06 22:42:04 +01:00
gingerBill
837ba6c33b
Minor change to #reverse for logic; add comments explaining it
2023-05-30 00:21:40 +01:00
gingerBill
e0530df98a
Support #reverse for strings
2023-05-29 23:45:21 +01:00
gingerBill
f07453d0ae
Support #reverse on #soa arrays
2023-05-29 23:24:03 +01:00
gingerBill
97490c6445
Basic support for #reverse for in on normal arrays
2023-05-29 23:17:06 +01:00
J.C. Moyer
4d5a442d1f
Use compound literal storage for ValueDecl lvals
...
Prior to this commit, if a variable was initialized using a compound
literal, its associated storage would not be set. This commit makes the
variable always take on the storage of the compound literal.
Fixes #2466
2023-05-21 16:43:34 -04:00
gingerBill
685f7d0fea
Rename word_size to ptr_size internally to make it clearer
2023-04-20 12:18:13 +01:00
gingerBill
bfb231fb8a
Simplify copy elision on variable declarations
2023-03-16 17:24:29 +00:00
gingerBill
93f7d3bfb9
Allow case nil within a type switch statement (experimental idea)
2023-03-12 16:33:21 +00:00