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 589 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
600 } else if (index == Linkage::GetJSCallArgCountParamIndex(parameter_count)) { | 600 } else if (index == Linkage::GetJSCallArgCountParamIndex(parameter_count)) { |
601 return Type::Range(0.0, Code::kMaxArguments, typer_->zone()); | 601 return Type::Range(0.0, Code::kMaxArguments, typer_->zone()); |
602 } else if (index == Linkage::GetJSCallContextParamIndex(parameter_count)) { | 602 } else if (index == Linkage::GetJSCallContextParamIndex(parameter_count)) { |
603 return Type::OtherInternal(); | 603 return Type::OtherInternal(); |
604 } | 604 } |
605 return Type::NonInternal(); | 605 return Type::NonInternal(); |
606 } | 606 } |
607 | 607 |
608 Type* Typer::Visitor::TypeOsrValue(Node* node) { return Type::Any(); } | 608 Type* Typer::Visitor::TypeOsrValue(Node* node) { return Type::Any(); } |
609 | 609 |
610 Type* Typer::Visitor::TypeOsrGuard(Node* node) { | |
611 switch (OsrGuardTypeOf(node->op())) { | |
612 case OsrGuardType::kUninitialized: | |
613 return Type::None(); | |
614 case OsrGuardType::kSignedSmall: | |
615 return Type::SignedSmall(); | |
616 case OsrGuardType::kAny: | |
617 return Type::Any(); | |
618 } | |
619 UNREACHABLE(); | |
620 return nullptr; | |
621 } | |
622 | |
623 Type* Typer::Visitor::TypeRetain(Node* node) { | 610 Type* Typer::Visitor::TypeRetain(Node* node) { |
624 UNREACHABLE(); | 611 UNREACHABLE(); |
625 return nullptr; | 612 return nullptr; |
626 } | 613 } |
627 | 614 |
628 Type* Typer::Visitor::TypeInt32Constant(Node* node) { | 615 Type* Typer::Visitor::TypeInt32Constant(Node* node) { |
629 UNREACHABLE(); | 616 UNREACHABLE(); |
630 return nullptr; | 617 return nullptr; |
631 } | 618 } |
632 | 619 |
(...skipping 1370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2003 Type* Typer::Visitor::TypeConstant(Handle<Object> value) { | 1990 Type* Typer::Visitor::TypeConstant(Handle<Object> value) { |
2004 if (Type::IsInteger(*value)) { | 1991 if (Type::IsInteger(*value)) { |
2005 return Type::Range(value->Number(), value->Number(), zone()); | 1992 return Type::Range(value->Number(), value->Number(), zone()); |
2006 } | 1993 } |
2007 return Type::NewConstant(value, zone()); | 1994 return Type::NewConstant(value, zone()); |
2008 } | 1995 } |
2009 | 1996 |
2010 } // namespace compiler | 1997 } // namespace compiler |
2011 } // namespace internal | 1998 } // namespace internal |
2012 } // namespace v8 | 1999 } // namespace v8 |
OLD | NEW |