From: johanknol Date: Sun, 3 Jun 2001 16:33:27 +0000 (+0000) Subject: comitted Bernhard's peephole 182a X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=6c1ca597378b3b0f7b5bcbf3d421528f5a1a7eb9;p=fw%2Fsdcc comitted Bernhard's peephole 182a git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@866 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- diff --git a/src/mcs51/peeph.def b/src/mcs51/peeph.def index fd7f2cf5..64bf597e 100644 --- a/src/mcs51/peeph.def +++ b/src/mcs51/peeph.def @@ -1036,6 +1036,16 @@ replace { mov dptr,#0x0000 } +// saving 3 bytes, 2 cycles +// provided by Bernhard Held +replace { + mov dpl,#%1 + mov dph,#(%1 >> 8) +} by { + ; Peephole 182a use 16 bit load of DPTR + mov dptr,#%1 +} + // saving 3 byte, 2 cycles, return(float_constant) profits here replace { mov dpl,#%1