         Edinburgh IMP77 Compiler - Version 8.4
    1 %BEGIN
		.Ltext0:
				.section	.rodata
				.align 32
		.LC0:
				.byte	7
				.string	"TEST OK"
				.zero	247
				.align 32
		.LC1:
				.byte	13
				.string	"WRONG ANSWERS"
				.zero	241
				.globl	main
		main:
		.LFB189:
				leal	4(%esp), %ecx
				andl	$-16, %esp
				pushl	-4(%ecx)
				pushl	%ebp
				movl	%esp, %ebp
				pushl	%edi
				pushl	%esi
				pushl	%ebx
				pushl	%ecx
				subl	$1144, %esp
				call	__x86.get_pc_thunk.bx
				addl	$_GLOBAL_OFFSET_TABLE_, %ebx
				movl	%ecx, %eax
				movl	4(%eax), %edx
				movl	%edx, -1148(%ebp)
				movl	%gs:20, %esi
				movl	%esi, -28(%ebp)
				xorl	%esi, %esi
				subl	$8, %esp
				pushl	-1148(%ebp)
				pushl	(%eax)
				call	_imp_initialise@PLT
				addl	$16, %esp
    2 !***********************************************************************
    3 !*    SHOULD RUN WITHOUT OPUT. LOOPS ON SOME COMPILERS DUE TO          *
    4 !*    MISSING LABELS GIVING JUMPS WITH ZERO OFFSET                     *
    5 !***********************************************************************
    6 %OWNBYTEINTEGERARRAY CH(0:16)='0','1','2','3','4','5','6','7','8',
				leal	-1120(%ebp), %edx
				movl	$0, %eax
				movl	$17, %ecx
				movl	%edx, %edi
				rep stosl
				leal	CH.6021@GOTOFF(%ebx), %eax
				movl	%eax, -1120(%ebp)
				movl	$1, -1116(%ebp)
    7       '9','A','B','C','D','E','F','G'
    8 %INTEGER I,K,L
    9 %CONSTINTEGER J=0
   10       I=4000; L=10
				movl	$4000, -1136(%ebp)
				movl	$10, -1128(%ebp)
   11       %IF I>4095 %AND J#0 %THEN I=I+1
				cmpl	$4095, -1136(%ebp)
				nop
		.L3:
   12       %IF I>4095 %AND J#0 %THEN I=I+1 %ELSE I=I-1
				cmpl	$4095, -1136(%ebp)
				nop
		.L5:
				subl	$1, -1136(%ebp)
		.L6:
   13       %IF I>4095 %AND J#0 %THEN %START; %FINISH
				cmpl	$4095, -1136(%ebp)
				nop
		.L8:
   14       %IF I>4095 %AND J#0 %THEN %START
				cmpl	$4095, -1136(%ebp)
				nop
		.L10:
   15          I=I+1
   16       %FINISH %ELSE I=I-1
				subl	$1, -1136(%ebp)
		.L11:
   17       %IF (I>4095 %AND J#0 ) %AND L=1 %THEN I=I+1
				cmpl	$4095, -1136(%ebp)
				nop
		.L13:
   18       %IF (I>4095 %AND J#0) %OR L=1 %THEN I=I+1
				cmpl	$4095, -1136(%ebp)
				nop
		.L15:
				cmpl	$1, -1128(%ebp)
				jne	.L51
				nop
		.L16:
				addl	$1, -1136(%ebp)
				jmp	.L17
		.L51:
				nop
		.L17:
   19       %UNLESS I>4095 %AND J#0 %THEN I=I+1
				cmpl	$4095, -1136(%ebp)
				nop
		.L19:
				addl	$1, -1136(%ebp)
		.L20:
   20       %UNLESS I>4095 %AND J#0 %THEN I=I+1 %ELSE I=I-1
				cmpl	$4095, -1136(%ebp)
				nop
		.L22:
				addl	$1, -1136(%ebp)
				nop
		.L23:
   21       %UNLESS I>4095 %AND J#0 %THEN %START; %FINISH
				cmpl	$4095, -1136(%ebp)
				nop
		.L25:
		.L26:
   22       %UNLESS I>4095 %AND J#0 %THEN %START
				cmpl	$4095, -1136(%ebp)
				nop
		.L28:
   23          I=I+1
				addl	$1, -1136(%ebp)
   24       %FINISH %ELSE I=I-1
				nop
		.L29:
   25       %UNLESS (I>4095 %AND J#0 ) %AND L=1 %THEN I=I+1
				cmpl	$4095, -1136(%ebp)
				nop
		.L31:
				addl	$1, -1136(%ebp)
		.L32:
   26       %UNLESS (I>4095 %AND J#0) %OR L=1 %THEN I=I+1
				cmpl	$4095, -1136(%ebp)
				nop
		.L34:
				cmpl	$1, -1128(%ebp)
				je	.L52
				addl	$1, -1136(%ebp)
				jmp	.L36
		.L52:
				nop
		.L36:
   27        %FOR K=0,1,16 %CYCLE
				movl	$-1, -1132(%ebp)
		.L37:
				cmpl	$16, -1132(%ebp)
				je	.L53
				addl	$1, -1132(%ebp)
		.LBB12:
				nop
		.L39:
   28          %UNLESS '0'<=CH(K)<='9' %OR 'A'<=CH(K)<='F' %THEN I=I+1
				leal	CH.6021@GOTOFF(%ebx), %edx
				movl	-1132(%ebp), %eax
				addl	%edx, %eax
				movzbl	(%eax), %eax
				movb	%al, -1138(%ebp)
				cmpb	$47, -1138(%ebp)
				jbe	.L54
				cmpb	$57, -1138(%ebp)
				jbe	.L55
		.LBE12:
				jmp	.L41
		.L54:
		.LBB13:
				nop
		.L41:
		.LBE13:
		.LBB14:
				leal	CH.6021@GOTOFF(%ebx), %edx
				movl	-1132(%ebp), %eax
				addl	%edx, %eax
				movzbl	(%eax), %eax
				movb	%al, -1137(%ebp)
				cmpb	$64, -1137(%ebp)
				jbe	.L56
				cmpb	$70, -1137(%ebp)
				jbe	.L57
		.LBE14:
				jmp	.L44
		.L56:
		.LBB15:
				nop
		.L44:
		.LBE15:
				addl	$1, -1136(%ebp)
				jmp	.L37
		.L55:
		.LBB16:
				nop
				jmp	.L37
		.L57:
		.LBE16:
		.LBB17:
				nop
		.L42:
		.LBE17:
   29       %REPEAT
				jmp	.L37
		.L53:
   30       %IF I=4004 %THEN PRINTSTRING("TEST OK") %ELSE %C
				cmpl	$4004, -1136(%ebp)
				jne	.L58
		.LBB18:
				leal	-284(%ebp), %eax
				leal	.LC0@GOTOFF(%ebx), %edx
				movl	$64, %ecx
				movl	%eax, %edi
				movl	%edx, %esi
				rep movsl
				leal	-1052(%ebp), %eax
				leal	-284(%ebp), %edx
				movl	$64, %ecx
				movl	%eax, %edi
				movl	%edx, %esi
				rep movsl
				leal	-540(%ebp), %eax
				leal	-1052(%ebp), %edx
				movl	$64, %ecx
				movl	%eax, %edi
				movl	%edx, %esi
				rep movsl
		.LBE18:
		.LBB19:
		.LBB20:
				subl	$256, %esp
				movl	%esp, %eax
				movl	%eax, %edi
				leal	-540(%ebp), %eax
				movl	$64, %edx
				movl	%eax, %esi
				movl	%edx, %ecx
				rep movsl
				call	_imp_printstring@PLT
				addl	$256, %esp
		.LBE20:
		.LBE19:
				jmp	.L47
		.L58:
				nop
		.L46:
		.LBB21:
				leal	-284(%ebp), %eax
				leal	.LC1@GOTOFF(%ebx), %edx
				movl	$64, %ecx
				movl	%eax, %edi
				movl	%edx, %esi
				rep movsl
				leal	-796(%ebp), %eax
				leal	-284(%ebp), %edx
				movl	$64, %ecx
				movl	%eax, %edi
				movl	%edx, %esi
				rep movsl
				leal	-284(%ebp), %eax
				leal	-796(%ebp), %edx
				movl	$64, %ecx
				movl	%eax, %edi
				movl	%edx, %esi
				rep movsl
		.LBE21:
		.LBB22:
		.LBB23:
				subl	$256, %esp
				movl	%esp, %eax
				movl	%eax, %edi
				leal	-284(%ebp), %eax
				movl	$64, %edx
				movl	%eax, %esi
				movl	%edx, %ecx
				rep movsl
				call	_imp_printstring@PLT
				addl	$256, %esp
		.LBE23:
		.LBE22:
				subl	$8, %esp
				pushl	$5
				pushl	-1136(%ebp)
				call	_imp_writeint@PLT
				addl	$16, %esp
		.L47:
				movl	$0, -1124(%ebp)
		.LBB24:
		.LBB25:
				subl	$12, %esp
				pushl	-1124(%ebp)
				call	exit@PLT
		.LBE25:
		.LBE24:
		.LFE189:
				.data
				.align 4
		CH.6021:
				.byte	48
				.byte	49
				.byte	50
				.byte	51
				.byte	52
				.byte	53
				.byte	54
				.byte	55
				.byte	56
				.byte	57
				.byte	65
				.byte	66
				.byte	67
				.byte	68
				.byte	69
				.byte	70
				.byte	71
				.section	.text.__x86.get_pc_thunk.bx,"axG",@progbits,__x86.get_pc_thunk.bx,comdat
				.globl	__x86.get_pc_thunk.bx
				.hidden	__x86.get_pc_thunk.bx
		__x86.get_pc_thunk.bx:
		.LFB190:
				movl	(%esp), %ebx
				ret
		.LFE190:
		.Letext0:
   31          PRINTSTRING("WRONG ANSWERS") %AND WRITE(I,5)
   32 %ENDOFPROGRAM
   29 Statements compiled
