	.file	"extr_dtrace_ioctl.c_dtrace_ioctl_helper.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	dtrace_ioctl_helper, @function
dtrace_ioctl_helper:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	mov	rbx, rdx
	sub	rsp, 16
	.cfi_def_cfa_offset 48
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	mov	DWORD PTR 4[rsp], 0
	cmp	esi, 128
	je	.L2
	mov	eax, DWORD PTR ENOTTY[rip]
	cmp	esi, 129
	jne	.L1
	mov	rbp, QWORD PTR curproc[rip]
	mov	r12d, DWORD PTR 8[rdx]
	mov	edi, DWORD PTR 4[rdx]
	cmp	DWORD PTR 16[rbp], edi
	je	.L25
	call	pfind@PLT
	mov	rbp, rax
	test	rax, rax
	je	.L21
	mov	rdi, rax
	call	P_SHOULDSTOP@PLT
	test	eax, eax
	je	.L8
	mov	edx, DWORD PTR P_TRACED[rip]
	mov	eax, DWORD PTR P_WEXIT[rip]
	or	eax, edx
	and	eax, DWORD PTR 0[rbp]
	cmp	edx, eax
	jne	.L8
	mov	rax, QWORD PTR curproc[rip]
	cmp	QWORD PTR 8[rbp], rax
	je	.L9
.L8:
	mov	rdi, rbp
	call	PROC_UNLOCK@PLT
.L21:
	mov	eax, DWORD PTR EINVAL[rip]
	.p2align 4,,10
	.p2align 3
.L1:
	mov	rcx, QWORD PTR 8[rsp]
	xor	rcx, QWORD PTR fs:40
	jne	.L26
	add	rsp, 16
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	pop	rbx
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	lea	rdi, dtrace_lock[rip]
	call	mutex_enter@PLT
	mov	esi, DWORD PTR [rbx]
	xor	edi, edi
	call	dtrace_helper_destroygen@PLT
	lea	rdi, dtrace_lock[rip]
	mov	DWORD PTR 4[rsp], eax
	call	mutex_exit@PLT
.L22:
	mov	eax, DWORD PTR 4[rsp]
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L25:
	movsx	rdi, r12d
	lea	rsi, 4[rsp]
	call	dtrace_dof_copyin@PLT
	mov	r12, rax
.L5:
	test	r12, r12
	je	.L23
	lea	rdi, dtrace_lock[rip]
	call	mutex_enter@PLT
	mov	rdx, rbp
	mov	rsi, rbx
	mov	rdi, r12
	call	dtrace_helper_slurp@PLT
	cmp	eax, -1
	je	.L13
	mov	DWORD PTR [rbx], eax
	mov	DWORD PTR 4[rsp], 0
.L14:
	lea	rdi, dtrace_lock[rip]
	call	mutex_exit@PLT
.L23:
	cmp	QWORD PTR curproc[rip], rbp
	je	.L22
	mov	rdi, rbp
	call	PRELE@PLT
	mov	eax, DWORD PTR 4[rsp]
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L13:
	mov	eax, DWORD PTR EINVAL[rip]
	mov	DWORD PTR 4[rsp], eax
	jmp	.L14
	.p2align 4,,10
	.p2align 3
.L9:
	mov	rdi, rbp
	call	_PHOLD@PLT
	mov	rdi, rbp
	call	PROC_UNLOCK@PLT
	movsx	rsi, r12d
	lea	rdx, 4[rsp]
	mov	rdi, rbp
	call	dtrace_dof_copyin_proc@PLT
	mov	r12, rax
	jmp	.L5
.L26:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	dtrace_ioctl_helper, .-dtrace_ioctl_helper
	.comm	dtrace_lock,4,4
	.comm	curproc,8,8
	.comm	P_WEXIT,4,4
	.comm	P_TRACED,4,4
	.comm	ENOTTY,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_dtrace_ioctl.c_dtrace_ioctl_helper.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	dtrace_ioctl_helper, %function
dtrace_ioctl_helper:
	@ args = 4, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, lr}
	mov	r5, #0
	ldr	r3, .L27
	sub	sp, sp, #12
	cmp	r1, #128
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	mov	r4, r2
	str	r5, [sp]
	beq	.L2
	cmp	r1, #129
	bne	.L3
	ldr	r6, .L27+4
	ldr	r0, [r2, #4]
	ldr	r5, [r6]
	ldr	r7, [r2, #8]
	ldr	r3, [r5, #8]
	cmp	r3, r0
	beq	.L25
	bl	pfind
	subs	r5, r0, #0
	beq	.L21
	bl	P_SHOULDSTOP
	cmp	r0, #0
	beq	.L8
	ldr	r2, .L27+8
	ldr	r3, .L27+12
	ldr	r2, [r2]
	ldr	r3, [r3]
	ldr	r1, [r5]
	orr	r3, r2, r3
	and	r3, r3, r1
	cmp	r2, r3
	bne	.L8
	ldr	r2, [r5, #4]
	ldr	r3, [r6]
	cmp	r2, r3
	beq	.L9
.L8:
	mov	r0, r5
	bl	PROC_UNLOCK
.L21:
	ldr	r3, .L27+16
	ldr	r0, [r3]
.L1:
	ldr	r3, .L27
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L26
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, pc}
.L2:
	ldr	r0, .L27+20
	bl	mutex_enter
	ldr	r1, [r4]
	mov	r0, r5
	bl	dtrace_helper_destroygen
	mov	r3, r0
	ldr	r0, .L27+20
	str	r3, [sp]
	bl	mutex_exit
	ldr	r0, [sp]
	b	.L1
.L3:
	ldr	r3, .L27+24
	ldr	r0, [r3]
	b	.L1
.L25:
	mov	r0, r7
	mov	r1, sp
	bl	dtrace_dof_copyin
	mov	r7, r0
.L5:
	cmp	r7, #0
	beq	.L23
	ldr	r0, .L27+20
	bl	mutex_enter
	mov	r2, r5
	mov	r1, r4
	mov	r0, r7
	bl	dtrace_helper_slurp
	cmn	r0, #1
	movne	r3, #0
	ldreq	r3, .L27+16
	strne	r0, [r4]
	ldreq	r3, [r3]
	ldr	r0, .L27+20
	str	r3, [sp]
	bl	mutex_exit
.L23:
	ldr	r3, [r6]
	cmp	r3, r5
	beq	.L22
	mov	r0, r5
	bl	PRELE
.L22:
	ldr	r0, [sp]
	b	.L1
.L9:
	mov	r0, r5
	bl	_PHOLD
	mov	r0, r5
	bl	PROC_UNLOCK
	mov	r1, r7
	mov	r2, sp
	mov	r0, r5
	bl	dtrace_dof_copyin_proc
	mov	r7, r0
	b	.L5
.L26:
	bl	__stack_chk_fail
.L28:
	.align	2
.L27:
	.word	.LC0
	.word	curproc
	.word	P_TRACED
	.word	P_WEXIT
	.word	EINVAL
	.word	dtrace_lock
	.word	ENOTTY
	.size	dtrace_ioctl_helper, .-dtrace_ioctl_helper
	.comm	dtrace_lock,4,4
	.comm	curproc,4,4
	.comm	P_WEXIT,4,4
	.comm	P_TRACED,4,4
	.comm	ENOTTY,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
