From ced2fc97ec95f2924059544f13d6ff353973d552 Mon Sep 17 00:00:00 2001 From: Vladimir Marko Date: Thu, 8 Feb 2024 09:49:48 +0000 Subject: Clean up `HGraphVisitor::VisitBasicBlock()`. Skip `HPhi::Accept()` and add functions to visit only Phis or only non-Phi instructions. Test: m test-art-host-gtest Test: testrunner.py --host --optimizing Bug: 181943478 Change-Id: Iba0690ae70f46d6a2bafa9055b2ae5167e58a2f4 --- compiler/optimizing/profiling_info_builder.cc | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'compiler/optimizing/profiling_info_builder.cc') diff --git a/compiler/optimizing/profiling_info_builder.cc b/compiler/optimizing/profiling_info_builder.cc index f6cf676813..7faf2bf5be 100644 --- a/compiler/optimizing/profiling_info_builder.cc +++ b/compiler/optimizing/profiling_info_builder.cc @@ -33,10 +33,7 @@ void ProfilingInfoBuilder::Run() { // Order does not matter. for (HBasicBlock* block : GetGraph()->GetReversePostOrder()) { // No need to visit the phis. - for (HInstructionIteratorHandleChanges inst_it(block->GetInstructions()); !inst_it.Done(); - inst_it.Advance()) { - inst_it.Current()->Accept(this); - } + VisitNonPhiInstructions(block); } ScopedObjectAccess soa(Thread::Current()); -- cgit v1.2.3-59-g8ed1b