Fix lower bound in JSLoadContext typer.

R=rossberg@chromium.org

Review URL: https://codereview.chromium.org/549133002

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@23777 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
mstarzinger@chromium.org 2014-09-08 14:32:17 +00:00
parent c3e63ee946
commit 05167dd73c

View File

@ -485,8 +485,6 @@ Bounds Typer::Visitor::TypeJSInstanceOf(Node* node) {
// JS context operators.
Bounds Typer::Visitor::TypeJSLoadContext(Node* node) {
// TODO(rossberg): Fix this once we actually use the lower bound anywhere.
#if 0
Bounds outer = OperandType(node, 0);
DCHECK(outer.upper->Maybe(Type::Internal()));
// TODO(rossberg): More precisely, instead of the above assertion, we should
@ -509,7 +507,7 @@ Bounds Typer::Visitor::TypeJSLoadContext(Node* node) {
if (context_type->IsConstant()) {
context = Handle<Context>::cast(context_type->AsConstant()->Value());
}
} else {
} else if (!context.is_null()) {
context = handle(context.ToHandleChecked()->previous(), isolate());
}
}
@ -521,9 +519,6 @@ Bounds Typer::Visitor::TypeJSLoadContext(Node* node) {
Type* lower = TypeConstant(value);
return Bounds(lower, Type::Any(zone()));
}
#else
return Bounds::Unbounded(zone());
#endif
}