| 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_GRAPH_H_ | 5 #ifndef V8_COMPILER_JS_GRAPH_H_ |
| 6 #define V8_COMPILER_JS_GRAPH_H_ | 6 #define V8_COMPILER_JS_GRAPH_H_ |
| 7 | 7 |
| 8 #include "src/compiler/common-node-cache.h" | 8 #include "src/compiler/common-node-cache.h" |
| 9 #include "src/compiler/common-operator.h" | 9 #include "src/compiler/common-operator.h" |
| 10 #include "src/compiler/graph.h" | 10 #include "src/compiler/graph.h" |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 Node* Constant(Handle<Object> value); | 54 Node* Constant(Handle<Object> value); |
| 55 | 55 |
| 56 // Creates a NumberConstant node, usually canonicalized. | 56 // Creates a NumberConstant node, usually canonicalized. |
| 57 Node* Constant(double value); | 57 Node* Constant(double value); |
| 58 | 58 |
| 59 // Creates a NumberConstant node, usually canonicalized. | 59 // Creates a NumberConstant node, usually canonicalized. |
| 60 Node* Constant(int32_t value); | 60 Node* Constant(int32_t value); |
| 61 | 61 |
| 62 // Creates a Int32Constant node, usually canonicalized. | 62 // Creates a Int32Constant node, usually canonicalized. |
| 63 Node* Int32Constant(int32_t value); | 63 Node* Int32Constant(int32_t value); |
| 64 Node* Uint32Constant(uint32_t value) { |
| 65 return Int32Constant(bit_cast<int32_t>(value)); |
| 66 } |
| 64 | 67 |
| 65 // Creates a Float64Constant node, usually canonicalized. | 68 // Creates a Float64Constant node, usually canonicalized. |
| 66 Node* Float64Constant(double value); | 69 Node* Float64Constant(double value); |
| 67 | 70 |
| 68 // Creates an ExternalConstant node, usually canonicalized. | 71 // Creates an ExternalConstant node, usually canonicalized. |
| 69 Node* ExternalConstant(ExternalReference ref); | 72 Node* ExternalConstant(ExternalReference ref); |
| 70 | 73 |
| 71 Node* SmiConstant(int32_t immediate) { | 74 Node* SmiConstant(int32_t immediate) { |
| 72 DCHECK(Smi::IsValid(immediate)); | 75 DCHECK(Smi::IsValid(immediate)); |
| 73 return Constant(immediate); | 76 return Constant(immediate); |
| (...skipping 22 matching lines...) Expand all Loading... |
| 96 SetOncePointer<Node> nan_constant_; | 99 SetOncePointer<Node> nan_constant_; |
| 97 | 100 |
| 98 CommonNodeCache cache_; | 101 CommonNodeCache cache_; |
| 99 | 102 |
| 100 Node* ImmovableHeapConstant(Handle<Object> value); | 103 Node* ImmovableHeapConstant(Handle<Object> value); |
| 101 Node* NumberConstant(double value); | 104 Node* NumberConstant(double value); |
| 102 Node* NewNode(const Operator* op); | 105 Node* NewNode(const Operator* op); |
| 103 | 106 |
| 104 Factory* factory() { return isolate()->factory(); } | 107 Factory* factory() { return isolate()->factory(); } |
| 105 }; | 108 }; |
| 109 |
| 106 } // namespace compiler | 110 } // namespace compiler |
| 107 } // namespace internal | 111 } // namespace internal |
| 108 } // namespace v8 | 112 } // namespace v8 |
| 109 | 113 |
| 110 #endif | 114 #endif |
| OLD | NEW |