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 #ifndef V8_COMPILER_JS_TYPED_LOWERING_H_ | 5 #ifndef V8_COMPILER_JS_TYPED_LOWERING_H_ |
6 #define V8_COMPILER_JS_TYPED_LOWERING_H_ | 6 #define V8_COMPILER_JS_TYPED_LOWERING_H_ |
7 | 7 |
8 #include "src/compiler/graph-reducer.h" | 8 #include "src/compiler/graph-reducer.h" |
9 #include "src/compiler/opcodes.h" | 9 #include "src/compiler/opcodes.h" |
10 #include "src/compiler/simplified-operator.h" | 10 #include "src/compiler/simplified-operator.h" |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 Reduction ReduceJSStrictEqual(Node* node, bool invert); | 50 Reduction ReduceJSStrictEqual(Node* node, bool invert); |
51 Reduction ReduceJSUnaryNot(Node* node); | 51 Reduction ReduceJSUnaryNot(Node* node); |
52 Reduction ReduceJSToBoolean(Node* node); | 52 Reduction ReduceJSToBoolean(Node* node); |
53 Reduction ReduceJSToNumberInput(Node* input); | 53 Reduction ReduceJSToNumberInput(Node* input); |
54 Reduction ReduceJSToNumber(Node* node); | 54 Reduction ReduceJSToNumber(Node* node); |
55 Reduction ReduceJSToStringInput(Node* input); | 55 Reduction ReduceJSToStringInput(Node* input); |
56 Reduction ReduceJSToString(Node* node); | 56 Reduction ReduceJSToString(Node* node); |
57 Reduction ReduceJSCreateClosure(Node* node); | 57 Reduction ReduceJSCreateClosure(Node* node); |
58 Reduction ReduceJSCreateLiteralArray(Node* node); | 58 Reduction ReduceJSCreateLiteralArray(Node* node); |
59 Reduction ReduceJSCreateLiteralObject(Node* node); | 59 Reduction ReduceJSCreateLiteralObject(Node* node); |
| 60 Reduction ReduceJSCreateWithContext(Node* node); |
| 61 Reduction ReduceJSCreateBlockContext(Node* node); |
60 Reduction ReduceNumberBinop(Node* node, const Operator* numberOp); | 62 Reduction ReduceNumberBinop(Node* node, const Operator* numberOp); |
61 Reduction ReduceInt32Binop(Node* node, const Operator* intOp); | 63 Reduction ReduceInt32Binop(Node* node, const Operator* intOp); |
62 Reduction ReduceUI32Shift(Node* node, Signedness left_signedness, | 64 Reduction ReduceUI32Shift(Node* node, Signedness left_signedness, |
63 const Operator* shift_op); | 65 const Operator* shift_op); |
64 | 66 |
65 Node* ConvertPrimitiveToNumber(Node* input); | 67 Node* ConvertPrimitiveToNumber(Node* input); |
66 template <IrOpcode::Value> | 68 template <IrOpcode::Value> |
67 Node* FindConversion(Node* input); | 69 Node* FindConversion(Node* input); |
68 void InsertConversion(Node* conversion); | 70 void InsertConversion(Node* conversion); |
69 | 71 |
70 Node* Word32Shl(Node* const lhs, int32_t const rhs); | 72 Node* Word32Shl(Node* const lhs, int32_t const rhs); |
71 | 73 |
72 Factory* factory() const; | 74 Factory* factory() const; |
73 Graph* graph() const; | 75 Graph* graph() const; |
74 JSGraph* jsgraph() const { return jsgraph_; } | 76 JSGraph* jsgraph() const { return jsgraph_; } |
75 JSOperatorBuilder* javascript() const; | 77 JSOperatorBuilder* javascript() const; |
76 CommonOperatorBuilder* common() const; | 78 CommonOperatorBuilder* common() const; |
77 SimplifiedOperatorBuilder* simplified() { return &simplified_; } | 79 SimplifiedOperatorBuilder* simplified() { return &simplified_; } |
78 MachineOperatorBuilder* machine() const; | 80 MachineOperatorBuilder* machine() const; |
79 | 81 |
| 82 // Limits up to which context allocations are inlined. |
| 83 static const int kBlockContextAllocationLimit = 16; |
| 84 |
80 JSGraph* jsgraph_; | 85 JSGraph* jsgraph_; |
81 SimplifiedOperatorBuilder simplified_; | 86 SimplifiedOperatorBuilder simplified_; |
82 ZoneVector<Node*> conversions_; // Cache inserted JSToXXX() conversions. | 87 ZoneVector<Node*> conversions_; // Cache inserted JSToXXX() conversions. |
83 Type* zero_range_; | 88 Type* zero_range_; |
84 Type* one_range_; | 89 Type* one_range_; |
85 Type* zero_thirtyone_range_; | 90 Type* zero_thirtyone_range_; |
86 Type* shifted_int32_ranges_[4]; | 91 Type* shifted_int32_ranges_[4]; |
87 }; | 92 }; |
88 | 93 |
89 } // namespace compiler | 94 } // namespace compiler |
90 } // namespace internal | 95 } // namespace internal |
91 } // namespace v8 | 96 } // namespace v8 |
92 | 97 |
93 #endif // V8_COMPILER_JS_TYPED_LOWERING_H_ | 98 #endif // V8_COMPILER_JS_TYPED_LOWERING_H_ |
OLD | NEW |