From b85079b76ed8f485a8277a1e42940d6b7d93982e Mon Sep 17 00:00:00 2001 From: Richard Kenner Date: Sun, 19 Jan 1997 18:45:13 -0500 Subject: [PATCH] (ashrdi_const, ashrdi3): Allow 31 as shift count. From-SVN: r13528 --- gcc/config/m68k/m68k.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gcc/config/m68k/m68k.md b/gcc/config/m68k/m68k.md index 877f4423cab..1ad55fc8e3e 100644 --- a/gcc/config/m68k/m68k.md +++ b/gcc/config/m68k/m68k.md @@ -4443,7 +4443,8 @@ "!TARGET_5200 && ((INTVAL (operands[2]) == 1 || INTVAL (operands[2]) == 2 || INTVAL (operands[2]) == 3 || INTVAL (operands[2]) == 8 - || INTVAL (operands[2]) == 16 || INTVAL (operands[2]) == 63))" + || INTVAL (operands[2]) == 16 || INTVAL (operands[2]) == 31 + || INTVAL (operands[2]) == 63))" "* { operands[1] = gen_rtx (REG, SImode, REGNO (operands[0]) + 1); @@ -4456,6 +4457,8 @@ return \"move%.b %0,%1\;asr%.l %#8,%0\;ror%.l %#8,%1\"; else if (INTVAL (operands[2]) == 16) return \"move%.w %0,%1\;clr%.w %0\;swap %1\;ext%.l %0\"; + else if (INTVAL (operands[2]) == 31) + return \"add%.l %1,%1\;addx%.l %0,%0\;move%.l %0,%1\;subx%.l %0,%0\"; else if (INTVAL (operands[2]) == 2) return \"asr%.l %#1,%0\;roxr%.l %#1,%1\;asr%.l %#1,%0\;roxr%.l %#1,%1\"; else/* if (INTVAL (operands[2]) == 3)*/ @@ -4472,8 +4475,8 @@ if (GET_CODE (operands[2]) != CONST_INT || (INTVAL (operands[2]) != 1 && INTVAL (operands[2]) != 2 && INTVAL (operands[2]) != 3 && INTVAL (operands[2]) != 8 - && INTVAL (operands[2]) != 16 && INTVAL (operands[2]) != 32 - && INTVAL (operands[2]) != 63)) + && INTVAL (operands[2]) != 16 && INTVAL (operands[2]) != 31 + && INTVAL (operands[2]) != 32 && INTVAL (operands[2]) != 63)) FAIL; } ")