| 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 <iomanip> | 7 #include <iomanip> |
| 8 | 8 |
| 9 #include "src/base/flags.h" | 9 #include "src/base/flags.h" |
| 10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
| (...skipping 802 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 813 Type* Typer::Visitor::TypeFinishRegion(Node* node) { return Operand(node, 0); } | 813 Type* Typer::Visitor::TypeFinishRegion(Node* node) { return Operand(node, 0); } |
| 814 | 814 |
| 815 | 815 |
| 816 Type* Typer::Visitor::TypeFrameState(Node* node) { | 816 Type* Typer::Visitor::TypeFrameState(Node* node) { |
| 817 // TODO(rossberg): Ideally FrameState wouldn't have a value output. | 817 // TODO(rossberg): Ideally FrameState wouldn't have a value output. |
| 818 return Type::Internal(); | 818 return Type::Internal(); |
| 819 } | 819 } |
| 820 | 820 |
| 821 Type* Typer::Visitor::TypeStateValues(Node* node) { return Type::Internal(); } | 821 Type* Typer::Visitor::TypeStateValues(Node* node) { return Type::Internal(); } |
| 822 | 822 |
| 823 Type* Typer::Visitor::TypeObjectState(Node* node) { return Type::Internal(); } | |
| 824 | |
| 825 Type* Typer::Visitor::TypeTypedStateValues(Node* node) { | 823 Type* Typer::Visitor::TypeTypedStateValues(Node* node) { |
| 826 return Type::Internal(); | 824 return Type::Internal(); |
| 827 } | 825 } |
| 828 | 826 |
| 827 Type* Typer::Visitor::TypeObjectState(Node* node) { return Type::Internal(); } |
| 828 |
| 829 Type* Typer::Visitor::TypeTypedObjectState(Node* node) { |
| 830 return Type::Internal(); |
| 831 } |
| 829 | 832 |
| 830 Type* Typer::Visitor::TypeCall(Node* node) { return Type::Any(); } | 833 Type* Typer::Visitor::TypeCall(Node* node) { return Type::Any(); } |
| 831 | 834 |
| 832 | 835 |
| 833 Type* Typer::Visitor::TypeProjection(Node* node) { | 836 Type* Typer::Visitor::TypeProjection(Node* node) { |
| 834 Type* const type = Operand(node, 0); | 837 Type* const type = Operand(node, 0); |
| 835 if (type->Is(Type::None())) return Type::None(); | 838 if (type->Is(Type::None())) return Type::None(); |
| 836 int const index = static_cast<int>(ProjectionIndexOf(node->op())); | 839 int const index = static_cast<int>(ProjectionIndexOf(node->op())); |
| 837 if (type->IsTuple() && index < type->AsTuple()->Arity()) { | 840 if (type->IsTuple() && index < type->AsTuple()->Arity()) { |
| 838 return type->AsTuple()->Element(index); | 841 return type->AsTuple()->Element(index); |
| (...skipping 895 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1734 Type* Typer::Visitor::TypeConstant(Handle<Object> value) { | 1737 Type* Typer::Visitor::TypeConstant(Handle<Object> value) { |
| 1735 if (Type::IsInteger(*value)) { | 1738 if (Type::IsInteger(*value)) { |
| 1736 return Type::Range(value->Number(), value->Number(), zone()); | 1739 return Type::Range(value->Number(), value->Number(), zone()); |
| 1737 } | 1740 } |
| 1738 return Type::NewConstant(value, zone()); | 1741 return Type::NewConstant(value, zone()); |
| 1739 } | 1742 } |
| 1740 | 1743 |
| 1741 } // namespace compiler | 1744 } // namespace compiler |
| 1742 } // namespace internal | 1745 } // namespace internal |
| 1743 } // namespace v8 | 1746 } // namespace v8 |
| OLD | NEW |