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_TYPE_CACHE_H_ | 5 #ifndef V8_TYPE_CACHE_H_ |
6 #define V8_TYPE_CACHE_H_ | 6 #define V8_TYPE_CACHE_H_ |
7 | 7 |
8 #include "src/types.h" | 8 #include "src/types.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 Type* const kAdditiveSafeIntegerOrMinusZero = | 71 Type* const kAdditiveSafeIntegerOrMinusZero = |
72 Type::Union(kAdditiveSafeInteger, Type::MinusZero(), zone()); | 72 Type::Union(kAdditiveSafeInteger, Type::MinusZero(), zone()); |
73 Type* const kSafeIntegerOrMinusZero = | 73 Type* const kSafeIntegerOrMinusZero = |
74 Type::Union(kSafeInteger, Type::MinusZero(), zone()); | 74 Type::Union(kSafeInteger, Type::MinusZero(), zone()); |
75 Type* const kPositiveSafeInteger = CreateRange(0.0, kMaxSafeInteger); | 75 Type* const kPositiveSafeInteger = CreateRange(0.0, kMaxSafeInteger); |
76 | 76 |
77 Type* const kUntaggedUndefined = | 77 Type* const kUntaggedUndefined = |
78 Type::Intersect(Type::Undefined(), Type::Untagged(), zone()); | 78 Type::Intersect(Type::Undefined(), Type::Untagged(), zone()); |
79 Type* const kSigned32OrMinusZero = | 79 Type* const kSigned32OrMinusZero = |
80 Type::Union(Type::Signed32(), Type::MinusZero(), zone()); | 80 Type::Union(Type::Signed32(), Type::MinusZero(), zone()); |
| 81 Type* const kSigned32OrMinusZeroOrNaN = |
| 82 Type::Union(Type::Signed32(), Type::MinusZeroOrNaN(), zone()); |
| 83 Type* const kUnsigned32OrMinusZeroOrNaN = |
| 84 Type::Union(Type::Unsigned32(), Type::MinusZeroOrNaN(), zone()); |
81 | 85 |
82 // Asm.js related types. | 86 // Asm.js related types. |
83 Type* const kAsmSigned = kInt32; | 87 Type* const kAsmSigned = kInt32; |
84 Type* const kAsmUnsigned = kUint32; | 88 Type* const kAsmUnsigned = kUint32; |
85 Type* const kAsmInt = Type::Union(kAsmSigned, kAsmUnsigned, zone()); | 89 Type* const kAsmInt = Type::Union(kAsmSigned, kAsmUnsigned, zone()); |
86 Type* const kAsmFixnum = Type::Intersect(kAsmSigned, kAsmUnsigned, zone()); | 90 Type* const kAsmFixnum = Type::Intersect(kAsmSigned, kAsmUnsigned, zone()); |
87 Type* const kAsmFloat = kFloat32; | 91 Type* const kAsmFloat = kFloat32; |
88 Type* const kAsmDouble = kFloat64; | 92 Type* const kAsmDouble = kFloat64; |
89 Type* const kAsmFloatQ = Type::Union(kAsmFloat, kUntaggedUndefined, zone()); | 93 Type* const kAsmFloatQ = Type::Union(kAsmFloat, kUntaggedUndefined, zone()); |
90 Type* const kAsmDoubleQ = Type::Union(kAsmDouble, kUntaggedUndefined, zone()); | 94 Type* const kAsmDoubleQ = Type::Union(kAsmDouble, kUntaggedUndefined, zone()); |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
164 return Type::Range(min, max, zone()); | 168 return Type::Range(min, max, zone()); |
165 } | 169 } |
166 | 170 |
167 Zone* zone() { return &zone_; } | 171 Zone* zone() { return &zone_; } |
168 }; | 172 }; |
169 | 173 |
170 } // namespace internal | 174 } // namespace internal |
171 } // namespace v8 | 175 } // namespace v8 |
172 | 176 |
173 #endif // V8_TYPE_CACHE_H_ | 177 #endif // V8_TYPE_CACHE_H_ |
OLD | NEW |