Migrates thread local free slot storage from std::list to std::vector.#44859
Migrates thread local free slot storage from std::list to std::vector.#44859ggreenway merged 2 commits intoenvoyproxy:mainfrom
std::list to std::vector.#44859Conversation
…hash_set. Signed-off-by: Biren Roy <birenroy@google.com>
|
/assign @adisuissa |
adisuissa
left a comment
There was a problem hiding this comment.
Thanks!
I believe that an std::vector is probably the most optimized data-structure that can be used as a stack to tackle the free_slot_indexes_ accounting (at least from a previous life experience of using different data-structures). WDYT?
Signed-off-by: Biren Roy <birenroy@google.com>
std::list to absl::flat_hash_set.std::list to std::vector.
Sure. The pseudo-random hash set iteration order seemed like a reasonable compromise between the FIFO of the previous version and the LIFO of a vector solution, but it probably doesn't matter. |
I'm not sure why FIFO was used in the first place, but I don't see a reason why it is required. I've also reviewed #7979 but didn't get any reason why other data types shouldn't be used. LIFO makes more sense IMHO. |
|
/assign-from @envoyproxy/senior-maintainers |
|
@envoyproxy/senior-maintainers assignee is @wbpcode |
|
/retest |
std::listis not a great choice for a performance critical utility, as it requires a heap operation on every mutation.Commit Message:
Additional Description:
Risk Level:
Testing:
Docs Changes:
Release Notes:
Platform Specific Features: