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

Unified Diff: src/compiler/schedule.cc

Issue 1178403004: [turbofan] Use appropriate type for NodeId. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix useless static_cast. Created 5 years, 6 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/osr.cc ('k') | src/compiler/simplified-lowering.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/schedule.cc
diff --git a/src/compiler/schedule.cc b/src/compiler/schedule.cc
index adb80a7b081b7c3ceba52752f589d669e25241bc..69ece96d4e3e431555b1a6570bcae7c75c64b52b 100644
--- a/src/compiler/schedule.cc
+++ b/src/compiler/schedule.cc
@@ -145,8 +145,7 @@ BasicBlock* Schedule::block(Node* node) const {
bool Schedule::IsScheduled(Node* node) {
- int length = static_cast<int>(nodeid_to_block_.size());
- if (node->id() >= length) return false;
+ if (node->id() >= nodeid_to_block_.size()) return false;
return nodeid_to_block_[node->id()] != NULL;
}
@@ -324,8 +323,7 @@ void Schedule::SetControlInput(BasicBlock* block, Node* node) {
void Schedule::SetBlockForNode(BasicBlock* block, Node* node) {
- int length = static_cast<int>(nodeid_to_block_.size());
- if (node->id() >= length) {
+ if (node->id() >= nodeid_to_block_.size()) {
nodeid_to_block_.resize(node->id() + 1);
}
nodeid_to_block_[node->id()] = block;
« no previous file with comments | « src/compiler/osr.cc ('k') | src/compiler/simplified-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698