	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_main                           ## -- Begin function main
	.p2align	4, 0x90
_main:                                  ## @main
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	movl	$65592, %eax                    ## imm = 0x10038
	callq	____chkstk_darwin
	subq	%rax, %rsp
	popq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movl	$-1, -65596(%rbp)
	movl	$-1, -65592(%rbp)
	cmpl	$2, %edi
	jl	LBB0_20
## %bb.1:
	movl	%edi, %r15d
	xorl	%eax, %eax
	movq	%rax, -65632(%rbp)              ## 8-byte Spill
	movl	$1, %r13d
	leaq	L_.str(%rip), %r14
	xorl	%eax, %eax
	movq	%rax, -65616(%rbp)              ## 8-byte Spill
	xorl	%eax, %eax
	movq	%rax, -65624(%rbp)              ## 8-byte Spill
	xorl	%eax, %eax
	movq	%rax, -65608(%rbp)              ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_2 Depth=1
	leal	1(%r12), %r13d
	movq	8(%rbx,%r12,8), %rax
	movq	%rax, -65608(%rbp)              ## 8-byte Spill
LBB0_14:                                ##   in Loop: Header=BB0_2 Depth=1
	incl	%r13d
	cmpl	%r15d, %r13d
	jge	LBB0_15
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movslq	%r13d, %r12
	movq	(%rbx,%r12,8), %rdi
	movq	%r14, %rsi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	(%rbx,%r12,8), %rdi
	leaq	L_.str.1(%rip), %rsi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	(%rbx,%r12,8), %rdi
	leaq	L_.str.2(%rip), %rsi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$-1, -65596(%rbp)
	je	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$-1, -65592(%rbp)
	je	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	$1, %eax
	movq	%rax, -65632(%rbp)              ## 8-byte Spill
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	leal	1(%r12), %r13d
	movq	8(%rbx,%r12,8), %rax
	movq	%rax, -65624(%rbp)              ## 8-byte Spill
	jmp	LBB0_14
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	leal	1(%r12), %r13d
	movq	8(%rbx,%r12,8), %rax
	movq	%rax, -65616(%rbp)              ## 8-byte Spill
	jmp	LBB0_14
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	(%rbx,%r12,8), %rdi
	leaq	L_.str.3(%rip), %rsi
	leaq	-65596(%rbp), %rdx
	jmp	LBB0_13
LBB0_12:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	(%rbx,%r12,8), %rdi
	leaq	L_.str.3(%rip), %rsi
	leaq	-65592(%rbp), %rdx
LBB0_13:                                ##   in Loop: Header=BB0_2 Depth=1
	callq	_sscanf
	jmp	LBB0_14
LBB0_15:
	movq	-65608(%rbp), %r14              ## 8-byte Reload
	testq	%r14, %r14
	je	LBB0_20
## %bb.16:
	movq	-65624(%rbp), %rax              ## 8-byte Reload
	orq	-65616(%rbp), %rax              ## 8-byte Folded Reload
	je	LBB0_20
## %bb.17:
	cmpl	$0, -65632(%rbp)                ## 4-byte Folded Reload
	jne	LBB0_20
## %bb.18:
	cmpl	$-1, -65596(%rbp)
	je	LBB0_20
## %bb.19:
	cmpl	$-1, -65592(%rbp)
	je	LBB0_20
## %bb.21:
	leaq	-65584(%rbp), %rdi
	xorl	%esi, %esi
	movl	$65536, %edx                    ## imm = 0x10000
	callq	_memset
	leaq	L_.str.5(%rip), %rsi
	movq	%r14, %rdi
	callq	_fopen
	testq	%rax, %rax
	je	LBB0_26
## %bb.22:
	movq	%rax, %r15
	leaq	-65585(%rbp), %rdi
	movl	$1, %esi
	movl	$1, %edx
	movq	%rax, %rcx
	callq	_fread
	cmpl	$1, %eax
	jne	LBB0_42
## %bb.23:
	movl	$131, %r13d
	leaq	LJTI0_0(%rip), %r14
                                        ## implicit-def: $eax
                                        ## kill: killed $eax
	xorl	%ebx, %ebx
	xorl	%r12d, %r12d
	jmp	LBB0_24
LBB0_20:
	movq	(%rbx), %rsi
	leaq	L_.str.4(%rip), %rdi
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_printf
LBB0_61:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_63
## %bb.62:
	movl	%r15d, %eax
	addq	$65592, %rsp                    ## imm = 0x10038
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_38:                                ##   in Loop: Header=BB0_24 Depth=1
	movzbl	-65585(%rbp), %eax
	movl	-65608(%rbp), %edx              ## 4-byte Reload
	movslq	%edx, %rcx
	incl	%edx
	movl	%edx, -65608(%rbp)              ## 4-byte Spill
	movb	%al, -65584(%rbp,%rcx)
	cmpl	%ebx, %ecx
	movl	$128, %r13d
	movl	$134, %eax
	cmovll	%eax, %r13d
	.p2align	4, 0x90
LBB0_41:                                ##   in Loop: Header=BB0_24 Depth=1
	leaq	-65585(%rbp), %rdi
	movl	$1, %esi
	movl	$1, %edx
	movq	%r15, %rcx
	callq	_fread
	cmpl	$1, %eax
	jne	LBB0_42
LBB0_24:                                ## =>This Inner Loop Header: Depth=1
	addl	$-128, %r13d
	cmpl	$6, %r13d
	ja	LBB0_39
## %bb.25:                              ##   in Loop: Header=BB0_24 Depth=1
	movslq	(%r14,%r13,4), %rax
	addq	%r14, %rax
	jmpq	*%rax
LBB0_33:                                ##   in Loop: Header=BB0_24 Depth=1
	andl	$65280, %r12d                   ## imm = 0xFF00
	movzbl	-65585(%rbp), %eax
	orl	%eax, %r12d
	movl	$129, %r13d
	jmp	LBB0_41
LBB0_34:                                ##   in Loop: Header=BB0_24 Depth=1
	movzbl	%r12b, %eax
	movzbl	-65585(%rbp), %r12d
	shll	$8, %r12d
	orl	%eax, %r12d
	leaq	L_.str.8(%rip), %rdi
	movl	%r12d, %esi
	xorl	%eax, %eax
	callq	_printf
	movl	$132, %r13d
	cmpl	$65535, %r12d                   ## imm = 0xFFFF
	jne	LBB0_41
## %bb.35:                              ##   in Loop: Header=BB0_24 Depth=1
	leaq	L_str(%rip), %rdi
	callq	_puts
	movl	$128, %r13d
	movl	$65535, %r12d                   ## imm = 0xFFFF
	jmp	LBB0_41
LBB0_30:                                ##   in Loop: Header=BB0_24 Depth=1
	cmpb	$-1, -65585(%rbp)
	je	LBB0_31
## %bb.32:                              ##   in Loop: Header=BB0_24 Depth=1
	leaq	L_str.21(%rip), %rdi
	callq	_puts
	movl	$130, %r13d
	jmp	LBB0_41
LBB0_28:                                ##   in Loop: Header=BB0_24 Depth=1
	cmpb	$-1, -65585(%rbp)
	je	LBB0_29
## %bb.40:                              ##   in Loop: Header=BB0_24 Depth=1
	leaq	L_str.22(%rip), %rdi
	callq	_puts
	movl	$131, %r13d
	jmp	LBB0_41
LBB0_36:                                ##   in Loop: Header=BB0_24 Depth=1
	andl	$65280, %ebx                    ## imm = 0xFF00
	movzbl	-65585(%rbp), %eax
	orl	%eax, %ebx
	movl	$133, %r13d
	jmp	LBB0_41
LBB0_37:                                ##   in Loop: Header=BB0_24 Depth=1
	movzbl	%bl, %eax
	movzbl	-65585(%rbp), %ebx
	shll	$8, %ebx
	orl	%eax, %ebx
	leaq	L_.str.10(%rip), %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_printf
	movl	$134, %r13d
	movl	%r12d, -65608(%rbp)             ## 4-byte Spill
	jmp	LBB0_41
LBB0_31:                                ##   in Loop: Header=BB0_24 Depth=1
	movl	$128, %r13d
	jmp	LBB0_41
LBB0_29:                                ##   in Loop: Header=BB0_24 Depth=1
	movl	$130, %r13d
	jmp	LBB0_41
LBB0_42:
	movq	%r15, %rdi
	callq	_fclose
	movq	-65624(%rbp), %rbx              ## 8-byte Reload
	testq	%rbx, %rbx
	je	LBB0_46
## %bb.43:
	leaq	L_.str.12(%rip), %rsi
	movq	%rbx, %rdi
	callq	_fopen
	testq	%rax, %rax
	je	LBB0_44
## %bb.45:
	movq	%rax, %r14
	movslq	-65596(%rbp), %rax
	leaq	(%rax,%rbp), %rdi
	addq	$-65584, %rdi                   ## imm = 0xFFFEFFD0
	movl	-65592(%rbp), %edx
	subl	%eax, %edx
	incl	%edx
	movl	$1, %esi
	movq	%r14, %rcx
	callq	_fwrite
	movq	%r14, %rdi
	callq	_fclose
LBB0_46:
	movq	-65616(%rbp), %rbx              ## 8-byte Reload
	testq	%rbx, %rbx
	je	LBB0_47
## %bb.48:
	leaq	L_.str.12(%rip), %rsi
	movq	%rbx, %rdi
	callq	_fopen
	testq	%rax, %rax
	je	LBB0_44
## %bb.49:
	movq	%rax, %r13
	movb	(%rbx), %cl
	testb	%cl, %cl
	je	LBB0_55
## %bb.50:
	leaq	1(%rbx), %rax
	jmp	LBB0_51
	.p2align	4, 0x90
LBB0_54:                                ##   in Loop: Header=BB0_51 Depth=1
	movzbl	(%rax), %ecx
	incq	%rax
	testb	%cl, %cl
	je	LBB0_55
LBB0_51:                                ## =>This Inner Loop Header: Depth=1
	movl	%ecx, %edx
	andb	$-33, %dl
	addb	$-65, %dl
	cmpb	$26, %dl
	jb	LBB0_54
## %bb.52:                              ##   in Loop: Header=BB0_51 Depth=1
	addb	$-48, %cl
	cmpb	$10, %cl
	jb	LBB0_54
## %bb.53:                              ##   in Loop: Header=BB0_51 Depth=1
	movb	$95, -1(%rax)
	jmp	LBB0_54
LBB0_55:
	leaq	L_.str.13(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r13, %rdi
	movq	%rbx, %rdx
	xorl	%eax, %eax
	callq	_fprintf
	leaq	L_.str.14(%rip), %rsi
	movq	%r13, %rdi
	movq	%rbx, %rdx
	xorl	%eax, %eax
	callq	_fprintf
	leaq	L_.str.15(%rip), %rsi
	movq	%r13, %rdi
	movq	%rbx, %rdx
	xorl	%eax, %eax
	callq	_fprintf
	movslq	-65596(%rbp), %rbx
	movl	-65592(%rbp), %eax
	cmpl	%eax, %ebx
	jge	LBB0_60
## %bb.56:
	leaq	L_.str.16(%rip), %r14
	xorl	%r12d, %r12d
	jmp	LBB0_57
	.p2align	4, 0x90
LBB0_59:                                ##   in Loop: Header=BB0_57 Depth=1
	incq	%rbx
	movslq	-65592(%rbp), %rax
	cmpq	%rax, %rbx
	jge	LBB0_60
LBB0_57:                                ## =>This Inner Loop Header: Depth=1
	movzbl	-65584(%rbp,%rbx), %edx
	movq	%r13, %rdi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_fprintf
	incl	%r12d
	cmpl	$8, %r12d
	jne	LBB0_59
## %bb.58:                              ##   in Loop: Header=BB0_57 Depth=1
	movl	$2, %esi
	movl	$1, %edx
	leaq	L_.str.17(%rip), %rdi
	movq	%r13, %rcx
	callq	_fwrite
	xorl	%r12d, %r12d
	jmp	LBB0_59
LBB0_60:
	cltq
	movzbl	-65584(%rbp,%rax), %edx
	leaq	L_.str.18(%rip), %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_fprintf
	leaq	L_.str.19(%rip), %rdi
	movl	$3, %esi
	movl	$1, %edx
	movq	%r13, %rcx
	callq	_fwrite
	leaq	L_.str.20(%rip), %rdi
	movl	$8, %esi
	movl	$1, %edx
	movq	%r13, %rcx
	callq	_fwrite
	movq	%r13, %rdi
	callq	_fclose
	jmp	LBB0_61
LBB0_47:
	xorl	%r15d, %r15d
	jmp	LBB0_61
LBB0_44:
	movq	%rbx, %rdi
	jmp	LBB0_27
LBB0_39:
	leaq	L_str.23(%rip), %rdi
	callq	_puts
	movl	$1, %r15d
	jmp	LBB0_61
LBB0_26:
	movq	%r14, %rdi
LBB0_27:
	callq	_perror
	movl	$1, %r15d
	jmp	LBB0_61
LBB0_63:
	callq	___stack_chk_fail
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_33, LBB0_33-LJTI0_0
.set L0_0_set_34, LBB0_34-LJTI0_0
.set L0_0_set_30, LBB0_30-LJTI0_0
.set L0_0_set_28, LBB0_28-LJTI0_0
.set L0_0_set_36, LBB0_36-LJTI0_0
.set L0_0_set_37, LBB0_37-LJTI0_0
.set L0_0_set_38, LBB0_38-LJTI0_0
LJTI0_0:
	.long	L0_0_set_33
	.long	L0_0_set_34
	.long	L0_0_set_30
	.long	L0_0_set_28
	.long	L0_0_set_36
	.long	L0_0_set_37
	.long	L0_0_set_38
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"-input"

L_.str.1:                               ## @.str.1
	.asciz	"-image"

L_.str.2:                               ## @.str.2
	.asciz	"-header"

L_.str.3:                               ## @.str.3
	.asciz	"%x"

L_.str.4:                               ## @.str.4
	.asciz	"Usage: %s -input in_fname {-image image_fname|-header header_fname} hexaddr1 hexaddr2\n"

L_.str.5:                               ## @.str.5
	.asciz	"rb"

L_.str.8:                               ## @.str.8
	.asciz	"StartAddr = %x\n"

L_.str.10:                              ## @.str.10
	.asciz	"FinishAddr = %x\n"

L_.str.12:                              ## @.str.12
	.asciz	"wb"

L_.str.13:                              ## @.str.13
	.asciz	"#ifndef _%s_\n"

L_.str.14:                              ## @.str.14
	.asciz	"#define _%s_\n\n"

L_.str.15:                              ## @.str.15
	.asciz	"static unsigned char %s[] =\n{\n\t"

L_.str.16:                              ## @.str.16
	.asciz	"0x%02x,"

L_.str.17:                              ## @.str.17
	.asciz	"\n\t"

L_.str.18:                              ## @.str.18
	.asciz	"0x%02x\n"

L_.str.19:                              ## @.str.19
	.asciz	"};\n"

L_.str.20:                              ## @.str.20
	.asciz	"\n#endif\n"

L_str:                                  ## @str
	.asciz	"Oops thats a header"

L_str.21:                               ## @str.21
	.asciz	"Error: Expecting Header2"

L_str.22:                               ## @str.22
	.asciz	"Error: Expecting Header1"

L_str.23:                               ## @str.23
	.asciz	"Error: Invalid State"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_main                           ; -- Begin function main
	.p2align	2
_main:                                  ; @main
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	w9, #48
	movk	w9, #1, lsl #16
Lloh0:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh1:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	sub	sp, sp, #16, lsl #12            ; =65536
	sub	sp, sp, #48
	mov	x21, x1
Lloh2:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh3:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	stur	x8, [x29, #-96]
	mov	w8, #-1
	stp	w8, w8, [sp, #24]
	cmp	w0, #2
	b.lt	LBB0_24
; %bb.1:
	mov	x23, x0
	mov	w28, #0
	str	xzr, [sp, #8]                   ; 8-byte Folded Spill
	mov	x20, #0
	mov	x22, #0
	mov	w19, #1
Lloh5:
	adrp	x24, l_.str@PAGE
Lloh6:
	add	x24, x24, l_.str@PAGEOFF
Lloh7:
	adrp	x25, l_.str.1@PAGE
Lloh8:
	add	x25, x25, l_.str.1@PAGEOFF
Lloh9:
	adrp	x26, l_.str.2@PAGE
Lloh10:
	add	x26, x26, l_.str.2@PAGEOFF
	b	LBB0_5
LBB0_2:                                 ;   in Loop: Header=BB0_5 Depth=1
	add	x19, x27, #1
	ldr	x22, [x21, x19, lsl #3]
LBB0_3:                                 ;   in Loop: Header=BB0_5 Depth=1
                                        ; kill: def $w19 killed $w19 killed $x19 def $x19
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	add	w19, w19, #1
	cmp	w19, w23
	b.ge	LBB0_16
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	sxtw	x27, w19
	ldr	x0, [x21, w19, sxtw #3]
	mov	x1, x24
	bl	_strcmp
	cbz	x0, LBB0_2
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x0, [x21, x27, lsl #3]
	mov	x1, x25
	bl	_strcmp
	cbz	x0, LBB0_11
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x0, [x21, x27, lsl #3]
	mov	x1, x26
	bl	_strcmp
	cbz	x0, LBB0_12
; %bb.8:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [sp, #28]
	cmn	w8, #1
	b.eq	LBB0_13
; %bb.9:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [sp, #24]
	cmn	w8, #1
	b.eq	LBB0_14
; %bb.10:                               ;   in Loop: Header=BB0_5 Depth=1
	mov	w28, #1
	b	LBB0_4
LBB0_11:                                ;   in Loop: Header=BB0_5 Depth=1
	add	x19, x27, #1
	ldr	x20, [x21, x19, lsl #3]
	b	LBB0_3
LBB0_12:                                ;   in Loop: Header=BB0_5 Depth=1
	add	x19, x27, #1
	ldr	x8, [x21, x19, lsl #3]
	str	x8, [sp, #8]                    ; 8-byte Folded Spill
	b	LBB0_3
LBB0_13:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x0, [x21, x27, lsl #3]
	add	x2, sp, #28
	b	LBB0_15
LBB0_14:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x0, [x21, x27, lsl #3]
	add	x2, sp, #24
LBB0_15:                                ;   in Loop: Header=BB0_5 Depth=1
Lloh11:
	adrp	x1, l_.str.3@PAGE
Lloh12:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_sscanf
	b	LBB0_4
LBB0_16:
	cbz	x22, LBB0_24
; %bb.17:
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	orr	x8, x20, x8
	cbz	x8, LBB0_24
; %bb.18:
	cbnz	w28, LBB0_24
; %bb.19:
	ldr	w8, [sp, #28]
	cmn	w8, #1
	b.eq	LBB0_24
; %bb.20:
	ldr	w8, [sp, #24]
	cmn	w8, #1
	b.eq	LBB0_24
; %bb.21:
	add	x0, sp, #32
	mov	w1, #0
	mov	w2, #65536
	bl	_memset
Lloh13:
	adrp	x1, l_.str.5@PAGE
Lloh14:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x22
	bl	_fopen
	cbz	x0, LBB0_61
; %bb.22:
	mov	x21, x0
	add	x0, sp, #23
	mov	w1, #1
	mov	w2, #1
	mov	x3, x21
	bl	_fread
	cmp	w0, #1
	b.ne	LBB0_44
; %bb.23:
	mov	w27, #0
	mov	w23, #0
	mov	w19, #131
Lloh15:
	adrp	x28, lJTI0_0@PAGE
Lloh16:
	add	x28, x28, lJTI0_0@PAGEOFF
	mov	w22, #128
	mov	w24, #134
                                        ; implicit-def: $w25
Lloh17:
	adrp	x26, l_.str.10@PAGE
Lloh18:
	add	x26, x26, l_.str.10@PAGEOFF
	b	LBB0_30
LBB0_24:
	ldr	x8, [x21]
	str	x8, [sp]
Lloh19:
	adrp	x0, l_.str.4@PAGE
Lloh20:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_printf
LBB0_25:
	mov	w0, #0
LBB0_26:
	ldur	x8, [x29, #-96]
Lloh21:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh22:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh23:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_65
; %bb.27:
	add	sp, sp, #16, lsl #12            ; =65536
	add	sp, sp, #48
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_28:                                ;   in Loop: Header=BB0_30 Depth=1
	ldrb	w8, [sp, #23]
	add	x9, sp, #32
	strb	w8, [x9, w25, sxtw]
	add	w8, w25, #1
	cmp	w25, w27
	csel	w19, w24, w22, lt
	mov	x25, x8
LBB0_29:                                ;   in Loop: Header=BB0_30 Depth=1
	add	x0, sp, #23
	mov	w1, #1
	mov	w2, #1
	mov	x3, x21
	bl	_fread
	cmp	w0, #1
	b.ne	LBB0_44
LBB0_30:                                ; =>This Inner Loop Header: Depth=1
	sub	w8, w19, #128
	cmp	w8, #6
	b.hi	LBB0_60
; %bb.31:                               ;   in Loop: Header=BB0_30 Depth=1
	adr	x9, LBB0_28
	ldrb	w10, [x28, x8]
	add	x9, x9, x10, lsl #2
	br	x9
LBB0_32:                                ;   in Loop: Header=BB0_30 Depth=1
	and	w8, w23, #0xff00
	ldrb	w9, [sp, #23]
	orr	w23, w8, w9
	mov	w19, #129
	b	LBB0_29
LBB0_33:                                ;   in Loop: Header=BB0_30 Depth=1
	and	w23, w23, #0xff
	ldrb	w8, [sp, #23]
	bfi	w23, w8, #8, #8
	str	x23, [sp]
Lloh24:
	adrp	x0, l_.str.8@PAGE
Lloh25:
	add	x0, x0, l_.str.8@PAGEOFF
	bl	_printf
	mov	w8, #65535
	cmp	w23, w8
	b.ne	LBB0_41
; %bb.34:                               ;   in Loop: Header=BB0_30 Depth=1
Lloh26:
	adrp	x0, l_str@PAGE
Lloh27:
	add	x0, x0, l_str@PAGEOFF
	bl	_puts
	mov	w19, #128
	mov	w23, #65535
	b	LBB0_29
LBB0_35:                                ;   in Loop: Header=BB0_30 Depth=1
	ldrb	w8, [sp, #23]
	cmp	w8, #255
	b.eq	LBB0_42
; %bb.36:                               ;   in Loop: Header=BB0_30 Depth=1
Lloh28:
	adrp	x0, l_str.21@PAGE
Lloh29:
	add	x0, x0, l_str.21@PAGEOFF
	bl	_puts
	mov	w19, #130
	b	LBB0_29
LBB0_37:                                ;   in Loop: Header=BB0_30 Depth=1
	ldrb	w8, [sp, #23]
	cmp	w8, #255
	b.eq	LBB0_43
; %bb.38:                               ;   in Loop: Header=BB0_30 Depth=1
Lloh30:
	adrp	x0, l_str.22@PAGE
Lloh31:
	add	x0, x0, l_str.22@PAGEOFF
	bl	_puts
	mov	w19, #131
	b	LBB0_29
LBB0_39:                                ;   in Loop: Header=BB0_30 Depth=1
	and	w8, w27, #0xff00
	ldrb	w9, [sp, #23]
	orr	w27, w8, w9
	mov	w19, #133
	b	LBB0_29
LBB0_40:                                ;   in Loop: Header=BB0_30 Depth=1
	and	w27, w27, #0xff
	ldrb	w8, [sp, #23]
	bfi	w27, w8, #8, #8
	str	x27, [sp]
	mov	x0, x26
	bl	_printf
	mov	w19, #134
	mov	x25, x23
	b	LBB0_29
LBB0_41:                                ;   in Loop: Header=BB0_30 Depth=1
	mov	w19, #132
	b	LBB0_29
LBB0_42:                                ;   in Loop: Header=BB0_30 Depth=1
	mov	w19, #128
	b	LBB0_29
LBB0_43:                                ;   in Loop: Header=BB0_30 Depth=1
	mov	w19, #130
	b	LBB0_29
LBB0_44:
	mov	x0, x21
	bl	_fclose
	cbz	x20, LBB0_47
; %bb.45:
Lloh32:
	adrp	x1, l_.str.12@PAGE
Lloh33:
	add	x1, x1, l_.str.12@PAGEOFF
	mov	x0, x20
	bl	_fopen
	cbz	x0, LBB0_62
; %bb.46:
	mov	x21, x0
	ldrsw	x8, [sp, #28]
	add	x9, sp, #32
	add	x0, x9, x8
	ldr	w9, [sp, #24]
	sub	w8, w9, w8
	add	w2, w8, #1
	mov	w1, #1
	mov	x3, x21
	bl	_fwrite
	mov	x0, x21
	bl	_fclose
LBB0_47:
	ldr	x19, [sp, #8]                   ; 8-byte Folded Reload
	cbz	x19, LBB0_25
; %bb.48:
Lloh34:
	adrp	x1, l_.str.12@PAGE
Lloh35:
	add	x1, x1, l_.str.12@PAGEOFF
	mov	x0, x19
	bl	_fopen
	cbz	x0, LBB0_63
; %bb.49:
	mov	x20, x0
	ldrb	w11, [x19]
	cbz	w11, LBB0_54
; %bb.50:
	add	x8, x19, #1
	mov	w9, #223
	mov	w10, #95
	b	LBB0_52
LBB0_51:                                ;   in Loop: Header=BB0_52 Depth=1
	ldrb	w11, [x8], #1
	cbz	w11, LBB0_54
LBB0_52:                                ; =>This Inner Loop Header: Depth=1
	and	w12, w11, w9
	sub	w12, w12, #65
	sub	w11, w11, #48
	cmp	w12, #26
	ccmp	w11, #10, #0, hs
	b.lo	LBB0_51
; %bb.53:                               ;   in Loop: Header=BB0_52 Depth=1
	sturb	w10, [x8, #-1]
	b	LBB0_51
LBB0_54:
	str	x19, [sp]
Lloh36:
	adrp	x1, l_.str.13@PAGE
Lloh37:
	add	x1, x1, l_.str.13@PAGEOFF
	mov	x0, x20
	bl	_fprintf
	str	x19, [sp]
Lloh38:
	adrp	x1, l_.str.14@PAGE
Lloh39:
	add	x1, x1, l_.str.14@PAGEOFF
	mov	x0, x20
	bl	_fprintf
	str	x19, [sp]
Lloh40:
	adrp	x1, l_.str.15@PAGE
Lloh41:
	add	x1, x1, l_.str.15@PAGEOFF
	mov	x0, x20
	bl	_fprintf
	ldp	w8, w22, [sp, #24]
                                        ; kill: def $w22 killed $w22 def $x22
	sxtw	x22, w22
	cmp	w22, w8
	b.ge	LBB0_59
; %bb.55:
	mov	w24, #0
	add	x23, sp, #32
Lloh42:
	adrp	x19, l_.str.16@PAGE
Lloh43:
	add	x19, x19, l_.str.16@PAGEOFF
Lloh44:
	adrp	x21, l_.str.17@PAGE
Lloh45:
	add	x21, x21, l_.str.17@PAGEOFF
	b	LBB0_57
LBB0_56:                                ;   in Loop: Header=BB0_57 Depth=1
	add	x22, x22, #1
	ldrsw	x8, [sp, #24]
	cmp	x22, x8
	b.ge	LBB0_59
LBB0_57:                                ; =>This Inner Loop Header: Depth=1
	ldrb	w8, [x23, x22]
	str	x8, [sp]
	mov	x0, x20
	mov	x1, x19
	bl	_fprintf
	add	w24, w24, #1
	cmp	w24, #8
	b.ne	LBB0_56
; %bb.58:                               ;   in Loop: Header=BB0_57 Depth=1
	mov	x0, x21
	mov	w1, #2
	mov	w2, #1
	mov	x3, x20
	bl	_fwrite
	mov	w24, #0
	b	LBB0_56
LBB0_59:
	add	x9, sp, #32
	ldrb	w8, [x9, w8, sxtw]
	str	x8, [sp]
Lloh46:
	adrp	x1, l_.str.18@PAGE
Lloh47:
	add	x1, x1, l_.str.18@PAGEOFF
	mov	x0, x20
	bl	_fprintf
Lloh48:
	adrp	x0, l_.str.19@PAGE
Lloh49:
	add	x0, x0, l_.str.19@PAGEOFF
	mov	w1, #3
	mov	w2, #1
	mov	x3, x20
	bl	_fwrite
Lloh50:
	adrp	x0, l_.str.20@PAGE
Lloh51:
	add	x0, x0, l_.str.20@PAGEOFF
	mov	w1, #8
	mov	w2, #1
	mov	x3, x20
	bl	_fwrite
	mov	x0, x20
	bl	_fclose
	b	LBB0_25
LBB0_60:
Lloh52:
	adrp	x0, l_str.23@PAGE
Lloh53:
	add	x0, x0, l_str.23@PAGEOFF
	bl	_puts
	mov	w0, #1
	b	LBB0_26
LBB0_61:
	mov	x0, x22
	b	LBB0_64
LBB0_62:
	mov	x0, x20
	b	LBB0_64
LBB0_63:
	mov	x0, x19
LBB0_64:
	bl	_perror
	mov	w0, #1
	b	LBB0_26
LBB0_65:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpAdd	Lloh34, Lloh35
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpAdd	Lloh38, Lloh39
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpAdd	Lloh44, Lloh45
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpAdd	Lloh48, Lloh49
	.loh AdrpAdd	Lloh46, Lloh47
	.loh AdrpAdd	Lloh52, Lloh53
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_32-LBB0_28)>>2
	.byte	(LBB0_33-LBB0_28)>>2
	.byte	(LBB0_35-LBB0_28)>>2
	.byte	(LBB0_37-LBB0_28)>>2
	.byte	(LBB0_39-LBB0_28)>>2
	.byte	(LBB0_40-LBB0_28)>>2
	.byte	(LBB0_28-LBB0_28)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"-input"

l_.str.1:                               ; @.str.1
	.asciz	"-image"

l_.str.2:                               ; @.str.2
	.asciz	"-header"

l_.str.3:                               ; @.str.3
	.asciz	"%x"

l_.str.4:                               ; @.str.4
	.asciz	"Usage: %s -input in_fname {-image image_fname|-header header_fname} hexaddr1 hexaddr2\n"

l_.str.5:                               ; @.str.5
	.asciz	"rb"

l_.str.8:                               ; @.str.8
	.asciz	"StartAddr = %x\n"

l_.str.10:                              ; @.str.10
	.asciz	"FinishAddr = %x\n"

l_.str.12:                              ; @.str.12
	.asciz	"wb"

l_.str.13:                              ; @.str.13
	.asciz	"#ifndef _%s_\n"

l_.str.14:                              ; @.str.14
	.asciz	"#define _%s_\n\n"

l_.str.15:                              ; @.str.15
	.asciz	"static unsigned char %s[] =\n{\n\t"

l_.str.16:                              ; @.str.16
	.asciz	"0x%02x,"

l_.str.17:                              ; @.str.17
	.asciz	"\n\t"

l_.str.18:                              ; @.str.18
	.asciz	"0x%02x\n"

l_.str.19:                              ; @.str.19
	.asciz	"};\n"

l_.str.20:                              ; @.str.20
	.asciz	"\n#endif\n"

l_str:                                  ; @str
	.asciz	"Oops thats a header"

l_str.21:                               ; @str.21
	.asciz	"Error: Expecting Header2"

l_str.22:                               ; @str.22
	.asciz	"Error: Expecting Header1"

l_str.23:                               ; @str.23
	.asciz	"Error: Invalid State"

.subsections_via_symbols
