	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gethostname                    ## -- Begin function gethostname
	.p2align	4, 0x90
_gethostname:                           ## @gethostname
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -24
	movq	%rdi, %rdx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -16(%rbp)
	movq	%rsi, -32(%rbp)
	movq	_CTL_KERN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -24(%rbp)
	movq	_KERN_HOSTNAME@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -20(%rbp)
	xorl	%ebx, %ebx
	leaq	-24(%rbp), %rdi
	leaq	-32(%rbp), %rcx
	movl	$2, %esi
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_sysctl
	cmpl	$-1, %eax
	jne	LBB0_3
## %bb.1:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	_ENOMEM@GOTPCREL(%rip), %rdx
	movl	$-1, %ebx
	cmpq	(%rdx), %rcx
	jne	LBB0_3
## %bb.2:
	movq	_ENAMETOOLONG@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
LBB0_3:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-16(%rbp), %rax
	jne	LBB0_5
## %bb.4:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%rbp
	retq
LBB0_5:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_CTL_KERN,4,2                   ## @CTL_KERN
	.comm	_KERN_HOSTNAME,4,2              ## @KERN_HOSTNAME
	.comm	_errno,8,3                      ## @errno
	.comm	_ENOMEM,8,3                     ## @ENOMEM
	.comm	_ENAMETOOLONG,8,3               ## @ENAMETOOLONG
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gethostname                    ; -- Begin function gethostname
	.p2align	2
_gethostname:                           ; @gethostname
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	mov	x2, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-8]
	str	x1, [sp, #8]
Lloh3:
	adrp	x8, _CTL_KERN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _CTL_KERN@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _KERN_HOSTNAME@GOTPAGE
Lloh7:
	ldr	x9, [x9, _KERN_HOSTNAME@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #16]
	add	x0, sp, #16
	add	x3, sp, #8
	mov	w1, #2
	mov	x4, #0
	mov	w5, #0
	bl	_sysctl
	mov	x8, x0
	mov	w0, #0
	cmn	w8, #1
	b.ne	LBB0_4
; %bb.1:
Lloh9:
	adrp	x8, _errno@GOTPAGE
Lloh10:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
	ldr	x9, [x8]
Lloh11:
	adrp	x10, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x10, [x10, _ENOMEM@GOTPAGEOFF]
Lloh13:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_3
; %bb.2:
Lloh14:
	adrp	x9, _ENAMETOOLONG@GOTPAGE
Lloh15:
	ldr	x9, [x9, _ENAMETOOLONG@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	str	x9, [x8]
LBB0_3:
	mov	w0, #-1
LBB0_4:
	ldur	x8, [x29, #-8]
Lloh17:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh18:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh19:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_6
; %bb.5:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_6:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_CTL_KERN,4,2                   ; @CTL_KERN
	.comm	_KERN_HOSTNAME,4,2              ; @KERN_HOSTNAME
	.comm	_errno,8,3                      ; @errno
	.comm	_ENOMEM,8,3                     ; @ENOMEM
	.comm	_ENAMETOOLONG,8,3               ; @ENAMETOOLONG
.subsections_via_symbols
