Brendan Hansknecht
|
2a6c82c937
|
fix bug where we don't decrement elements if the list is non-unique
|
2023-03-16 12:12:28 -07:00 |
|
Brendan Hansknecht
|
a955a4937c
|
misc list refcounting updates
|
2023-03-16 12:12:28 -07:00 |
|
Brendan Hansknecht
|
ce29c7e92f
|
fix bugs from recent changes and additions
|
2023-03-16 12:12:27 -07:00 |
|
Brendan Hansknecht
|
1319ba4844
|
add List.releaseExcessCapacity builtin
|
2023-03-13 17:43:21 -07:00 |
|
Brendan Hansknecht
|
b94a046b0d
|
make sure to check raw capacity when decrementing refcounts
|
2023-03-13 14:08:24 -07:00 |
|
Brendan Hansknecht
|
dfb748fb03
|
misc cleanup + change refcount pointer to avoid branching
|
2023-03-13 14:08:24 -07:00 |
|
Brendan Hansknecht
|
5f6910f747
|
add todo about upgrading to bit manipulation
|
2023-03-13 14:08:24 -07:00 |
|
Brendan Hansknecht
|
f96a63c1d4
|
correct case for zig naming
|
2023-03-13 14:08:23 -07:00 |
|
Brendan Hansknecht
|
146dff5446
|
add llvm refcounting and fix memory leak
|
2023-03-13 14:08:23 -07:00 |
|
Brendan Hansknecht
|
cda37a5d1b
|
use seamless slices for List.dropAt when possible
|
2023-03-13 14:08:23 -07:00 |
|
Brendan Hansknecht
|
4ced1bcfdd
|
add baseline of seamless slices
|
2023-03-13 14:08:23 -07:00 |
|
Brendan Hansknecht
|
e32c5f6514
|
standardize on decref instead of deinit for name
|
2023-03-13 14:08:23 -07:00 |
|
Brendan Hansknecht
|
440c0518f1
|
Change list.deinit to take alignment directly
In doing so remove the many class directly to utils.decref
|
2023-03-13 14:08:22 -07:00 |
|
Folkert
|
0af11c210e
|
fix memory leak in List.concat
|
2023-01-26 20:31:33 +01:00 |
|
Folkert
|
4e5b106f98
|
use capacity instead of length in list deinit
|
2023-01-20 21:44:41 +01:00 |
|
Folkert
|
437498b7ac
|
list decrement must use capacity, not length
|
2023-01-14 13:14:37 +01:00 |
|
Folkert
|
05e23f8c5c
|
decref owned but empty list in List.concat
|
2022-12-29 00:13:24 +01:00 |
|
Folkert
|
2dfa7d6ef1
|
fix memory leak in List.concat
|
2022-12-28 22:52:32 +01:00 |
|
Ayaz Hafiz
|
4df83d67ea
|
use copyBackwards when copying overlapping items in non-unique.unique concat
`mem.copy` requires that `dest` has start index `<= src`, but in our
case, `dest` has start index `>= src`. For this, `copyBackwards` should
be used.
See https://github.com/ziglang/zig/blob/master/lib/std/mem.zig#L195-L222.
Closes #4697
|
2022-12-06 12:58:04 -06:00 |
|
Ayaz Hafiz
|
a549176886
|
Add reproduction of failing unique concat bug
|
2022-12-06 12:57:32 -06:00 |
|
Brendan Hansknecht
|
9f09bebdca
|
run
|
2022-10-17 21:50:25 -07:00 |
|
Brendan Hansknecht
|
1225cb54fc
|
Fix memory leak in List.concat
|
2022-10-17 21:45:46 -07:00 |
|
Brendan Hansknecht
|
96b5d365b2
|
Add capacity growth to RocStr
Also, cleans up the alloc and realloc api for both list and str.
Updates Str.reserve to match List.reserve
|
2022-10-10 22:24:55 -07:00 |
|
Brendan Hansknecht
|
fdafac4323
|
Remove RocResult from utils.zig
It is implemented wrong and not used anywhere
|
2022-10-10 08:25:59 -07:00 |
|
Brendan Hansknecht
|
aca6f2a8f1
|
add todo around improving performance
|
2022-10-08 07:53:50 -07:00 |
|
Brendan Hansknecht
|
8269986113
|
remove comment on zero width types.
They should not affect the normal case. It is better they affect the capacity calculation
|
2022-10-08 07:53:33 -07:00 |
|
Brendan Hansknecht
|
eca4682787
|
deal with zero element_width
That being said, this only affects wasm.
So wasm probably should be handling zero element lists in a smarter way.
|
2022-10-07 17:58:48 -07:00 |
|
Brendan Hansknecht
|
557ee69557
|
fix minor typo
|
2022-10-07 17:11:46 -07:00 |
|
Brendan Hansknecht
|
1665f7160d
|
Fix bug in reallocate
|
2022-10-07 17:11:33 -07:00 |
|
Brendan Hansknecht
|
d06966392f
|
Add smarter list capacity growth calculations
|
2022-10-07 08:59:32 -07:00 |
|
Brendan Hansknecht
|
4ebe1b2bce
|
Avoid allocating a new list when calling List.sublist
|
2022-10-05 08:11:02 -07:00 |
|
Folkert
|
f44a30cf48
|
fix off-by-one error in List.dropAt
|
2022-09-28 14:57:55 +02:00 |
|
Brian Carroll
|
b1b28650e9
|
builtins: Avoid reallocating Lists when they have enough capacity
|
2022-09-04 14:37:42 +01:00 |
|
Folkert
|
56c9787e8f
|
List.appendUnsafe and List.reserve
|
2022-07-07 22:40:28 +02:00 |
|
Brian Carroll
|
40231535fa
|
builtins: Delete Zig implementation of List.mapWithIndex
|
2022-07-04 15:14:32 +01:00 |
|
Folkert de Vries
|
2a82d24847
|
Merge pull request #3369 from rtfeldman/pure-roc-list-walk
List.walk and friends in pure Roc
|
2022-07-03 02:32:43 +02:00 |
|
Folkert de Vries
|
75b4b3a206
|
Merge pull request #3365 from rtfeldman/to-scalars
Add Str.toScalars builtin
|
2022-07-02 23:04:28 +02:00 |
|
Brian Carroll
|
94181111be
|
Merge branch 'trunk' of github.com:rtfeldman/roc into pure-roc-list-walk
|
2022-07-02 21:44:42 +01:00 |
|
Richard Feldman
|
077c37d9fb
|
Use alignCast over intToPtr
|
2022-07-02 15:22:29 -04:00 |
|
Folkert
|
e29a89d33c
|
remove zig implementation of keepIf/keepErrs/keepOks
|
2022-07-02 19:38:38 +02:00 |
|
Richard Feldman
|
1b872022bb
|
Don't let fromSlice allocate when slice is empty
|
2022-07-02 13:13:28 -04:00 |
|
Richard Feldman
|
ce6c2f330c
|
Improve some RocList functions in zig
|
2022-07-02 13:11:43 -04:00 |
|
Richard Feldman
|
6cdf63b319
|
Add some zig helpers to RocList
|
2022-07-02 13:11:42 -04:00 |
|
Richard Feldman
|
ff596f5e75
|
Add RocList.first_elem_ptr to list.zig
|
2022-07-02 13:11:42 -04: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
|
b74fc3554b
|
Merge branch 'trunk' of github.com:rtfeldman/roc into crates-folder
|
2022-07-02 12:35:19 +02:00 |
|
Anton-4
|
b1b9a8dc0a
|
Merge branch 'trunk' of github.com:rtfeldman/roc into crates-folder
|
2022-07-02 10:44:25 +02:00 |
|
Anton-4
|
eee85fa45d
|
moved all crates into seperate folder + related path fixes
|
2022-07-01 17:37:43 +02:00 |
|