Closed
Description
Since recently, codegen always passes constants of vector type as immediates in LLVM (#128537). This gives us a change to clean up this hack, where the idx
argument of simd_shuffle
is forced to be passed as an immediate. However, simd_shuffle for some reason actually takes an array as argument, not a vector, so the hack is still required to ensure that the array becomes an immediate (which then later stages of codegen convert into a vector, as that's what LLVM needs).
This is more painful than it should be because stdarch is a submodule 😢 , so we'll have to do it in stages:
- make simd_shuffle support both arrays and vectors: simd_shuffle intrinsic: allow argument to be passed as vector #128731
- switch stdarch to use vectors: simd_shuffle: pass the idx argument as a vector stdarch#1633
- update stdarch in rustc: update stdarch #129696
- remove the array hack: simd_shuffle: require index argument to be a vector #130268