[llvm] [RISC-V][GISEL] Select G_BITCAST for scalable vectors (PR #101486)
Jiahan Xie via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 24 05:28:33 PDT 2024
================
@@ -785,6 +786,26 @@ void RISCVInstructionSelector::preISelLower(MachineInstr &MI,
replacePtrWithInt(MI.getOperand(1), MIB, MRI);
MI.setDesc(TII.get(TargetOpcode::G_AND));
MRI.setType(DstReg, sXLen);
+ break;
+ }
+ case TargetOpcode::G_LOAD: {
+ Register DstReg = MI.getOperand(0).getReg();
+ const LLT DstTy = MRI.getType(DstReg);
+ if (!(DstTy.isVector() && DstTy.getElementType().isPointer()))
----------------
jiahanxie353 wrote:
would `!DstTy.isPointerVector()` suffice since that also checks if `DestTy` is a `Vector` or not?
https://github.com/llvm/llvm-project/pull/101486
More information about the llvm-commits
mailing list