This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

AVR: optimize ashrqi3 by 7



2000-05-07  Marek Michalkiewicz  <marekm@linux.org.pl>

	* config/avr/avr.c (ashrqi3_out): Optimize shift by 7.

*** gcc/config/avr/avr.c.orig	Sat May  6 14:21:50 2000
--- gcc/config/avr/avr.c	Sun May  7 20:24:31 2000
*************** ashrqi3_out (insn,operands,len)
*** 2344,2349 ****
--- 2344,2353 ----
  		  AS1 (asr,%0) CR_TAB
  		  AS1 (asr,%0) CR_TAB
  		  AS1 (asr,%0));
+ 	case 7:
+ 	  *len=2;
+ 	  return (AS1 (lsl,%0) CR_TAB
+ 		  AS2 (sbc,%0,%0));
  	}
      }
    if (len)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]