Farzon Lotfi 5496267025
[SPIRV] Add Intermediate cast when Vector From/To types are of different element size and type (#182166)
fixes https://github.com/llvm/llvm-project/issues/177838

- Replaced assert(TargetTypeSize == SourceTypeSize) with a conditional:
when sizes differ, compute a BitcastType with the target's element type
but sized to match the source's total bitwidth
- Instead of unconditionally returning after bitcast, only return early
if BitcastType == TargetType (same-size case), otherwise fall through to
the shuffle logic
- Updated the final assert to use AssignValue->getType() since that may
now be the intermediate type rather than SourceType
2026-02-24 18:29:35 -05:00
..