-
Notifications
You must be signed in to change notification settings - Fork 998
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
List types memory tracking is inaccurate #3800
Comments
Same for strings, this is a duplicate. One sec |
duplicate of #3723 |
I think this bug is better defined than #3723 because it clearly shows how to reproduce it. In fact, even an external contributor can try fixing it. |
It reproduces in the test I added as well 😄 Sure let's keep it though |
It could be nice if we could account for memory usage for lists in O(1) time. |
Also remove unused quicklist function. Relates to #3800 Signed-off-by: Roman Gershman <[email protected]>
Seems that quicklistNodeUpdateSz and __quicklistCompress are places where we should update |
Also remove unused quicklist function. Relates to #3800 Signed-off-by: Roman Gershman <[email protected]>
Discussed with roman and agreed this will require bigger changes than expected, so unassigning myself |
@andydunstall / @romange, can you please elaborate on what you've learned that make this bigger than originally expected? Is it not enough to add accounting in |
It is enough but I did not feel comfortable to do intrusive changes to quicklist.cc |
@adiholden I am assigning to myself since I am doing changes in that area. |
After running `debug POPULATE 100 list 100 rand type list elements 10000` with `--list_experimental_v2=false`: ``` type_used_memory_list:16512800 used_memory:105573120 ``` When running with `--list_experimental_v2=true`: ``` used_memory:105573120 type_used_memory_list:103601700 ``` Fixes #3800 Signed-off-by: Roman Gershman <[email protected]>
After running `debug POPULATE 100 list 100 rand type list elements 10000` with `--list_experimental_v2=false`: ``` type_used_memory_list:16512800 used_memory:105573120 ``` When running with `--list_experimental_v2=true`: ``` used_memory:105573120 type_used_memory_list:103601700 ``` TODO: does not yet handle compressed entries correctly but we do not enable compression by default. Fixes #3800 Signed-off-by: Roman Gershman <[email protected]>
After running `debug POPULATE 100 list 100 rand type list elements 10000` with `--list_experimental_v2=false`: ``` type_used_memory_list:16512800 used_memory:105573120 ``` When running with `--list_experimental_v2=true`: ``` used_memory:105573120 type_used_memory_list:103601700 ``` TODO: does not yet handle compressed entries correctly but we do not enable compression by default. Fixes #3800 Signed-off-by: Roman Gershman <[email protected]>
Create a list with 1,000,000 entries, consuming 1,000 bytes each:
Then inspect it:
(this means each element in the list takes 21 bytes)
This is also shown in:
The text was updated successfully, but these errors were encountered: