	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cap_task_fix_setuid            ## -- Begin function cap_task_fix_setuid
	.p2align	4, 0x90
_cap_task_fix_setuid:                   ## @cap_task_fix_setuid
	.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
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
                                        ## kill: def $edx killed $edx def $rdx
	movq	%rsi, %r15
	movq	%rdi, %r14
	leal	-128(%rdx), %eax
	cmpl	$3, %eax
	jae	LBB0_1
## %bb.8:
	movq	_SECURE_NO_SETUID_FIXUP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_issecure
	xorl	%ebx, %ebx
	testl	%eax, %eax
	jne	LBB0_11
## %bb.9:
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_cap_emulate_setxuid
	jmp	LBB0_11
LBB0_1:
	cmpl	$131, %edx
	jne	LBB0_10
## %bb.2:
	movq	_SECURE_NO_SETUID_FIXUP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_issecure
	xorl	%ebx, %ebx
	testl	%eax, %eax
	jne	LBB0_11
## %bb.3:
	cmpl	$0, 8(%r15)
	je	LBB0_4
LBB0_6:
	cmpl	$0, 8(%r14)
	jne	LBB0_11
## %bb.7:
	movl	(%r14), %esi
	movl	4(%r14), %edi
	callq	_cap_raise_fs_set
	movl	%eax, 4(%r14)
	jmp	LBB0_11
LBB0_10:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_11:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	cmpl	$0, 8(%r14)
	je	LBB0_11
## %bb.5:
	movl	4(%r14), %edi
	callq	_cap_drop_fs_set
	movl	%eax, 4(%r14)
	cmpl	$0, 8(%r15)
	jne	LBB0_6
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_SECURE_NO_SETUID_FIXUP,4,2     ## @SECURE_NO_SETUID_FIXUP
	.comm	_EINVAL,4,2                     ## @EINVAL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cap_task_fix_setuid            ; -- Begin function cap_task_fix_setuid
	.p2align	2
_cap_task_fix_setuid:                   ; @cap_task_fix_setuid
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x20, x1
	mov	x19, x0
	sub	w8, w2, #128
	cmp	w8, #3
	b.hs	LBB0_3
; %bb.1:
Lloh0:
	adrp	x8, _SECURE_NO_SETUID_FIXUP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SECURE_NO_SETUID_FIXUP@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_issecure
	cbnz	w0, LBB0_11
; %bb.2:
	mov	x0, x19
	mov	x1, x20
	bl	_cap_emulate_setxuid
	mov	w0, #0
	b	LBB0_12
LBB0_3:
	cmp	w2, #131
	b.ne	LBB0_8
; %bb.4:
Lloh3:
	adrp	x8, _SECURE_NO_SETUID_FIXUP@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SECURE_NO_SETUID_FIXUP@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_issecure
	cbnz	w0, LBB0_11
; %bb.5:
	ldr	w8, [x20, #8]
	cbz	w8, LBB0_9
LBB0_6:
	ldr	w8, [x19, #8]
	cbnz	w8, LBB0_11
; %bb.7:
	ldp	w1, w0, [x19]
	bl	_cap_raise_fs_set
	mov	x8, x0
	mov	w0, #0
	str	w8, [x19, #4]
	b	LBB0_12
LBB0_8:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_12
LBB0_9:
	ldr	w8, [x19, #8]
	cbz	w8, LBB0_11
; %bb.10:
	ldr	w0, [x19, #4]
	bl	_cap_drop_fs_set
	str	w0, [x19, #4]
	ldr	w8, [x20, #8]
	cbnz	w8, LBB0_6
LBB0_11:
	mov	w0, #0
LBB0_12:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_SECURE_NO_SETUID_FIXUP,4,2     ; @SECURE_NO_SETUID_FIXUP
	.comm	_EINVAL,4,2                     ; @EINVAL
.subsections_via_symbols
