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

Side by Side Diff: src/compiler/js-graph.h

Issue 792463003: [turbofan] Turn JSToBoolean and JSUnaryNot into pure operators. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years 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 #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 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 Node* Float64Constant(double value); 98 Node* Float64Constant(double value);
99 99
100 // Creates an ExternalConstant node, usually canonicalized. 100 // Creates an ExternalConstant node, usually canonicalized.
101 Node* ExternalConstant(ExternalReference ref); 101 Node* ExternalConstant(ExternalReference ref);
102 102
103 Node* SmiConstant(int32_t immediate) { 103 Node* SmiConstant(int32_t immediate) {
104 DCHECK(Smi::IsValid(immediate)); 104 DCHECK(Smi::IsValid(immediate));
105 return Constant(immediate); 105 return Constant(immediate);
106 } 106 }
107 107
108 // Creates a dummy Constant node, used to satisfy calling conventions of
109 // stubs and runtime functions that do not require a context.
110 Node* NoContextConstant() { return ZeroConstant(); }
111
108 JSOperatorBuilder* javascript() { return javascript_; } 112 JSOperatorBuilder* javascript() { return javascript_; }
109 CommonOperatorBuilder* common() { return common_; } 113 CommonOperatorBuilder* common() { return common_; }
110 MachineOperatorBuilder* machine() { return machine_; } 114 MachineOperatorBuilder* machine() { return machine_; }
111 Graph* graph() { return graph_; } 115 Graph* graph() { return graph_; }
112 Zone* zone() { return graph()->zone(); } 116 Zone* zone() { return graph()->zone(); }
113 Isolate* isolate() { return zone()->isolate(); } 117 Isolate* isolate() { return zone()->isolate(); }
114 118
115 void GetCachedNodes(NodeVector* nodes); 119 void GetCachedNodes(NodeVector* nodes);
116 120
117 private: 121 private:
(...skipping 21 matching lines...) Expand all
139 Factory* factory() { return isolate()->factory(); } 143 Factory* factory() { return isolate()->factory(); }
140 144
141 DISALLOW_COPY_AND_ASSIGN(JSGraph); 145 DISALLOW_COPY_AND_ASSIGN(JSGraph);
142 }; 146 };
143 147
144 } // namespace compiler 148 } // namespace compiler
145 } // namespace internal 149 } // namespace internal
146 } // namespace v8 150 } // namespace v8
147 151
148 #endif 152 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698