summaryrefslogtreecommitdiffstats
path: root/contrib/gcc/config
diff options
context:
space:
mode:
authorpfg <pfg@FreeBSD.org>2013-12-31 20:15:21 +0000
committerpfg <pfg@FreeBSD.org>2013-12-31 20:15:21 +0000
commitf881b459a3fe369b609e6a178021b210add26f5c (patch)
treeba6b6de6309eae50fbdda36926f761281e13ff15 /contrib/gcc/config
parent4adac037c326c987b31153809fdf6a8d96fc0d22 (diff)
downloadFreeBSD-src-f881b459a3fe369b609e6a178021b210add26f5c.zip
FreeBSD-src-f881b459a3fe369b609e6a178021b210add26f5c.tar.gz
MFC r259525, r259526, r259529
gcc: small merges from upstream fix ICE in rs6000 when using -fno-trapping-math. Solves GCC-PR target/30485 Solve GCC issues: PR middle-end/32602 PR middle-end/32603 Updates the to documentation and processing improvement. Obtained from: gcc 4.3 (rev. 120902, 120902, 119427, 126278, 126422; GPLv2)
Diffstat (limited to 'contrib/gcc/config')
-rw-r--r--contrib/gcc/config/rs6000/rs6000.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/contrib/gcc/config/rs6000/rs6000.c b/contrib/gcc/config/rs6000/rs6000.c
index 287902f..7878ed1 100644
--- a/contrib/gcc/config/rs6000/rs6000.c
+++ b/contrib/gcc/config/rs6000/rs6000.c
@@ -11738,11 +11738,20 @@ rs6000_emit_vector_compare (enum rtx_code rcode,
try_again = true;
break;
case NE:
- /* Treat A != B as ~(A==B). */
+ case UNLE:
+ case UNLT:
+ case UNGE:
+ case UNGT:
+ /* Invert condition and try again.
+ e.g., A != B becomes ~(A==B). */
{
+ enum rtx_code rev_code;
enum insn_code nor_code;
- rtx eq_rtx = rs6000_emit_vector_compare (EQ, op0, op1,
- dest_mode);
+ rtx eq_rtx;
+
+ rev_code = reverse_condition_maybe_unordered (rcode);
+ eq_rtx = rs6000_emit_vector_compare (rev_code, op0, op1,
+ dest_mode);
nor_code = one_cmpl_optab->handlers[(int)dest_mode].insn_code;
gcc_assert (nor_code != CODE_FOR_nothing);
OpenPOWER on IntegriCloud