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

Side by Side Diff: src/crankshaft/hydrogen-instructions.h

Issue 2161543002: [turbofan] Add support for eager/soft deoptimization reasons. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Do the ports properly Created 4 years, 5 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
« no previous file with comments | « src/crankshaft/hydrogen.cc ('k') | src/crankshaft/ia32/lithium-codegen-ia32.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ 5 #ifndef V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_
6 #define V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ 6 #define V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_
7 7
8 #include <cstring> 8 #include <cstring>
9 #include <iosfwd> 9 #include <iosfwd>
10 10
(...skipping 1283 matching lines...) Expand 10 before | Expand all | Expand 10 after
1294 1294
1295 std::ostream& PrintDataTo(std::ostream& os) const override; // NOLINT 1295 std::ostream& PrintDataTo(std::ostream& os) const override; // NOLINT
1296 1296
1297 DECLARE_CONCRETE_INSTRUCTION(Goto) 1297 DECLARE_CONCRETE_INSTRUCTION(Goto)
1298 }; 1298 };
1299 1299
1300 1300
1301 class HDeoptimize final : public HTemplateControlInstruction<1, 0> { 1301 class HDeoptimize final : public HTemplateControlInstruction<1, 0> {
1302 public: 1302 public:
1303 static HDeoptimize* New(Isolate* isolate, Zone* zone, HValue* context, 1303 static HDeoptimize* New(Isolate* isolate, Zone* zone, HValue* context,
1304 Deoptimizer::DeoptReason reason, 1304 DeoptimizeReason reason,
1305 Deoptimizer::BailoutType type, 1305 Deoptimizer::BailoutType type,
1306 HBasicBlock* unreachable_continuation) { 1306 HBasicBlock* unreachable_continuation) {
1307 return new(zone) HDeoptimize(reason, type, unreachable_continuation); 1307 return new(zone) HDeoptimize(reason, type, unreachable_continuation);
1308 } 1308 }
1309 1309
1310 bool KnownSuccessorBlock(HBasicBlock** block) override { 1310 bool KnownSuccessorBlock(HBasicBlock** block) override {
1311 *block = NULL; 1311 *block = NULL;
1312 return true; 1312 return true;
1313 } 1313 }
1314 1314
1315 Representation RequiredInputRepresentation(int index) override { 1315 Representation RequiredInputRepresentation(int index) override {
1316 return Representation::None(); 1316 return Representation::None();
1317 } 1317 }
1318 1318
1319 Deoptimizer::DeoptReason reason() const { return reason_; } 1319 DeoptimizeReason reason() const { return reason_; }
1320 Deoptimizer::BailoutType type() { return type_; } 1320 Deoptimizer::BailoutType type() { return type_; }
1321 1321
1322 DECLARE_CONCRETE_INSTRUCTION(Deoptimize) 1322 DECLARE_CONCRETE_INSTRUCTION(Deoptimize)
1323 1323
1324 private: 1324 private:
1325 explicit HDeoptimize(Deoptimizer::DeoptReason reason, 1325 explicit HDeoptimize(DeoptimizeReason reason, Deoptimizer::BailoutType type,
1326 Deoptimizer::BailoutType type,
1327 HBasicBlock* unreachable_continuation) 1326 HBasicBlock* unreachable_continuation)
1328 : reason_(reason), type_(type) { 1327 : reason_(reason), type_(type) {
1329 SetSuccessorAt(0, unreachable_continuation); 1328 SetSuccessorAt(0, unreachable_continuation);
1330 } 1329 }
1331 1330
1332 Deoptimizer::DeoptReason reason_; 1331 DeoptimizeReason reason_;
1333 Deoptimizer::BailoutType type_; 1332 Deoptimizer::BailoutType type_;
1334 }; 1333 };
1335 1334
1336 1335
1337 class HUnaryControlInstruction : public HTemplateControlInstruction<2, 1> { 1336 class HUnaryControlInstruction : public HTemplateControlInstruction<2, 1> {
1338 public: 1337 public:
1339 HUnaryControlInstruction(HValue* value, 1338 HUnaryControlInstruction(HValue* value,
1340 HBasicBlock* true_target, 1339 HBasicBlock* true_target,
1341 HBasicBlock* false_target) { 1340 HBasicBlock* false_target) {
1342 SetOperandAt(0, value); 1341 SetOperandAt(0, value);
(...skipping 5784 matching lines...) Expand 10 before | Expand all | Expand 10 after
7127 bool IsDeletable() const override { return true; } 7126 bool IsDeletable() const override { return true; }
7128 }; 7127 };
7129 7128
7130 #undef DECLARE_INSTRUCTION 7129 #undef DECLARE_INSTRUCTION
7131 #undef DECLARE_CONCRETE_INSTRUCTION 7130 #undef DECLARE_CONCRETE_INSTRUCTION
7132 7131
7133 } // namespace internal 7132 } // namespace internal
7134 } // namespace v8 7133 } // namespace v8
7135 7134
7136 #endif // V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ 7135 #endif // V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_
OLDNEW
« no previous file with comments | « src/crankshaft/hydrogen.cc ('k') | src/crankshaft/ia32/lithium-codegen-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698