	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function put_siz
_put_siz:                               ## @put_siz
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	(%rdi), %eax
	subl	4(%rdi), %eax
	movl	8(%rdi), %ecx
	leal	(%rcx,%rcx,2), %ecx
	addl	$40, %ecx
	movl	$-1, %r15d
	cmpl	%ecx, %eax
	jl	LBB0_4
## %bb.1:
	movq	%rdi, %r14
	leaq	4(%rdi), %r12
	movq	_JPEG2000_SIZ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_bytestream_put_be16
	movl	8(%r14), %eax
	leal	(%rax,%rax,2), %esi
	addl	$38, %esi
	movq	%r12, %rdi
	callq	_bytestream_put_be16
	xorl	%r15d, %r15d
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_bytestream_put_be16
	movl	36(%r14), %esi
	movq	%r12, %rdi
	callq	_bytestream_put_be32
	movl	32(%r14), %esi
	movq	%r12, %rdi
	callq	_bytestream_put_be32
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_bytestream_put_be32
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_bytestream_put_be32
	movl	28(%r14), %esi
	movq	%r12, %rdi
	callq	_bytestream_put_be32
	movl	24(%r14), %esi
	movq	%r12, %rdi
	callq	_bytestream_put_be32
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_bytestream_put_be32
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_bytestream_put_be32
	movl	8(%r14), %esi
	movq	%r12, %rdi
	callq	_bytestream_put_be16
	cmpl	$0, 8(%r14)
	jle	LBB0_4
## %bb.2:
	movq	%r12, %rdi
	movl	$7, %esi
	callq	_bytestream_put_byte
	movl	$1, %ebx
	movq	%r12, %rdi
	movl	$1, %esi
	callq	_bytestream_put_byte
	movq	%r12, %rdi
	movl	$1, %esi
	callq	_bytestream_put_byte
	cmpl	$2, 8(%r14)
	jl	LBB0_4
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rdi
	movl	$7, %esi
	callq	_bytestream_put_byte
	movq	16(%r14), %rax
	movzbl	(%rax), %ecx
	movl	$1, %esi
	shll	%cl, %esi
	movq	%r12, %rdi
	callq	_bytestream_put_byte
	movq	16(%r14), %rax
	movzbl	4(%rax), %ecx
	movl	$1, %esi
	shll	%cl, %esi
	movq	%r12, %rdi
	callq	_bytestream_put_byte
	incl	%ebx
	cmpl	8(%r14), %ebx
	jl	LBB0_3
LBB0_4:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_JPEG2000_SIZ,4,2               ## @JPEG2000_SIZ
	.no_dead_strip	_put_siz
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function put_siz
_put_siz:                               ; @put_siz
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x20, x0
	ldr	w8, [x20, #4]!
	ldr	w9, [x0]
	ldr	w10, [x0, #8]
	add	w10, w10, w10, lsl #1
	add	w10, w10, #40
	sub	w8, w9, w8
	cmp	w8, w10
	b.ge	LBB0_2
; %bb.1:
	mov	w0, #-1
	b	LBB0_7
LBB0_2:
	mov	x19, x0
Lloh0:
	adrp	x8, _JPEG2000_SIZ@GOTPAGE
Lloh1:
	ldr	x8, [x8, _JPEG2000_SIZ@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_bytestream_put_be16
	ldr	w8, [x19, #8]
	add	w8, w8, w8, lsl #1
	add	w1, w8, #38
	mov	x0, x20
	bl	_bytestream_put_be16
	mov	x0, x20
	mov	w1, #0
	bl	_bytestream_put_be16
	ldr	w1, [x19, #36]
	mov	x0, x20
	bl	_bytestream_put_be32
	ldr	w1, [x19, #32]
	mov	x0, x20
	bl	_bytestream_put_be32
	mov	x0, x20
	mov	w1, #0
	bl	_bytestream_put_be32
	mov	x0, x20
	mov	w1, #0
	bl	_bytestream_put_be32
	ldr	w1, [x19, #28]
	mov	x0, x20
	bl	_bytestream_put_be32
	ldr	w1, [x19, #24]
	mov	x0, x20
	bl	_bytestream_put_be32
	mov	x0, x20
	mov	w1, #0
	bl	_bytestream_put_be32
	mov	x0, x20
	mov	w1, #0
	bl	_bytestream_put_be32
	ldr	w1, [x19, #8]
	mov	x0, x20
	bl	_bytestream_put_be16
	ldr	w8, [x19, #8]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.3:
	mov	x0, x20
	mov	w1, #7
	bl	_bytestream_put_byte
	mov	w21, #1
	mov	x0, x20
	mov	w1, #1
	bl	_bytestream_put_byte
	mov	x0, x20
	mov	w1, #1
	bl	_bytestream_put_byte
	ldr	w8, [x19, #8]
	cmp	w8, #2
	b.lt	LBB0_6
; %bb.4:
	mov	w22, #1
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	w1, #7
	bl	_bytestream_put_byte
	ldr	x8, [x19, #16]
	ldr	w8, [x8]
	lsl	w1, w21, w8
	mov	x0, x20
	bl	_bytestream_put_byte
	ldr	x8, [x19, #16]
	ldr	w8, [x8, #4]
	lsl	w1, w21, w8
	mov	x0, x20
	bl	_bytestream_put_byte
	add	w22, w22, #1
	ldr	w8, [x19, #8]
	cmp	w22, w8
	b.lt	LBB0_5
LBB0_6:
	mov	w0, #0
LBB0_7:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_JPEG2000_SIZ,4,2               ; @JPEG2000_SIZ
	.no_dead_strip	_put_siz
.subsections_via_symbols
