#include <perms.h>

                                                                //      1  %systemroutinespec print(%real x, %integer n,m)
#line 1 "regression-bugs-tmp/printfl.imp"
extern void print( float X, int N, int M );
                                                                //      2  %systemroutine printfl(%real x, %integer n)
#line 2 "regression-bugs-tmp/printfl.imp"
extern void printfl( float X, int N )
#line 2 "regression-bugs-tmp/printfl.imp"
{
  __label__ _imp_endofblock;
                                                                //      3  %real y,round
_imp_current_line = 3; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 3 "regression-bugs-tmp/printfl.imp"
float Y;
#line 3 "regression-bugs-tmp/printfl.imp"
float ROUND;
                                                                //      4  %integer count=-99,sign=0
_imp_current_line = 4; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 4 "regression-bugs-tmp/printfl.imp"
int COUNT;
#line 4 "regression-bugs-tmp/printfl.imp"
COUNT = (-99);
#line 4 "regression-bugs-tmp/printfl.imp"
int SIGN;
#line 4 "regression-bugs-tmp/printfl.imp"
SIGN = 0;
                                                                //      5    %if x # 0 %start
_imp_current_line = 5; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 5 "regression-bugs-tmp/printfl.imp"
if (((X) == (0))) goto L_0002;
                                                                //      6      x = -x %and sign = 1 %if x < 0
_imp_current_line = 6; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 6 "regression-bugs-tmp/printfl.imp"
if (((X) >= (0))) goto L_0003;
#line 6 "regression-bugs-tmp/printfl.imp"
X = (-(X));
#line 6 "regression-bugs-tmp/printfl.imp"
SIGN = 1;
#line 6 "regression-bugs-tmp/printfl.imp"
L_0003:;
                                                                //      7     !Adjust X so that 1.0 <= rounded(X) < 10.0
                                                                //      8      count = 0;  round = 0.5\{^}n
_imp_current_line = 8; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 8 "regression-bugs-tmp/printfl.imp"
COUNT = 0;
_imp_current_line = 8; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 8 "regression-bugs-tmp/printfl.imp"
ROUND = _imp_REXP(0.5, N);
                                                                //      9      y = 1.0-round
_imp_current_line = 9; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 9 "regression-bugs-tmp/printfl.imp"
Y = ((1.0) - ((double)(ROUND)));
                                                                //     10      %if x < y %start;  !ie rounded(X) < 1.0
_imp_current_line = 10; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 10 "regression-bugs-tmp/printfl.imp"
if (((X) >= (Y))) goto L_0004;
                                                                //     11        count = count-1 %and x = x*10.0 %until x >= y
_imp_current_line = 11; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 11 "regression-bugs-tmp/printfl.imp"
L_0005:;
#line 11 "regression-bugs-tmp/printfl.imp"
COUNT = (((int)(COUNT)) - (1));
#line 11 "regression-bugs-tmp/printfl.imp"
X = (((double)(X)) * (10.0));
#line 11 "regression-bugs-tmp/printfl.imp"
if (((X) >= (Y))) goto L_0006;
#line 11 "regression-bugs-tmp/printfl.imp"
goto L_0005;
#line 11 "regression-bugs-tmp/printfl.imp"
L_0006:;
                                                                //     12      %finish %else %start
_imp_current_line = 12; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 12 "regression-bugs-tmp/printfl.imp"
goto L_0008;
#line 12 "regression-bugs-tmp/printfl.imp"
L_0004:;
                                                                //     13        y = 10.0-round
_imp_current_line = 13; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 13 "regression-bugs-tmp/printfl.imp"
Y = ((10.0) - ((double)(ROUND)));
                                                                //     14        %while x >= y %cycle;  !ie rounded(X) > 10.0
_imp_current_line = 14; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 14 "regression-bugs-tmp/printfl.imp"
L_0009:;
#line 14 "regression-bugs-tmp/printfl.imp"
if (((X) < (Y))) goto L_000a;
                                                                //     15          count = count+1;  x = x/10.0
_imp_current_line = 15; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 15 "regression-bugs-tmp/printfl.imp"
COUNT = (((int)(COUNT)) + (1));
_imp_current_line = 15; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 15 "regression-bugs-tmp/printfl.imp"
X = (double)((double)((float)(X)) / (double)((double)(10.0)));
                                                                //     16        %repeat
_imp_current_line = 16; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 16 "regression-bugs-tmp/printfl.imp"
goto L_0009;
#line 16 "regression-bugs-tmp/printfl.imp"
L_000a:;
                                                                //     17      %finish
_imp_current_line = 17; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 17 "regression-bugs-tmp/printfl.imp"
L_0008:;
                                                                //     18      x = -x %if sign # 0
_imp_current_line = 18; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 18 "regression-bugs-tmp/printfl.imp"
if (((SIGN) == (0))) goto L_000c;
#line 18 "regression-bugs-tmp/printfl.imp"
X = (-(X));
#line 18 "regression-bugs-tmp/printfl.imp"
L_000c:;
                                                                //     19    %finish
_imp_current_line = 19; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 19 "regression-bugs-tmp/printfl.imp"
L_0002:;
                                                                //     20    print(x,1,n)
_imp_current_line = 20; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 20 "regression-bugs-tmp/printfl.imp"
print(X, 1, N);
                                                                //     21    printsymbol('@')
_imp_current_line = 21; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 21 "regression-bugs-tmp/printfl.imp"
_imp_PRINTSYMBOL(64);
                                                                //     22    write(count,0)
_imp_current_line = 22; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 22 "regression-bugs-tmp/printfl.imp"
_imp_WRITE(COUNT, 0);
                                                                //     23  %end;  !printfl
_imp_current_line = 23; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 23 "regression-bugs-tmp/printfl.imp"
return;
_imp_endofblock: ;
} // End of block printfl at level 1
                                                                //     24  
                                                                //     25  %begin
#line 25 "regression-bugs-tmp/printfl.imp"
int main(int argc, char **argv) {
  __label__ _imp_endofblock;
  _imp_initialise(argc, argv);
                                                                //     26  %end
_imp_current_line = 26; _imp_current_file = "regression-bugs-tmp/printfl.imp";
#line 26 "regression-bugs-tmp/printfl.imp"
return 0;
_imp_endofblock: ;
} // End of block _imp_main at level 1
                                                                //     27  
                                                                //     28  %endoffile
#line 28 "regression-bugs-tmp/printfl.imp"
// End of file
