* device/lib/_gptrput.c,
[fw/sdcc] / src / ds390 / gen.c
index d32a3894a78fac776aeecab4cc8dd74280fe309f..bbc1f5d681d9d459328b5f281050a833af3dbdd3 100644 (file)
@@ -26,7 +26,7 @@
 -------------------------------------------------------------------------*/
 
 //#define D(x)
-#define D(x) x
+#define D(x) do if (options.verboseAsm) {x;} while(0)
 
 #include <stdio.h>
 #include <stdlib.h>
@@ -9867,7 +9867,7 @@ genrshFour (operand * result, operand * left,
       _startLazyDPSEvaluation();
       if (shCount == 1)
         {
-            shiftRLong (left, MSB16, result, sign);
+          shiftRLong (left, MSB16, result, sign);
         }
       else if (shCount == 0)
         {
@@ -10997,8 +10997,8 @@ genGenPointerGet (operand * left,
                 // with the implementation of __gptrgetWord
                 // in device/lib/_gptrget.c
                 emitcode ("lcall", "__gptrgetWord");
-                aopPut (result, DP2_RESULT_REG, offset++);
                 aopPut (result, "a", offset++);
+                aopPut (result, DP2_RESULT_REG, offset++);
                 size--;
             }
             else
@@ -14453,8 +14453,11 @@ gen390Code (iCode * lic)
 #endif
 
         default:
-          ic = ic;
-        }
+           /* This should never happen, right? */
+           fprintf(stderr, "*** Probable error: unsupported op 0x%x (%c) in %s @ %d\n", 
+                   ic->op, ic->op, __FILE__, __LINE__);
+           ic = ic;
+       }
     }