components/desktop/thunderbird/patches/firefox-27-stacksize.patch
author Stacy Yeh <stacy.yeh@oracle.com>
Tue, 19 Jul 2016 14:15:23 -0700
changeset 6431 e4667e7df088
permissions -rw-r--r--
23601539 Update Thunderbird to version 45.1.0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
6431
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     1
For sparc. Our function frame is very big, so on sparc we need more stack size.
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     2
Potentially send upstream. 
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     3
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     4
diff --git a/js/src/jsapi.cpp b/js/src/jsapi.cpp
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     5
--- a/js/src/jsapi.cpp
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     6
+++ b/js/src/jsapi.cpp
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     7
@@ -1491,6 +1491,9 @@
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     8
 static void
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
     9
 SetNativeStackQuotaAndLimit(JSRuntime* rt, StackKind kind, size_t stackSize)
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
    10
 {
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
    11
+#ifdef JS_CPU_SPARC
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
    12
+    stackSize = stackSize * 8 < 7 * 1024 * 1024 ? stackSize * 8 : 7 * 1024 * 1024;
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
    13
+#endif
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
    14
     rt->nativeStackQuota[kind] = stackSize;
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
    15
      
e4667e7df088 23601539 Update Thunderbird to version 45.1.0
Stacy Yeh <stacy.yeh@oracle.com>
parents:
diff changeset
    16
 #if JS_STACK_GROWTH_DIRECTION > 0