	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ad_sd_read_reg_raw
_ad_sd_read_reg_raw:                    ## @ad_sd_read_reg_raw
	.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	%rbx
	subq	$88, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	(%rdi), %r15
	movq	%r15, -96(%rbp)
	movl	$1, -88(%rbp)
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -80(%rbp)
	movq	$0, -64(%rbp)
	movl	%edx, -56(%rbp)
	movq	%rcx, -48(%rbp)
	movq	16(%rdi), %rax
	movq	%rax, -40(%rbp)
	leaq	-104(%rbp), %rdi
	callq	_spi_message_init
	movq	24(%r14), %rax
	cmpq	$0, 8(%rax)
	je	LBB0_2
## %bb.1:
	movb	(%rax), %cl
	shll	%cl, %ebx
	movl	%ebx, (%r15)
	orl	4(%rax), %ebx
	movl	%ebx, (%r15)
	orl	8(%r14), %ebx
	movl	%ebx, (%r15)
	leaq	-96(%rbp), %rdi
	leaq	-104(%rbp), %rsi
	callq	_spi_message_add_tail
LBB0_2:
	leaq	-64(%rbp), %rdi
	leaq	-104(%rbp), %rsi
	callq	_spi_message_add_tail
	cmpq	$0, 16(%r14)
	movl	12(%r14), %edi
	leaq	-104(%rbp), %rsi
	je	LBB0_4
## %bb.3:
	callq	_spi_sync_locked
	jmp	LBB0_5
LBB0_4:
	callq	_spi_sync
LBB0_5:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-32(%rbp), %rcx
	jne	LBB0_7
## %bb.6:
	addq	$88, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_ad_sd_read_reg_raw
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ad_sd_read_reg_raw
_ad_sd_read_reg_raw:                    ; @ad_sd_read_reg_raw
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-40]
	ldr	x21, [x0]
	str	x21, [sp, #8]
	mov	w8, #1
	str	w8, [sp, #16]
	stp	xzr, xzr, [sp, #32]
	str	xzr, [sp, #24]
	str	w2, [sp, #48]
	ldr	x8, [x0, #16]
	stp	x3, x8, [sp, #56]
	mov	x0, sp
	bl	_spi_message_init
	ldr	x8, [x19, #24]
	ldr	x9, [x8, #8]
	cbz	x9, LBB0_2
; %bb.1:
	ldr	w9, [x8]
	lsl	w9, w20, w9
	str	w9, [x21]
	ldr	w8, [x8, #4]
	orr	w8, w8, w9
	str	w8, [x21]
	ldr	w9, [x19, #8]
	orr	w8, w9, w8
	str	w8, [x21]
	add	x0, sp, #8
	mov	x1, sp
	bl	_spi_message_add_tail
LBB0_2:
	add	x8, sp, #8
	add	x0, x8, #32
	mov	x1, sp
	bl	_spi_message_add_tail
	ldr	x8, [x19, #16]
	ldr	w0, [x19, #12]
	mov	x1, sp
	cbz	x8, LBB0_4
; %bb.3:
	bl	_spi_sync_locked
	b	LBB0_5
LBB0_4:
	bl	_spi_sync
LBB0_5:
	ldur	x8, [x29, #-40]
Lloh3:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh4:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_7
; %bb.6:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_7:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_ad_sd_read_reg_raw
.subsections_via_symbols
