summaryrefslogtreecommitdiff
path: root/compiler/optimizing/code_generator.cc
diff options
context:
space:
mode:
author Vladimir Marko <vmarko@google.com> 2024-10-04 06:39:30 +0000
committer VladimĂ­r Marko <vmarko@google.com> 2024-10-04 14:04:37 +0000
commit92a62ec92ef7ea0f047f5be569388608136b4803 (patch)
treeb9ab473da3bff19055c9468b63513ca4e36e3175 /compiler/optimizing/code_generator.cc
parentc7f1c1039a7eb4abdfd3800c1b876d546c3059f8 (diff)
Reduce memory used by `HEnvironment`.
Test: m test-art-host-gtest Test: testrunner.py --host --optimizing Bug: 181943478 Change-Id: Ie05d4001e411a669e11b8edda375414e5da52ae2
Diffstat (limited to 'compiler/optimizing/code_generator.cc')
-rw-r--r--compiler/optimizing/code_generator.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/optimizing/code_generator.cc b/compiler/optimizing/code_generator.cc
index 51714ef548..757fdc2cee 100644
--- a/compiler/optimizing/code_generator.cc
+++ b/compiler/optimizing/code_generator.cc
@@ -913,8 +913,9 @@ void CodeGenerator::BlockIfInRegister(Location location, bool is_out) const {
}
void CodeGenerator::AllocateLocations(HInstruction* instruction) {
+ ArenaAllocator* allocator = GetGraph()->GetAllocator();
for (HEnvironment* env = instruction->GetEnvironment(); env != nullptr; env = env->GetParent()) {
- env->AllocateLocations();
+ env->AllocateLocations(allocator);
}
instruction->Accept(GetLocationBuilder());
DCHECK(CheckTypeConsistency(instruction));