	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Save256Image                   ## -- Begin function Save256Image
	.p2align	4, 0x90
_Save256Image:                          ## @Save256Image
	.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
	subq	$152, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, -180(%rbp)                ## 4-byte Spill
	movl	%ecx, %r13d
	movq	%rdx, %r12
	movq	%rsi, %r15
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	leaq	-176(%rbp), %r14
	movq	%r14, %rsi
	callq	_ExtractFileExtension
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	callq	_Q_stricmp
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movq	%r15, %r14
	movl	-180(%rbp), %r15d               ## 4-byte Reload
	leaq	L_.str.1(%rip), %rsi
	leaq	-176(%rbp), %rdi
	callq	_Q_stricmp
	testl	%eax, %eax
	je	LBB0_3
## %bb.4:
	leaq	L_.str.2(%rip), %rdi
	movq	%rbx, %rsi
	callq	_Error
	jmp	LBB0_5
LBB0_1:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movl	%r13d, %edx
	movl	-180(%rbp), %ecx                ## 4-byte Reload
	movq	%r12, %r8
	callq	_WriteLBMfile
	jmp	LBB0_5
LBB0_3:
	movq	%rbx, %rdi
	movq	%r14, %rsi
	movl	%r13d, %edx
	movl	%r15d, %ecx
	movq	%r12, %r8
	callq	_WritePCXfile
LBB0_5:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_7
## %bb.6:
	addq	$152, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"lbm"

L_.str.1:                               ## @.str.1
	.asciz	"pcx"

L_.str.2:                               ## @.str.2
	.asciz	"%s doesn't have a known image extension"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Save256Image                   ; -- Begin function Save256Image
	.p2align	2
_Save256Image:                          ; @Save256Image
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #208
	.cfi_def_cfa_offset 208
	stp	x24, x23, [sp, #144]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #160]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #176]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #192]            ; 16-byte Folded Spill
	add	x29, sp, #192
	.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
	mov	x20, x4
	mov	x21, x3
	mov	x19, x2
	mov	x23, x1
	mov	x22, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	add	x1, sp, #8
	bl	_ExtractFileExtension
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	add	x0, sp, #8
	bl	_Q_stricmp
	cbz	w0, LBB0_3
; %bb.1:
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x0, sp, #8
	bl	_Q_stricmp
	cbz	w0, LBB0_4
; %bb.2:
Lloh7:
	adrp	x0, l_.str.2@PAGE
Lloh8:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x22
	bl	_Error
	b	LBB0_5
LBB0_3:
	mov	x0, x22
	mov	x1, x23
	mov	x2, x21
	mov	x3, x20
	mov	x4, x19
	bl	_WriteLBMfile
	b	LBB0_5
LBB0_4:
	mov	x0, x22
	mov	x1, x23
	mov	x2, x21
	mov	x3, x20
	mov	x4, x19
	bl	_WritePCXfile
LBB0_5:
	ldur	x8, [x29, #-56]
Lloh9:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh10:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_7
; %bb.6:
	ldp	x29, x30, [sp, #192]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #176]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #160]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #144]            ; 16-byte Folded Reload
	add	sp, sp, #208
	ret
LBB0_7:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"lbm"

l_.str.1:                               ; @.str.1
	.asciz	"pcx"

l_.str.2:                               ; @.str.2
	.asciz	"%s doesn't have a known image extension"

.subsections_via_symbols
