Brendan Hansknecht
6dc5bfb1b7
Use roc_target over target_lexicon
...
Tailors a target class for our needs.
Replaces tons of uses across the entire compiler.
This is a base for later adding new targets like thumb.
2024-03-31 10:50:26 -07:00
Richard Feldman
ada83561e5
Split ListLen into ListLenU64 and ListLenUsize
...
The usize one gets used internally for things like
pattern matches. This is both more efficient (means
they don't have to do unnecessary casts) and also
less error-prone due to e.g. comparing length to
capacity, which is usize.
2024-02-14 21:00:49 -05:00
Folkert
1e744dca7c
missing functions for dev backend for glue
2024-01-27 14:51:09 +01:00
Folkert
104c44a754
ensure that when a switch case uses a callee-saved register, that register gets stored/restored properly
2023-11-25 20:18:37 +01:00
Brendan Hansknecht
398bf2f96c
update rust code to llvm-16 and fix build
...
also update:
- llvm frame address
- erased function type
- dec passing to zig
- gen dev storage size
2023-10-23 13:50:31 -07:00
Folkert
c2216dfc9f
the actual fix
2023-10-09 15:24:43 +02:00
Folkert
5f9008fbcc
on x86 (systemv, haven't checked windows) pass small structs via registers
2023-10-09 15:24:32 +02:00
Folkert
0d665a89b0
give the free float registers
2023-09-16 16:28:36 +02:00
Folkert
fdacfce108
all gen-dev tests work again
2023-09-14 14:43:28 +02:00
Folkert
5e4f43e1d8
checkpoint
2023-09-14 14:43:24 +02:00
Folkert
45ce8e4da6
stack allocate with alignment
2023-09-14 14:38:32 +02:00
Folkert
bb97b9ff74
cleanup
2023-07-30 20:44:10 +02:00
Folkert
f59eed6366
so close
2023-07-30 20:44:10 +02:00
Folkert
8c99cdf817
working codegen
2023-07-30 20:44:07 +02:00
J.Teeuwissen
80faf0eeee
removed borrow.rs
2023-07-30 14:03:38 +02:00
Ayaz Hafiz
7ea85e44d2
Add Layout::Erased
2023-07-12 14:43:24 -05:00
Ayaz Hafiz
929579d51d
Fix
2023-07-12 14:14:25 -05:00
Ayaz Hafiz
6312d75ee0
Add FunctionPointer layout
2023-07-12 13:59:50 -05:00
Folkert
6a19009acf
32-bit float mov instruction
2023-07-09 15:47:29 +02:00
Folkert
17512873e8
add LayoutRepr::Ptr
2023-06-24 14:49:45 +02:00
Ayaz Hafiz
bc41db2a34
Get rid of passing target_info a bunch
2023-06-17 18:13:00 -05:00
Folkert
2eaf158053
fix register not cleared before reading bool
2023-06-11 15:29:20 +02:00
Ayaz Hafiz
457cdabc5c
Make repr private and accessible only via the interner
2023-06-06 16:01:27 -05:00
Folkert
58d4ae91d2
clippy
2023-05-31 23:57:36 +02:00
Folkert
e33c2b3c84
first working linked list test
2023-05-31 23:57:36 +02:00
Ayaz Hafiz
a67c148be7
Convert LayoutRepr::Struct into a tuple variant
2023-05-16 11:58:16 -05:00
Brian Carroll
cfcd2a5289
Merge pull request #5312 from roc-lang/dev-refcount-seamless-slice
...
Dev refcount seamless slice
2023-05-14 18:37:23 +01:00
Folkert
8ba3fd082d
dev backend: treat box like a machine-sized integer when storing to register
2023-05-14 15:20:42 +02:00
Ayaz Hafiz
1b84cbafe3
Only compare reprs in gen_dev
2023-05-11 12:48:38 -05:00
Ayaz Hafiz
c3eeb5e2cc
Wrap layouts in a LayoutRepr
constructor
...
Part 1 of support semantic layout representations.
2023-05-10 13:22:10 -05:00
Folkert
e12a7f4f81
refactor nasty loops into recursive functions
2023-05-03 14:43:31 +02:00
Folkert
d6885ec17a
implement List.dropAt
2023-05-02 23:30:06 +02:00
Folkert
fb123b8990
lambda set unwrapping
2023-05-02 22:31:57 +02:00
Folkert
0fa85fe91d
don't copy zero-sized types to the stack
2023-05-02 22:31:57 +02:00
Folkert
ac64e4ab87
fix for re-used DEV_TMP symbol
2023-05-02 22:31:55 +02:00
Folkert
29bc9a2e85
short-circuit loading field from size 0 struct
2023-05-02 22:31:52 +02:00
Folkert
9f8077c3a3
allow no_data return value
2023-05-01 18:41:50 +02:00
Folkert
2aca07d889
asserted restrictions have been lifted
2023-04-27 00:43:59 +02:00
Folkert
2e41ef68b0
cleanup
2023-04-23 20:23:35 +02:00
Folkert
f7e3254a35
unwrap lamda set to runtime representation
2023-04-23 17:56:23 +02:00
Folkert
9f8fb61281
fix assert
2023-04-09 16:49:19 +02:00
Folkert
679337e4c4
fix alignment issue in union creation
2023-04-09 15:13:24 +02:00
Folkert
9dd69f6f9c
Revert "WIP fix for zig functions returning Bool (strEqual)"
...
This reverts commit 09b01893c6
.
2023-04-08 16:56:25 +02:00
Folkert
09b01893c6
WIP fix for zig functions returning Bool (strEqual)
2023-04-08 16:11:04 +02:00
Folkert
ab2cc76717
special-case true/false loading
2023-04-08 13:30:35 +02:00
Folkert
a7aa9530b6
load literal symbols when inserting a jump
2023-04-08 13:15:22 +02:00
Folkert
f1fa014524
support 128-bit literals
2023-02-26 15:11:49 +01:00
Folkert
808262892e
fix off-by-one error in loop condition
2023-02-18 16:42:47 +01:00
Folkert
b2a875c355
use debug_assert_eq
2023-02-18 16:42:47 +01:00
Folkert
a3d5e7bee5
fully implement sign/zero extension
2023-02-18 16:42:46 +01:00