aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/bin
diff options
context:
space:
mode:
authorMitko Haralanov <[email protected]>2016-02-03 14:34:41 -0800
committerDoug Ledford <[email protected]>2016-03-10 20:37:54 -0500
commita92ba6d628d362811c8112280826de0e8b178e67 (patch)
tree67f5baf2a50123254f324d3ac62c5ff7abfd3b1c /tools/perf/scripts/python/bin
parente002dcc0abd318b0c5d7b2d05ba41ef4d00abe73 (diff)
staging/rdma/hfi1: Improve performance of TID cache look up
When TID caching was enabled, the way the driver found RB nodes when PSM was unprogramming TID entries was by traversing the RB tree, looking for a match on the RcvArray entry index. The performance of this algorithm was not only poor but also inconsistent depending on how many RB nodes would have to be traversed before a match was found. The lower performance was especially evident in cases where there was a cache miss with the cache full, requiring the unprogramming of several TID entries. This commit changes how RB nodes are looked up when being free'd by PSM to a index-based lookup into a flat array on the index of the RcvArray entry. This turns the entire look-up process into an O(1) algorithm. Special care needs to be taken for situations when TID caching is disabled. In those cases, there is no need to insert the RB nodes into an actual RB tree. Since the entire RcvArray management mechanism is managed by an index-based algorithm, the RB nodes can be saved into the flat array, making both "insertion" and "removal" faster. Reviewed-by: Arthur Kepner <[email protected]> Reviewed-by: Dennis Dalessandro <[email protected]> Signed-off-by: Mitko Haralanov <[email protected]> Signed-off-by: Jubin John <[email protected]> Signed-off-by: Doug Ledford <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions