Re: [PATCH] bswap: Fix up recent vector CONSTRUCTOR optimization [PR98568]

2021-01-07 Thread Richard Biener
On Thu, 7 Jan 2021, Jakub Jelinek wrote: > Hi! > > As the testcase shows, bswap can match even byte-swapping or indentity > from low part of some wider SSA_NAME. > For bswap replacement other than for vector CONSTRUCTOR the code has been > using NOP_EXPR casts if the types weren't compatible, but

[PATCH] bswap: Fix up recent vector CONSTRUCTOR optimization [PR98568]

2021-01-07 Thread Jakub Jelinek via Gcc-patches
Hi! As the testcase shows, bswap can match even byte-swapping or indentity from low part of some wider SSA_NAME. For bswap replacement other than for vector CONSTRUCTOR the code has been using NOP_EXPR casts if the types weren't compatible, but for vectors we need to use VIEW_CONVERT_EXPR. The pr