	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function getctty
_getctty:                               ## @getctty
	.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	$80, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	%rsi, %rdi
	callq	_assert
	movq	8(%rbx), %rsi
	leaq	-40(%rbp), %rdx
	movq	%r14, %rdi
	movl	$24, %ecx
	callq	_kvm_read_all
	testl	%eax, %eax
	je	LBB0_5
## %bb.1:
	movq	-24(%rbp), %rsi
	testq	%rsi, %rsi
	je	LBB0_10
## %bb.2:
	leaq	-64(%rbp), %rdx
	movq	%r14, %rdi
	movl	$24, %ecx
	callq	_kvm_read_all
	testl	%eax, %eax
	je	LBB0_7
## %bb.3:
	movq	-56(%rbp), %rsi
	leaq	-88(%rbp), %rdx
	movq	%r14, %rdi
	movl	$24, %ecx
	callq	_kvm_read_all
	testl	%eax, %eax
	je	LBB0_8
## %bb.4:
	movq	-88(%rbp), %rax
	jmp	LBB0_11
LBB0_5:
	movq	8(%rbx), %rsi
	movl	(%rbx), %edx
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_9
LBB0_7:
	movq	-24(%rbp), %rsi
	movl	(%rbx), %edx
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_9
LBB0_8:
	movq	-56(%rbp), %rsi
	movl	(%rbx), %edx
	leaq	L_.str.2(%rip), %rdi
LBB0_9:
	callq	_warnx
LBB0_10:
	xorl	%eax, %eax
LBB0_11:
	addq	$80, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"can't read proc struct at %p for pid %d"

L_.str.1:                               ## @.str.1
	.asciz	"can't read pgrp struct at %p for pid %d"

L_.str.2:                               ## @.str.2
	.asciz	"can't read session struct at %p for pid %d"

	.no_dead_strip	_getctty
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function getctty
_getctty:                               ; @getctty
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	mov	x20, x0
	mov	x0, x1
	bl	_assert
	ldr	x1, [x19, #8]
	add	x2, sp, #32
	mov	x0, x20
	mov	w3, #24
	bl	_kvm_read_all
	cbz	w0, LBB0_5
; %bb.1:
	ldr	x1, [sp, #48]
	cbz	x1, LBB0_9
; %bb.2:
	sub	x2, x29, #40
	mov	x0, x20
	mov	w3, #24
	bl	_kvm_read_all
	cbz	w0, LBB0_6
; %bb.3:
	ldur	x1, [x29, #-32]
	add	x2, sp, #8
	mov	x0, x20
	mov	w3, #24
	bl	_kvm_read_all
	cbz	w0, LBB0_7
; %bb.4:
	ldr	x0, [sp, #8]
	b	LBB0_10
LBB0_5:
	ldr	x1, [x19, #8]
	ldr	w2, [x19]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_8
LBB0_6:
	ldr	x1, [sp, #48]
	ldr	w2, [x19]
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_8
LBB0_7:
	ldur	x1, [x29, #-32]
	ldr	w2, [x19]
Lloh4:
	adrp	x0, l_.str.2@PAGE
Lloh5:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_8:
	bl	_warnx
LBB0_9:
	mov	x0, #0
LBB0_10:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"can't read proc struct at %p for pid %d"

l_.str.1:                               ; @.str.1
	.asciz	"can't read pgrp struct at %p for pid %d"

l_.str.2:                               ; @.str.2
	.asciz	"can't read session struct at %p for pid %d"

	.no_dead_strip	_getctty
.subsections_via_symbols
