X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=src%2Favr%2Fgen.c;h=c24c40103d1c5a3971e2992fabf1db91ff493a10;hb=4c2406aa9b2d5b4e9b9b3f72d336a4c0e7eb7add;hp=fe2a666f9e7b1c4ec7722cf052b1200206f935f6;hpb=5283cac6f1c783136e8a2e7419b7b485c54bf069;p=fw%2Fsdcc diff --git a/src/avr/gen.c b/src/avr/gen.c index fe2a666f..c24c4010 100644 --- a/src/avr/gen.c +++ b/src/avr/gen.c @@ -231,6 +231,26 @@ isLiteralBit (unsigned long lit) return idx + 1; return 0; } + +/*-----------------------------------------------------------------*/ +/* outAcc - output Acc */ +/*-----------------------------------------------------------------*/ +static void +outAcc (operand * result) +{ + int size, offset; + size = getDataSize (result); + if (size) { + aopPut (AOP (result), "r0", 0); + size--; + offset = 1; + /* unsigned or positive */ + while (size--) { + aopPut (AOP (result), zero, offset++); + } + } +} + #endif // End Unused code section /*-----------------------------------------------------------------*/ @@ -1197,25 +1217,6 @@ getDataSize (operand * op) return size; } -/*-----------------------------------------------------------------*/ -/* outAcc - output Acc */ -/*-----------------------------------------------------------------*/ -static void -outAcc (operand * result) -{ - int size, offset; - size = getDataSize (result); - if (size) { - aopPut (AOP (result), "r0", 0); - size--; - offset = 1; - /* unsigned or positive */ - while (size--) { - aopPut (AOP (result), zero, offset++); - } - } -} - /*-----------------------------------------------------------------*/ /* toBoolean - emit code for orl a,operator(sizeop) */ /*-----------------------------------------------------------------*/