	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_d3drm_object_get_name          ## -- Begin function d3drm_object_get_name
	.p2align	4, 0x90
_d3drm_object_get_name:                 ## @d3drm_object_get_name
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_E_INVALIDARG@GOTPCREL(%rip), %rbx
	testq	%rsi, %rsi
	je	LBB0_11
## %bb.1:
	movq	%rdx, %r14
	movq	%rsi, %r15
	movq	%rdi, %r12
	movq	(%rdi), %rdi
	testq	%rdi, %rdi
	je	LBB0_2
## %bb.3:
	callq	_strlen
	movl	%eax, %r13d
	incl	%r13d
	testq	%r14, %r14
	jne	LBB0_5
	jmp	LBB0_10
LBB0_2:
	xorl	%r13d, %r13d
	testq	%r14, %r14
	je	LBB0_10
LBB0_5:
	movl	(%r15), %eax
	cmpl	%r13d, %eax
	jl	LBB0_11
## %bb.6:
	movq	(%r12), %rsi
	testq	%rsi, %rsi
	je	LBB0_8
## %bb.7:
	movq	%r14, %rdi
	movl	%r13d, %edx
	callq	_memcpy
	jmp	LBB0_10
LBB0_8:
	testl	%eax, %eax
	je	LBB0_10
## %bb.9:
	movb	$0, (%r14)
LBB0_10:
	movl	%r13d, (%r15)
	movq	_D3DRM_OK@GOTPCREL(%rip), %rbx
LBB0_11:
	movl	(%rbx), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_E_INVALIDARG,4,2               ## @E_INVALIDARG
	.comm	_D3DRM_OK,4,2                   ## @D3DRM_OK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_d3drm_object_get_name          ; -- Begin function d3drm_object_get_name
	.p2align	2
_d3drm_object_get_name:                 ; @d3drm_object_get_name
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	cbz	x1, LBB0_5
; %bb.1:
	mov	x20, x2
	mov	x19, x1
	mov	x22, x0
	ldr	x0, [x0]
	cbz	x0, LBB0_3
; %bb.2:
	bl	_strlen
	add	w21, w0, #1
	cbnz	x20, LBB0_4
	b	LBB0_10
LBB0_3:
	mov	w21, #0
	cbz	x20, LBB0_10
LBB0_4:
	ldr	w8, [x19]
	cmp	w8, w21
	b.ge	LBB0_6
LBB0_5:
Lloh0:
	adrp	x8, _E_INVALIDARG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _E_INVALIDARG@GOTPAGEOFF]
	b	LBB0_11
LBB0_6:
	ldr	x1, [x22]
	cbz	x1, LBB0_8
; %bb.7:
	mov	x0, x20
	mov	x2, x21
	bl	_memcpy
	b	LBB0_10
LBB0_8:
	cbz	w8, LBB0_10
; %bb.9:
	strb	wzr, [x20]
LBB0_10:
	str	w21, [x19]
Lloh2:
	adrp	x8, _D3DRM_OK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _D3DRM_OK@GOTPAGEOFF]
LBB0_11:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.comm	_E_INVALIDARG,4,2               ; @E_INVALIDARG
	.comm	_D3DRM_OK,4,2                   ; @D3DRM_OK
.subsections_via_symbols
