	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function do_autosusptest
_do_autosusptest:                       ## @do_autosusptest
	.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	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	cmpl	$4, %edi
	jne	LBB0_8
## %bb.1:
	movq	16(%r14), %rdi
	callq	_atoi
	movl	%eax, %ebx
	movq	24(%r14), %rdi
	callq	_atoi
	movq	_autosusp_signal@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	xorl	%eax, %eax
	callq	_mmal_vc_use
	movq	_MMAL_SUCCESS@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_9
## %bb.2:
	leaq	-40(%rbp), %r15
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$12, %edx
	callq	_memset
	movq	_autosusp_timeout_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -32(%rbp)
	leaq	-36(%rbp), %rdi
	callq	_sigemptyset
	movq	_SA_SIGINFO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -40(%rbp)
	movq	_SIGALRM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r15, %rsi
	xorl	%edx, %edx
	callq	_sigaction
	testq	%rax, %rax
	jne	LBB0_3
## %bb.5:
	imull	$1000, %ebx, %eax               ## imm = 0x3E8
	movslq	%ebx, %rcx
	imulq	$274877907, %rcx, %rcx          ## imm = 0x10624DD3
	movq	%rcx, %rdx
	shrq	$63, %rdx
	sarq	$38, %rcx
	addl	%edx, %ecx
	movslq	%ecx, %rcx
	movslq	%eax, %rbx
	imulq	$1125899907, %rbx, %rax         ## imm = 0x431BDE83
	movq	%rax, %rdx
	shrq	$63, %rdx
	sarq	$50, %rax
	addl	%edx, %eax
	imull	$1000000, %eax, %eax            ## imm = 0xF4240
	movl	%ebx, %edx
	subl	%eax, %edx
	movslq	%edx, %rax
	movq	%rcx, -64(%rbp)
	movq	%rax, -56(%rbp)
	movl	$0, -48(%rbp)
	movq	_ITIMER_REAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-64(%rbp), %rsi
	xorl	%edx, %edx
	callq	_setitimer
	testl	%eax, %eax
	js	LBB0_6
## %bb.7:
	addq	$1000000, %rbx                  ## imm = 0xF4240
	movq	%rbx, %rdi
	callq	_usleep
	movq	(%r14), %rsi
	leaq	L_.str.5(%rip), %rdi
	xorl	%eax, %eax
	callq	_printf
	xorl	%eax, %eax
	callq	_mmal_vc_release
LBB0_4:
	xorl	%eax, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	callq	_do_autosusptest.cold.2
	jmp	LBB0_4
LBB0_6:
	callq	_do_autosusptest.cold.1
	jmp	LBB0_4
LBB0_8:
	movq	(%r14), %rsi
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_printf
	leaq	L_str(%rip), %rdi
	callq	_puts
	movl	$1, %edi
	callq	_exit
LBB0_9:
	movq	_stderr@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	leaq	L_.str.2(%rip), %rsi
	movl	%eax, %edx
	callq	_fprintf
	movl	$1, %edi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.p2align	4, 0x90                         ## -- Begin function do_autosusptest.cold.1
_do_autosusptest.cold.1:                ## @do_autosusptest.cold.1
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	leaq	L_.str.4(%rip), %rdi
	callq	_perror
	pushq	$1
	popq	%rdi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.p2align	4, 0x90                         ## -- Begin function do_autosusptest.cold.2
_do_autosusptest.cold.2:                ## @do_autosusptest.cold.2
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	leaq	L_.str.3(%rip), %rdi
	callq	_perror
	pushq	$1
	popq	%rdi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"usage: %s autosusp <timeout-ms> <signal>\n"

	.comm	_autosusp_signal,4,2            ## @autosusp_signal
	.comm	_MMAL_SUCCESS,4,2               ## @MMAL_SUCCESS
	.comm	_stderr,4,2                     ## @stderr
L_.str.2:                               ## @.str.2
	.asciz	"mmal_vc_use failed: %d\n"

	.comm	_autosusp_timeout_handler,4,2   ## @autosusp_timeout_handler
	.comm	_SA_SIGINFO,4,2                 ## @SA_SIGINFO
	.comm	_SIGALRM,4,2                    ## @SIGALRM
L_.str.3:                               ## @.str.3
	.asciz	"sigaction"

	.comm	_ITIMER_REAL,4,2                ## @ITIMER_REAL
L_.str.4:                               ## @.str.4
	.asciz	"setitimer failed"

L_.str.5:                               ## @.str.5
	.asciz	"%s: not killed by timer\n"

L_str:                                  ## @str
	.asciz	"   e.g. 650 9"

	.no_dead_strip	_do_autosusptest
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function do_autosusptest
_do_autosusptest:                       ; @do_autosusptest
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x19, x1
	cmp	w0, #4
	b.ne	LBB0_5
; %bb.1:
	ldr	x0, [x19, #16]
	bl	_atoi
	mov	x20, x0
	ldr	x0, [x19, #24]
	bl	_atoi
Lloh0:
	adrp	x8, _autosusp_signal@GOTPAGE
Lloh1:
	ldr	x8, [x8, _autosusp_signal@GOTPAGEOFF]
Lloh2:
	str	w0, [x8]
	bl	_mmal_vc_use
Lloh3:
	adrp	x8, _MMAL_SUCCESS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MMAL_SUCCESS@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_6
; %bb.2:
	add	x21, sp, #32
	add	x0, sp, #32
	mov	w1, #0
	mov	w2, #12
	bl	_memset
Lloh6:
	adrp	x8, _autosusp_timeout_handler@GOTPAGE
Lloh7:
	ldr	x8, [x8, _autosusp_timeout_handler@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	str	w8, [sp, #40]
	orr	x0, x21, #0x4
	bl	_sigemptyset
Lloh9:
	adrp	x8, _SA_SIGINFO@GOTPAGE
Lloh10:
	ldr	x8, [x8, _SA_SIGINFO@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	str	w8, [sp, #32]
Lloh12:
	adrp	x8, _SIGALRM@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SIGALRM@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	add	x1, sp, #32
	mov	w2, #0
	bl	_sigaction
	cbnz	x0, LBB0_7
; %bb.3:
	mov	w8, #1000
	mul	w21, w20, w8
	mov	w8, #19923
	movk	w8, #4194, lsl #16
	smull	x8, w20, w8
	lsr	x9, x8, #63
	asr	x8, x8, #38
	add	w8, w8, w9
	sxtw	x8, w8
	mov	w9, #56963
	movk	w9, #17179, lsl #16
	smull	x9, w21, w9
	lsr	x10, x9, #63
	asr	x9, x9, #50
	add	w9, w9, w10
	mov	w10, #16960
	movk	w10, #15, lsl #16
	msub	w9, w9, w10, w21
	sxtw	x9, w9
	stp	x8, x9, [sp, #8]
	str	wzr, [sp, #24]
Lloh15:
	adrp	x8, _ITIMER_REAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ITIMER_REAL@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	add	x1, sp, #8
	mov	x2, #0
	bl	_setitimer
	tbnz	w0, #31, LBB0_8
; %bb.4:
	mov	w8, #16960
	movk	w8, #15, lsl #16
	add	x0, x8, w21, sxtw
	bl	_usleep
	ldr	x8, [x19]
	str	x8, [sp]
Lloh18:
	adrp	x0, l_.str.5@PAGE
Lloh19:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_printf
	bl	_mmal_vc_release
	mov	w0, #0
	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
	add	sp, sp, #96
	ret
LBB0_5:
	ldr	x8, [x19]
	str	x8, [sp]
Lloh20:
	adrp	x0, l_.str@PAGE
Lloh21:
	add	x0, x0, l_.str@PAGEOFF
	bl	_printf
Lloh22:
	adrp	x0, l_str@PAGE
Lloh23:
	add	x0, x0, l_str@PAGEOFF
	bl	_puts
	mov	w0, #1
	bl	_exit
LBB0_6:
	mov	x2, x0
Lloh24:
	adrp	x8, _stderr@GOTPAGE
Lloh25:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
Lloh27:
	adrp	x1, l_.str.2@PAGE
Lloh28:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_fprintf
	mov	w0, #1
	bl	_exit
LBB0_7:
	bl	_do_autosusptest.cold.2
LBB0_8:
	bl	_do_autosusptest.cold.1
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotStr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.p2align	2                               ; -- Begin function do_autosusptest.cold.1
_do_autosusptest.cold.1:                ; @do_autosusptest.cold.1
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh29:
	adrp	x0, l_.str.4@PAGE
Lloh30:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_perror
	mov	w0, #1
	bl	_exit
	.loh AdrpAdd	Lloh29, Lloh30
	.cfi_endproc
                                        ; -- End function
	.p2align	2                               ; -- Begin function do_autosusptest.cold.2
_do_autosusptest.cold.2:                ; @do_autosusptest.cold.2
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh31:
	adrp	x0, l_.str.3@PAGE
Lloh32:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_perror
	mov	w0, #1
	bl	_exit
	.loh AdrpAdd	Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"usage: %s autosusp <timeout-ms> <signal>\n"

	.comm	_autosusp_signal,4,2            ; @autosusp_signal
	.comm	_MMAL_SUCCESS,4,2               ; @MMAL_SUCCESS
	.comm	_stderr,4,2                     ; @stderr
l_.str.2:                               ; @.str.2
	.asciz	"mmal_vc_use failed: %d\n"

	.comm	_autosusp_timeout_handler,4,2   ; @autosusp_timeout_handler
	.comm	_SA_SIGINFO,4,2                 ; @SA_SIGINFO
	.comm	_SIGALRM,4,2                    ; @SIGALRM
l_.str.3:                               ; @.str.3
	.asciz	"sigaction"

	.comm	_ITIMER_REAL,4,2                ; @ITIMER_REAL
l_.str.4:                               ; @.str.4
	.asciz	"setitimer failed"

l_.str.5:                               ; @.str.5
	.asciz	"%s: not killed by timer\n"

l_str:                                  ; @str
	.asciz	"   e.g. 650 9"

	.no_dead_strip	_do_autosusptest
.subsections_via_symbols
