OLD | NEW |
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 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 info.state_combine()); | 96 info.state_combine()); |
97 } | 97 } |
98 | 98 |
99 | 99 |
100 std::ostream& operator<<(std::ostream& os, FrameStateCallInfo const& info) { | 100 std::ostream& operator<<(std::ostream& os, FrameStateCallInfo const& info) { |
101 return os << info.type() << ", " << info.bailout_id() << ", " | 101 return os << info.type() << ", " << info.bailout_id() << ", " |
102 << info.state_combine(); | 102 << info.state_combine(); |
103 } | 103 } |
104 | 104 |
105 | 105 |
| 106 size_t ProjectionIndexOf(const Operator* const op) { |
| 107 DCHECK_EQ(IrOpcode::kProjection, op->opcode()); |
| 108 return OpParameter<size_t>(op); |
| 109 } |
| 110 |
| 111 |
106 #define CACHED_OP_LIST(V) \ | 112 #define CACHED_OP_LIST(V) \ |
107 V(Dead, Operator::kFoldable, 0, 0, 0, 0, 0, 1) \ | 113 V(Dead, Operator::kFoldable, 0, 0, 0, 0, 0, 1) \ |
108 V(End, Operator::kFoldable, 0, 0, 1, 0, 0, 0) \ | 114 V(End, Operator::kFoldable, 0, 0, 1, 0, 0, 0) \ |
109 V(IfTrue, Operator::kFoldable, 0, 0, 1, 0, 0, 1) \ | 115 V(IfTrue, Operator::kFoldable, 0, 0, 1, 0, 0, 1) \ |
110 V(IfFalse, Operator::kFoldable, 0, 0, 1, 0, 0, 1) \ | 116 V(IfFalse, Operator::kFoldable, 0, 0, 1, 0, 0, 1) \ |
111 V(Throw, Operator::kFoldable, 1, 1, 1, 0, 0, 1) \ | 117 V(Throw, Operator::kFoldable, 1, 1, 1, 0, 0, 1) \ |
112 V(Return, Operator::kNoProperties, 1, 1, 1, 0, 0, 1) \ | 118 V(Return, Operator::kNoProperties, 1, 1, 1, 0, 0, 1) \ |
113 V(OsrNormalEntry, Operator::kFoldable, 0, 1, 1, 0, 1, 1) \ | 119 V(OsrNormalEntry, Operator::kFoldable, 0, 1, 1, 0, 1, 1) \ |
114 V(OsrLoopEntry, Operator::kFoldable, 0, 1, 1, 0, 1, 1) | 120 V(OsrLoopEntry, Operator::kFoldable, 0, 1, 1, 0, 1, 1) |
115 | 121 |
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
482 return new (zone()) Operator1<size_t>( // -- | 488 return new (zone()) Operator1<size_t>( // -- |
483 IrOpcode::kProjection, Operator::kPure, // opcode | 489 IrOpcode::kProjection, Operator::kPure, // opcode |
484 "Projection", // name | 490 "Projection", // name |
485 1, 0, 0, 1, 0, 0, // counts | 491 1, 0, 0, 1, 0, 0, // counts |
486 index); // parameter | 492 index); // parameter |
487 } | 493 } |
488 | 494 |
489 } // namespace compiler | 495 } // namespace compiler |
490 } // namespace internal | 496 } // namespace internal |
491 } // namespace v8 | 497 } // namespace v8 |
OLD | NEW |