	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_isc_resource_setlimit          ## -- Begin function isc_resource_setlimit
	.p2align	4, 0x90
_isc_resource_setlimit:                 ## @isc_resource_setlimit
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movq	%rdi, %r14
	leaq	-36(%rbp), %rsi
	callq	_resource2rlim
	movq	_ISC_R_SUCCESS@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rax
	jne	LBB0_11
## %bb.1:
	movq	_ISC_RESOURCE_UNLIMITED@GOTPCREL(%rip), %rax
	cmpq	%r12, (%rax)
	jne	LBB0_3
## %bb.2:
	movq	_RLIM_INFINITY@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_4
LBB0_3:
	movl	$1, %edi
	callq	_ISC_TF
	xorl	%ebx, %ebx
	cmpq	$1, %rax
	sbbq	%rbx, %rbx
	orq	$2147483647, %rbx               ## imm = 0x7FFFFFFF
	cmpq	%r12, %rbx
	cmovgeq	%r12, %rbx
LBB0_4:
	movl	%ebx, -44(%rbp)
	movl	%ebx, -48(%rbp)
	movl	-36(%rbp), %edi
	leaq	-48(%rbp), %rsi
	callq	_setrlimit
	testl	%eax, %eax
	je	LBB0_10
## %bb.5:
	movq	_isc_resource_openfiles@GOTPCREL(%rip), %rax
	cmpq	%r14, (%rax)
	jne	LBB0_9
## %bb.6:
	movq	_RLIM_INFINITY@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_9
## %bb.7:
	movl	-36(%rbp), %edi
	leaq	-48(%rbp), %rsi
	callq	_getrlimit
	testq	%rax, %rax
	jne	LBB0_9
## %bb.8:
	movl	-44(%rbp), %eax
	movl	%eax, -48(%rbp)
	movl	-36(%rbp), %edi
	leaq	-48(%rbp), %rsi
	callq	_setrlimit
	testl	%eax, %eax
	je	LBB0_10
LBB0_9:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_isc__errno2result
	jmp	LBB0_11
LBB0_10:
	movq	(%r15), %rax
LBB0_11:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ISC_R_SUCCESS,8,3              ## @ISC_R_SUCCESS
	.comm	_ISC_RESOURCE_UNLIMITED,8,3     ## @ISC_RESOURCE_UNLIMITED
	.comm	_RLIM_INFINITY,4,2              ## @RLIM_INFINITY
	.comm	_isc_resource_openfiles,8,3     ## @isc_resource_openfiles
	.comm	_errno,4,2                      ## @errno
	.comm	_NR_OPEN,4,2                    ## @NR_OPEN
	.comm	_OPEN_MAX,4,2                   ## @OPEN_MAX
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_isc_resource_setlimit          ; -- Begin function isc_resource_setlimit
	.p2align	2
_isc_resource_setlimit:                 ; @isc_resource_setlimit
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	add	x1, sp, #4
	bl	_resource2rlim
Lloh0:
	adrp	x21, _ISC_R_SUCCESS@GOTPAGE
Lloh1:
	ldr	x21, [x21, _ISC_R_SUCCESS@GOTPAGEOFF]
	ldr	x8, [x21]
	cmp	x0, x8
	b.ne	LBB0_10
; %bb.1:
Lloh2:
	adrp	x8, _ISC_RESOURCE_UNLIMITED@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ISC_RESOURCE_UNLIMITED@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
Lloh5:
	adrp	x22, _RLIM_INFINITY@GOTPAGE
Lloh6:
	ldr	x22, [x22, _RLIM_INFINITY@GOTPAGEOFF]
	cmp	x8, x20
	b.ne	LBB0_3
; %bb.2:
	ldr	w20, [x22]
	b	LBB0_4
LBB0_3:
	mov	w0, #1
	bl	_ISC_TF
	cmp	x0, #0
	mov	w8, #2147483647
	csinv	x8, x8, xzr, ne
	cmp	x8, x20
	csel	x20, x8, x20, lt
LBB0_4:
	stp	w20, w20, [sp, #8]
	ldr	w0, [sp, #4]
	add	x1, sp, #8
	bl	_setrlimit
	cbz	w0, LBB0_9
; %bb.5:
Lloh7:
	adrp	x8, _isc_resource_openfiles@GOTPAGE
Lloh8:
	ldr	x8, [x8, _isc_resource_openfiles@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	ldr	w9, [x22]
	cmp	x8, x19
	ccmp	w20, w9, #0, eq
	b.ne	LBB0_8
; %bb.6:
	ldr	w0, [sp, #4]
	add	x1, sp, #8
	bl	_getrlimit
	cbnz	x0, LBB0_8
; %bb.7:
	ldr	w8, [sp, #12]
	str	w8, [sp, #8]
	ldr	w0, [sp, #4]
	add	x1, sp, #8
	bl	_setrlimit
	cbz	w0, LBB0_9
LBB0_8:
Lloh10:
	adrp	x8, _errno@GOTPAGE
Lloh11:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh12:
	ldr	w0, [x8]
	bl	_isc__errno2result
	b	LBB0_10
LBB0_9:
	ldr	x0, [x21]
LBB0_10:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_ISC_R_SUCCESS,8,3              ; @ISC_R_SUCCESS
	.comm	_ISC_RESOURCE_UNLIMITED,8,3     ; @ISC_RESOURCE_UNLIMITED
	.comm	_RLIM_INFINITY,4,2              ; @RLIM_INFINITY
	.comm	_isc_resource_openfiles,8,3     ; @isc_resource_openfiles
	.comm	_errno,4,2                      ; @errno
	.comm	_NR_OPEN,4,2                    ; @NR_OPEN
	.comm	_OPEN_MAX,4,2                   ; @OPEN_MAX
.subsections_via_symbols
