Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(163)

Unified Diff: src/compiler/register-allocator.cc

Issue 1098863003: Import Reversed adapter from Chromium and use it in v8. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed feedback. Rebased. Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/ppc/instruction-selector-ppc.cc ('k') | src/compiler/scheduler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/register-allocator.cc
diff --git a/src/compiler/register-allocator.cc b/src/compiler/register-allocator.cc
index 9d745d0097f4e627707a0349f006c6073db7592d..a429a97076b05f7a6408ea5ebdca8acc5aaf6c75 100644
--- a/src/compiler/register-allocator.cc
+++ b/src/compiler/register-allocator.cc
@@ -2,6 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "src/base/adapters.h"
#include "src/compiler/linkage.h"
#include "src/compiler/register-allocator.h"
#include "src/string-stream.h"
@@ -1411,9 +1412,8 @@ void RegisterAllocator::MeetRegisterConstraints() {
void RegisterAllocator::ResolvePhis() {
// Process the blocks in reverse order.
- for (auto i = code()->instruction_blocks().rbegin();
- i != code()->instruction_blocks().rend(); ++i) {
- ResolvePhis(*i);
+ for (InstructionBlock* block : base::Reversed(code()->instruction_blocks())) {
+ ResolvePhis(block);
}
}
« no previous file with comments | « src/compiler/ppc/instruction-selector-ppc.cc ('k') | src/compiler/scheduler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698