#include <perms.h>

                                                                //      1  %begin
#line 1 "regression-compile-tmp/unwinding.imp"
int main(int argc, char **argv) {
  _imp_initialise(argc, argv);
                                                                //      2  
                                                                //      3     %on %event 15 %start
#line 3 "regression-compile-tmp/unwinding.imp"
if (!_imp_on_event(15)) goto L_0002;  /* TO DO: Remove %on %event handler just before L_0002: if present for this block */
                                                                //      4       print string("END OF DIAGNOSTICS"); newline
#line 4 "regression-compile-tmp/unwinding.imp"
_imp_PRINTSTRING(_imp_str_literal("END OF DIAGNOSTICS"));
#line 4 "regression-compile-tmp/unwinding.imp"
_imp_NEWLINE();
                                                                //      5       %stop
#line 5 "regression-compile-tmp/unwinding.imp"
exit(0);
                                                                //      6     %finish
#line 6 "regression-compile-tmp/unwinding.imp"
L_0002:;
                                                                //      7     
                                                                //      8     %routine the procedure(%integer i)
#line 8 "regression-compile-tmp/unwinding.imp"
void THEPROCEDURE( int I )
#line 8 "regression-compile-tmp/unwinding.imp"
{
                                                                //      9       %integer local variable
#line 9 "regression-compile-tmp/unwinding.imp"
int LOCALVARIABLE;
                                                                //     10       local variable = i
#line 10 "regression-compile-tmp/unwinding.imp"
LOCALVARIABLE = I;
                                                                //     11  
                                                                //     12       %on %event 15 %start
#line 12 "regression-compile-tmp/unwinding.imp"
if (!_imp_on_event(15)) goto L_0003;  /* TO DO: Remove %on %event handler just before L_0003: if present for this block */
                                                                //     13         print string("Entered from THEPROCEDURE "); write(i, -1); newlines(2)
#line 13 "regression-compile-tmp/unwinding.imp"
_imp_PRINTSTRING(_imp_str_literal("Entered from THEPROCEDURE "));
#line 13 "regression-compile-tmp/unwinding.imp"
_imp_WRITE(I, (-1));
#line 13 "regression-compile-tmp/unwinding.imp"
_imp_NEWLINES(2);
                                                                //     14         print string("LOCALVARIABLE = "); write(local variable, 0); newline
#line 14 "regression-compile-tmp/unwinding.imp"
_imp_PRINTSTRING(_imp_str_literal("LOCALVARIABLE = "));
#line 14 "regression-compile-tmp/unwinding.imp"
_imp_WRITE(LOCALVARIABLE, 0);
#line 14 "regression-compile-tmp/unwinding.imp"
_imp_NEWLINE();
                                                                //     15         ! For comparative testing: Vax compiler needs event_extra not event_info
                                                                //     16         %signal 15, event_sub, event_info  { pass up one level to caller }
#line 16 "regression-compile-tmp/unwinding.imp"
_imp_signal(15, _imp_EVENT().SUB, _imp_EVENT().INFO, "");
                                                                //     17       %finish
#line 17 "regression-compile-tmp/unwinding.imp"
L_0003:;
                                                                //     18  
                                                                //     19       %signal 15, 1 %if i >= 10
#line 19 "regression-compile-tmp/unwinding.imp"
if (((I) < (10))) goto L_0004;
#line 19 "regression-compile-tmp/unwinding.imp"
_imp_signal(15, 1, 0, "");
#line 19 "regression-compile-tmp/unwinding.imp"
L_0004:;
                                                                //     20       the procedure(i+3)
#line 20 "regression-compile-tmp/unwinding.imp"
THEPROCEDURE((((int)(I)) + (3)));
                                                                //     21     %end
#line 21 "regression-compile-tmp/unwinding.imp"
/* Remove %on %event handler here if present for this block */
return;
} // End of block THEPROCEDURE at level 2
                                                                //     22  
                                                                //     23     the procedure(1)
#line 23 "regression-compile-tmp/unwinding.imp"
THEPROCEDURE(1);
                                                                //     24  
                                                                //     25  %endofprogram
#line 25 "regression-compile-tmp/unwinding.imp"
/* Remove %on %event handler here if present for this block */
return 0;
} // End of block _imp_main at level 1
#line 25 "regression-compile-tmp/unwinding.imp"
// End of file
