* src/mcs51/peeph.def: renamed rule 400 to 500, moved rule 253.x to 400.x for better...
authorbernhardheld <bernhardheld@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Sat, 30 Dec 2006 22:32:47 +0000 (22:32 +0000)
committerbernhardheld <bernhardheld@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Sat, 30 Dec 2006 22:32:47 +0000 (22:32 +0000)
git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@4541 4a8a32a2-be11-0410-ad9d-d568d2c75423

ChangeLog
src/mcs51/peeph.def

index 37f1e1f016096fece2a416b3abe6f2d5c79ef38a..1247abc86b8f7e4cda340bac47d20fb75896dfb0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
+       * src/mcs51/peeph.def: renamed rule 400 to 500, moved rule 253.x to
+       400.x for better code in RFE 899102
+
 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
 
        * src/SDCCpeeph.c (deadMove),
index e0ea01950bc2b68fd0e8b3ddf6cbae2cc6453525..146a39f02d6189364d00fa0e545f81d0ff81c273 100644 (file)
@@ -3712,39 +3712,6 @@ replace {
        mov     r%3,a
 }
 
-// applies to: void test( char c ) { if( c ) func1(); else func2(); }
-replace {
-       lcall   %1
-       ret
-} by {
-       ;       Peephole 253.a  replaced lcall/ret with ljmp
-       ljmp    %1
-}
-
-// applies to: void test( char c ) { if( c ) func1(); else func2(); }
-replace {
-       lcall   %1
-%2:
-       ret
-} by {
-       ;       Peephole 253.b  replaced lcall/ret with ljmp
-       ljmp    %1
-       ;
-} if labelRefCount %2 0
-
-// applies to f.e. scott-bool1.c
-replace {
-       lcall   %1
-%2:
-       ret
-} by {
-       ;       Peephole 253.c  replaced lcall with ljmp
-       ljmp    %1
-%2:
-       ret
-}
-
-
 // applies to f.e. funptrs.c
 // saves one byte if %1 is a register or @register
 replace {
@@ -4605,9 +4572,42 @@ replace {
 } if notVolatile(%2), deadMove(%1)
 
 
+// applies to: void test( char c ) { if( c ) func1(); else func2(); }
+replace {
+       lcall   %1
+       ret
+} by {
+       ;       Peephole 400.a  replaced lcall/ret with ljmp
+       ljmp    %1
+}
+
+// applies to: void test( char c ) { if( c ) func1(); else func2(); }
+replace {
+       lcall   %1
+%2:
+       ret
+} by {
+       ;       Peephole 400.b  replaced lcall/ret with ljmp
+       ljmp    %1
+       ;
+} if labelRefCount %2 0
+
+// applies to f.e. scott-bool1.c
+replace {
+       lcall   %1
+%2:
+       ret
+} by {
+       ;       Peephole 400.c  replaced lcall with ljmp
+       ljmp    %1
+%2:
+       ret
+}
+
+
 // should be one of the last peepholes
 replace{
 %1:
 } by {
-       ;       Peephole 400    removed redundant label %1
+       ;       Peephole 500    removed redundant label %1
 } if labelRefCount(%1 0)