         Edinburgh IMP77 Compiler - Version 8.4
    1         %begin
		.Ltext0:
				.section	.rodata
		.LC0:
				.string	"\n\nArguments:\n\n"
		.LC1:
				.string	"ARGC = %d\n"
		.LC2:
				.string	"ARGV @[%p]\n"
		.LC3:
				.string	"  ARGV(%d) = \"%s\"\n"
		.LC4:
				.string	"  ARGV(%d) = NULL\n"
		.LC5:
				.string	"\nLocal Variables:\n\n"
		.LC6:
				.string	"A"
		.LC7:
				.string	"%s = <UNASSIGNED INTEGER>\n"
		.LC8:
				.string	"%s = %lld\n"
		.LC9:
				.string	"B"
		.LC10:
				.string	"SUM"
		.LC11:
				.string	"DIFFERENCE"
		.LC12:
				.string	"MAX"
		.LC13:
				.string	"MIN"
		main_backtrace.6165:
		.LFB192:
				leal	4(%esp), %ecx
				andl	$-16, %esp
				pushl	-4(%ecx)
				pushl	%ebp
				movl	%esp, %ebp
				pushl	%ebx
				pushl	%ecx
				subl	$96, %esp
				call	__x86.get_pc_thunk.bx
				addl	$_GLOBAL_OFFSET_TABLE_, %ebx
				movl	%ecx, %eax
				movl	(%eax), %edx
				movl	4(%eax), %eax
				movl	%gs:20, %ecx
				movl	%ecx, -12(%ebp)
				xorl	%ecx, %ecx
				leal	8(%ebp), %ecx
				movl	%ecx, -16(%ebp)
				movl	%edx, -32(%ebp)
				movl	%eax, -36(%ebp)
				leal	-60(%ebp), %eax
				addl	$32, %eax
				leal	-60(%ebp), %edx
				movb	$-71, (%eax)
				movl	%edx, 1(%eax)
				movb	$-23, 5(%eax)
				leal	main_backtrace.6165@GOTOFF(%ebx), %ecx
				leal	10(%eax), %edx
				subl	%edx, %ecx
				movl	%ecx, %edx
				movl	%edx, 6(%eax)
		.L26:
				leal	.LC14@GOTOFF(%ebx), %eax
				movl	%eax, -92(%ebp)
				leal	-60(%ebp), %eax
				addl	$32, %eax
				movl	%eax, -88(%ebp)
				leal	.L26@GOTOFF(%ebx), %eax
				movl	%eax, -84(%ebp)
				movl	_imp_current_frame@GOT(%ebx), %eax
				movl	(%eax), %eax
				movl	%eax, -80(%ebp)
				movl	_imp_current_frame@GOT(%ebx), %eax
				leal	-92(%ebp), %edx
				movl	%edx, (%eax)
				movl	-32(%ebp), %eax
				movl	-36(%ebp), %edx
				subl	$8, %esp
				pushl	%edx
				pushl	%eax
				call	_imp_initialise@PLT
				addl	$16, %esp
    2
    3            %integer A, B, SUM, DIFFERENCE, MAX, MIN
				movl	$-16843010, %eax
				movl	%eax, -40(%ebp)
				movl	$-16843010, %eax
				movl	%eax, -44(%ebp)
				movl	$-16843010, %eax
				movl	%eax, -48(%ebp)
				movl	$-16843010, %eax
				movl	%eax, -52(%ebp)
				movl	$-16843010, %eax
				movl	%eax, -56(%ebp)
				movl	$-16843010, %eax
				movl	%eax, -60(%ebp)
    4
    5            MAX = -1; MIN = 5000
				movl	$-1, %eax
				movl	%eax, -56(%ebp)
				movl	$5000, %eax
				movl	%eax, -60(%ebp)
		.L27:
		.LBB20:
    6
    7            %cycle
    8               READ(A)
				movl	$0, -76(%ebp)
				movl	$0, -72(%ebp)
				movl	$0, -68(%ebp)
				movl	$0, -64(%ebp)
				leal	-60(%ebp), %eax
				addl	$20, %eax
				movl	%eax, -76(%ebp)
				movl	$4, -68(%ebp)
				movb	$1, -64(%ebp)
				pushl	-64(%ebp)
				pushl	-68(%ebp)
				pushl	-72(%ebp)
				pushl	-76(%ebp)
				call	_imp_readgeneric@PLT
				addl	$16, %esp
		.LBE20:
    9               %exit %if A=-1; ! End of input.
				movl	-40(%ebp), %eax
				cmpl	$-1, %eax
				je	.L41
				nop
		.L29:
		.LBB21:
				nop
		.L30:
		.LBB27:
		.LBB28:
				call	_imp_newline@PLT
		.LBE28:
		.LBE27:
   10               READ(B)
				movl	$0, -76(%ebp)
				movl	$0, -72(%ebp)
				movl	$0, -68(%ebp)
				movl	$0, -64(%ebp)
				leal	-60(%ebp), %eax
				addl	$16, %eax
				movl	%eax, -76(%ebp)
				movl	$4, -68(%ebp)
				movb	$1, -64(%ebp)
				pushl	-64(%ebp)
				pushl	-68(%ebp)
				pushl	-72(%ebp)
				pushl	-76(%ebp)
				call	_imp_readgeneric@PLT
				addl	$16, %esp
		.LBE21:
   11               PRINTSTRING("Input values:")
				subl	$8, %esp
				leal	.LC15@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC16@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_printf@PLT
				addl	$16, %esp
   12               WRITE(A,3); PRINTSYMBOL(',')
				movl	-40(%ebp), %eax
				subl	$8, %esp
				pushl	$3
				pushl	%eax
				call	_imp_writeint@PLT
				addl	$16, %esp
				movb	$44, -97(%ebp)
		.LBB22:
		.LBB23:
				movsbl	-97(%ebp), %eax
				subl	$12, %esp
				pushl	%eax
				call	_imp_printsymbol@PLT
				addl	$16, %esp
		.LBE23:
		.LBE22:
   13               WRITE(B,3)
				movl	-44(%ebp), %eax
				subl	$8, %esp
				pushl	$3
				pushl	%eax
				call	_imp_writeint@PLT
				addl	$16, %esp
   14               SUM = A+B; DIFFERENCE = A-B
				movl	-40(%ebp), %edx
				movl	-44(%ebp), %eax
				addl	%edx, %eax
				movl	%eax, -48(%ebp)
				movl	-40(%ebp), %edx
				movl	-44(%ebp), %eax
				subl	%eax, %edx
				movl	%edx, %eax
				movl	%eax, -52(%ebp)
   15               PRINTSTRING(" ... Sum is")
				subl	$8, %esp
				leal	.LC17@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC16@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_printf@PLT
				addl	$16, %esp
   16               WRITE(SUM,3)
				movl	-48(%ebp), %eax
				subl	$8, %esp
				pushl	$3
				pushl	%eax
				call	_imp_writeint@PLT
				addl	$16, %esp
   17               PRINTSTRING(",   Difference is")
				subl	$8, %esp
				leal	.LC18@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC16@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_printf@PLT
				addl	$16, %esp
   18               WRITE(DIFFERENCE,3); NEWLINE
				movl	-52(%ebp), %eax
				subl	$8, %esp
				pushl	$3
				pushl	%eax
				call	_imp_writeint@PLT
				addl	$16, %esp
		.LBB24:
		.LBB25:
				call	_imp_newline@PLT
		.LBE25:
		.LBE24:
   19               %if SUM>MAX %start
				movl	-48(%ebp), %edx
				movl	-56(%ebp), %eax
				cmpl	%eax, %edx
				jle	.L42
				nop
		.L32:
   20                  MAX = SUM
				movl	-48(%ebp), %eax
				movl	%eax, -56(%ebp)
   21               %finish %else %if SUM<MIN %start    { BUG! <--- a sum betweem initial min and max only assigns max, should assign min as well! }
				jmp	.L36
		.L42:
				movl	-48(%ebp), %edx
				movl	-60(%ebp), %eax
				cmpl	%eax, %edx
				jge	.L43
				nop
		.L36:
		.LBB26:
   22                  MIN = SUM
				movl	-48(%ebp), %eax
				movl	%eax, -60(%ebp)
				jmp	.L36
		.L33:
		.L35:
		.L43:
   23               %finish
   24               %monitor
				subl	$8, %esp
				leal	.LC14@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	__PRETTY_FUNCTION__.6190@GOTOFF(%ebx), %eax
				pushl	%eax
				call	strcmp@PLT
				addl	$16, %esp
				testl	%eax, %eax
				jne	.L37
				leal	.LC19@GOTOFF(%ebx), %eax
				jmp	.L38
		.L37:
				leal	__PRETTY_FUNCTION__.6190@GOTOFF(%ebx), %eax
		.L38:
				pushl	$24
				leal	.LC20@GOTOFF(%ebx), %edx
				pushl	%edx
				pushl	%eax
				leal	.LC21@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				leal	.L36@GOTOFF(%ebx), %eax
				subl	$12, %esp
				pushl	%eax
				call	_imp_monitor_internal@PLT
				addl	$16, %esp
		.LBE26:
   25            %repeat
				jmp	.L27
		.L41:
   26
   27            ! Now print out the maximum and minimum of the sums of all
   28            ! the pairs of numbers read in.
   29            NEWLINE
   30            PRINTSTRING("Maximum sum is")
				subl	$8, %esp
				leal	.LC22@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC16@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_printf@PLT
				addl	$16, %esp
   31            WRITE(MAX,3); NEWLINE
				movl	-56(%ebp), %eax
				subl	$8, %esp
				pushl	$3
				pushl	%eax
				call	_imp_writeint@PLT
				addl	$16, %esp
		.LBB29:
		.LBB30:
				call	_imp_newline@PLT
		.LBE30:
		.LBE29:
   32            PRINTSTRING("Minimum sum is")
				subl	$8, %esp
				leal	.LC23@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC16@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_printf@PLT
				addl	$16, %esp
   33            WRITE(MIN,3); NEWLINE
				movl	-60(%ebp), %eax
				subl	$8, %esp
				pushl	$3
				pushl	%eax
				call	_imp_writeint@PLT
				addl	$16, %esp
		.LBB31:
		.LBB32:
				call	_imp_newline@PLT
				movl	$0, -96(%ebp)
		.LBE32:
		.LBE31:
		.LBB33:
		.LBB34:
				subl	$12, %esp
				pushl	-96(%ebp)
				call	exit@PLT
		.LBE34:
		.LBE33:
		.LFE191:
				.section	.rodata
				.align 4
		__PRETTY_FUNCTION__.6190:
				.string	"main"
				.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:
		.LFB193:
				movl	(%esp), %ebx
				ret
		.LFE193:
		.Letext0:
   34
   35         %end %of %program
				pushl	%ebp
				movl	%esp, %ebp
				pushl	%esi
				pushl	%ebx
				subl	$32, %esp
				call	__x86.get_pc_thunk.bx
				addl	$_GLOBAL_OFFSET_TABLE_, %ebx
				movl	%ecx, %esi
				movl	%ecx, -28(%ebp)
				movl	%gs:20, %eax
				movl	%eax, -12(%ebp)
				xorl	%eax, %eax
				subl	$12, %esp
				leal	.LC0@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				movl	28(%esi), %eax
				subl	$8, %esp
				pushl	%eax
				leal	.LC1@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				movl	24(%esi), %eax
				subl	$8, %esp
				pushl	%eax
				leal	.LC2@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
		.LBB19:
				movl	$0, -16(%ebp)
				jmp	.L2
		.L3:
				movl	-16(%ebp), %eax
				leal	0(,%eax,4), %edx
				movl	24(%esi), %eax
				addl	%edx, %eax
				movl	(%eax), %eax
				subl	$4, %esp
				pushl	%eax
				pushl	-16(%ebp)
				leal	.LC3@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				addl	$1, -16(%ebp)
		.L2:
				movl	28(%esi), %eax
				cmpl	%eax, -16(%ebp)
				jl	.L3
		.LBE19:
				movl	28(%esi), %eax
				leal	0(,%eax,4), %edx
				movl	24(%esi), %eax
				addl	%edx, %eax
				movl	(%eax), %eax
				testl	%eax, %eax
				jne	.L4
				movl	28(%esi), %eax
				subl	$8, %esp
				pushl	%eax
				leal	.LC4@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				jmp	.L5
		.L4:
				movl	28(%esi), %eax
				leal	0(,%eax,4), %edx
				movl	24(%esi), %eax
				addl	%edx, %eax
				movl	(%eax), %edx
				movl	28(%esi), %eax
				subl	$4, %esp
				pushl	%edx
				pushl	%eax
				leal	.LC3@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
		.L5:
				subl	$12, %esp
				leal	.LC5@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				leal	20(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-128, %al
				je	.L6
				leal	20(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-2, %al
				jne	.L7
		.L6:
				leal	20(%esi), %eax
				leal	1(%eax), %edx
				leal	20(%esi), %eax
				subl	$4, %esp
				pushl	$3
				pushl	%edx
				pushl	%eax
				call	memcmp@PLT
				addl	$16, %esp
				testl	%eax, %eax
				jne	.L7
				subl	$8, %esp
				leal	.LC6@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC7@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				jmp	.L8
		.L7:
				movl	20(%esi), %eax
				cltd
				pushl	%edx
				pushl	%eax
				leal	.LC6@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC8@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
		.L8:
				leal	16(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-128, %al
				je	.L9
				leal	16(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-2, %al
				jne	.L10
		.L9:
				leal	16(%esi), %eax
				leal	1(%eax), %edx
				leal	16(%esi), %eax
				subl	$4, %esp
				pushl	$3
				pushl	%edx
				pushl	%eax
				call	memcmp@PLT
				addl	$16, %esp
				testl	%eax, %eax
				jne	.L10
				subl	$8, %esp
				leal	.LC9@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC7@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				jmp	.L11
		.L10:
				movl	16(%esi), %eax
				cltd
				pushl	%edx
				pushl	%eax
				leal	.LC9@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC8@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
		.L11:
				leal	12(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-128, %al
				je	.L12
				leal	12(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-2, %al
				jne	.L13
		.L12:
				leal	12(%esi), %eax
				leal	1(%eax), %edx
				leal	12(%esi), %eax
				subl	$4, %esp
				pushl	$3
				pushl	%edx
				pushl	%eax
				call	memcmp@PLT
				addl	$16, %esp
				testl	%eax, %eax
				jne	.L13
				subl	$8, %esp
				leal	.LC10@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC7@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				jmp	.L14
		.L13:
				movl	12(%esi), %eax
				cltd
				pushl	%edx
				pushl	%eax
				leal	.LC10@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC8@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
		.L14:
				leal	8(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-128, %al
				je	.L15
				leal	8(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-2, %al
				jne	.L16
		.L15:
				leal	8(%esi), %eax
				leal	1(%eax), %edx
				leal	8(%esi), %eax
				subl	$4, %esp
				pushl	$3
				pushl	%edx
				pushl	%eax
				call	memcmp@PLT
				addl	$16, %esp
				testl	%eax, %eax
				jne	.L16
				subl	$8, %esp
				leal	.LC11@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC7@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				jmp	.L17
		.L16:
				movl	8(%esi), %eax
				cltd
				pushl	%edx
				pushl	%eax
				leal	.LC11@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC8@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
		.L17:
				leal	4(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-128, %al
				je	.L18
				leal	4(%esi), %eax
				movzbl	(%eax), %eax
				cmpb	$-2, %al
				jne	.L19
		.L18:
				leal	4(%esi), %eax
				leal	1(%eax), %edx
				leal	4(%esi), %eax
				subl	$4, %esp
				pushl	$3
				pushl	%edx
				pushl	%eax
				call	memcmp@PLT
				addl	$16, %esp
				testl	%eax, %eax
				jne	.L19
				subl	$8, %esp
				leal	.LC12@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC7@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				jmp	.L20
		.L19:
				movl	4(%esi), %eax
				cltd
				pushl	%edx
				pushl	%eax
				leal	.LC12@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC8@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
		.L20:
				movl	%esi, %eax
				movzbl	(%eax), %eax
				cmpb	$-128, %al
				je	.L21
				movl	%esi, %eax
				movzbl	(%eax), %eax
				cmpb	$-2, %al
				jne	.L22
		.L21:
				movl	%esi, %eax
				addl	$1, %eax
				movl	%esi, %edx
				subl	$4, %esp
				pushl	$3
				pushl	%eax
				pushl	%edx
				call	memcmp@PLT
				addl	$16, %esp
				testl	%eax, %eax
				jne	.L22
				subl	$8, %esp
				leal	.LC13@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC7@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
				jmp	.L23
		.L22:
				movl	(%esi), %eax
				cltd
				pushl	%edx
				pushl	%eax
				leal	.LC13@GOTOFF(%ebx), %eax
				pushl	%eax
				leal	.LC8@GOTOFF(%ebx), %eax
				pushl	%eax
				call	_imp_diagf@PLT
				addl	$16, %esp
		.L23:
				nop
				movl	-12(%ebp), %eax
				xorl	%gs:20, %eax
				je	.L24
				call	__stack_chk_fail_local
		.L24:
				leal	-8(%ebp), %esp
				popl	%ebx
				popl	%esi
				popl	%ebp
				ret
		.LFE192:
				.section	.rodata
		.LC14:
				.string	"main"
		.LC15:
				.string	"Input values:"
		.LC16:
				.string	"%s"
		.LC17:
				.string	" ... Sum is"
		.LC18:
				.string	",   Difference is"
		.LC19:
				.string	"MAIN PROGRAM"
		.LC20:
				.string	"test-in/sum80.imp"
				.align 4
		.LC21:
				.string	"\n\n[E] MONITOR ENTERED FROM %s AT %s:%0d\n\n"
		.LC22:
				.string	"Maximum sum is"
		.LC23:
				.string	"Minimum sum is"
				.globl	main
		main:
		.LFB191:
   34 Statements compiled
