ARM Neon: Store n-th position(s) of non-zero byte(s) in a 8-byte vector lane
问题 I want to convert a Neon 64-bit vector lane to get the n-th position(s) of non-zero (aka. 0xFF) 8-bit value(s), and then fill the rest of the vector with zeros. Here are some examples: 0 1 2 3 4 5 6 7 d0: 00 FF 00 FF 00 00 00 FF d1: 1 3 7 0 0 0 0 0 d0: 00 FF FF FF 00 00 FF 00 d1: 1 2 3 6 0 0 0 0 d0: FF FF FF FF FF FF FF FF d1: 0 1 2 3 4 5 6 7 d0: FF 00 00 00 00 00 00 00 d1: 0 0 0 0 0 0 0 0 d0: 00 00 00 00 00 00 00 00 d1: 0 0 0 0 0 0 0 0 I have the feeling that it's probably one or two bit