Bug 1139152: IonMonkey: Don't improve types at MTypeOf for unknown types, r=jandem
authorHannes Verschore <hv1989@gmail.com>
Wed, 04 Mar 2015 16:17:27 +0100
changeset 231890 6dfab0f84d52708d4be83453961c4fea1050e60a
parent 231889 b06982ec6797d8351b9ec8bc6103cbb599acd5e8
child 231891 ec41cc2959b5889310a1b499f7790bfb7c2b5cae
push id28362
push userryanvm@gmail.com
push dateWed, 04 Mar 2015 21:35:51 +0000
treeherdermozilla-central@56492f7244a9 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjandem
bugs1139152
milestone39.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1139152: IonMonkey: Don't improve types at MTypeOf for unknown types, r=jandem
js/src/jit/IonBuilder.cpp
--- a/js/src/jit/IonBuilder.cpp
+++ b/js/src/jit/IonBuilder.cpp
@@ -3503,16 +3503,18 @@ IonBuilder::improveTypesAtTypeOfCompare(
         filter.addType(TypeSet::SymbolType(), alloc_->lifoAlloc());
     } else if (constant->toString() == TypeName(JSTYPE_OBJECT, names)) {
         filter.addType(TypeSet::NullType(), alloc_->lifoAlloc());
         if (trueBranch)
             filter.addType(TypeSet::AnyObjectType(), alloc_->lifoAlloc());
     } else if (constant->toString() == TypeName(JSTYPE_FUNCTION, names)) {
         if (typeOf->inputMaybeCallableOrEmulatesUndefined() && trueBranch)
             filter.addType(TypeSet::AnyObjectType(), alloc_->lifoAlloc());
+    } else {
+        return true;
     }
 
     TemporaryTypeSet *type;
     if (trueBranch)
         type = TypeSet::intersectSets(&filter, inputTypes, alloc_->lifoAlloc());
     else
         type = TypeSet::removeSet(inputTypes, &filter, alloc_->lifoAlloc());