From: Richard Kenner Date: Tue, 12 Nov 1996 19:26:11 +0000 (-0500) Subject: (addsi3): If TARGET_5200, use the lea insn to add small constants to X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=71e1e2c8431247a4f7c0961da1fff7e65d0ee14f;p=gcc.git (addsi3): If TARGET_5200, use the lea insn to add small constants to address registers. From-SVN: r13137 --- diff --git a/gcc/config/m68k/m68k.md b/gcc/config/m68k/m68k.md index b9b3bff39ba..cb791f65843 100644 --- a/gcc/config/m68k/m68k.md +++ b/gcc/config/m68k/m68k.md @@ -2173,9 +2173,17 @@ #endif if (ADDRESS_REG_P (operands[0]) && INTVAL (operands[2]) >= -0x8000 - && INTVAL (operands[2]) < 0x8000 - && !TARGET_5200) - return \"add%.w %2,%0\"; + && INTVAL (operands[2]) < 0x8000) + { + if (!TARGET_5200) + return \"add%.w %2,%0\"; + else +#ifdef MOTOROLA + return \"lea (%c2,%0),%0\"; +#else + return \"lea %0@(%c2),%0\"; +#endif + } } return \"add%.l %2,%0\"; }")