Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(174)

Unified Diff: src/compiler/typer.cc

Issue 1205473004: [turbofan] Make global variable loads and stores explicit. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/operator-properties.cc ('k') | src/compiler/verifier.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/typer.cc
diff --git a/src/compiler/typer.cc b/src/compiler/typer.cc
index 6e9a28ee3b0f7cb889e4606f7a759a7f8d110822..955fc754399f53c7fb0897bcf01f49551b41fc43 100644
--- a/src/compiler/typer.cc
+++ b/src/compiler/typer.cc
@@ -1338,6 +1338,11 @@ Bounds Typer::Visitor::TypeJSLoadNamed(Node* node) {
}
+Bounds Typer::Visitor::TypeJSLoadGlobal(Node* node) {
+ return Bounds::Unbounded(zone());
+}
+
+
// Returns a somewhat larger range if we previously assigned
// a (smaller) range to this node. This is used to speed up
// the fixpoint calculation in case there appears to be a loop
@@ -1431,6 +1436,12 @@ Bounds Typer::Visitor::TypeJSStoreNamed(Node* node) {
}
+Bounds Typer::Visitor::TypeJSStoreGlobal(Node* node) {
+ UNREACHABLE();
+ return Bounds();
+}
+
+
Bounds Typer::Visitor::TypeJSDeleteProperty(Node* node) {
return Bounds(Type::None(zone()), Type::Boolean(zone()));
}
@@ -1453,12 +1464,9 @@ Bounds Typer::Visitor::TypeJSLoadContext(Node* node) {
ContextAccess access = OpParameter<ContextAccess>(node);
Bounds outer = Operand(node, 0);
Type* context_type = outer.upper;
- Type* upper = (access.index() == Context::GLOBAL_OBJECT_INDEX)
- ? Type::GlobalObject()
- : Type::Any();
if (context_type->Is(Type::None())) {
// Upper bound of context is not yet known.
- return Bounds(Type::None(), upper);
+ return Bounds(Type::None(), Type::Any());
}
DCHECK(context_type->Maybe(Type::Internal()));
@@ -1488,7 +1496,7 @@ Bounds Typer::Visitor::TypeJSLoadContext(Node* node) {
handle(context.ToHandleChecked()->get(static_cast<int>(access.index())),
isolate()));
}
- return Bounds(lower, upper);
+ return Bounds(lower, Type::Any());
}
« no previous file with comments | « src/compiler/operator-properties.cc ('k') | src/compiler/verifier.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698