This is the mail archive of the gcc@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: [RFC] optabs and tree-codes for vector operations


On Wed, 2004-08-18 at 14:34, Devang Patel wrote:
> Expanding VEC_COND_EXPR tree nodes means
> 	- generate vector compare instruction	
> 	- generate vector select instruction that selects elements for first 
> vector operand or second vector operand and put them in resulting 
> vector.

See for instance the cbranch named pattern, and the
emit_cmp_and_jump_insn_1 function in optabs.c.  This emits a compare and
branch without exposing the compare result to the middle end.

Also, keep in mind, that the compare expanders don't actually return a
result.  They just set up operands for the following branch, conditional
move, etc expander.  We may not want to do things the same way for
vector compares, but it is an alternative.  A combined named pattern is
a better choice though.
-- 
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com



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