	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_D3D9BaseObject_GetDeviceInt    ## -- Begin function D3D9BaseObject_GetDeviceInt
	.p2align	4, 0x90
_D3D9BaseObject_GetDeviceInt:           ## @D3D9BaseObject_GetDeviceInt
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	testq	%rsi, %rsi
	je	LBB0_1
## %bb.2:
	movq	%rsi, %rbx
	movq	$0, (%rsi)
	movq	(%rdi), %rdi
	testq	%rdi, %rdi
	je	LBB0_5
## %bb.3:
	movq	_IID_IDirect3DDevice9@GOTPCREL(%rip), %rsi
	leaq	-12(%rbp), %rdx
	callq	_IUnknown_QueryInterface
	movl	%eax, %edi
	callq	_FAILED
	testq	%rax, %rax
	je	LBB0_4
LBB0_5:
	movq	_E_NOINTERFACE@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_1:
	movq	_D3DERR_INVALIDCALL@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_4:
	movl	-12(%rbp), %edi
	callq	_IDirect3DDevice9ToImpl
	movq	%rax, (%rbx)
	movq	_D3D_OK@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_D3DERR_INVALIDCALL,4,2         ## @D3DERR_INVALIDCALL
	.comm	_IID_IDirect3DDevice9,4,2       ## @IID_IDirect3DDevice9
	.comm	_E_NOINTERFACE,4,2              ## @E_NOINTERFACE
	.comm	_D3D_OK,4,2                     ## @D3D_OK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_D3D9BaseObject_GetDeviceInt    ; -- Begin function D3D9BaseObject_GetDeviceInt
	.p2align	2
_D3D9BaseObject_GetDeviceInt:           ; @D3D9BaseObject_GetDeviceInt
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	cbz	x1, LBB0_4
; %bb.1:
	mov	x19, x1
	str	xzr, [x1]
	ldr	x0, [x0]
	cbz	x0, LBB0_3
; %bb.2:
Lloh0:
	adrp	x1, _IID_IDirect3DDevice9@GOTPAGE
Lloh1:
	ldr	x1, [x1, _IID_IDirect3DDevice9@GOTPAGEOFF]
	add	x2, sp, #12
	bl	_IUnknown_QueryInterface
	bl	_FAILED
	cbz	x0, LBB0_5
LBB0_3:
Lloh2:
	adrp	x8, _E_NOINTERFACE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _E_NOINTERFACE@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:
Lloh4:
	adrp	x8, _D3DERR_INVALIDCALL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _D3DERR_INVALIDCALL@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:
	ldr	w0, [sp, #12]
	bl	_IDirect3DDevice9ToImpl
	str	x0, [x19]
Lloh6:
	adrp	x8, _D3D_OK@GOTPAGE
Lloh7:
	ldr	x8, [x8, _D3D_OK@GOTPAGEOFF]
LBB0_6:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_D3DERR_INVALIDCALL,4,2         ; @D3DERR_INVALIDCALL
	.comm	_IID_IDirect3DDevice9,4,2       ; @IID_IDirect3DDevice9
	.comm	_E_NOINTERFACE,4,2              ; @E_NOINTERFACE
	.comm	_D3D_OK,4,2                     ; @D3D_OK
.subsections_via_symbols
