The predecoder functions related to floating-point conditional move
instructions were not consistent with the use of these instructions
in the funcs.cc file.
Suggested work-around
Replace the occurrences of in->aux1 with in->aux2 in
the following four functions in predecode_instr.cc: fmovrcc, fmovrccs, fmovcc, and fmovccs. The corrected
code will look like:
int fmovrcc(instr *in, unsigned undec)
{
in->rs1=in->rd =Extract(undec,29,25);
in->rscc = Extract(undec,18,14);
in->rs2 = Extract(undec,4,0);
in->aux2 = Extract(undec,12,10);
in->rd_regtype =REG_FP;
in->rs2_regtype =REG_FP;
in->rs1_regtype =REG_FP;
return 1;
}
int fmovrccs(instr *in, unsigned undec)
{
in->rs1=in->rd =Extract(undec,29,25);
in->rscc = Extract(undec,18,14);
in->rs2 = Extract(undec,4,0);
in->aux2 = Extract(undec,12,10);
in->rd_regtype =REG_FPHALF;
in->rs2_regtype =REG_FPHALF;
in->rs1_regtype =REG_FPHALF;
return 1;
}
int fmovcc(instr *in, unsigned undec)
{
in->rs1=in->rd=Extract(undec,29,25);
in->rs2=Extract(undec,4,0);
in->aux2=Extract(undec,17,14);
/* here rscc represents the condition code used */
in->rscc=COND_REGISTERS+ Extract(undec,13,11);
in->rd_regtype =REG_FP;
in->rs2_regtype =REG_FP;
in->rs1_regtype =REG_FP;
return 1;
}
int fmovccs(instr *in, unsigned undec)
{
in->rs1=in->rd=Extract(undec,29,25);
in->rs2=Extract(undec,4,0);
in->aux2=Extract(undec,17,14);
/* here rscc represents the condition code used */
in->rscc=COND_REGISTERS+ Extract(undec,13,11);
in->rd_regtype =REG_FPHALF;
in->rs2_regtype =REG_FPHALF;
in->rs1_regtype =REG_FPHALF;
return 1;
}