This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: i386 vector min/max improvements


On Wed, Jun 29, 2005 at 10:38:28AM -0700, Richard Henderson wrote:
> Implements stuff for V4SImode along the same lines as I came up with
> for V2SImode on ia64.  Also copies the same unsigned saturation tricks
> for vcond and umin.
> 
> One new trick for umax: the combination of us_minus and plus results
> in umax without further bit manipulation.  There are two cases:
> 
>   (1) op2 >= op1.  In this case we saturate to zero, resulting in
>       0 + op2, resulting in op2.
> 
>   (2) op2 < op1.  In this case no saturation happens, resulting in
>       (op1 - op2) + op2 == op1.

Clever - but the high level description makes me wonder if this sort of
thing should be happening somewhere outside of config/i386/?  I've been
watching the target-specific vector support get cleverer and cleverer
lately, and I'm not a big fan of clever targets.


-- 
Daniel Jacobowitz
CodeSourcery, LLC


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]