summaryrefslogtreecommitdiff
path: root/compiler/optimizing/gvn_test.cc
diff options
context:
space:
mode:
author David Brazdil <dbrazdil@google.com> 2016-04-07 09:54:26 +0000
committer David Brazdil <dbrazdil@google.com> 2016-04-07 16:03:16 +0000
commitdee58d6bb6d567fcd0c4f39d8d690c3acaf0e432 (patch)
tree5a2f20546ca3c1544c44bee560062580e22dc79c /compiler/optimizing/gvn_test.cc
parent391e155a6936a05bd39b171031ec21d2dee62133 (diff)
Revert "Revert "Refactor HGraphBuilder and SsaBuilder to remove HLocals""
This patch merges the instruction-building phases from HGraphBuilder and SsaBuilder into a single HInstructionBuilder class. As a result, it is not necessary to generate HLocal, HLoadLocal and HStoreLocal instructions any more, as the builder produces SSA form directly. Saves 5-15% of arena-allocated memory (see bug for more data): GMS 20.46MB => 19.26MB (-5.86%) Maps 24.12MB => 21.47MB (-10.98%) YouTube 28.60MB => 26.01MB (-9.05%) This CL fixed an issue with parsing quickened instructions. Bug: 27894376 Bug: 27998571 Bug: 27995065 Change-Id: I20dbe1bf2d0fe296377478db98cb86cba695e694
Diffstat (limited to 'compiler/optimizing/gvn_test.cc')
-rw-r--r--compiler/optimizing/gvn_test.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/optimizing/gvn_test.cc b/compiler/optimizing/gvn_test.cc
index 56dc08826b..6abf00e21a 100644
--- a/compiler/optimizing/gvn_test.cc
+++ b/compiler/optimizing/gvn_test.cc
@@ -357,8 +357,10 @@ TEST_F(GVNTest, LoopSideEffects) {
Primitive::kPrimBoolean);
entry->AddInstruction(parameter);
entry->AddInstruction(new (&allocator) HGoto());
+ outer_loop_header->AddInstruction(new (&allocator) HSuspendCheck());
outer_loop_header->AddInstruction(new (&allocator) HIf(parameter));
outer_loop_body->AddInstruction(new (&allocator) HGoto());
+ inner_loop_header->AddInstruction(new (&allocator) HSuspendCheck());
inner_loop_header->AddInstruction(new (&allocator) HIf(parameter));
inner_loop_body->AddInstruction(new (&allocator) HGoto());
inner_loop_exit->AddInstruction(new (&allocator) HGoto());