Bug 1347486 - Replace MOZ_CRASH in GetCacheIRExpectedInputType with MOZ_ASSERT_UNREACHABLE. r=h4writer
authorJan de Mooij <jdemooij@mozilla.com>
Mon, 27 Mar 2017 14:39:56 +0200
changeset 349916 47b5e2e4dce6bc8198964b09f7ee6c362e30566c
parent 349915 e370a8a25bb188703d077ed8999c4cd2b03b5234
child 349917 5cbddcaa3e0cf0c8b761844717a0d0b49e651607
push id31563
push userkwierso@gmail.com
push dateTue, 28 Mar 2017 00:13:42 +0000
treeherdermozilla-central@5182b2c4b963 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersh4writer
bugs1347486
milestone55.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 1347486 - Replace MOZ_CRASH in GetCacheIRExpectedInputType with MOZ_ASSERT_UNREACHABLE. r=h4writer
js/src/jit/BaselineInspector.cpp
--- a/js/src/jit/BaselineInspector.cpp
+++ b/js/src/jit/BaselineInspector.cpp
@@ -1238,17 +1238,19 @@ GetCacheIRExpectedInputType(ICCacheIR_Mo
     if (reader.matchOp(CacheOp::GuardIsObject, ValOperandId(0)))
         return MIRType::Object;
     if (reader.matchOp(CacheOp::GuardIsString, ValOperandId(0)))
         return MIRType::String;
     if (reader.matchOp(CacheOp::GuardType, ValOperandId(0))) {
         JSValueType type = reader.valueType();
         return MIRTypeFromValueType(type);
     }
-    MOZ_CRASH("Unexpected instruction");
+
+    MOZ_ASSERT_UNREACHABLE("Unexpected instruction");
+    return MIRType::Value;
 }
 
 MIRType
 BaselineInspector::expectedPropertyAccessInputType(jsbytecode* pc)
 {
     if (!hasBaselineScript())
         return MIRType::Value;