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: ambiguous insn in altivec


On Tue, 8 Jan 2002, Aldy Hernandez wrote:

> dan
> 
> is there a reason for the second insn?  you added this.
Yes, if you look closely, you'll note one works on floats, one works on 
integers.
Since we have no conversions from v4sf to v4si, without the second insn, 
we couldn't do splats into vector floats.

> 
> aldy
> 
> (define_insn "altivec_vspltisw"
>   [(set (match_operand:V4SI 0 "register_operand" "=v")
>         (unspec:V4SI [(match_operand:QI 1 "immediate_operand" "i")] 141))]
>   "TARGET_ALTIVEC"
>   "vspltisw %0, %1"
>   [(set_attr "type" "vecsimple")])
> 
> (define_insn ""
>   [(set (match_operand:V4SF 0 "register_operand" "=v")
>         (unspec:V4SF [(match_operand:QI 1 "immediate_operand" "i")] 142))]
>   "TARGET_ALTIVEC"
>   "vspltisw %0, %1"
>   [(set_attr "type" "vecsimple")])
> 


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