In most cases, the dup(*ext) pattern can be rearranged to perform
the extension on the vector side, allowing for further vector-specific
optimisations to be made. However the initial checks for this conversion
were insufficient, allowing invalid encodings to be attempted (causing
compilation to fail).
Fixes the crash reported in D91271
Is it worth making sure Extend.getOperand(0) is the right size instead, with a DAG.getAnyExtOrTrunc?