Hi all, This patch series reimplements the MD patterns for the instructions that perform narrowing right shifts with optional rounding and saturation using standard RTL codes rather than unspecs. This includes the scalar forms and the *2 forms that write to the high half of the result vector. This allows us to get rid of a number of unspecs and should significantly improve the simplification capabilities around these instructions. I attempted to compress as many forms as possible with iterators and the end result looks reasonably orthogonal with a few small exceptions described in the individual patches.
The semantics are pretty well exercised by tests in advsimd-intrinsics.exp and in many of those tests the intrinsics involved are now entirely evaluated at compile-time and disappear from the output at optimisation levels. The validation against the reference numbers still passes (though I got many failures during development as I was getting little things wrong, so the tests are working as intended!). Bootstrapped and tested on aarch64-none-linux-gnu and aarch64_be-none-elf. Pushing to trunk. Thanks, Kyrill