Commit graph

697 commits

Author SHA1 Message Date
Brian Carroll
f1cadbcc05
Merge branch 'trunk' of github.com:rtfeldman/roc into wasm-linking-test-improvements 2022-06-17 23:20:05 +01:00
Brian Carroll
ba7f336e53
wasm: Fix linking bug in calls from Roc to JS 2022-06-17 23:18:18 +01:00
Brian Carroll
e416b70e08
wasm: fix double-counting of host-to-app linking dummies 2022-06-17 22:04:18 +01:00
Brian Carroll
7f47bd8ced
wasm: better comment for call_indirect DCE 2022-06-17 08:18:24 +01:00
Brian Carroll
c12098bffd
wasm: create NameSection::from_imports_and_linking_data 2022-06-17 07:51:07 +01:00
Brian Carroll
3d8d184901
wasm: fix some out-of-bounds errors in DCE 2022-06-16 00:27:51 +01:00
Brian Carroll
328eaaa861
wasm: link host-to-app calls after creating the name section rather than before 2022-06-16 00:27:10 +01:00
Brian Carroll
6452961ea4
wasm: Don't crash if debug names are missing 2022-06-16 00:24:09 +01:00
Brian Carroll
0fef1e1576
Create to_exposed_symbol_string helper function for all backends 2022-06-15 22:30:10 +01:00
Brian Carroll
6e30811b0c
wasm: use a BitVec for called host functions 2022-06-15 21:31:10 +01:00
Brian Carroll
c1aa9f229a
wasm: move linking tests to test_gen and execute the module 2022-06-15 20:20:55 +01:00
Brian Carroll
115c2b524e
wasm: add some more assertions to linking DCE test 2022-06-15 20:20:55 +01:00
Brian Carroll
87e020fcca
wasm: tweak comments 2022-06-15 20:20:54 +01:00
Folkert
71ae32e55a
use bitwise or to mark functions as live 2022-06-15 15:48:22 +02:00
Folkert
edb801c094
use a bitvec to store indices of functions in a pass 2022-06-15 15:36:23 +02:00
Brian Carroll
ffec060490
clippy 2022-06-14 10:20:28 +01:00
Brian Carroll
c6b5f4934f
wasm: swap instead of copying, during DCE call graph tracing 2022-06-14 09:50:10 +01:00
Brian Carroll
6e098d9d63
wasm: dead code elimination for indirect calls 2022-06-14 09:46:32 +01:00
Brian Carroll
c34b278402
wasm: generate debug names separately from host lookup, including local symbols 2022-06-13 18:20:15 +01:00
Brian Carroll
71225ee5f2
wasm: tidy up after self-review 2022-06-13 17:40:45 +01:00
Brian Carroll
8493c8cfca
Merge branch 'trunk' of github.com:rtfeldman/roc into wasm-dce-imports 2022-06-13 08:41:41 +01:00
Brian Carroll
e8069bf256
wasm: Bugfix: don't forget to include code section length during preload DCE 2022-06-13 00:32:47 +01:00
Brian Carroll
acebdee3dd
wasm: fix DCE for signatures and debug names 2022-06-13 00:32:47 +01:00
Brian Carroll
c169815c9e
wasm: fix some DCE bugs 2022-06-13 00:32:47 +01:00
Brian Carroll
a224d89050
wasm: Start preloaded_bytes at the section start for better consistency 2022-06-13 00:32:44 +01:00
Brian Carroll
f6f7672e1c
wasm: rename DEBUG_LOG_SETTINGS->DEBUG_SETTINGS and add skip_dead_code_elim 2022-06-12 20:45:43 +01:00
Brian Carroll
6d39f50bcc
wasm: use linking data to implement call graph tracing for DCE 2022-06-12 20:42:09 +01:00
Brian Carroll
9b15a9b99b
wasm: Don't create a _start if we already have one! 2022-06-11 23:40:49 +01:00
Brian Carroll
c6e982e5c0
wasm: if we have no debug info, get it from the linker symbol table 2022-06-11 23:21:18 +01:00
Brian Carroll
f926650b10
wasm: remove some roc_ prefixes from host symbols 2022-06-10 21:53:51 +01:00
Brian Carroll
89811d5ae3
wasm: linking tests with and without DCE 2022-06-10 21:49:45 +01:00
Brian Carroll
323e628d17
wasm: Use a Vec instead of an Iter 2022-06-10 21:48:57 +01:00
Brian Carroll
3c0e1d75e5
wasm: linking test working 2022-06-10 18:09:42 +01:00
Brian Carroll
59c0d531c6
wasm: Get linker test to run (without asserting anything yet) 2022-06-10 10:49:22 +01:00
Brian Carroll
2dfe318329
wasm: Don't fail if Name section is missing, it's only debug info 2022-06-10 10:48:03 +01:00
Brian Carroll
d354c3a730
wasm: Don't fail if DataCount section is missing 2022-06-10 10:47:28 +01:00
Brian Carroll
d455efeab0
wasm: only panic on missing __heap_base if app actually allocates 2022-06-10 10:46:13 +01:00
Brian Carroll
da17df09df
wasm: build a linking test app in mono IR 2022-06-10 00:02:45 +01:00
Brian Carroll
5c15fc1629
wasm: Implement ForeignCall 2022-06-09 22:53:15 +01:00
Brian Carroll
50ea6ec41c
wasm: delete c test host 2022-06-09 22:14:02 +01:00
Brian Carroll
757d3dd443
wasm: rewrite test host in zig 2022-06-09 22:12:51 +01:00
Brian Carroll
2b7ec63226
wasm: start creating a test for linking 2022-06-09 22:12:01 +01:00
Richard Feldman
f45d1281f7
Merge pull request #3137 from rtfeldman/expect-report
Expect report
2022-06-08 10:13:35 -04:00
Brian Carroll
967f723ca1
wasm: add some TODO comments 2022-06-08 08:07:22 +01:00
Brian Carroll
1bf27fe782
wasm: update Symbols when we are relocating them 2022-06-08 07:54:48 +01:00
Brian Carroll
c00b43c36b
wasm: Move some of the DCE code from CodeSection to WasmModule 2022-06-07 23:52:33 +01:00
Brian Carroll
dfda992d93
wasm: first draft DCE for imports 2022-06-07 22:01:17 +01:00
Brian Carroll
87deb1c13c
wasm: fix bug in dead code elimination 2022-06-06 23:17:47 +01:00
Brian Carroll
87cb9298d9
wasm: insert _start function to call host main 2022-06-06 23:17:46 +01:00
Brian Carroll
27ecf4424f
wasm: get hello-world to build (but not run yet!) 2022-06-06 15:23:36 +01:00