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

Side by Side Diff: src/compiler/operator-properties-inl.h

Issue 474983003: Move some methods from OperatorProperties into Scheduler that are only related to scheduling. Now t… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/compiler/operator-properties.h ('k') | src/compiler/scheduler.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_COMPILER_OPERATOR_PROPERTIES_INL_H_ 5 #ifndef V8_COMPILER_OPERATOR_PROPERTIES_INL_H_
6 #define V8_COMPILER_OPERATOR_PROPERTIES_INL_H_ 6 #define V8_COMPILER_OPERATOR_PROPERTIES_INL_H_
7 7
8 #include "src/v8.h" 8 #include "src/v8.h"
9 9
10 #include "src/compiler/js-operator.h" 10 #include "src/compiler/js-operator.h"
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 116
117 117
118 inline bool OperatorProperties::IsBasicBlockBegin(Operator* op) { 118 inline bool OperatorProperties::IsBasicBlockBegin(Operator* op) {
119 uint8_t opcode = op->opcode(); 119 uint8_t opcode = op->opcode();
120 return opcode == IrOpcode::kStart || opcode == IrOpcode::kEnd || 120 return opcode == IrOpcode::kStart || opcode == IrOpcode::kEnd ||
121 opcode == IrOpcode::kDead || opcode == IrOpcode::kLoop || 121 opcode == IrOpcode::kDead || opcode == IrOpcode::kLoop ||
122 opcode == IrOpcode::kMerge || opcode == IrOpcode::kIfTrue || 122 opcode == IrOpcode::kMerge || opcode == IrOpcode::kIfTrue ||
123 opcode == IrOpcode::kIfFalse; 123 opcode == IrOpcode::kIfFalse;
124 } 124 }
125 125
126 inline bool OperatorProperties::CanBeScheduled(Operator* op) { return true; }
127
128 inline bool OperatorProperties::HasFixedSchedulePosition(Operator* op) {
129 IrOpcode::Value opcode = static_cast<IrOpcode::Value>(op->opcode());
130 return (IrOpcode::IsControlOpcode(opcode)) ||
131 opcode == IrOpcode::kParameter || opcode == IrOpcode::kEffectPhi ||
132 opcode == IrOpcode::kPhi;
133 }
134
135 inline bool OperatorProperties::IsScheduleRoot(Operator* op) {
136 uint8_t opcode = op->opcode();
137 return opcode == IrOpcode::kEnd || opcode == IrOpcode::kEffectPhi ||
138 opcode == IrOpcode::kPhi;
139 }
140
141 inline bool OperatorProperties::CanLazilyDeoptimize(Operator* op) { 126 inline bool OperatorProperties::CanLazilyDeoptimize(Operator* op) {
142 // TODO(jarin) This function allows turning on lazy deoptimization 127 // TODO(jarin) This function allows turning on lazy deoptimization
143 // incrementally. It will change as we turn on lazy deopt for 128 // incrementally. It will change as we turn on lazy deopt for
144 // more nodes. 129 // more nodes.
145 130
146 if (!FLAG_turbo_deoptimization) { 131 if (!FLAG_turbo_deoptimization) {
147 return false; 132 return false;
148 } 133 }
149 134
150 switch (op->opcode()) { 135 switch (op->opcode()) {
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 default: 171 default:
187 return false; 172 return false;
188 } 173 }
189 return false; 174 return false;
190 } 175 }
191 } 176 }
192 } 177 }
193 } // namespace v8::internal::compiler 178 } // namespace v8::internal::compiler
194 179
195 #endif // V8_COMPILER_OPERATOR_PROPERTIES_INL_H_ 180 #endif // V8_COMPILER_OPERATOR_PROPERTIES_INL_H_
OLDNEW
« no previous file with comments | « src/compiler/operator-properties.h ('k') | src/compiler/scheduler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698