Commit graph

41 commits

Author SHA1 Message Date
Ayaz Hafiz
50826d1a83
Inline interners into the layout interner module
I realized that we'll need to make the layout interner more complicated
to support things like recursive pointers pointing to their parents and
to support lambda set layout caching. Since the layout interner is the
only user of intern crate right now anyway, just inline the whole thing.
2023-01-03 14:19:39 -06:00
Ayaz Hafiz
972046445b
Lift Niche from just captures-niche to generic niche 2022-12-29 18:43:26 -06:00
Ayaz Hafiz
7ab7fdfa7b
Push interned layouts as mut throughout the backend, and intern box layouts 2022-12-28 18:51:26 -06:00
Folkert
f76df8a356
make dbg transparent to refcounting 2022-12-22 01:03:03 +01:00
Ayaz Hafiz
d660016b53
Clippy 2022-12-03 23:43:47 -06:00
Ayaz Hafiz
ea386bf0af
Dont remove stmt_error 2022-11-24 14:46:54 -06:00
Ayaz Hafiz
ce5636d94f
Get rid of stmt_runtime_error in gen-wasm 2022-11-24 14:46:54 -06:00
Ayaz Hafiz
803d7e30e3
Eliminate Stmt::RuntimeError in favor of crash 2022-11-24 14:46:53 -06:00
Ayaz Hafiz
32400e37e1
Implement crash in gen-wasm 2022-11-24 14:46:52 -06:00
Ayaz Hafiz
c7ef1668d4
Implement mono of crash 2022-11-24 14:46:51 -06:00
Ayaz Hafiz
d33985db92
RocStr roc_panic for wasm gen 2022-11-24 14:46:51 -06:00
Ayaz Hafiz
2b49aee3d2
Pull out string literal creation 2022-11-24 14:46:51 -06:00
Brian Carroll
e57ca0aa12
Remove "Roc host" specifics from Wasm dead code elimination 2022-11-16 08:07:22 +00:00
Brian Carroll
ddddb7d4f1
Fix import relocations in CodeBuilder. 2022-11-15 09:36:59 +00:00
Brian Carroll
4dea82b2f5
Move code_builder from wasm_module to gen_wasm 2022-11-14 09:18:53 +00:00
Brian Carroll
2e67bdf4d0
Move some wasm constants and macros 2022-11-13 09:03:26 +00:00
Brian Carroll
63d9187343
move wasm_module out of gen_wasm 2022-11-13 09:03:08 +00:00
Folkert
66a1ba00eb
1.65 clippy fixes 2022-11-03 16:20:37 +01:00
Ayaz Hafiz
3b4b1838b8
Push layout interner further through Layout 2022-08-31 14:33:52 -05:00
Folkert
a22e04361c
Merge remote-tracking branch 'origin/main' into expect-fx-codegen 2022-08-23 16:28:21 +02:00
Ayaz Hafiz
79a5766854
Make method private 2022-08-19 22:16:47 -05:00
Ayaz Hafiz
b7c799702f
wasm: store closure data passed to higher-order low-level in struct, not box 2022-08-19 22:16:47 -05:00
Ayaz Hafiz
15ef517cf2
gen-wasm: box captured data before passing it to a higher-order lowlevel
Previously, when it existed, captured data would always be represented
as a struct, and hence implicitly boxed. That meant that passing
captured data would always pass a pointer. However, now, captured data
can live unwrapped. This poses a challenge for the higher-order
lowlevels, which always expect captures data to be passed as an opaque
pointer. As such, always box captured data.

It's possible to optimize this so that only unwrapped captures data
needs to be boxed; however, that is not attempted in this patch.
2022-08-19 22:16:41 -05:00
Folkert
10b6f33ed2
boilerplate 2022-08-12 13:34:36 +02:00
Brian Carroll
dd040d5f73
wasm: add stack_bytes field to Env 2022-08-08 21:41:25 +01:00
Brian Carroll
11929a7b6d
wasm: set memory layout after code gen, when we know the amount of const data 2022-08-07 21:34:49 +01:00
Brian Carroll
aa0e9e8d31
wasm: Get RC reset/reuse working correctly 2022-08-06 09:58:47 +01:00
Brian Carroll
7f44ace383
wasm: nicer debug output for Let statements 2022-08-04 12:30:25 +01:00
Brian Carroll
5c6eed570d
wasm: Ensure List literals have an initialized capacity field 2022-07-29 15:18:15 +02:00
Folkert
c09cb4e3ea
fix stack size of empty tag union 2022-07-23 23:10:56 +02:00
Folkert
e6104ee52f
update api usage in wasm backend 2022-07-22 21:13:53 +02:00
Folkert
d1f7b0fc5a
wasm: store tag id right after the content 2022-07-09 14:28:41 +02:00
Brian Carroll
c9a1600751
wasm: Fix List.map where the mapper has zero-size arguments 2022-07-07 00:05:56 +01:00
Brian Carroll
f132350ef3
wasm: implement List.sortWith 2022-07-06 22:01:01 +01:00
Ayaz Hafiz
8855f269ba
Make captures niche more private 2022-07-03 10:37:36 -04:00
Ayaz Hafiz
019ebd93f7
Put the capture niche in the lambda name instead of generating new names 2022-07-03 10:37:29 -04:00
Ayaz Hafiz
51978e08ed
First pass at supporting multimorphic lambdas in lambda sets 2022-07-03 10:37:26 -04:00
Brian Carroll
7ea9854e49
wasm: Refactor and bug-fix copy_value_from_memory 2022-07-03 10:22:11 +01:00
Brian Carroll
07a432581f
wasm: start implementing Box and Unbox (bugs!) 2022-07-03 09:47:53 +01:00
Brian Carroll
219e6d11cf
Merge branch 'trunk' of github.com:rtfeldman/roc into pure-roc-list-walk 2022-07-02 18:08:43 +01:00
Anton-4
eee85fa45d
moved all crates into seperate folder + related path fixes 2022-07-01 17:37:43 +02:00
Renamed from compiler/gen_wasm/src/backend.rs (Browse further)