	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function iqs5xx_write_burst
_iqs5xx_write_burst:                    ## @iqs5xx_write_burst
	.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
	movl	%ecx, %ebx
	movq	%rdx, %r12
	movl	%esi, %r15d
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_IQS5XX_WR_BYTES_MAX@GOTPCREL(%rip), %rax
	movslq	(%rax), %r14
	leaq	16(,%r14,4), %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r13
	cmpl	%ebx, %r14d
	jge	LBB0_2
## %bb.1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_9
LBB0_2:
	movl	%r15d, %edi
	movq	%r13, %rsi
	callq	_put_unaligned_be16
	movq	%r13, %rdi
	addq	$16, %rdi
	movq	%r12, %rsi
	movl	%ebx, %edx
	callq	_memcpy
	movq	_IQS5XX_NUM_RETRIES@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jle	LBB0_3
## %bb.4:
	movl	%r15d, -52(%rbp)                ## 4-byte Spill
	addl	$4, %ebx
	xorl	%r12d, %r12d
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%r13, %rsi
	movl	%ebx, %edx
	callq	_i2c_master_send
	cmpl	%ebx, %eax
	je	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	%eax, %r14d
	movl	$200, %edi
	movl	$300, %esi                      ## imm = 0x12C
	callq	_usleep_range
	incl	%r15d
	movq	_IQS5XX_NUM_RETRIES@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r15d
	jl	LBB0_5
## %bb.7:
	movl	-52(%rbp), %r15d                ## 4-byte Reload
	jmp	LBB0_8
LBB0_3:
                                        ## implicit-def: $r14d
LBB0_8:
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	testl	%r14d, %r14d
	cmovsl	%r14d, %r12d
	leaq	L_.str(%rip), %rsi
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movl	%r15d, %edx
	movl	%r12d, %ecx
	callq	_dev_err
LBB0_9:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_11
## %bb.10:
	movl	%r12d, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_IQS5XX_WR_BYTES_MAX,4,2        ## @IQS5XX_WR_BYTES_MAX
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_IQS5XX_NUM_RETRIES,4,2         ## @IQS5XX_NUM_RETRIES
	.comm	_EIO,4,2                        ## @EIO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to write to address 0x%04X: %d\n"

	.no_dead_strip	_iqs5xx_write_burst
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function iqs5xx_write_burst
_iqs5xx_write_burst:                    ; @iqs5xx_write_burst
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	sub	sp, sp, #16
	mov	x22, x3
	mov	x23, x2
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
Lloh3:
	adrp	x8, _IQS5XX_WR_BYTES_MAX@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IQS5XX_WR_BYTES_MAX@GOTPAGEOFF]
Lloh5:
	ldrsw	x8, [x8]
	lsl	x12, x8, #2
	add	x9, x12, #16
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x10, x12, #31
	and	x10, x10, #0xfffffffffffffff0
	sub	x21, x9, x10
	mov	sp, x21
	cmp	w8, w3
	b.ge	LBB0_2
; %bb.1:
Lloh8:
	adrp	x8, _EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_9
LBB0_2:
	mov	x0, x19
	mov	x1, x21
	bl	_put_unaligned_be16
	add	x0, x21, #16
	mov	x1, x23
	mov	x2, x22
	bl	_memcpy
Lloh11:
	adrp	x24, _IQS5XX_NUM_RETRIES@GOTPAGE
Lloh12:
	ldr	x24, [x24, _IQS5XX_NUM_RETRIES@GOTPAGEOFF]
	ldr	w8, [x24]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.3:
	mov	w25, #0
	add	w22, w22, #4
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x21
	mov	x2, x22
	bl	_i2c_master_send
	cmp	w0, w22
	b.eq	LBB0_8
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x23, x0
	mov	w0, #200
	mov	w1, #300
	bl	_usleep_range
	add	w25, w25, #1
	ldr	w8, [x24]
	cmp	w25, w8
	b.lt	LBB0_4
	b	LBB0_7
LBB0_6:
                                        ; implicit-def: $w23
LBB0_7:
Lloh13:
	adrp	x8, _EIO@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	cmp	w23, #0
	csneg	w21, w23, w8, lt
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, x19
	mov	x3, x21
	bl	_dev_err
	b	LBB0_9
LBB0_8:
	mov	w21, #0
LBB0_9:
	ldur	x8, [x29, #-72]
Lloh18:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh19:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_11
; %bb.10:
	mov	x0, x21
	sub	sp, x29, #64
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_11:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_IQS5XX_WR_BYTES_MAX,4,2        ; @IQS5XX_WR_BYTES_MAX
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_IQS5XX_NUM_RETRIES,4,2         ; @IQS5XX_NUM_RETRIES
	.comm	_EIO,4,2                        ; @EIO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to write to address 0x%04X: %d\n"

	.no_dead_strip	_iqs5xx_write_burst
.subsections_via_symbols
