The logic in isWideningInstruction handles instructions like uaddw and smull, where add(x, zext(y)) or mul(sext(x), sext(y)) can be converted to single instructions, making the extends free. This doesn't apply the same to SVE instructions though.
https://godbolt.org/z/695d3nhGd
(There are instructions like SMULLT/B, but they require top/bottom lane interleaving. That is similar to MVE instructions, which required a special pass to perform the lane interleaving).
This patch just bails out of the call to isWideningInstruction if the vector is scalable, getting a more accurate cost.
It's probably better to use !useNeonVector(DstTy) for this, given that fixed-width SVE has the same issue.
You may want to add a similar test to llvm/test/Analysis/CostModel/AArch64/sve-fixed-length.ll for this as well.