[packages/iceweasel] backported long-standing bug 941837 (vmem fragmentation) fix, while waiting for 837835, 767343, 9307

gotar gotar at pld-linux.org
Thu Nov 28 05:12:59 CET 2013


commit 77cef3635a1762370687bc1cc67e4ca09dd11936
Author: Tomasz Pala <gotar at pld-linux.org>
Date:   Thu Nov 28 05:08:25 2013 +0100

    backported long-standing bug 941837 (vmem fragmentation) fix, while
    waiting for 837835, 767343, 930797 and dozen related ones in this bugware

 941837.patch   | 20 ++++++++++++++++++++
 iceweasel.spec |  2 ++
 2 files changed, 22 insertions(+)
---
diff --git a/iceweasel.spec b/iceweasel.spec
index ab1caa3..c55dcd2 100644
--- a/iceweasel.spec
+++ b/iceweasel.spec
@@ -38,6 +38,7 @@ Source4:	%{name}.sh
 Source5:	vendor.js
 Source6:	vendor-ac.js
 Patch0:		%{name}-branding.patch
+Patch1:		941837.patch
 Patch7:		%{name}-prefs.patch
 Patch8:		%{name}-pld-branding.patch
 Patch9:		%{name}-no-subshell.patch
@@ -158,6 +159,7 @@ cd mozilla
 /bin/sh %{SOURCE2}
 
 %patch0 -p1
+%patch1 -p1
 %patch7 -p1
 %patch8 -p1
 %patch9 -p2
diff --git a/941837.patch b/941837.patch
new file mode 100644
index 0000000..8e85cf6
--- /dev/null
+++ b/941837.patch
@@ -0,0 +1,20 @@
+--- a/js/src/gc/Memory.cpp.orig	2013-11-13 01:13:53.000000000 +0100
++++ a/js/src/gc/Memory.cpp	2013-11-28 05:03:31.160133711 +0100
+@@ -63,7 +63,7 @@
+         p = VirtualAlloc(NULL, size * 2, MEM_RESERVE, PAGE_READWRITE);
+         if (!p)
+             return NULL;
+-        void *chunkStart = (void *)(uintptr_t(p) + (alignment - (uintptr_t(p) % alignment)));
++        void *chunkStart = (void *)AlignBytes(uintptr_t(p), alignment);
+         UnmapPages(rt, p, size * 2);
+         p = VirtualAlloc(chunkStart, size, MEM_COMMIT | MEM_RESERVE, PAGE_READWRITE);
+ 
+@@ -335,7 +335,7 @@
+     uintptr_t offset = uintptr_t(region) % alignment;
+     JS_ASSERT(offset < reqSize - size);
+ 
+-    void *front = (void *)(uintptr_t(region) + (alignment - offset));
++    void *front = (void *)AlignBytes(uintptr_t(region), alignment);
+     void *end = (void *)(uintptr_t(front) + size);
+     if (front != region)
+         JS_ALWAYS_TRUE(0 == munmap(region, alignment - offset));
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/iceweasel.git/commitdiff/77cef3635a1762370687bc1cc67e4ca09dd11936



More information about the pld-cvs-commit mailing list