[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#417542: gcc-4.1: Fix PR28508 for m32r



Package:gcc-4.1
Version:4.1.1ds2-21
Severity:wishlist
Tags:patch

I'm sorry, I sent a miss patch (Fix PR2850 patch)

Please apply this patch to fix PR28505 for m32r.

Regards,
Kazuhiro Inaoka
changelog:
  Fix PR gcc/28508.
  * debian/patches/pr28508.dpatch: Fix PR gcc/28508 for m32r.

 -- Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>  Tue,  3 Apr 2007 14:15:32 +0900

diff -Nrp ../../gcc-4.1-4.1.1ds2/debian/README.Debian ./debian/README.Debian
*** ../../gcc-4.1-4.1.1ds2/debian/README.Debian	Thu Jan 18 08:38:45 2007
--- ./debian/README.Debian	Tue Apr  3 05:59:26 2007
*************** i386-biarch:
*** 297,299 ****
--- 297,302 ----
  disable-configure-run-check:
    don't bogusly check if the 64bit binaries also work,
    which does break on 32bit kernels.
+ 
+ pr28508:
+   Fix PR gcc/2850.
diff -Nrp ../../gcc-4.1-4.1.1ds2/debian/patches/pr28508.dpatch ./debian/patches/pr28508.dpatch
*** ../../gcc-4.1-4.1.1ds2/debian/patches/pr28508.dpatch	Thu Jan  1 00:00:00 1970
--- ./debian/patches/pr28508.dpatch	Tue Apr  3 05:56:07 2007
***************
*** 0 ****
--- 1,70 ----
+ #! /bin/sh -e
+ 
+ # All lines beginning with `# DPATCH:' are a description of the patch.
+ # DP: Backport for M32R PR gcc/28508
+ 
+ dir=
+ if [ $# -eq 3 -a "$2" = '-d' ]; then
+     pdir="-d $3"
+     dir="$3/"
+ elif [ $# -ne 1 ]; then
+     echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+     exit 1
+ fi
+ case "$1" in
+     -patch)
+         patch $pdir -f --no-backup-if-mismatch -p0 < $0
+         #cd ${dir}gcc && autoconf
+         ;;
+     -unpatch)
+         patch $pdir -f --no-backup-if-mismatch -R -p0 < $0
+         #rm ${dir}gcc/configure
+         ;;
+     *)
+         echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
+         exit 1
+ esac
+ exit 0
+ 
+ # append the patch here and adjust the -p? flag in the patch calls.
+ --- gcc/config/m32r/m32r.md.orig	2007-04-03 13:31:10.393833856 +0900
+ +++ gcc/config/m32r/m32r.md	2007-04-03 13:31:34.469799848 +0900
+ @@ -1378,15 +1378,15 @@
+    return instruction;
+  }"
+    [(set_attr "type" "branch")
+ -   ; We use 400/800 instead of 512,1024 to account for inaccurate insn
+ +   ; We use 300/600 instead of 512,1024 to account for inaccurate insn
+     ; lengths and insn alignments that are complex to track.
+     ; It's not important that we be hyper-precise here.  It may be more
+     ; important blah blah blah when the chip supports parallel execution
+     ; blah blah blah but until then blah blah blah this is simple and
+     ; suffices.
+     (set (attr "length") (if_then_else (ltu (plus (minus (match_dup 0) (pc))
+ -						 (const_int 400))
+ -					   (const_int 800))
+ +						 (const_int 300))
+ +					   (const_int 600))
+  				      (const_int 2)
+  				      (const_int 4)))])
+  
+ @@ -1407,15 +1407,15 @@
+    return instruction;
+  }"
+    [(set_attr "type" "branch")
+ -   ; We use 400/800 instead of 512,1024 to account for inaccurate insn
+ +   ; We use 300/600 instead of 512,1024 to account for inaccurate insn
+     ; lengths and insn alignments that are complex to track.
+     ; It's not important that we be hyper-precise here.  It may be more
+     ; important blah blah blah when the chip supports parallel execution
+     ; blah blah blah but until then blah blah blah this is simple and
+     ; suffices.
+     (set (attr "length") (if_then_else (ltu (plus (minus (match_dup 0) (pc))
+ -						 (const_int 400))
+ -					   (const_int 800))
+ +						 (const_int 300))
+ +					   (const_int 600))
+  				      (const_int 2)
+  				      (const_int 4)))])
+  
+ 
diff -Nrp ../../gcc-4.1-4.1.1ds2/debian/rules.patch ./debian/rules.patch
*** ../../gcc-4.1-4.1.1ds2/debian/rules.patch	Thu Jan 18 08:38:45 2007
--- ./debian/rules.patch	Tue Apr  3 05:53:32 2007
*************** debian_patches += \
*** 84,89 ****
--- 84,90 ----
  	pr25878-revert \
  	libjava-sjlj \
  	pr29805 \
+ 	pr28508 \
  
  #	svn-updates \
  

Reply to: