You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[RF] Don't recreate hash tables in RooLinkedList::Add()
Thanks to #7818, where the `RooHashTable` was migrated to
`std::unordered_map`, we can now use proper `reserve()` functions to
increase the hash table size when adding elements.
The current mechanism deleting and recreating the hash tables from
scratch when the list size changed incurred a pretty large overhead.
In fact, it made adding to the list a `O(n)` operation, because it has
to iterate over the collection to fill the hash table again.
Consequently, copying a `RooLinkedList` was `O(n^2)`, which is
unexpected to the user.
This change will speed up the handling of objects in a RooWorkspace,
which uses `RooLinkedLists` to manage the elemens.
0 commit comments