gcc-patches@gcc.gnu.org
[Top] [All Lists]

[autovect] [patch] Improve code generated for VEC_COND_EXPR

Subject: [autovect] [patch] Improve code generated for VEC_COND_EXPR
From: Victor Kaplansky
Date: Thu, 25 May 2006 17:43:33 +0300
Hi,
This patch is second try to improve code generated by
rs6000_emit_cond_expr()
See first one in http://gcc.gnu.org/ml/gcc-patches/2006-05/msg01121.html


We replace any of LT, LT and GE conditions by GT condition by
swapping between operands of compare and/or swapping between
operands of select. Also, we replace NE by EQ using same technique

Is OK for autovect-brach if bootstrap and regression passed?

-- Victor and Vladimir


2006-05-25  Victor Kaplansky   <victork@xxxxxxxxxx>
            Vladimir Yanovsky  <yanov@xxxxxxxxxx>

        * gcc/config/rs6000/rs6000.c (rs6000_emit_vector_compare): New
        return param swap_select_operands. Handle NE, LE, LEU rcodes by
        requesting to swap operands of select.
        (rs6000_emit_vector_cond_expr): call to rs6000_emit_vector_compare
with
        new param and swap operands of select if needed.

(see attached file autovect.reverse_vect_compare.patch.txt)

(See attached file: autovect.improve_cond_vect_expr.patch.txt)

Attachment: autovect.improve_cond_vect_expr.patch.txt
Description: Text document

<Prev in Thread] Current Thread [Next in Thread>