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

Side by Side Diff: src/compiler/common-operator.cc

Issue 928213003: Model exceptional edges from call nodes in TurboFan. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed comments by Benedikt Meurer. Created 5 years, 10 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
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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 #include "src/compiler/common-operator.h" 5 #include "src/compiler/common-operator.h"
6 6
7 #include "src/assembler.h" 7 #include "src/assembler.h"
8 #include "src/base/lazy-instance.h" 8 #include "src/base/lazy-instance.h"
9 #include "src/compiler/linkage.h" 9 #include "src/compiler/linkage.h"
10 #include "src/compiler/opcodes.h" 10 #include "src/compiler/opcodes.h"
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 return OpParameter<size_t>(op); 114 return OpParameter<size_t>(op);
115 } 115 }
116 116
117 117
118 #define CACHED_OP_LIST(V) \ 118 #define CACHED_OP_LIST(V) \
119 V(Always, Operator::kPure, 0, 0, 0, 1, 0, 0) \ 119 V(Always, Operator::kPure, 0, 0, 0, 1, 0, 0) \
120 V(Dead, Operator::kFoldable, 0, 0, 0, 0, 0, 1) \ 120 V(Dead, Operator::kFoldable, 0, 0, 0, 0, 0, 1) \
121 V(End, Operator::kKontrol, 0, 0, 1, 0, 0, 0) \ 121 V(End, Operator::kKontrol, 0, 0, 1, 0, 0, 0) \
122 V(IfTrue, Operator::kKontrol, 0, 0, 1, 0, 0, 1) \ 122 V(IfTrue, Operator::kKontrol, 0, 0, 1, 0, 0, 1) \
123 V(IfFalse, Operator::kKontrol, 0, 0, 1, 0, 0, 1) \ 123 V(IfFalse, Operator::kKontrol, 0, 0, 1, 0, 0, 1) \
124 V(IfException, Operator::kKontrol, 0, 0, 1, 0, 0, 1) \
125 V(IfSuccess, Operator::kKontrol, 0, 0, 1, 0, 0, 1) \
124 V(Throw, Operator::kFoldable, 1, 1, 1, 0, 0, 1) \ 126 V(Throw, Operator::kFoldable, 1, 1, 1, 0, 0, 1) \
125 V(Return, Operator::kNoThrow, 1, 1, 1, 0, 0, 1) \ 127 V(Return, Operator::kNoThrow, 1, 1, 1, 0, 0, 1) \
126 V(OsrNormalEntry, Operator::kFoldable, 0, 1, 1, 0, 1, 1) \ 128 V(OsrNormalEntry, Operator::kFoldable, 0, 1, 1, 0, 1, 1) \
127 V(OsrLoopEntry, Operator::kFoldable, 0, 1, 1, 0, 1, 1) 129 V(OsrLoopEntry, Operator::kFoldable, 0, 1, 1, 0, 1, 1)
128 130
129 131
130 #define CACHED_LOOP_LIST(V) \ 132 #define CACHED_LOOP_LIST(V) \
131 V(1) \ 133 V(1) \
132 V(2) 134 V(2)
133 135
(...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after
493 const Operator* CommonOperatorBuilder::Call(const CallDescriptor* descriptor) { 495 const Operator* CommonOperatorBuilder::Call(const CallDescriptor* descriptor) {
494 class CallOperator FINAL : public Operator1<const CallDescriptor*> { 496 class CallOperator FINAL : public Operator1<const CallDescriptor*> {
495 public: 497 public:
496 CallOperator(const CallDescriptor* descriptor, const char* mnemonic) 498 CallOperator(const CallDescriptor* descriptor, const char* mnemonic)
497 : Operator1<const CallDescriptor*>( 499 : Operator1<const CallDescriptor*>(
498 IrOpcode::kCall, descriptor->properties(), mnemonic, 500 IrOpcode::kCall, descriptor->properties(), mnemonic,
499 descriptor->InputCount() + descriptor->FrameStateCount(), 501 descriptor->InputCount() + descriptor->FrameStateCount(),
500 Operator::ZeroIfPure(descriptor->properties()), 502 Operator::ZeroIfPure(descriptor->properties()),
501 Operator::ZeroIfPure(descriptor->properties()), 503 Operator::ZeroIfPure(descriptor->properties()),
502 descriptor->ReturnCount(), 504 descriptor->ReturnCount(),
503 Operator::ZeroIfPure(descriptor->properties()), 0, descriptor) {} 505 Operator::ZeroIfPure(descriptor->properties()),
506 Operator::ZeroIfNoThrow(descriptor->properties()), descriptor) {}
504 507
505 void PrintParameter(std::ostream& os) const OVERRIDE { 508 void PrintParameter(std::ostream& os) const OVERRIDE {
506 os << "[" << *parameter() << "]"; 509 os << "[" << *parameter() << "]";
507 } 510 }
508 }; 511 };
509 return new (zone()) CallOperator(descriptor, "Call"); 512 return new (zone()) CallOperator(descriptor, "Call");
510 } 513 }
511 514
512 515
513 const Operator* CommonOperatorBuilder::Projection(size_t index) { 516 const Operator* CommonOperatorBuilder::Projection(size_t index) {
(...skipping 19 matching lines...) Expand all
533 } else { 536 } else {
534 UNREACHABLE(); 537 UNREACHABLE();
535 return nullptr; 538 return nullptr;
536 } 539 }
537 } 540 }
538 541
539 542
540 } // namespace compiler 543 } // namespace compiler
541 } // namespace internal 544 } // namespace internal
542 } // namespace v8 545 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698