Skip to content

Commit 0c9be47

Browse files
shushanhfmichaelgsharp
authored andcommitted
[LoongArch64] don't clear float-regs when passed by integer-regs. (dotnet#101902)
1 parent 4ee40e1 commit 0c9be47

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/coreclr/jit/targetloongarch64.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,6 @@ ABIPassingInformation LoongArch64Classifier::Classify(Compiler* comp,
123123

124124
if (!canPassArgInRegisters)
125125
{
126-
m_floatRegs.Clear();
127126
slots = (passedSize + TARGET_POINTER_SIZE - 1) / TARGET_POINTER_SIZE;
128127
// On LoongArch64, if there aren't any remaining floating-point registers to pass the argument,
129128
// integer registers (if any) are used instead.
@@ -161,8 +160,7 @@ ABIPassingInformation LoongArch64Classifier::Classify(Compiler* comp,
161160
canPassArgInRegisters = m_floatRegs.Count() > 0;
162161
if (!canPassArgInRegisters)
163162
{
164-
type = TYP_I_IMPL;
165-
m_floatRegs.Clear();
163+
type = TYP_I_IMPL;
166164
canPassArgInRegisters = m_intRegs.Count() > 0;
167165
}
168166
}

0 commit comments

Comments
 (0)