diff options
author | 2025-02-17 08:55:37 +0000 | |
---|---|---|
committer | 2025-02-17 23:11:18 -0800 | |
commit | e82d04b37415974cfd85be881f50656610890daf (patch) | |
tree | 0bb0e16e21f976d50bc6b94e2852991b7773d72b /compiler/optimizing/instruction_builder.cc | |
parent | 474e99956e8be96e84404b5be6ad075bb5cb6b79 (diff) |
Optimizing: Speed up `HInstruction::Add{,Env}UseAt()`.
Avoid three dependent loads to fetch the allocator on the
hot paths. Inline the `FixupUserRecordsAfter*UseInsertion()`
loop and use the fact that it's known to execute exactly one
or two iterations.
Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Bug: 181943478
Change-Id: I7fd4d48caebc6aeb13fb9a9f8146a06129c72b2e
Diffstat (limited to 'compiler/optimizing/instruction_builder.cc')
-rw-r--r-- | compiler/optimizing/instruction_builder.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/optimizing/instruction_builder.cc b/compiler/optimizing/instruction_builder.cc index 1f2628c8ec..74880463c3 100644 --- a/compiler/optimizing/instruction_builder.cc +++ b/compiler/optimizing/instruction_builder.cc @@ -305,7 +305,7 @@ void HInstructionBuilder::InitializeInstruction(HInstruction* instruction) { graph_->GetArtMethod(), instruction->GetDexPc(), instruction); - environment->CopyFrom(ArrayRef<HInstruction* const>(*current_locals_)); + environment->CopyFrom(allocator_, ArrayRef<HInstruction* const>(*current_locals_)); instruction->SetRawEnvironment(environment); } } |