	.file	"868890.c"
	.intel_syntax noprefix
	.text
	.data
	.align 32
	.type	Rcs_Id, @object
	.size	Rcs_Id, 53
Rcs_Id:
	.string	"$Id: fix8bit.c,v 1.3 1994/01/25 07:12:26 geoff Exp $"
	.section	.rodata
.LC0:
	.string	"-7"
.LC1:
	.string	"-8"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	DWORD PTR -4[rbp], edi
	mov	QWORD PTR -16[rbp], rsi
	cmp	DWORD PTR -4[rbp], 2
	je	.L2
	mov	eax, 0
	call	usage
.L2:
	mov	rax, QWORD PTR -16[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L3
	mov	eax, 0
	call	to7bit
	jmp	.L4
.L3:
	mov	rax, QWORD PTR -16[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L5
	mov	eax, 0
	call	to8bit
	jmp	.L4
.L5:
	mov	eax, 0
	call	usage
.L4:
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.section	.rodata
	.align 8
.LC2:
	.string	"Usage:  fix8bit {-7 | -8} < infile > outfile\n"
	.text
	.type	usage, @function
usage:
.LFB1:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 45
	mov	esi, 1
	lea	rdi, .LC2[rip]
	call	fwrite@PLT
	mov	edi, 1
	call	exit@PLT
	.cfi_endproc
.LFE1:
	.size	usage, .-usage
	.section	.rodata
.LC3:
	.string	"\\%3.3o"
	.text
	.type	to7bit, @function
to7bit:
.LFB2:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	jmp	.L9
.L11:
	and	DWORD PTR -4[rbp], 255
	cmp	DWORD PTR -4[rbp], 127
	jle	.L10
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L9
.L10:
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	putchar@PLT
.L9:
	call	getchar@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	jne	.L11
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	to7bit, .-to7bit
	.type	to8bit, @function
to8bit:
.LFB3:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	jmp	.L13
.L31:
	and	DWORD PTR -4[rbp], 255
	cmp	DWORD PTR -4[rbp], 92
	je	.L14
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	putchar@PLT
	jmp	.L13
.L14:
	call	getchar@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 120
	je	.L15
	cmp	DWORD PTR -4[rbp], 120
	jg	.L16
	cmp	DWORD PTR -4[rbp], 88
	je	.L15
	cmp	DWORD PTR -4[rbp], 88
	jg	.L16
	cmp	DWORD PTR -4[rbp], -1
	je	.L17
	cmp	DWORD PTR -4[rbp], -1
	jl	.L16
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, 48
	cmp	eax, 7
	ja	.L16
	jmp	.L32
.L17:
	mov	edi, 92
	call	putchar@PLT
	jmp	.L12
.L15:
	mov	eax, DWORD PTR -4[rbp]
	mov	DWORD PTR -8[rbp], eax
	call	getchar@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 47
	jle	.L20
	cmp	DWORD PTR -4[rbp], 57
	jg	.L20
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, 48
	mov	DWORD PTR -8[rbp], eax
	jmp	.L21
.L20:
	cmp	DWORD PTR -4[rbp], 96
	jle	.L22
	cmp	DWORD PTR -4[rbp], 102
	jg	.L22
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, 87
	mov	DWORD PTR -8[rbp], eax
	jmp	.L21
.L22:
	cmp	DWORD PTR -4[rbp], 64
	jle	.L23
	cmp	DWORD PTR -4[rbp], 70
	jg	.L23
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, 55
	mov	DWORD PTR -8[rbp], eax
	jmp	.L21
.L23:
	mov	edi, 92
	call	putchar@PLT
	mov	eax, DWORD PTR -8[rbp]
	mov	edi, eax
	call	putchar@PLT
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	putchar@PLT
	jmp	.L13
.L21:
	call	getchar@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 47
	jle	.L24
	cmp	DWORD PTR -4[rbp], 57
	jg	.L24
	mov	eax, DWORD PTR -8[rbp]
	sal	eax, 4
	mov	edx, eax
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, 48
	or	eax, edx
	mov	DWORD PTR -8[rbp], eax
	jmp	.L25
.L24:
	cmp	DWORD PTR -4[rbp], 96
	jle	.L26
	cmp	DWORD PTR -4[rbp], 102
	jg	.L26
	mov	eax, DWORD PTR -4[rbp]
	sal	eax, 4
	sub	eax, 87
	mov	DWORD PTR -8[rbp], eax
	jmp	.L25
.L26:
	cmp	DWORD PTR -4[rbp], 64
	jle	.L27
	cmp	DWORD PTR -4[rbp], 70
	jg	.L27
	mov	eax, DWORD PTR -4[rbp]
	sal	eax, 4
	sub	eax, 55
	mov	DWORD PTR -8[rbp], eax
	jmp	.L25
.L27:
	mov	eax, DWORD PTR -8[rbp]
	mov	edi, eax
	call	putchar@PLT
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	putchar@PLT
	jmp	.L13
.L25:
	mov	eax, DWORD PTR -8[rbp]
	mov	edi, eax
	call	putchar@PLT
	jmp	.L13
.L32:
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, 48
	mov	DWORD PTR -8[rbp], eax
	call	getchar@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 47
	jle	.L28
	cmp	DWORD PTR -4[rbp], 55
	jg	.L28
	mov	eax, DWORD PTR -8[rbp]
	lea	edx, 0[0+rax*8]
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, 48
	or	eax, edx
	mov	DWORD PTR -8[rbp], eax
	call	getchar@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 47
	jg	.L29
	jmp	.L30
.L28:
	mov	eax, DWORD PTR -8[rbp]
	mov	edi, eax
	call	putchar@PLT
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	putchar@PLT
	jmp	.L13
.L29:
	cmp	DWORD PTR -4[rbp], 55
	jg	.L30
	mov	eax, DWORD PTR -8[rbp]
	lea	edx, 0[0+rax*8]
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, 48
	or	eax, edx
	mov	DWORD PTR -8[rbp], eax
	mov	eax, DWORD PTR -8[rbp]
	mov	edi, eax
	call	putchar@PLT
	jmp	.L13
.L30:
	mov	eax, DWORD PTR -8[rbp]
	mov	edi, eax
	call	putchar@PLT
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	putchar@PLT
	jmp	.L13
.L16:
	mov	edi, 92
	call	putchar@PLT
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	putchar@PLT
	nop
.L13:
	call	getchar@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	jne	.L31
.L12:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.size	to8bit, .-to8bit
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"868890.c"
	.text
	.data
	.align	2
	.type	Rcs_Id, %object
	.size	Rcs_Id, 53
Rcs_Id:
	.ascii	"$Id: fix8bit.c,v 1.3 1994/01/25 07:12:26 geoff Exp "
	.ascii	"$\000"
	.section	.rodata
	.align	2
.LC0:
	.ascii	"-7\000"
	.align	2
.LC1:
	.ascii	"-8\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	ldr	r3, [fp, #-8]
	cmp	r3, #2
	beq	.L2
	bl	usage
.L2:
	ldr	r3, [fp, #-12]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldr	r1, .L7
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L3
	bl	to7bit
	b	.L4
.L3:
	ldr	r3, [fp, #-12]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldr	r1, .L7+4
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L5
	bl	to8bit
	b	.L4
.L5:
	bl	usage
.L4:
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L8:
	.align	2
.L7:
	.word	.LC0
	.word	.LC1
	.size	main, .-main
	.section	.rodata
	.align	2
.LC2:
	.ascii	"Usage:  fix8bit {-7 | -8} < infile > outfile\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	usage, %function
usage:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r3, .L10
	ldr	r3, [r3]
	mov	r2, #45
	mov	r1, #1
	ldr	r0, .L10+4
	bl	fwrite
	mov	r0, #1
	bl	exit
.L11:
	.align	2
.L10:
	.word	stderr
	.word	.LC2
	.size	usage, .-usage
	.section	.rodata
	.align	2
.LC3:
	.ascii	"\\%3.3o\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	to7bit, %function
to7bit:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	b	.L13
.L15:
	ldr	r3, [fp, #-8]
	and	r3, r3, #255
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #127
	ble	.L14
	ldr	r3, [fp, #-8]
	mov	r1, r3
	ldr	r0, .L16
	bl	printf
	b	.L13
.L14:
	ldr	r0, [fp, #-8]
	bl	putchar
.L13:
	bl	getchar
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	bne	.L15
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L17:
	.align	2
.L16:
	.word	.LC3
	.size	to7bit, .-to7bit
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	to8bit, %function
to8bit:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	b	.L19
.L37:
	ldr	r3, [fp, #-8]
	and	r3, r3, #255
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #92
	beq	.L20
	ldr	r0, [fp, #-8]
	bl	putchar
	b	.L19
.L20:
	bl	getchar
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #120
	beq	.L21
	ldr	r3, [fp, #-8]
	cmp	r3, #120
	bgt	.L22
	ldr	r3, [fp, #-8]
	cmp	r3, #88
	beq	.L21
	ldr	r3, [fp, #-8]
	cmp	r3, #88
	bgt	.L22
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	beq	.L23
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	blt	.L22
	ldr	r3, [fp, #-8]
	sub	r3, r3, #48
	cmp	r3, #7
	bhi	.L22
	b	.L38
.L23:
	mov	r0, #92
	bl	putchar
	b	.L18
.L21:
	ldr	r3, [fp, #-8]
	str	r3, [fp, #-12]
	bl	getchar
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #47
	ble	.L26
	ldr	r3, [fp, #-8]
	cmp	r3, #57
	bgt	.L26
	ldr	r3, [fp, #-8]
	sub	r3, r3, #48
	str	r3, [fp, #-12]
	b	.L27
.L26:
	ldr	r3, [fp, #-8]
	cmp	r3, #96
	ble	.L28
	ldr	r3, [fp, #-8]
	cmp	r3, #102
	bgt	.L28
	ldr	r3, [fp, #-8]
	sub	r3, r3, #87
	str	r3, [fp, #-12]
	b	.L27
.L28:
	ldr	r3, [fp, #-8]
	cmp	r3, #64
	ble	.L29
	ldr	r3, [fp, #-8]
	cmp	r3, #70
	bgt	.L29
	ldr	r3, [fp, #-8]
	sub	r3, r3, #55
	str	r3, [fp, #-12]
	b	.L27
.L29:
	mov	r0, #92
	bl	putchar
	ldr	r0, [fp, #-12]
	bl	putchar
	ldr	r0, [fp, #-8]
	bl	putchar
	b	.L19
.L27:
	bl	getchar
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #47
	ble	.L30
	ldr	r3, [fp, #-8]
	cmp	r3, #57
	bgt	.L30
	ldr	r3, [fp, #-12]
	lsl	r2, r3, #4
	ldr	r3, [fp, #-8]
	sub	r3, r3, #48
	orr	r3, r2, r3
	str	r3, [fp, #-12]
	b	.L31
.L30:
	ldr	r3, [fp, #-8]
	cmp	r3, #96
	ble	.L32
	ldr	r3, [fp, #-8]
	cmp	r3, #102
	bgt	.L32
	ldr	r3, [fp, #-8]
	lsl	r3, r3, #4
	sub	r3, r3, #87
	str	r3, [fp, #-12]
	b	.L31
.L32:
	ldr	r3, [fp, #-8]
	cmp	r3, #64
	ble	.L33
	ldr	r3, [fp, #-8]
	cmp	r3, #70
	bgt	.L33
	ldr	r3, [fp, #-8]
	lsl	r3, r3, #4
	sub	r3, r3, #55
	str	r3, [fp, #-12]
	b	.L31
.L33:
	ldr	r0, [fp, #-12]
	bl	putchar
	ldr	r0, [fp, #-8]
	bl	putchar
	b	.L19
.L31:
	ldr	r0, [fp, #-12]
	bl	putchar
	b	.L19
.L38:
	ldr	r3, [fp, #-8]
	sub	r3, r3, #48
	str	r3, [fp, #-12]
	bl	getchar
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #47
	ble	.L34
	ldr	r3, [fp, #-8]
	cmp	r3, #55
	bgt	.L34
	ldr	r3, [fp, #-12]
	lsl	r2, r3, #3
	ldr	r3, [fp, #-8]
	sub	r3, r3, #48
	orr	r3, r2, r3
	str	r3, [fp, #-12]
	bl	getchar
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #47
	bgt	.L35
	b	.L36
.L34:
	ldr	r0, [fp, #-12]
	bl	putchar
	ldr	r0, [fp, #-8]
	bl	putchar
	b	.L19
.L35:
	ldr	r3, [fp, #-8]
	cmp	r3, #55
	bgt	.L36
	ldr	r3, [fp, #-12]
	lsl	r2, r3, #3
	ldr	r3, [fp, #-8]
	sub	r3, r3, #48
	orr	r3, r2, r3
	str	r3, [fp, #-12]
	ldr	r0, [fp, #-12]
	bl	putchar
	b	.L19
.L36:
	ldr	r0, [fp, #-12]
	bl	putchar
	ldr	r0, [fp, #-8]
	bl	putchar
	b	.L19
.L22:
	mov	r0, #92
	bl	putchar
	ldr	r0, [fp, #-8]
	bl	putchar
	nop
.L19:
	bl	getchar
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	bne	.L37
.L18:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	to8bit, .-to8bit
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
