From 209c8048bbdd1c362a753b1f29422c442b56988f Mon Sep 17 00:00:00 2001 From: Richard Stallman Date: Sat, 27 Nov 1993 08:53:07 +0000 Subject: [PATCH] (cmpsi, cmphi, cmpqi): Handle SGS_CMP_ORDER when outputting cmpm insn. From-SVN: r6167 --- gcc/config/m68k/m68k.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/gcc/config/m68k/m68k.md b/gcc/config/m68k/m68k.md index 910c02eb8ab..8c5dcc4f5b8 100644 --- a/gcc/config/m68k/m68k.md +++ b/gcc/config/m68k/m68k.md @@ -387,7 +387,11 @@ "* { if (GET_CODE (operands[0]) == MEM && GET_CODE (operands[1]) == MEM) +#ifdef SGS_CMP_ORDER + return \"cmpm%.l %0,%1\"; +#else return \"cmpm%.l %1,%0\"; +#endif if (REG_P (operands[1]) || (!REG_P (operands[0]) && GET_CODE (operands[0]) != MEM)) { cc_status.flags |= CC_REVERSED; @@ -412,7 +416,11 @@ "* { if (GET_CODE (operands[0]) == MEM && GET_CODE (operands[1]) == MEM) +#ifdef SGS_CMP_ORDER + return \"cmpm%.w %0,%1\"; +#else return \"cmpm%.w %1,%0\"; +#endif if ((REG_P (operands[1]) && !ADDRESS_REG_P (operands[1])) || (!REG_P (operands[0]) && GET_CODE (operands[0]) != MEM)) { cc_status.flags |= CC_REVERSED; @@ -437,7 +445,11 @@ "* { if (GET_CODE (operands[0]) == MEM && GET_CODE (operands[1]) == MEM) +#ifdef SGS_CMP_ORDER + return \"cmpm%.b %0,%1\"; +#else return \"cmpm%.b %1,%0\"; +#endif if (REG_P (operands[1]) || (!REG_P (operands[0]) && GET_CODE (operands[0]) != MEM)) { cc_status.flags |= CC_REVERSED; -- 2.30.2