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 #include "src/compiler/typer.h" | 5 #include "src/compiler/typer.h" |
6 | 6 |
7 #include "src/base/flags.h" | 7 #include "src/base/flags.h" |
8 #include "src/bootstrapper.h" | 8 #include "src/bootstrapper.h" |
9 #include "src/compilation-dependencies.h" | 9 #include "src/compilation-dependencies.h" |
10 #include "src/compiler/common-operator.h" | 10 #include "src/compiler/common-operator.h" |
(...skipping 2021 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2032 } | 2032 } |
2033 } | 2033 } |
2034 return type; | 2034 return type; |
2035 } | 2035 } |
2036 | 2036 |
2037 Type* Typer::Visitor::TypeCheckIf(Node* node) { | 2037 Type* Typer::Visitor::TypeCheckIf(Node* node) { |
2038 UNREACHABLE(); | 2038 UNREACHABLE(); |
2039 return nullptr; | 2039 return nullptr; |
2040 } | 2040 } |
2041 | 2041 |
2042 Type* Typer::Visitor::TypeCheckUnless(Node* node) { | |
2043 UNREACHABLE(); | |
2044 return nullptr; | |
2045 } | |
2046 | |
2047 Type* Typer::Visitor::TypeTruncateTaggedToWord32(Node* node) { | 2042 Type* Typer::Visitor::TypeTruncateTaggedToWord32(Node* node) { |
2048 Type* arg = Operand(node, 0); | 2043 Type* arg = Operand(node, 0); |
2049 // TODO(jarin): DCHECK(arg->Is(Type::NumberOrUndefined())); | 2044 // TODO(jarin): DCHECK(arg->Is(Type::NumberOrUndefined())); |
2050 // Several mjsunit and cctest tests fail this check. For instance, | 2045 // Several mjsunit and cctest tests fail this check. For instance, |
2051 // mjsunit/compiler/regress-607493 fails with Any/Any in simplified-lowering | 2046 // mjsunit/compiler/regress-607493 fails with Any/Any in simplified-lowering |
2052 // (after propagation). | 2047 // (after propagation). |
2053 return ChangeRepresentation(arg, Type::UntaggedIntegral32(), zone()); | 2048 return ChangeRepresentation(arg, Type::UntaggedIntegral32(), zone()); |
2054 } | 2049 } |
2055 | 2050 |
2056 Type* Typer::Visitor::TypeAllocate(Node* node) { return Type::TaggedPointer(); } | 2051 Type* Typer::Visitor::TypeAllocate(Node* node) { return Type::TaggedPointer(); } |
(...skipping 718 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2775 } | 2770 } |
2776 if (Type::IsInteger(*value)) { | 2771 if (Type::IsInteger(*value)) { |
2777 return Type::Range(value->Number(), value->Number(), zone()); | 2772 return Type::Range(value->Number(), value->Number(), zone()); |
2778 } | 2773 } |
2779 return Type::Constant(value, zone()); | 2774 return Type::Constant(value, zone()); |
2780 } | 2775 } |
2781 | 2776 |
2782 } // namespace compiler | 2777 } // namespace compiler |
2783 } // namespace internal | 2778 } // namespace internal |
2784 } // namespace v8 | 2779 } // namespace v8 |
OLD | NEW |