[i386] scalar ops that preserve the high part of a vector

Marc Glisse marc.glisse@inria.fr
Fri Dec 7 15:12:00 GMT 2012


On Fri, 7 Dec 2012, Richard Henderson wrote:

> On 2012-12-07 09:00, Marc Glisse wrote:
>> On Fri, 7 Dec 2012, Richard Henderson wrote:
>>
>>> On 2012-12-07 02:49, Marc Glisse wrote:
>>>> For 2-element vectors, vec_concat does seem more natural than
>>>> vec_merge. If we chose vec_merge as the canonical representation, we
>>>> should chose it for setting an element in a vector
>>>> (ix86_expand_vector_set) everywhere, not just those scalarish
>>>> operations.
>>>
>>> I'd hate to enshrine vec_merge over vec_concat for the benefit of x86,
>>> and to the detriment of e.g. mips.  There are plenty of embedded simd
>>> implementations that are V2xx only.
>>>
>>> If we simply pull the various x86 patterns into one common form, set
>>> and extract included, does that buy us most of what we'd get for
>>> playing games in combine?
>>
>> I'm sorry, could you be more precise? I don't see clearly what you are suggesting.
>
> Don't change combine?

but change ix86_expand_vector_set and others to generate vec_merge and 
have only the vec_merge define_insn in sse.md? I guess it would buy a 
large part of it. That's a pretty invasive change, I'll have to try...

-- 
Marc Glisse



More information about the Gcc-patches mailing list