Figure out a better type during bitcast
of a scalar to a vector
#1140
Labels
cranelift
Issues related to the Cranelift code generator
bitcast
of a scalar to a vector
#1140
As noted in bytecodealliance/cranelift#1120 (comment), when moving a scalar value (
I32
orI64
) to a vector register in x86, the destination must be a aI64x2
due to typing restrictions that ensure vectors have more than one lane. This may be rather confusing when looking at CLIF IR because the intent of that move (using thebitcast
instruction) is to zero out the upper bits and only load the lower bits using the scalar value--it's more aI128x1
than anything else.There are several options here, some of which are:
I64x2
and remove the TODO commentI128x1
The text was updated successfully, but these errors were encountered: