CachedCall should not consider it UNLIKELY that it will not stack overflow
authorrmorisset@apple.com <rmorisset@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 19 Feb 2019 23:17:17 +0000 (23:17 +0000)
committerrmorisset@apple.com <rmorisset@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 19 Feb 2019 23:17:17 +0000 (23:17 +0000)
https://bugs.webkit.org/show_bug.cgi?id=194831

Reviewed by Mark Lam.

* interpreter/CachedCall.h:
(JSC::CachedCall::CachedCall):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241781 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/interpreter/CachedCall.h

index cdfe4c1..f82aab3 100644 (file)
@@ -1,3 +1,13 @@
+2019-02-19  Robin Morisset  <rmorisset@apple.com>
+
+        CachedCall should not consider it UNLIKELY that it will not stack overflow
+        https://bugs.webkit.org/show_bug.cgi?id=194831
+
+        Reviewed by Mark Lam.
+
+        * interpreter/CachedCall.h:
+        (JSC::CachedCall::CachedCall):
+
 2019-02-19  Mark Lam  <mark.lam@apple.com>
 
         Fix DFG doesGC() for TryGetById and ProfileType nodes.
index c20a855..80d7977 100644 (file)
@@ -49,7 +49,7 @@ namespace JSC {
             auto scope = DECLARE_THROW_SCOPE(vm);
 
             ASSERT(!function->isHostFunctionNonInline());
-            if (UNLIKELY(vm.isSafeToRecurseSoft())) {
+            if (LIKELY(vm.isSafeToRecurseSoft())) {
                 m_arguments.ensureCapacity(argumentCount);
                 if (LIKELY(!m_arguments.hasOverflowed()))
                     m_closure = m_interpreter->prepareForRepeatCall(function->jsExecutable(), callFrame, &m_protoCallFrame, function, argumentCount + 1, function->scope(), m_arguments);