	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ugen20_tr_renew
_ugen20_tr_renew:                       ## @ugen20_tr_renew
	.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
	movl	(%rdi), %r12d
	testl	%r12d, %r12d
	je	LBB0_1
## %bb.2:
	movq	%rdi, %rbx
	leal	(,%r12,8), %r15d
	movq	8(%rdi), %rdi
	testq	%rdi, %rdi
	jne	LBB0_6
## %bb.3:
	movl	%r15d, %edi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	movq	%rax, %rdi
	movq	%rax, 8(%rbx)
LBB0_6:
	xorl	%r14d, %r14d
	xorl	%esi, %esi
	movl	%r15d, %edx
	callq	_memset
	leaq	-40(%rbp), %r15
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movq	8(%rbx), %rdi
	callq	_libusb20_pass_ptr
	movl	%eax, -36(%rbp)
	movl	%r12d, -40(%rbp)
	movl	4(%rbx), %ebx
	movq	_USB_FS_INIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_IOUSB
	movl	%ebx, %edi
	movl	%eax, %esi
	movq	%r15, %rdx
	callq	_ioctl
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	movq	_LIBUSB20_ERROR_OTHER@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_1:
	xorl	%r14d, %r14d
	jmp	LBB0_9
LBB0_4:
	movq	_LIBUSB20_ERROR_NO_MEM@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %r14d
LBB0_9:
	movl	%r14d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LIBUSB20_ERROR_NO_MEM,4,2      ## @LIBUSB20_ERROR_NO_MEM
	.comm	_USB_FS_INIT,4,2                ## @USB_FS_INIT
	.comm	_LIBUSB20_ERROR_OTHER,4,2       ## @LIBUSB20_ERROR_OTHER
	.no_dead_strip	_ugen20_tr_renew
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ugen20_tr_renew
_ugen20_tr_renew:                       ; @ugen20_tr_renew
	.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
	ldr	w21, [x0]
	cbz	w21, LBB0_5
; %bb.1:
	mov	x19, x0
	lsl	w20, w21, #3
	ldr	x0, [x0, #8]
	cbnz	x0, LBB0_4
; %bb.2:
	mov	x0, x20
	bl	_malloc
	cbz	x0, LBB0_6
; %bb.3:
	str	x0, [x19, #8]
LBB0_4:
	mov	w1, #0
	mov	x2, x20
	bl	_memset
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #8
	bl	_memset
	ldr	x0, [x19, #8]
	bl	_libusb20_pass_ptr
	stp	w21, w0, [sp, #8]
	ldr	w19, [x19, #4]
Lloh0:
	adrp	x8, _USB_FS_INIT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _USB_FS_INIT@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_IOUSB
	mov	x1, x0
	add	x2, sp, #8
	mov	x0, x19
	bl	_ioctl
Lloh3:
	adrp	x8, _LIBUSB20_ERROR_OTHER@GOTPAGE
Lloh4:
	ldr	x8, [x8, _LIBUSB20_ERROR_OTHER@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	x0, #0
	csel	w0, wzr, w8, eq
	b	LBB0_7
LBB0_5:
	mov	w0, #0
	b	LBB0_7
LBB0_6:
Lloh6:
	adrp	x8, _LIBUSB20_ERROR_NO_MEM@GOTPAGE
Lloh7:
	ldr	x8, [x8, _LIBUSB20_ERROR_NO_MEM@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
LBB0_7:
	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 AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_LIBUSB20_ERROR_NO_MEM,4,2      ; @LIBUSB20_ERROR_NO_MEM
	.comm	_USB_FS_INIT,4,2                ; @USB_FS_INIT
	.comm	_LIBUSB20_ERROR_OTHER,4,2       ; @LIBUSB20_ERROR_OTHER
	.no_dead_strip	_ugen20_tr_renew
.subsections_via_symbols
