diff options
| author | Zhenhua Luo <b19537@freescale.com> | 2012-03-16 17:02:31 +0000 |
|---|---|---|
| committer | Matthew McClintock <msm@freescale.com> | 2012-03-16 09:19:17 -0500 |
| commit | 2b64e1719a05a1985ca68d5820c562d76fb82ade (patch) | |
| tree | 4c1a81ecf5b3dd898ae507023fdf38560d10dd39 /recipes-devtools | |
| parent | 5f310948b0782ff291f86bc920f624af1105c6cc (diff) | |
| download | meta-fsl-ppc-2b64e1719a05a1985ca68d5820c562d76fb82ade.tar.gz | |
gcc: add gcc.fix_min_max.patch
Signed-off-by: Zhenhua Luo <b19537@freescale.com>
Diffstat (limited to 'recipes-devtools')
| -rw-r--r-- | recipes-devtools/gcc/files/gcc.fix_min_max.patch | 38 | ||||
| -rw-r--r-- | recipes-devtools/gcc/gcc-fsl.inc | 3 |
2 files changed, 40 insertions, 1 deletions
diff --git a/recipes-devtools/gcc/files/gcc.fix_min_max.patch b/recipes-devtools/gcc/files/gcc.fix_min_max.patch new file mode 100644 index 0000000..81167be --- /dev/null +++ b/recipes-devtools/gcc/files/gcc.fix_min_max.patch | |||
| @@ -0,0 +1,38 @@ | |||
| 1 | diff -Naur gcc-4.6.2/gcc/config/rs6000/rs6000.c gcc-4.6.2-modified-office2-gs8-ice-fix/gcc/config/rs6000/rs6000.c | ||
| 2 | --- gcc-4.6.2/gcc/config/rs6000/rs6000.c 2011-09-18 17:01:56.000000000 -0500 | ||
| 3 | +++ gcc-4.6.2-modified-office2-gs8-ice-fix/gcc/config/rs6000/rs6000.c 2012-01-13 07:07:31.702487887 -0600 | ||
| 4 | @@ -17727,11 +17727,34 @@ | ||
| 5 | c = GEU; | ||
| 6 | |||
| 7 | if (code == SMAX || code == UMAX) | ||
| 8 | + { | ||
| 9 | target = emit_conditional_move (dest, c, op0, op1, mode, | ||
| 10 | op0, op1, mode, 0); | ||
| 11 | + if(!target) | ||
| 12 | + { | ||
| 13 | + rtx tem; | ||
| 14 | + tem = simplify_const_relational_operation (c, mode, op0, op1); | ||
| 15 | + if(rtx_equal_p(tem,const0_rtx)) | ||
| 16 | + target = op1; | ||
| 17 | + else if(rtx_equal_p(tem,const1_rtx)) | ||
| 18 | + target = op0; | ||
| 19 | + } | ||
| 20 | + | ||
| 21 | + } | ||
| 22 | else | ||
| 23 | + { | ||
| 24 | target = emit_conditional_move (dest, c, op0, op1, mode, | ||
| 25 | op1, op0, mode, 0); | ||
| 26 | + if(!target) | ||
| 27 | + { | ||
| 28 | + rtx tem; | ||
| 29 | + tem = simplify_const_relational_operation (c, mode, op0, op1); | ||
| 30 | + if(rtx_equal_p(tem,const0_rtx)) | ||
| 31 | + target = op0; | ||
| 32 | + else if(rtx_equal_p(tem,const1_rtx)) | ||
| 33 | + target = op1; | ||
| 34 | + } | ||
| 35 | + } | ||
| 36 | gcc_assert (target); | ||
| 37 | if (target != dest) | ||
| 38 | emit_move_insn (dest, target); | ||
diff --git a/recipes-devtools/gcc/gcc-fsl.inc b/recipes-devtools/gcc/gcc-fsl.inc index 2e5be82..9e7c615 100644 --- a/recipes-devtools/gcc/gcc-fsl.inc +++ b/recipes-devtools/gcc/gcc-fsl.inc | |||
| @@ -38,8 +38,9 @@ SRC_URI_fsl = "svn://gcc.gnu.org/svn/gcc/branches;module=${BRANCH};proto=http \ | |||
| 38 | file://gcc.fix_header_issue.patch \ | 38 | file://gcc.fix_header_issue.patch \ |
| 39 | file://gcc.fix_SSIZE_MAX_undefine_issue.patch \ | 39 | file://gcc.fix_SSIZE_MAX_undefine_issue.patch \ |
| 40 | file://GPLUSPLUS_INCLUDE_DIR_with_sysroot_fsl.patch \ | 40 | file://GPLUSPLUS_INCLUDE_DIR_with_sysroot_fsl.patch \ |
| 41 | file://gcc.fix_min_max.patch \ | ||
| 41 | " | 42 | " |
| 42 | 43 | ||
| 43 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" | 44 | FILESEXTRAPATHS_prepend := "${THISDIR}/files:" |
| 44 | 45 | ||
| 45 | PR_fsl .= "+${DISTRO}.1" | 46 | PR_fsl .= "+${DISTRO}.2" |
