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: Vector shuffling


On Mon, Aug 16, 2010 at 7:42 PM, Richard Henderson <rth@redhat.com> wrote:
> Only looking closely at the i386 changes for now.
>
> On 08/15/2010 07:30 AM, Artem Shinkarov wrote:
>> + ?/* Recursively grab the definition of the variable. ?*/
>> + ?while (TREE_CODE (mask) == SSA_NAME)
>> + ? ?{
>> + ? ? ?gimple maskdef = SSA_NAME_DEF_STMT (mask);
>> + ? ? ?if (gimple_assign_single_p (maskdef))
>> + ? ? ? ?mask = gimple_assign_rhs1 (maskdef);
>> + ? ? ?else
>> + ? ? ? ?break;
>> + ? ?}
>> +
>
> Err, surely copy-propagation has happened and this loop isn't needed.
> In particular, I'd hope that MASK is *already* VECTOR_CST if it is
> in fact constant.

I think it can happen when not optimizing.  The question is of course
whether we are fine with producing less optimal code in that case.

Richard.


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