[Pkg-mono-svn-commits] rev 3238 - in mono/trunk/debian: . patches

Sebastian Dröge slomo at alioth.debian.org
Mon Jul 16 11:57:15 UTC 2007


Author: slomo
Date: 2007-07-16 11:57:15 +0000 (Mon, 16 Jul 2007)
New Revision: 3238

Added:
   mono/trunk/debian/patches/mono-ppc-corruption.dpatch
Modified:
   mono/trunk/debian/changelog
   mono/trunk/debian/patches/00list
Log:
* debian/patches/mono-ppc-corruption.dpatch:
  + Fix memory corruption on PPC, causing many Gtk# programs to crash.
    Patch from upstream SVN.
    (Closes: #428209, #430614, #427934, #428190, #429685)

Modified: mono/trunk/debian/changelog
===================================================================
--- mono/trunk/debian/changelog	2007-07-15 20:29:54 UTC (rev 3237)
+++ mono/trunk/debian/changelog	2007-07-16 11:57:15 UTC (rev 3238)
@@ -1,3 +1,12 @@
+mono (1.2.4-5) UNRELEASED; urgency=low
+
+  * debian/patches/mono-ppc-corruption.dpatch:
+    + Fix memory corruption on PPC, causing many Gtk# programs to crash.
+      Patch from upstream SVN.
+      (Closes: #428209, #430614, #427934, #428190, #429685)
+
+ -- Sebastian Dröge <slomo at debian.org>  Mon, 16 Jul 2007 13:52:03 +0200
+
 mono (1.2.4-4) unstable; urgency=low
 
   * Mirco 'meebey' Bauer:

Modified: mono/trunk/debian/patches/00list
===================================================================
--- mono/trunk/debian/patches/00list	2007-07-15 20:29:54 UTC (rev 3237)
+++ mono/trunk/debian/patches/00list	2007-07-16 11:57:15 UTC (rev 3238)
@@ -6,3 +6,4 @@
 fix-mono-cairo.pc.in
 #dont_remap_non-runtime_libs
 g_thread_init.dpatch
+mono-ppc-corruption.dpatch

Added: mono/trunk/debian/patches/mono-ppc-corruption.dpatch
===================================================================
--- mono/trunk/debian/patches/mono-ppc-corruption.dpatch	                        (rev 0)
+++ mono/trunk/debian/patches/mono-ppc-corruption.dpatch	2007-07-16 11:57:15 UTC (rev 3238)
@@ -0,0 +1,35 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+
+ at DPATCH@
+
+Index: mono/mono/mini/mini-ppc.c
+===================================================================
+--- mono/mono/mini/mini-ppc.c	(Revision 81412)
++++ mono/mono/mini/mini-ppc.c	(Revision 81413)
+@@ -2560,8 +2560,12 @@
+ 			ppc_rlwinm (code, ppc_r11, ppc_r11, 0, 0, 27);
+ 			/* use ctr to store the number of words to 0 if needed */
+ 			if (ins->flags & MONO_INST_INIT) {
+-				/* we zero 4 bytes at a time */
+-				ppc_addi (code, ppc_r0, ins->sreg1, 3);
++				/* we zero 4 bytes at a time:
++				 * we add 7 instead of 3 so that we set the counter to
++				 * at least 1, otherwise the bdnz instruction will make
++				 * it negative and iterate billions of times.
++				 */
++				ppc_addi (code, ppc_r0, ins->sreg1, 7);
+ 				ppc_srawi (code, ppc_r0, ppc_r0, 2);
+ 				ppc_mtctr (code, ppc_r0);
+ 			}
+@@ -2571,7 +2575,10 @@
+ 			
+ 			if (ins->flags & MONO_INST_INIT) {
+ 				/* adjust the dest reg by -4 so we can use stwu */
+-				ppc_addi (code, ins->dreg, ppc_sp, (area_offset - 4));
++				/* we actually adjust -8 because we let the loop
++				 * run at least once
++				 */
++				ppc_addi (code, ins->dreg, ppc_sp, (area_offset - 8));
+ 				ppc_li (code, ppc_r11, 0);
+ 				zero_loop_start = code;
+ 				ppc_stwu (code, ppc_r11, 4, ins->dreg);


Property changes on: mono/trunk/debian/patches/mono-ppc-corruption.dpatch
___________________________________________________________________
Name: svn:executable
   + *




More information about the Pkg-mono-svn-commits mailing list