Skip to content

Commit 32acf1e

Browse files
committed
[RISCV] Use XLenVT as LocVT for f16/f32/f164 with Zfinx in CC_RISCV_FastCC.
This is need to make sure we create FMV_X_W/FMV_X_H/bitcast nodes that match up with what return lowering will do.
1 parent 7f04a8a commit 32acf1e

File tree

2 files changed

+216
-238
lines changed

2 files changed

+216
-238
lines changed

llvm/lib/Target/RISCV/RISCVISelLowering.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19150,6 +19150,8 @@ bool RISCV::CC_RISCV_FastCC(const DataLayout &DL, RISCVABI::ABI ABI,
1915019150
(LocVT == MVT::f64 && Subtarget.is64Bit() &&
1915119151
Subtarget.hasStdExtZdinx())) {
1915219152
if (MCRegister Reg = State.AllocateReg(getFastCCArgGPRs(ABI))) {
19153+
LocInfo = CCValAssign::BCvt;
19154+
LocVT = Subtarget.getXLenVT();
1915319155
State.addLoc(CCValAssign::getReg(ValNo, ValVT, Reg, LocVT, LocInfo));
1915419156
return false;
1915519157
}

0 commit comments

Comments
 (0)