Title: [161361] branches/jsCStack/Source/_javascript_Core
Revision
161361
Author
[email protected]
Date
2014-01-06 12:23:07 -0800 (Mon, 06 Jan 2014)

Log Message

CStack: jsStackLimit fixup should not exceed native stack limit.
https://bugs.webkit.org/show_bug.cgi?id=126487.

Reviewed by Michael Saboff.

In doCallToJavaScript, we fixup VM::m_jsStackLimit once we know what the
stackPointerAtVMEntry is. However, we also need to ensure that the fixed
up jsStackLimit does not exceed the native stack limit. This check was
missing, and resulted in an assertion failure when running testapi on
platforms that have smaller stacks. This is now fixed.

* llint/LowLevelInterpreter64.asm:

Modified Paths

Diff

Modified: branches/jsCStack/Source/_javascript_Core/ChangeLog (161360 => 161361)


--- branches/jsCStack/Source/_javascript_Core/ChangeLog	2014-01-06 20:10:07 UTC (rev 161360)
+++ branches/jsCStack/Source/_javascript_Core/ChangeLog	2014-01-06 20:23:07 UTC (rev 161361)
@@ -1,3 +1,18 @@
+2014-01-06  Mark Lam  <[email protected]>
+
+        CStack: jsStackLimit fixup should not exceed native stack limit.
+        https://bugs.webkit.org/show_bug.cgi?id=126487.
+
+        Reviewed by Michael Saboff.
+
+        In doCallToJavaScript, we fixup VM::m_jsStackLimit once we know what the
+        stackPointerAtVMEntry is. However, we also need to ensure that the fixed
+        up jsStackLimit does not exceed the native stack limit. This check was
+        missing, and resulted in an assertion failure when running testapi on
+        platforms that have smaller stacks. This is now fixed.
+
+        * llint/LowLevelInterpreter64.asm:
+
 2014-01-05  Michael Saboff  <[email protected]>
 
         CStack Branch: ARM64 Fix other prologue and epilogue macros in LLInt

Modified: branches/jsCStack/Source/_javascript_Core/llint/LowLevelInterpreter64.asm (161360 => 161361)


--- branches/jsCStack/Source/_javascript_Core/llint/LowLevelInterpreter64.asm	2014-01-06 20:10:07 UTC (rev 161360)
+++ branches/jsCStack/Source/_javascript_Core/llint/LowLevelInterpreter64.asm	2014-01-06 20:23:07 UTC (rev 161361)
@@ -128,6 +128,12 @@
     move sp, temp2
     subp VM::stackPointerAtVMEntry[vm], temp2, temp2
     subp VM::m_jsStackLimit[vm], temp2, temp2
+if C_LOOP
+else
+    bpaeq temp2, VM::m_stackLimit[vm], .noNeedToCapJSStackToNativeStackLimit
+    loadp VM::m_stackLimit[vm], temp2
+.noNeedToCapJSStackToNativeStackLimit:
+end
     storep temp2, VM::m_jsStackLimit[vm]
     move sp, temp2
     storep temp2, VM::stackPointerAtVMEntry[vm]
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to