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

Side by Side Diff: src/compiler/simplified-operator.h

Issue 2066223002: [turbofan] Introduce CheckHole and CheckHoleNaN operators. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Address comments. Blacklist test Created 4 years, 6 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
« no previous file with comments | « src/compiler/simplified-lowering.cc ('k') | src/compiler/simplified-operator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_SIMPLIFIED_OPERATOR_H_ 5 #ifndef V8_COMPILER_SIMPLIFIED_OPERATOR_H_
6 #define V8_COMPILER_SIMPLIFIED_OPERATOR_H_ 6 #define V8_COMPILER_SIMPLIFIED_OPERATOR_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 9
10 #include "src/compiler/type-hints.h" 10 #include "src/compiler/type-hints.h"
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 96
97 bool operator==(ElementAccess const&, ElementAccess const&); 97 bool operator==(ElementAccess const&, ElementAccess const&);
98 bool operator!=(ElementAccess const&, ElementAccess const&); 98 bool operator!=(ElementAccess const&, ElementAccess const&);
99 99
100 size_t hash_value(ElementAccess const&); 100 size_t hash_value(ElementAccess const&);
101 101
102 std::ostream& operator<<(std::ostream&, ElementAccess const&); 102 std::ostream& operator<<(std::ostream&, ElementAccess const&);
103 103
104 ElementAccess const& ElementAccessOf(const Operator* op) WARN_UNUSED_RESULT; 104 ElementAccess const& ElementAccessOf(const Operator* op) WARN_UNUSED_RESULT;
105 105
106 enum class CheckFloat64HoleMode : uint8_t {
107 kNeverReturnHole, // Never return the hole (deoptimize instead).
108 kAllowReturnHole // Allow to return the hole (signaling NaN).
109 };
110
111 size_t hash_value(CheckFloat64HoleMode);
112
113 std::ostream& operator<<(std::ostream&, CheckFloat64HoleMode);
114
115 CheckFloat64HoleMode CheckFloat64HoleModeOf(const Operator*) WARN_UNUSED_RESULT;
116
117 enum class CheckTaggedHoleMode : uint8_t {
118 kNeverReturnHole, // Never return the hole (deoptimize instead).
119 kConvertHoleToUndefined // Convert the hole to undefined.
120 };
121
122 size_t hash_value(CheckTaggedHoleMode);
123
124 std::ostream& operator<<(std::ostream&, CheckTaggedHoleMode);
125
126 CheckTaggedHoleMode CheckTaggedHoleModeOf(const Operator*) WARN_UNUSED_RESULT;
127
106 Type* TypeOf(const Operator* op) WARN_UNUSED_RESULT; 128 Type* TypeOf(const Operator* op) WARN_UNUSED_RESULT;
107 129
108 BinaryOperationHints::Hint BinaryOperationHintOf(const Operator* op); 130 BinaryOperationHints::Hint BinaryOperationHintOf(const Operator* op);
109 131
110 // Interface for building simplified operators, which represent the 132 // Interface for building simplified operators, which represent the
111 // medium-level operations of V8, including adding numbers, allocating objects, 133 // medium-level operations of V8, including adding numbers, allocating objects,
112 // indexing into objects and arrays, etc. 134 // indexing into objects and arrays, etc.
113 // All operators are typed but many are representation independent. 135 // All operators are typed but many are representation independent.
114 136
115 // Number values from JS can be in one of these representations: 137 // Number values from JS can be in one of these representations:
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 const Operator* NumberFround(); 179 const Operator* NumberFround();
158 const Operator* NumberAtan(); 180 const Operator* NumberAtan();
159 const Operator* NumberAtan2(); 181 const Operator* NumberAtan2();
160 const Operator* NumberLog(); 182 const Operator* NumberLog();
161 const Operator* NumberLog1p(); 183 const Operator* NumberLog1p();
162 const Operator* NumberRound(); 184 const Operator* NumberRound();
163 const Operator* NumberSqrt(); 185 const Operator* NumberSqrt();
164 const Operator* NumberTrunc(); 186 const Operator* NumberTrunc();
165 const Operator* NumberToInt32(); 187 const Operator* NumberToInt32();
166 const Operator* NumberToUint32(); 188 const Operator* NumberToUint32();
167 const Operator* NumberIsHoleNaN();
168 const Operator* NumberConvertHoleNaN();
169 189
170 const Operator* NumberSilenceNaN(); 190 const Operator* NumberSilenceNaN();
171 191
172 const Operator* SpeculativeNumberAdd(BinaryOperationHints::Hint hint); 192 const Operator* SpeculativeNumberAdd(BinaryOperationHints::Hint hint);
173 const Operator* SpeculativeNumberSubtract(BinaryOperationHints::Hint hint); 193 const Operator* SpeculativeNumberSubtract(BinaryOperationHints::Hint hint);
174 194
175 const Operator* ReferenceEqual(Type* type); 195 const Operator* ReferenceEqual(Type* type);
176 196
177 const Operator* StringEqual(); 197 const Operator* StringEqual();
178 const Operator* StringLessThan(); 198 const Operator* StringLessThan();
(...skipping 16 matching lines...) Expand all
195 const Operator* ChangeTaggedToBit(); 215 const Operator* ChangeTaggedToBit();
196 const Operator* ChangeBitToTagged(); 216 const Operator* ChangeBitToTagged();
197 const Operator* TruncateTaggedToWord32(); 217 const Operator* TruncateTaggedToWord32();
198 const Operator* TruncateTaggedToFloat64(); 218 const Operator* TruncateTaggedToFloat64();
199 219
200 const Operator* CheckedUint32ToInt32(); 220 const Operator* CheckedUint32ToInt32();
201 const Operator* CheckedFloat64ToInt32(); 221 const Operator* CheckedFloat64ToInt32();
202 const Operator* CheckedTaggedToInt32(); 222 const Operator* CheckedTaggedToInt32();
203 const Operator* CheckedTaggedToFloat64(); 223 const Operator* CheckedTaggedToFloat64();
204 224
225 const Operator* CheckFloat64Hole(CheckFloat64HoleMode);
226 const Operator* CheckTaggedHole(CheckTaggedHoleMode);
205 const Operator* CheckIf(); 227 const Operator* CheckIf();
206 228
207 const Operator* ObjectIsCallable(); 229 const Operator* ObjectIsCallable();
208 const Operator* ObjectIsNumber(); 230 const Operator* ObjectIsNumber();
209 const Operator* ObjectIsReceiver(); 231 const Operator* ObjectIsReceiver();
210 const Operator* ObjectIsSmi(); 232 const Operator* ObjectIsSmi();
211 const Operator* ObjectIsString(); 233 const Operator* ObjectIsString();
212 const Operator* ObjectIsUndetectable(); 234 const Operator* ObjectIsUndetectable();
213 235
214 const Operator* TypeGuard(Type* type); 236 const Operator* TypeGuard(Type* type);
(...skipping 22 matching lines...) Expand all
237 Zone* const zone_; 259 Zone* const zone_;
238 260
239 DISALLOW_COPY_AND_ASSIGN(SimplifiedOperatorBuilder); 261 DISALLOW_COPY_AND_ASSIGN(SimplifiedOperatorBuilder);
240 }; 262 };
241 263
242 } // namespace compiler 264 } // namespace compiler
243 } // namespace internal 265 } // namespace internal
244 } // namespace v8 266 } // namespace v8
245 267
246 #endif // V8_COMPILER_SIMPLIFIED_OPERATOR_H_ 268 #endif // V8_COMPILER_SIMPLIFIED_OPERATOR_H_
OLDNEW
« no previous file with comments | « src/compiler/simplified-lowering.cc ('k') | src/compiler/simplified-operator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698