Leonardo de Moura
81545c12f2
chore(runtime/object): fix comment
2018-09-11 14:31:14 -07:00
Leonardo de Moura
46d6f7bfb5
chore(runtime/object): store function pointer as void * inside closure
2018-09-11 14:27:45 -07:00
Leonardo de Moura
e8fa692611
chore(runtime/object): change default object_memory_kind to STHeap
2018-09-11 13:57:55 -07:00
Leonardo de Moura
5bc9b07ab9
feat(runtime/object): split Heap into MTHeap and STHeap
2018-09-09 14:46:28 -07:00
Leonardo de Moura
0573d7e1d5
fix(runtime/object): parray RC bugs
2018-09-09 12:04:27 -07:00
Leonardo de Moura
b45ac3fcc0
chore(runtime/object): minor
2018-09-09 10:59:36 -07:00
Leonardo de Moura
36423e4389
fix(runtime): parray memory leaks
2018-09-09 10:33:15 -07:00
Leonardo de Moura
4863ca071a
chore(runtime): make sure we use the same naming convention for getters and setters
2018-09-09 10:07:00 -07:00
Leonardo de Moura
8f195515a6
feat(runtime): add persistent arrays to runtime
2018-09-09 09:44:38 -07:00
Leonardo de Moura
3770df2a48
fix(runtime/apply): must use free_heap_obj instead of free
2018-08-28 12:29:14 -07:00
Leonardo de Moura
5c3678482f
chore(runtime/object): cleanup
2018-08-28 12:29:04 -07:00
Leonardo de Moura
3e528a9b67
chore(runtime): fix assertions
2018-08-28 10:33:22 -07:00
Leonardo de Moura
4d6da3dd69
fix(runtime/compact): bug at read
2018-08-28 10:30:51 -07:00
Leonardo de Moura
b63b05e5fd
fix(runtime/thread): MULTI_THREAD=OFF build
2018-08-28 08:08:55 -07:00
Leonardo de Moura
030669ea4d
feat(runtime): do not waste space with RC for region and stack allocated objects
...
The modification introduces an overhead of 1.5% on the
execution time. Here is the the time for compiling the corelib
Before: 8.61 secs (avg of 3 runs)
After: 8.74 secs (avg of 3 runs)
On the other hand, the size of the compacted region for the command
`#compact_tst 10` is smaller.
Before: 176687728
After: 153794704
The size before this change was 14.8% bigger.
For reference, using the old serializer we generate a buffer of size 105291117.
cc @kha
2018-08-28 07:41:55 -07:00
Leonardo de Moura
fdcbf3fe9e
chore(runtime/object): "section comments"
2018-08-22 17:53:11 -07:00
Leonardo de Moura
3ab1ebcb3f
feat(init/core): add task
2018-08-21 16:10:07 -07:00
Leonardo de Moura
0b349f1abf
chore(*): fix style
2018-08-21 09:32:01 -07:00
Leonardo de Moura
38b23431a3
chore(runtime/compact): add inline
2018-08-20 15:30:21 -07:00
Leonardo de Moura
7f9d131a1f
chore(runtime/compact): one alloc per object
2018-08-20 14:46:06 -07:00
Leonardo de Moura
474a0c40c7
fix(runtime/compact): missing memcpy
2018-08-20 10:33:04 -07:00
Leonardo de Moura
dc1f5c0aa6
feat(runtime/object): task API functions can take thunks as arguments
2018-08-20 09:13:35 -07:00
Leonardo de Moura
a27aa53e88
refactor(runtime/compact): save task objects as thunks
...
TODO: modify task API and make sure all functions there can take thunks
instead of tasks as arguments.
2018-08-20 08:52:35 -07:00
Leonardo de Moura
db98397cc0
feat(runtime): object compactor
...
We need more testing and performance testing.
We also need to compare serializer and compacted_region.
2018-08-19 17:10:18 -07:00
Leonardo de Moura
ce504b4c21
feat(runtime/serializer): support for tasks
2018-08-18 14:52:29 -07:00
Leonardo de Moura
684085d93f
refactor(runtime/object): delete data needed to execute task after it finishes
2018-08-18 14:33:27 -07:00
Leonardo de Moura
a0b5502821
fix(runtime/object): memory leak and simplify task_object
...
We remove per task condition_variable and use m_task_finished_cv.
The same condition_variable used to implement `wait_any`.
2018-08-18 10:29:12 -07:00
Leonardo de Moura
d0bc663f0d
chore(runtime/object): avoid ugly handle_finished_rec
...
Users should not rely on the order the dependencies have beed inserted.
If the order matters, priorities should be used instead.
2018-08-17 18:15:58 -07:00
Leonardo de Moura
d52507c4b2
fix(runtime/object): memory leak
2018-08-17 18:12:17 -07:00
Leonardo de Moura
861592fe6a
chore(runtime/object): cleanup
2018-08-17 15:43:01 -07:00
Leonardo de Moura
4bc8414d2b
feat(runtime/object): use "weak pointers" in the task manager, and interrupt tasks at GC time
2018-08-17 15:35:00 -07:00
Leonardo de Moura
24444d65c4
refactor(runtime/object): do not use Lean runtime lists to implement the reverse dependency list in task objects
2018-08-17 14:42:43 -07:00
Leonardo de Moura
1d5411f455
feat(runtime/object): add support for io.wait_any
2018-08-17 13:04:06 -07:00
Leonardo de Moura
5f78087b08
feat(runtime/object): add support for io.has_finished
2018-08-17 12:36:48 -07:00
Leonardo de Moura
5e63e7806c
chore(runtime/object): cleanup
2018-08-17 12:32:47 -07:00
Leonardo de Moura
ae9eac6781
feat(runtime/object): simplify and more tests
2018-08-17 09:41:22 -07:00
Leonardo de Moura
c863e86429
feat(runtime/object): primitives for interrupting threads
2018-08-17 09:25:40 -07:00
Leonardo de Moura
0a2e9c109f
fix(runtime/object): memory leak and violation at task_bind
2018-08-17 09:03:45 -07:00
Leonardo de Moura
f5ecd8477f
fix(runtime/object): memory leak
2018-08-17 08:47:29 -07:00
Leonardo de Moura
168eaefff5
fix(runtime/object): finalization and avoid leak
2018-08-17 08:32:33 -07:00
Leonardo de Moura
cc13c8ee7f
refactor(runtime/object): remove unnecessary, fix malloc/delete mismatch
2018-08-17 08:10:05 -07:00
Leonardo de Moura
018542e2e1
fix(runtime/object): task bugs
2018-08-16 21:28:58 -07:00
Leonardo de Moura
066fbf2d5b
refactor(runtime/object): remove state field
2018-08-16 20:46:14 -07:00
Leonardo de Moura
584eddee01
feat(runtime/object): add support for tasks
...
This is just the first draft. We still need a lot of testing.
2018-08-16 19:09:50 -07:00
Leonardo de Moura
d14831c470
fix(runtime/apply): apply should use the standard calling convention
2018-08-15 21:07:54 -07:00
Leonardo de Moura
c3be026645
chore(runtime/object): document calling convention for runtime primitives
2018-08-15 20:10:43 -07:00
Leonardo de Moura
74d94432da
fix(runtime/object): make thunk_get thread safe
2018-08-15 15:34:15 -07:00
Leonardo de Moura
4ec43a84ca
chore(runtime/object): document standard/borrowed calling convetion
2018-08-14 17:43:00 -07:00
Leonardo de Moura
bcb37ef862
feat(runtime): thunk serialization
2018-08-14 15:15:12 -07:00
Leonardo de Moura
f036a7ad16
chore(runtime/object): mk_thunk(c) should not modify c's RC
...
This is useful when we are generating a function that does not use the
"borrow semantics" for an argument `c` which is used in `mk_thunk(c)`.
2018-08-10 18:11:29 -07:00