summaryrefslogtreecommitdiff
path: root/compiler/optimizing/graph_test.cc
diff options
context:
space:
mode:
author Santiago Aboy Solanes <solanes@google.com> 2025-02-06 16:13:06 +0000
committer Santiago Aboy Solanes <solanes@google.com> 2025-02-06 16:52:51 +0000
commitb6714bc1835e99e49d1175bb639bd91ebebe334d (patch)
treec1dd1a01cfbc0327221fb9730451fe4ad20d8e7f /compiler/optimizing/graph_test.cc
parent3428f9be71b0d20978d11d63b5d82962b88d02bf (diff)
Reduce HashSet's kMinBuckets to 10
HashSet (and its child classes like HashMap) used to have a big kMinBuckets which slowed down compilation times. The idea behind such number was to start with a big table and avoid resizing. However, this is not efficient as e.g. we sometimes create a table way bigger than what we need. This also has a performance impact in cases where we clear HashMaps to be reused. The problem there is that `clear()` will deallocate the storage which will be reallocated when something is inserted. Since kMinBuckets was 1000, it meant that said first insertion would be very costly. From local compiles, it improves ~1.3-2% of compile time. Both Scheduling and WriteBarrierElimination greatly benefit from this change. Bug: 393108375 Test: art/test/testrunner/testrunner.py --host --64 -b --optimizing Change-Id: I49b305145398bb748a3bc6153a3c281c758eba6f
Diffstat (limited to 'compiler/optimizing/graph_test.cc')
0 files changed, 0 insertions, 0 deletions