	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ThermometerRead
_ThermometerRead:                       ## @ThermometerRead
	.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	$72, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	(%rdi), %rax
	movq	_TM@GOTPCREL(%rip), %r15
	movq	(%r15), %rsi
	orl	$16, (%rax,%rsi,4)
	callq	_UpdateReg
	testl	%eax, %eax
	js	LBB0_12
## %bb.1:
	leaq	-96(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_Read
	testl	%eax, %eax
	js	LBB0_12
## %bb.2:
	movq	(%r15), %rsi
	movl	-96(%rbp,%rsi,4), %eax
	movl	%eax, %ecx
	andl	$47, %ecx
	cmpl	$32, %ecx
	je	LBB0_4
## %bb.3:
	cmpl	$8, %ecx
	jne	LBB0_7
LBB0_4:
	movq	(%rbx), %rax
	xorl	$32, (%rax,%rsi,4)
	movq	%rbx, %rdi
	callq	_UpdateReg
	testl	%eax, %eax
	js	LBB0_12
## %bb.5:
	movl	$10, %edi
	callq	_msleep
	leaq	-96(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_Read
	testl	%eax, %eax
	js	LBB0_12
## %bb.6:
	movq	(%r15), %rsi
	movl	-96(%rbp,%rsi,4), %eax
LBB0_7:
	movl	%eax, %ecx
	andl	$15, %ecx
	testb	$32, %al
	jne	LBB0_8
## %bb.9:
	movq	_m_Thermometer_Map_1@GOTPCREL(%rip), %rax
	jmp	LBB0_10
LBB0_8:
	movq	_m_Thermometer_Map_2@GOTPCREL(%rip), %rax
LBB0_10:
	movq	(%rax), %rax
	movl	(%rax,%rcx,4), %eax
	movl	%eax, (%r14)
	movq	(%rbx), %rax
	andl	$-17, (%rax,%rsi,4)
	movq	%rbx, %rdi
	callq	_UpdateReg
	testl	%eax, %eax
	js	LBB0_12
## %bb.11:
	movq	(%rbx), %rax
	movq	_EP4@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rsi
	andl	$-4, (%rax,%rsi,4)
	movq	%rbx, %rdi
	callq	_UpdateReg
LBB0_12:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-32(%rbp), %rcx
	jne	LBB0_14
## %bb.13:
	addq	$72, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_TM,8,3                         ## @TM
	.comm	_m_Thermometer_Map_2,8,3        ## @m_Thermometer_Map_2
	.comm	_m_Thermometer_Map_1,8,3        ## @m_Thermometer_Map_1
	.comm	_EP4,8,3                        ## @EP4
	.no_dead_strip	_ThermometerRead
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ThermometerRead
_ThermometerRead:                       ; @ThermometerRead
	.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	x8, [x0]
Lloh3:
	adrp	x21, _TM@GOTPAGE
Lloh4:
	ldr	x21, [x21, _TM@GOTPAGEOFF]
	ldr	x1, [x21]
	lsl	x9, x1, #2
	ldr	w10, [x8, x9]
	orr	w10, w10, #0x10
	str	w10, [x8, x9]
	bl	_UpdateReg
	tbnz	w0, #31, LBB0_8
; %bb.1:
	add	x22, sp, #8
	add	x1, sp, #8
	mov	x0, x19
	bl	_Read
	tbnz	w0, #31, LBB0_8
; %bb.2:
	ldr	x1, [x21]
	ldr	w8, [x22, x1, lsl #2]
	mov	w9, #47
	and	w9, w8, w9
	cmp	w9, #32
	ccmp	w9, #8, #4, ne
	b.ne	LBB0_6
; %bb.3:
	ldr	x8, [x19]
	lsl	x9, x1, #2
	ldr	w10, [x8, x9]
	eor	w10, w10, #0x20
	str	w10, [x8, x9]
	mov	x0, x19
	bl	_UpdateReg
	tbnz	w0, #31, LBB0_8
; %bb.4:
	mov	w0, #10
	bl	_msleep
	add	x22, sp, #8
	add	x1, sp, #8
	mov	x0, x19
	bl	_Read
	tbnz	w0, #31, LBB0_8
; %bb.5:
	ldr	x1, [x21]
	ldr	w8, [x22, x1, lsl #2]
LBB0_6:
Lloh5:
	adrp	x9, _m_Thermometer_Map_2@GOTPAGE
Lloh6:
	ldr	x9, [x9, _m_Thermometer_Map_2@GOTPAGEOFF]
	and	w10, w8, #0xf
Lloh7:
	adrp	x11, _m_Thermometer_Map_1@GOTPAGE
Lloh8:
	ldr	x11, [x11, _m_Thermometer_Map_1@GOTPAGEOFF]
	tst	w8, #0x20
	csel	x8, x11, x9, eq
	ldr	x8, [x8]
	ldr	w8, [x8, w10, uxtw #2]
	str	w8, [x20]
	ldr	x8, [x19]
	lsl	x9, x1, #2
	ldr	w10, [x8, x9]
	and	w10, w10, #0xffffffef
	str	w10, [x8, x9]
	mov	x0, x19
	bl	_UpdateReg
	tbnz	w0, #31, LBB0_8
; %bb.7:
	ldr	x8, [x19]
Lloh9:
	adrp	x9, _EP4@GOTPAGE
Lloh10:
	ldr	x9, [x9, _EP4@GOTPAGEOFF]
Lloh11:
	ldr	x1, [x9]
	lsl	x9, x1, #2
	ldr	w10, [x8, x9]
	and	w10, w10, #0xfffffffc
	str	w10, [x8, x9]
	mov	x0, x19
	bl	_UpdateReg
LBB0_8:
	ldur	x8, [x29, #-40]
Lloh12:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh13:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_10
; %bb.9:
	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_10:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_TM,8,3                         ; @TM
	.comm	_m_Thermometer_Map_2,8,3        ; @m_Thermometer_Map_2
	.comm	_m_Thermometer_Map_1,8,3        ; @m_Thermometer_Map_1
	.comm	_EP4,8,3                        ; @EP4
	.no_dead_strip	_ThermometerRead
.subsections_via_symbols
