	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gdImageCreateFromWBMPCtx       ## -- Begin function gdImageCreateFromWBMPCtx
	.p2align	4, 0x90
_gdImageCreateFromWBMPCtx:              ## @gdImageCreateFromWBMPCtx
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rsi
	movq	_gd_getin@GOTPCREL(%rip), %rdi
	leaq	-48(%rbp), %rdx
	callq	_readwbmp
	testq	%rax, %rax
	je	LBB0_2
LBB0_14:
	xorl	%r14d, %r14d
	jmp	LBB0_15
LBB0_2:
	movq	-48(%rbp), %rax
	movl	(%rax), %edi
	movl	4(%rax), %esi
	callq	_gdImageCreate
	testq	%rax, %rax
	je	LBB0_13
## %bb.3:
	movq	%rax, %r14
	movq	%rax, %rdi
	movl	$255, %esi
	movl	$255, %edx
	movl	$255, %ecx
	callq	_gdImageColorAllocate
	movl	%eax, %r12d
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_gdImageColorAllocate
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movq	-48(%rbp), %rdi
	cmpl	$0, 4(%rdi)
	jle	LBB0_12
## %bb.4:
	xorl	%r13d, %r13d
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_7 Depth=1
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	addl	%ebx, %eax
	movq	%rax, %rbx
LBB0_6:                                 ##   in Loop: Header=BB0_7 Depth=1
	incl	%r13d
	cmpl	4(%rdi), %r13d
	jge	LBB0_12
LBB0_7:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_10 Depth 2
	cmpl	$0, (%rdi)
	jle	LBB0_6
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	movslq	%ebx, %r15
	shlq	$3, %r15
	xorl	%ebx, %ebx
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_10 Depth=2
	movq	%r14, %rdi
	movl	%ebx, %esi
	movl	%r13d, %edx
	callq	_gdImageSetPixel
	movq	-48(%rbp), %rdi
	incq	%rbx
	cmpl	(%rdi), %ebx
	jge	LBB0_5
LBB0_10:                                ##   Parent Loop BB0_7 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	8(%rdi), %rax
	addq	%r15, %rax
	movq	(%rax,%rbx,8), %rax
	movl	%r12d, %ecx
	movq	_WBMP_WHITE@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	je	LBB0_9
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=2
	movl	-52(%rbp), %ecx                 ## 4-byte Reload
	jmp	LBB0_9
LBB0_12:
	callq	_freewbmp
LBB0_15:
	movq	%r14, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	movq	-48(%rbp), %rdi
	callq	_freewbmp
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_gd_getin,4,2                   ## @gd_getin
	.comm	_WBMP_WHITE,8,3                 ## @WBMP_WHITE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gdImageCreateFromWBMPCtx       ; -- Begin function gdImageCreateFromWBMPCtx
	.p2align	2
_gdImageCreateFromWBMPCtx:              ; @gdImageCreateFromWBMPCtx
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.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
	mov	x1, x0
Lloh0:
	adrp	x0, _gd_getin@GOTPAGE
Lloh1:
	ldr	x0, [x0, _gd_getin@GOTPAGEOFF]
	add	x2, sp, #8
	bl	_readwbmp
	cbz	x0, LBB0_2
; %bb.1:
	mov	x19, #0
	b	LBB0_12
LBB0_2:
	ldr	x8, [sp, #8]
	ldp	w0, w1, [x8]
	bl	_gdImageCreate
	mov	x19, x0
	cbz	x0, LBB0_10
; %bb.3:
	mov	x0, x19
	mov	w1, #255
	mov	w2, #255
	mov	w3, #255
	bl	_gdImageColorAllocate
	mov	x20, x0
	mov	x0, x19
	mov	w1, #0
	mov	w2, #0
	mov	w3, #0
	bl	_gdImageColorAllocate
	mov	x21, x0
	ldr	x0, [sp, #8]
	ldr	w8, [x0, #4]
	cmp	w8, #1
	b.lt	LBB0_11
; %bb.4:
	mov	w24, #0
	mov	w22, #0
Lloh2:
	adrp	x25, _WBMP_WHITE@GOTPAGE
Lloh3:
	ldr	x25, [x25, _WBMP_WHITE@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	w22, w22, #1
	ldr	w8, [x0, #4]
	cmp	w22, w8
	b.ge	LBB0_11
LBB0_6:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_8 Depth 2
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x23, #0
	sbfiz	x26, x24, #3, #32
LBB0_8:                                 ;   Parent Loop BB0_6 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [x0, #8]
	add	x8, x8, x26
	ldr	x8, [x8, x23, lsl #3]
	ldr	x9, [x25]
	cmp	x8, x9
	csel	w3, w20, w21, eq
	mov	x0, x19
	mov	x1, x23
	mov	x2, x22
	bl	_gdImageSetPixel
	ldr	x0, [sp, #8]
	ldr	w8, [x0]
	add	x23, x23, #1
	cmp	w23, w8
	b.lt	LBB0_8
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	add	w24, w24, w23
	b	LBB0_5
LBB0_10:
	ldr	x0, [sp, #8]
LBB0_11:
	bl	_freewbmp
LBB0_12:
	mov	x0, x19
	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
	add	sp, sp, #96
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.comm	_gd_getin,4,2                   ; @gd_getin
	.comm	_WBMP_WHITE,8,3                 ; @WBMP_WHITE
.subsections_via_symbols
