mccolljr / segvec

SegVec data structure for rust. Similar to Vec, but allocates memory in chunks of increasing size.
MIT License
33 stars 4 forks source link

MemConfig memory grow policies #18

Closed cehteh closed 1 year ago

cehteh commented 1 year ago

I hacked some Policies for linear, proportional and exponential growth together. Just for review, do-not-merge. Nothing integrated yet, more will follow up at slow pace.

mccolljr commented 1 year ago

@cehteh Thanks for working on this! I like what you've got so far. Sorry, I've been busy and haven't had a ton of time to spend on this. I will try to get back into it this weekend - if you are working on this, I will take a stab at generalizing the storage implementation into a set of traits so that a user can select their particular storage structure without having to use feature flags.

cehteh commented 1 year ago

On 2023-06-09 05:29, Jacob Ryan McCollum wrote:

@cehteh Thanks for working on this! I like what you've got so far. Sorry, I've been busy and haven't had a ton of time to spend on this. I will try to get back into it this weekend - if you are working on this, I will take a stab at generalizing the storage implementation into a set of traits so that a user can select their particular storage structure without having to use feature flags.

Np. no urge. I want to propose some changes in future and working slowly on this. Integrating this MemConfig comes next. Later making the ctor const again, this may need to kiss thinvec a goodbye, I hope you are ok with that (I don't see an advantage using thinvec, but maybe I am missing something). Eventually using SmallVec can become default, not sure about that but I don't see a problem with that. I'll also want to profile the changes I introduced with MemConfig and play with a cache impl as I noted as idea. I am busy with other things as well so there is no real timeframe/urge to complete these ideas.

-- Reply to this email directly or view it on GitHub: https://github.com/mccolljr/segvec/pull/18#issuecomment-1584496107 You are receiving this because you were mentioned.

Message ID: @.***>

cehteh commented 1 year ago

Closing this, since work moved to another branch/PR