	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dumpstate
_dumpstate:                             ## @dumpstate
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$48, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -48(%rbp)
	movaps	%xmm0, -64(%rbp)
	movq	$0, -32(%rbp)
	cmpl	$1, %edi
	jne	LBB0_1
## %bb.2:
	movq	(%rsi), %r14
	leaq	-48(%rbp), %rdi
	movl	$255, %esi
	movl	$4, %edx
	callq	_memset
	movl	$8388608, -64(%rbp)             ## imm = 0x800000
	movl	$8388608, %edi                  ## imm = 0x800000
	callq	_malloc
	movq	%rax, -56(%rbp)
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	_CHELSIO_T4_CUDBG_DUMP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-64(%rbp), %rsi
	callq	_doit
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_8
## %bb.5:
	movq	_O_CREAT@GOTPCREL(%rip), %rax
	movq	_O_TRUNC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	(%rax), %esi
	movq	_O_EXCL@GOTPCREL(%rip), %rax
	orl	(%rax), %esi
	movq	_O_WRONLY@GOTPCREL(%rip), %rax
	orl	(%rax), %esi
	movq	_S_IRUSR@GOTPCREL(%rip), %rax
	movq	_S_IRGRP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movq	_S_IROTH@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	%r14, %rdi
	callq	_open
	testl	%eax, %eax
	js	LBB0_6
## %bb.7:
	movl	%eax, %ebx
	movq	-56(%rbp), %rsi
	movl	-64(%rbp), %edx
	movl	%eax, %edi
	callq	_write
	movl	%ebx, %edi
	callq	_close
	xorl	%ebx, %ebx
	jmp	LBB0_8
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_warnx
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_9
LBB0_3:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_9
LBB0_6:
	leaq	L_.str.1(%rip), %rdi
	movq	%r14, %rsi
	callq	_warn
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_8:
	movq	-56(%rbp), %rdi
	callq	_free
LBB0_9:
	movl	%ebx, %eax
	addq	$48, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"dumpstate: incorrect number of arguments."

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_CHELSIO_T4_CUDBG_DUMP,4,2      ## @CHELSIO_T4_CUDBG_DUMP
	.comm	_O_CREAT,4,2                    ## @O_CREAT
	.comm	_O_TRUNC,4,2                    ## @O_TRUNC
	.comm	_O_EXCL,4,2                     ## @O_EXCL
	.comm	_O_WRONLY,4,2                   ## @O_WRONLY
	.comm	_S_IRUSR,4,2                    ## @S_IRUSR
	.comm	_S_IRGRP,4,2                    ## @S_IRGRP
	.comm	_S_IROTH,4,2                    ## @S_IROTH
L_.str.1:                               ## @.str.1
	.asciz	"open(%s)"

	.comm	_errno,4,2                      ## @errno
	.no_dead_strip	_dumpstate
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dumpstate
_dumpstate:                             ; @dumpstate
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	str	xzr, [sp, #32]
	movi.2d	v0, #0000000000000000
	stp	q0, q0, [sp]
	cmp	w0, #1
	b.ne	LBB0_5
; %bb.1:
	ldr	x19, [x1]
	mov	x8, sp
	add	x0, x8, #16
	mov	w1, #255
	mov	w2, #4
	bl	_memset
	mov	w8, #8388608
	str	w8, [sp]
	mov	w0, #8388608
	bl	_malloc
	str	x0, [sp, #8]
	cbz	x0, LBB0_6
; %bb.2:
Lloh0:
	adrp	x8, _CHELSIO_T4_CUDBG_DUMP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CHELSIO_T4_CUDBG_DUMP@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	mov	x1, sp
	bl	_doit
	mov	x20, x0
	cbnz	w0, LBB0_8
; %bb.3:
Lloh3:
	adrp	x8, _O_CREAT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _O_CREAT@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _O_TRUNC@GOTPAGE
Lloh7:
	ldr	x9, [x9, _O_TRUNC@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
Lloh9:
	adrp	x10, _O_EXCL@GOTPAGE
Lloh10:
	ldr	x10, [x10, _O_EXCL@GOTPAGEOFF]
	orr	w8, w9, w8
Lloh11:
	ldr	w9, [x10]
	orr	w8, w8, w9
Lloh12:
	adrp	x9, _O_WRONLY@GOTPAGE
Lloh13:
	ldr	x9, [x9, _O_WRONLY@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	orr	w1, w8, w9
Lloh15:
	adrp	x8, _S_IRUSR@GOTPAGE
Lloh16:
	ldr	x8, [x8, _S_IRUSR@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
Lloh18:
	adrp	x9, _S_IRGRP@GOTPAGE
Lloh19:
	ldr	x9, [x9, _S_IRGRP@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh21:
	adrp	x9, _S_IROTH@GOTPAGE
Lloh22:
	ldr	x9, [x9, _S_IROTH@GOTPAGEOFF]
Lloh23:
	ldr	w9, [x9]
	orr	w2, w8, w9
	mov	x0, x19
	bl	_open
	tbnz	w0, #31, LBB0_7
; %bb.4:
	mov	x20, x0
	ldr	x1, [sp, #8]
	ldr	w2, [sp]
	bl	_write
	mov	x0, x20
	bl	_close
	mov	w20, #0
	b	LBB0_8
LBB0_5:
Lloh24:
	adrp	x0, l_.str@PAGE
Lloh25:
	add	x0, x0, l_.str@PAGEOFF
	bl	_warnx
Lloh26:
	adrp	x8, _EINVAL@GOTPAGE
Lloh27:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh28:
	ldr	w20, [x8]
	b	LBB0_9
LBB0_6:
Lloh29:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh30:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh31:
	ldr	w20, [x8]
	b	LBB0_9
LBB0_7:
Lloh32:
	adrp	x0, l_.str.1@PAGE
Lloh33:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x19
	bl	_warn
Lloh34:
	adrp	x8, _errno@GOTPAGE
Lloh35:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh36:
	ldr	w20, [x8]
LBB0_8:
	ldr	x0, [sp, #8]
	bl	_free
LBB0_9:
	mov	x0, x20
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpAdd	Lloh32, Lloh33
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"dumpstate: incorrect number of arguments."

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_CHELSIO_T4_CUDBG_DUMP,4,2      ; @CHELSIO_T4_CUDBG_DUMP
	.comm	_O_CREAT,4,2                    ; @O_CREAT
	.comm	_O_TRUNC,4,2                    ; @O_TRUNC
	.comm	_O_EXCL,4,2                     ; @O_EXCL
	.comm	_O_WRONLY,4,2                   ; @O_WRONLY
	.comm	_S_IRUSR,4,2                    ; @S_IRUSR
	.comm	_S_IRGRP,4,2                    ; @S_IRGRP
	.comm	_S_IROTH,4,2                    ; @S_IROTH
l_.str.1:                               ; @.str.1
	.asciz	"open(%s)"

	.comm	_errno,4,2                      ; @errno
	.no_dead_strip	_dumpstate
.subsections_via_symbols
