| 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_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/operator.h" | 10 #include "src/compiler/operator.h" |
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 kNeverReturnHole, // Never return the hole (deoptimize instead). | 123 kNeverReturnHole, // Never return the hole (deoptimize instead). |
| 124 kConvertHoleToUndefined // Convert the hole to undefined. | 124 kConvertHoleToUndefined // Convert the hole to undefined. |
| 125 }; | 125 }; |
| 126 | 126 |
| 127 size_t hash_value(CheckTaggedHoleMode); | 127 size_t hash_value(CheckTaggedHoleMode); |
| 128 | 128 |
| 129 std::ostream& operator<<(std::ostream&, CheckTaggedHoleMode); | 129 std::ostream& operator<<(std::ostream&, CheckTaggedHoleMode); |
| 130 | 130 |
| 131 CheckTaggedHoleMode CheckTaggedHoleModeOf(const Operator*) WARN_UNUSED_RESULT; | 131 CheckTaggedHoleMode CheckTaggedHoleModeOf(const Operator*) WARN_UNUSED_RESULT; |
| 132 | 132 |
| 133 enum class CheckTaggedInputMode : uint8_t { |
| 134 kNumber, |
| 135 kNumberOrOddball, |
| 136 }; |
| 137 |
| 138 size_t hash_value(CheckTaggedInputMode); |
| 139 |
| 140 std::ostream& operator<<(std::ostream&, CheckTaggedInputMode); |
| 141 |
| 142 CheckTaggedInputMode CheckTaggedInputModeOf(const Operator*) WARN_UNUSED_RESULT; |
| 143 |
| 133 enum class CheckForMinusZeroMode : uint8_t { | 144 enum class CheckForMinusZeroMode : uint8_t { |
| 134 kCheckForMinusZero, | 145 kCheckForMinusZero, |
| 135 kDontCheckForMinusZero, | 146 kDontCheckForMinusZero, |
| 136 }; | 147 }; |
| 137 | 148 |
| 138 size_t hash_value(CheckForMinusZeroMode); | 149 size_t hash_value(CheckForMinusZeroMode); |
| 139 | 150 |
| 140 std::ostream& operator<<(std::ostream&, CheckForMinusZeroMode); | 151 std::ostream& operator<<(std::ostream&, CheckForMinusZeroMode); |
| 141 | 152 |
| 142 CheckForMinusZeroMode CheckMinusZeroModeOf(const Operator*) WARN_UNUSED_RESULT; | 153 CheckForMinusZeroMode CheckMinusZeroModeOf(const Operator*) WARN_UNUSED_RESULT; |
| (...skipping 23 matching lines...) Expand all Loading... |
| 166 size_t hash_value(ElementsTransition); | 177 size_t hash_value(ElementsTransition); |
| 167 | 178 |
| 168 std::ostream& operator<<(std::ostream&, ElementsTransition); | 179 std::ostream& operator<<(std::ostream&, ElementsTransition); |
| 169 | 180 |
| 170 ElementsTransition ElementsTransitionOf(const Operator* op) WARN_UNUSED_RESULT; | 181 ElementsTransition ElementsTransitionOf(const Operator* op) WARN_UNUSED_RESULT; |
| 171 | 182 |
| 172 // A hint for speculative number operations. | 183 // A hint for speculative number operations. |
| 173 enum class NumberOperationHint : uint8_t { | 184 enum class NumberOperationHint : uint8_t { |
| 174 kSignedSmall, // Inputs were always Smi so far, output was in Smi range. | 185 kSignedSmall, // Inputs were always Smi so far, output was in Smi range. |
| 175 kSigned32, // Inputs and output were Signed32 so far. | 186 kSigned32, // Inputs and output were Signed32 so far. |
| 187 kNumber, // Inputs were Number, output was Number. |
| 176 kNumberOrOddball, // Inputs were Number or Oddball, output was Number. | 188 kNumberOrOddball, // Inputs were Number or Oddball, output was Number. |
| 177 }; | 189 }; |
| 178 | 190 |
| 179 size_t hash_value(NumberOperationHint); | 191 size_t hash_value(NumberOperationHint); |
| 180 | 192 |
| 181 std::ostream& operator<<(std::ostream&, NumberOperationHint); | 193 std::ostream& operator<<(std::ostream&, NumberOperationHint); |
| 182 | 194 |
| 183 NumberOperationHint NumberOperationHintOf(const Operator* op) | 195 NumberOperationHint NumberOperationHintOf(const Operator* op) |
| 184 WARN_UNUSED_RESULT; | 196 WARN_UNUSED_RESULT; |
| 185 | 197 |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 316 const Operator* CheckedInt32Sub(); | 328 const Operator* CheckedInt32Sub(); |
| 317 const Operator* CheckedInt32Div(); | 329 const Operator* CheckedInt32Div(); |
| 318 const Operator* CheckedInt32Mod(); | 330 const Operator* CheckedInt32Mod(); |
| 319 const Operator* CheckedUint32Div(); | 331 const Operator* CheckedUint32Div(); |
| 320 const Operator* CheckedUint32Mod(); | 332 const Operator* CheckedUint32Mod(); |
| 321 const Operator* CheckedInt32Mul(CheckForMinusZeroMode); | 333 const Operator* CheckedInt32Mul(CheckForMinusZeroMode); |
| 322 const Operator* CheckedUint32ToInt32(); | 334 const Operator* CheckedUint32ToInt32(); |
| 323 const Operator* CheckedFloat64ToInt32(CheckForMinusZeroMode); | 335 const Operator* CheckedFloat64ToInt32(CheckForMinusZeroMode); |
| 324 const Operator* CheckedTaggedSignedToInt32(); | 336 const Operator* CheckedTaggedSignedToInt32(); |
| 325 const Operator* CheckedTaggedToInt32(CheckForMinusZeroMode); | 337 const Operator* CheckedTaggedToInt32(CheckForMinusZeroMode); |
| 326 const Operator* CheckedTaggedToFloat64(); | 338 const Operator* CheckedTaggedToFloat64(CheckTaggedInputMode); |
| 327 const Operator* CheckedTruncateTaggedToWord32(); | 339 const Operator* CheckedTruncateTaggedToWord32(); |
| 328 | 340 |
| 329 const Operator* CheckFloat64Hole(CheckFloat64HoleMode); | 341 const Operator* CheckFloat64Hole(CheckFloat64HoleMode); |
| 330 const Operator* CheckTaggedHole(CheckTaggedHoleMode); | 342 const Operator* CheckTaggedHole(CheckTaggedHoleMode); |
| 331 | 343 |
| 332 const Operator* ObjectIsCallable(); | 344 const Operator* ObjectIsCallable(); |
| 333 const Operator* ObjectIsNumber(); | 345 const Operator* ObjectIsNumber(); |
| 334 const Operator* ObjectIsReceiver(); | 346 const Operator* ObjectIsReceiver(); |
| 335 const Operator* ObjectIsSmi(); | 347 const Operator* ObjectIsSmi(); |
| 336 const Operator* ObjectIsString(); | 348 const Operator* ObjectIsString(); |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 375 Zone* const zone_; | 387 Zone* const zone_; |
| 376 | 388 |
| 377 DISALLOW_COPY_AND_ASSIGN(SimplifiedOperatorBuilder); | 389 DISALLOW_COPY_AND_ASSIGN(SimplifiedOperatorBuilder); |
| 378 }; | 390 }; |
| 379 | 391 |
| 380 } // namespace compiler | 392 } // namespace compiler |
| 381 } // namespace internal | 393 } // namespace internal |
| 382 } // namespace v8 | 394 } // namespace v8 |
| 383 | 395 |
| 384 #endif // V8_COMPILER_SIMPLIFIED_OPERATOR_H_ | 396 #endif // V8_COMPILER_SIMPLIFIED_OPERATOR_H_ |
| OLD | NEW |