Add new patch to fix code generation on amd64, stolen from upstream
authorJulien Cristau <julien.cristau@ens-lyon.org>
Tue, 14 Jun 2005 01:28:06 +0000 (01:28 +0000)
committerJulien Cristau <julien.cristau@ens-lyon.org>
Tue, 14 Jun 2005 01:28:06 +0000 (01:28 +0000)
release308 CVS branch.

debian/changelog
debian/patches/00list
debian/patches/asmcomp_amd64_emit.mlp.dpatch [new file with mode: 0755]

index dd393b7631c7fbf55c6e3d7131e6e03bd6bd6049..228baddafab53dfe4fa9bc9318ada63f1ab3a4e0 100644 (file)
@@ -2,9 +2,11 @@ ocaml (3.08.3-3+SVN) UNRELEASED; urgency=low
 
   * Create directories in /usr/local/lib with proper permissions in
     ocaml-base-nox's postinst, and remove them if empty in prerm
-    (Closes: #270925)
+    (Closes: #270925).
+  * Add patch from upstream bugfix branch by Xavier Leroy to fix code
+    generation on amd64 (reported by John Skaller).
 
- -- Julien Cristau <julien.cristau@ens-lyon.org>  Sat, 16 Apr 2005 14:22:32 +0200
+ -- Julien Cristau <julien.cristau@ens-lyon.org>  Tue, 14 Jun 2005 03:17:55 +0200
 
 ocaml (3.08.3-3) unstable; urgency=medium
 
index 858d13e00b771b0f7df5c91b3c014dfae92d73f6..693b7a9bce62565111b4dd675478d58c23f6a1b8 100644 (file)
@@ -1,3 +1,4 @@
 versioned_libdir
 objinfo
 man-ocamlmklib
+asmcomp_amd64_emit.mlp
diff --git a/debian/patches/asmcomp_amd64_emit.mlp.dpatch b/debian/patches/asmcomp_amd64_emit.mlp.dpatch
new file mode 100755 (executable)
index 0000000..a9e7cea
--- /dev/null
@@ -0,0 +1,33 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## asmcomp_amd64_emit.mlp.dpatch by  <julien.cristau@ens-lyon.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Upstream fix for code generation bug on amd64 (PR#3640)
+
+@DPATCH@
+diff -urNad ocaml-3.08.3/asmcomp/amd64/emit.mlp /tmp/dpep.7xGPae/ocaml-3.08.3/asmcomp/amd64/emit.mlp
+--- ocaml-3.08.3/asmcomp/amd64/emit.mlp        2004-07-01 18:09:03.000000000 +0200
++++ /tmp/dpep.7xGPae/ocaml-3.08.3/asmcomp/amd64/emit.mlp       2005-06-14 03:08:25.481518269 +0200
+@@ -10,7 +10,7 @@
+ (*                                                                     *)
+ (***********************************************************************)
+-(* $Id: emit.mlp,v 1.6.6.1 2004/07/01 16:09:03 xleroy Exp $ *)
++(* $Id: emit.mlp,v 1.6.6.2 2005/06/12 13:35:56 xleroy Exp $ *)
+ (* Emission of Intel 386 assembly code *)
+@@ -35,8 +35,12 @@
+   !contains_calls || num_stack_slots.(0) > 0 || num_stack_slots.(1) > 0
+ let frame_size () =                     (* includes return address *)
+-  let sz = (!stack_offset + 8 * (num_stack_slots.(0) + num_stack_slots.(1)) + 8)
++  if frame_required() then begin
++    let sz = 
++      (!stack_offset + 8 * (num_stack_slots.(0) + num_stack_slots.(1)) + 8)
+   in Misc.align sz 16
++  end else 
++    !stack_offset + 8
+ let slot_offset loc cl =
+   match loc with