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
The use of the std::priority_queue in the C++ matching code (match_one_against_many_dice_k_top), is the main bottleneck when k is large. There a few deficiencies that may be negatively impacting performance. For example:
Extensive use of priority_queue::pop() in loops as though it were O(1) when it is in fact O(log n).
AoS memory layout of the queue elements (struct Node) when SoA would probably be better.
Possibly unnecessary maintenance of the queue invariant when k is small (a qsort at the end might do).
The use of the
std::priority_queue
in the C++ matching code (match_one_against_many_dice_k_top
), is the main bottleneck whenk
is large. There a few deficiencies that may be negatively impacting performance. For example:priority_queue::pop()
in loops as though it were O(1) when it is in fact O(log n).struct Node
) when SoA would probably be better.k
is small (aqsort
at the end might do).Some potentially useful resources:
Aha! Link: https://csiro.aha.io/features/ANONLINK-70
The text was updated successfully, but these errors were encountered: