Lines Matching refs:Truncation
22 class Truncation final {
25 static Truncation None() {
26 return Truncation(TruncationKind::kNone, kIdentifyZeros);
28 static Truncation Bool() {
29 return Truncation(TruncationKind::kBool, kIdentifyZeros);
31 static Truncation Word32() {
32 return Truncation(TruncationKind::kWord32, kIdentifyZeros);
34 static Truncation Word64() {
35 return Truncation(TruncationKind::kWord64, kIdentifyZeros);
37 static Truncation OddballAndBigIntToNumber(
39 return Truncation(TruncationKind::kOddballAndBigIntToNumber,
42 static Truncation Any(IdentifyZeros identify_zeros = kDistinguishZeros) {
43 return Truncation(TruncationKind::kAny, identify_zeros);
46 static Truncation Generalize(Truncation t1, Truncation t2) {
47 return Truncation(
75 bool operator==(Truncation other) const {
78 bool operator!=(Truncation other) const { return !(*this == other); }
82 bool IsLessGeneralThan(Truncation other) const {
99 explicit Truncation(TruncationKind kind, IdentifyZeros identify_zeros)
172 UseInfo(MachineRepresentation representation, Truncation truncation,
180 return UseInfo(MachineRepresentation::kWord32, Truncation::Word32());
186 return UseInfo(MachineRepresentation::kWord64, Truncation::Word64(),
190 return UseInfo(MachineRepresentation::kWord64, Truncation::Any());
193 return UseInfo(MachineType::PointerRepresentation(), Truncation::Any());
196 return UseInfo(MachineRepresentation::kBit, Truncation::Bool());
199 return UseInfo(MachineRepresentation::kFloat32, Truncation::Any());
202 return UseInfo(MachineRepresentation::kFloat64, Truncation::Any());
207 Truncation::OddballAndBigIntToNumber(identify_zeros));
210 return UseInfo(MachineRepresentation::kTagged, Truncation::Any());
213 return UseInfo(MachineRepresentation::kTaggedSigned, Truncation::Any());
216 return UseInfo(MachineRepresentation::kTaggedPointer, Truncation::Any());
222 Truncation::Any(kIdentifyZeros), TypeCheckKind::kArrayIndex,
227 return UseInfo(MachineRepresentation::kTaggedPointer, Truncation::Any(),
232 return UseInfo(MachineRepresentation::kTaggedPointer, Truncation::Any(),
240 Truncation::Any(identify_zeros), TypeCheckKind::kSignedSmall,
246 Truncation::Any(identify_zeros), TypeCheckKind::kSignedSmall,
252 Truncation::Any(identify_zeros), TypeCheckKind::kSigned32,
258 Truncation::Any(identify_zeros), TypeCheckKind::kSigned64,
264 Truncation::Any(identify_zeros), TypeCheckKind::kNumber,
268 return UseInfo(MachineRepresentation::kWord32, Truncation::Word32(),
274 Truncation::Any(identify_zeros),
280 Truncation::Any(identify_zeros),
285 return UseInfo(MachineRepresentation::kWord32, Truncation::Word32(),
291 return UseInfo(MachineRepresentation::kNone, Truncation::Any());
294 return UseInfo(MachineRepresentation::kNone, Truncation::Bool());
299 return UseInfo(MachineRepresentation::kNone, Truncation::None());
303 Truncation truncation() const { return truncation_; }
314 Truncation truncation_;
374 Type output_type, Truncation truncation);
377 Type output_type, Truncation truncation);