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

Side by Side Diff: src/type-cache.h

Issue 2078423002: [turbofan] More efficient truncation analysis for add, sub. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Comment 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') | no next file » | 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_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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 CreateRange(-4503599627370496.0, 4503599627370496.0); 58 CreateRange(-4503599627370496.0, 4503599627370496.0);
59 Type* const kSafeInteger = CreateRange(-kMaxSafeInteger, kMaxSafeInteger); 59 Type* const kSafeInteger = CreateRange(-kMaxSafeInteger, kMaxSafeInteger);
60 Type* const kAdditiveSafeIntegerOrMinusZero = 60 Type* const kAdditiveSafeIntegerOrMinusZero =
61 Type::Union(kAdditiveSafeInteger, Type::MinusZero(), zone()); 61 Type::Union(kAdditiveSafeInteger, Type::MinusZero(), zone());
62 Type* const kSafeIntegerOrMinusZero = 62 Type* const kSafeIntegerOrMinusZero =
63 Type::Union(kSafeInteger, Type::MinusZero(), zone()); 63 Type::Union(kSafeInteger, Type::MinusZero(), zone());
64 Type* const kPositiveSafeInteger = CreateRange(0.0, kMaxSafeInteger); 64 Type* const kPositiveSafeInteger = CreateRange(0.0, kMaxSafeInteger);
65 65
66 Type* const kUntaggedUndefined = 66 Type* const kUntaggedUndefined =
67 Type::Intersect(Type::Undefined(), Type::Untagged(), zone()); 67 Type::Intersect(Type::Undefined(), Type::Untagged(), zone());
68 Type* const kSigned32OrMinusZero =
69 Type::Union(Type::Signed32(), Type::MinusZero(), zone());
68 70
69 // Asm.js related types. 71 // Asm.js related types.
70 Type* const kAsmSigned = kInt32; 72 Type* const kAsmSigned = kInt32;
71 Type* const kAsmUnsigned = kUint32; 73 Type* const kAsmUnsigned = kUint32;
72 Type* const kAsmInt = Type::Union(kAsmSigned, kAsmUnsigned, zone()); 74 Type* const kAsmInt = Type::Union(kAsmSigned, kAsmUnsigned, zone());
73 Type* const kAsmFixnum = Type::Intersect(kAsmSigned, kAsmUnsigned, zone()); 75 Type* const kAsmFixnum = Type::Intersect(kAsmSigned, kAsmUnsigned, zone());
74 Type* const kAsmFloat = kFloat32; 76 Type* const kAsmFloat = kFloat32;
75 Type* const kAsmDouble = kFloat64; 77 Type* const kAsmDouble = kFloat64;
76 Type* const kAsmFloatQ = Type::Union(kAsmFloat, kUntaggedUndefined, zone()); 78 Type* const kAsmFloatQ = Type::Union(kAsmFloat, kUntaggedUndefined, zone());
77 Type* const kAsmDoubleQ = Type::Union(kAsmDouble, kUntaggedUndefined, zone()); 79 Type* const kAsmDoubleQ = Type::Union(kAsmDouble, kUntaggedUndefined, zone());
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 return Type::Range(min, max, zone()); 148 return Type::Range(min, max, zone());
147 } 149 }
148 150
149 Zone* zone() { return &zone_; } 151 Zone* zone() { return &zone_; }
150 }; 152 };
151 153
152 } // namespace internal 154 } // namespace internal
153 } // namespace v8 155 } // namespace v8
154 156
155 #endif // V8_TYPE_CACHE_H_ 157 #endif // V8_TYPE_CACHE_H_
OLDNEW
« no previous file with comments | « src/compiler/simplified-lowering.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698