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

Unified Diff: src/compiler/typer.cc

Issue 2237433003: [turbofan] Utilize type information for alias analysis. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix ASAN redness. Created 4 years, 4 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/load-elimination.cc ('k') | src/field-type.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 006029cd1a3b992d100c6c1645577a3112404fdf..37d9a94006ff7a7501fc9bb93bdd81da26215db2 100644
--- a/src/compiler/typer.cc
+++ b/src/compiler/typer.cc
@@ -294,7 +294,6 @@ class Typer::Visitor : public Reducer {
#undef DECLARE_METHOD
static Type* JSTypeOfTyper(Type*, Typer*);
- static Type* JSLoadPropertyTyper(Type*, Type*, Typer*);
static Type* JSCallFunctionTyper(Type*, Typer*);
static Type* ReferenceEqualTyper(Type*, Type*, Typer*);
@@ -545,8 +544,9 @@ Type* Typer::Visitor::ObjectIsUndetectable(Type* type, Typer* t) {
Type* Typer::Visitor::TypeStart(Node* node) { return Type::Internal(); }
-Type* Typer::Visitor::TypeIfException(Node* node) { return Type::Any(); }
-
+Type* Typer::Visitor::TypeIfException(Node* node) {
+ return Type::NonInternal();
+}
// Common operators.
@@ -1080,28 +1080,18 @@ Type* Typer::Visitor::TypeJSCreateLiteralRegExp(Node* node) {
}
-Type* Typer::Visitor::JSLoadPropertyTyper(Type* object, Type* name, Typer* t) {
- // TODO(rossberg): Use range types and sized array types to filter undefined.
- if (object->IsArray() && name->Is(Type::Integral32())) {
- return Type::Union(
- object->AsArray()->Element(), Type::Undefined(), t->zone());
- }
- return Type::Any();
-}
-
-
Type* Typer::Visitor::TypeJSLoadProperty(Node* node) {
- return TypeBinaryOp(node, JSLoadPropertyTyper);
+ return Type::NonInternal();
}
Type* Typer::Visitor::TypeJSLoadNamed(Node* node) {
- return Type::Any();
+ return Type::NonInternal();
}
-
-Type* Typer::Visitor::TypeJSLoadGlobal(Node* node) { return Type::Any(); }
-
+Type* Typer::Visitor::TypeJSLoadGlobal(Node* node) {
+ return Type::NonInternal();
+}
// Returns a somewhat larger range if we previously assigned
// a (smaller) range to this node. This is used to speed up
@@ -1359,7 +1349,7 @@ Type* Typer::Visitor::JSCallFunctionTyper(Type* fun, Typer* t) {
}
}
}
- return Type::Any();
+ return Type::NonInternal();
}
@@ -1402,6 +1392,9 @@ Type* Typer::Visitor::TypeJSCallRuntime(Node* node) {
default:
break;
}
+ // TODO(turbofan): This should be Type::NonInternal(), but unfortunately we
+ // have a few weird runtime calls that return the hole or even FixedArrays;
+ // change this once those weird runtime calls have been removed.
return Type::Any();
}
« no previous file with comments | « src/compiler/load-elimination.cc ('k') | src/field-type.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698