Hi! On Mon, Oct 24, 2022 at 11:14:20AM +0800, HAO CHEN GUI wrote: > This patch implements V8HI byte reverse on Power8 by vector rotation.
Please put *byte* reverse as the commit subject as well? > It should be effecient than orignial vector permute. The patch comes from > Xionghu's comments in PR. I just added a test case for it. Yeah, on all existing CPUs such a rotate is as fast or faster than a permute insn. And for bigger modes, we need more insns two dependent rotates for V4SI, and that is unlikely to be faster than a single permutation, certainly not if code can be unrolled. Okay for trunk. Thanks! Segher