	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_P_SpawnMobj                    ## -- Begin function P_SpawnMobj
	.p2align	4, 0x90
_P_SpawnMobj:                           ## @P_SpawnMobj
	.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	%rcx, %r12
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	movq	%rsi, %r15
	movq	%rdi, %r13
	movq	_PU_LEVEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$136, %edi
	xorl	%edx, %edx
	callq	_Z_Malloc
	movq	%rax, %rbx
	movq	%rax, %rdi
	xorl	%esi, %esi
	movl	$136, %edx
	callq	_memset
	movq	_mobjinfo@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%r12, %rcx
	shlq	$5, %rcx
	leaq	(%rax,%rcx), %r14
	movq	%r12, (%rbx)
	movq	%r14, 32(%rbx)
	movq	%r13, 128(%rbx)
	movq	%r15, 120(%rbx)
	movl	28(%rax,%rcx), %edx
	movl	%edx, 112(%rbx)
	movq	8(%rax,%rcx), %rdx
	movq	%rdx, 104(%rbx)
	movl	24(%rax,%rcx), %edx
	movl	%edx, 96(%rbx)
	movl	20(%rax,%rcx), %edx
	movl	%edx, 92(%rbx)
	movq	_gameskill@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	_sk_nightmare@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rdx
	je	LBB0_2
## %bb.1:
	movl	16(%rax,%rcx), %eax
	movl	%eax, 88(%rbx)
LBB0_2:
	xorl	%eax, %eax
	callq	_P_Random
	movq	_MAXPLAYERS@GOTPCREL(%rip), %rcx
	cltd
	idivl	(%rcx)
	movl	%edx, 8(%rbx)
	movq	_states@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%r14), %rcx
	leaq	(%rcx,%rcx,2), %rcx
	leaq	(%rax,%rcx,4), %rdx
	movq	%rdx, 80(%rbx)
	movl	8(%rax,%rcx,4), %edx
	movl	%edx, 72(%rbx)
	movl	4(%rax,%rcx,4), %edx
	movl	%edx, 68(%rbx)
	movl	(%rax,%rcx,4), %eax
	movl	%eax, 64(%rbx)
	movq	%rbx, %rdi
	callq	_P_SetThingPosition
	movq	56(%rbx), %rax
	movq	(%rax), %rax
	movq	8(%rax), %rcx
	movq	%rcx, 48(%rbx)
	movq	(%rax), %rax
	movq	%rax, 40(%rbx)
	movq	_ONFLOORZ@GOTPCREL(%rip), %rdx
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	cmpq	%rsi, (%rdx)
	je	LBB0_5
## %bb.3:
	movq	_ONCEILINGZ@GOTPCREL(%rip), %rdx
	movq	%rsi, %rcx
	cmpq	%rsi, (%rdx)
	jne	LBB0_5
## %bb.4:
	movq	32(%rbx), %rcx
	subq	8(%rcx), %rax
	movq	%rax, %rcx
LBB0_5:
	movq	%rcx, 24(%rbx)
	movq	_P_MobjThinker@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rbx, %rdi
	addq	$16, %rdi
	movq	%rax, 16(%rbx)
	callq	_P_AddThinker
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PU_LEVEL,4,2                   ## @PU_LEVEL
	.comm	_mobjinfo,8,3                   ## @mobjinfo
	.comm	_gameskill,8,3                  ## @gameskill
	.comm	_sk_nightmare,8,3               ## @sk_nightmare
	.comm	_MAXPLAYERS,4,2                 ## @MAXPLAYERS
	.comm	_states,8,3                     ## @states
	.comm	_ONFLOORZ,8,3                   ## @ONFLOORZ
	.comm	_ONCEILINGZ,8,3                 ## @ONCEILINGZ
	.comm	_P_MobjThinker,8,3              ## @P_MobjThinker
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_P_SpawnMobj                    ; -- Begin function P_SpawnMobj
	.p2align	2
_P_SpawnMobj:                           ; @P_SpawnMobj
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x3
	mov	x20, x2
	mov	x22, x1
	mov	x23, x0
Lloh0:
	adrp	x8, _PU_LEVEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PU_LEVEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #136
	mov	x2, #0
	bl	_Z_Malloc
	mov	x19, x0
	mov	w1, #0
	mov	w2, #136
	bl	_memset
Lloh3:
	adrp	x8, _mobjinfo@GOTPAGE
Lloh4:
	ldr	x8, [x8, _mobjinfo@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	add	x24, x8, x21, lsl #5
	str	x21, [x19]
	str	x24, [x19, #32]
	stp	x22, x23, [x19, #120]
	ldr	w8, [x24, #28]
	str	w8, [x19, #112]
	ldr	x8, [x24, #8]
	str	x8, [x19, #104]
	ldur	d0, [x24, #20]
Lloh6:
	adrp	x8, _gameskill@GOTPAGE
Lloh7:
	ldr	x8, [x8, _gameskill@GOTPAGEOFF]
	stur	d0, [x19, #92]
Lloh8:
	ldr	x8, [x8]
Lloh9:
	adrp	x9, _sk_nightmare@GOTPAGE
Lloh10:
	ldr	x9, [x9, _sk_nightmare@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_2
; %bb.1:
	ldr	w8, [x24, #16]
	str	w8, [x19, #88]
LBB0_2:
	bl	_P_Random
Lloh12:
	adrp	x8, _MAXPLAYERS@GOTPAGE
Lloh13:
	ldr	x8, [x8, _MAXPLAYERS@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	sdiv	w9, w0, w8
	msub	w8, w9, w8, w0
	str	w8, [x19, #8]
Lloh15:
	adrp	x8, _states@GOTPAGE
Lloh16:
	ldr	x8, [x8, _states@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	ldr	x9, [x24]
	mov	w10, #12
	madd	x8, x9, x10, x8
	str	x8, [x19, #80]
	ldr	w9, [x8, #8]
	str	w9, [x19, #72]
	ldr	d0, [x8]
	str	d0, [x19, #64]
	mov	x0, x19
	bl	_P_SetThingPosition
	ldr	x8, [x19, #56]
	ldr	x9, [x8]
	ldp	x9, x8, [x9]
	stp	x9, x8, [x19, #40]
Lloh18:
	adrp	x10, _ONFLOORZ@GOTPAGE
Lloh19:
	ldr	x10, [x10, _ONFLOORZ@GOTPAGEOFF]
Lloh20:
	ldr	x10, [x10]
	cmp	x10, x20
	b.eq	LBB0_5
; %bb.3:
Lloh21:
	adrp	x8, _ONCEILINGZ@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ONCEILINGZ@GOTPAGEOFF]
Lloh23:
	ldr	x10, [x8]
	mov	x8, x20
	cmp	x10, x20
	b.ne	LBB0_5
; %bb.4:
	ldr	x8, [x19, #32]
	ldr	x8, [x8, #8]
	sub	x8, x9, x8
LBB0_5:
	str	x8, [x19, #24]
Lloh24:
	adrp	x8, _P_MobjThinker@GOTPAGE
Lloh25:
	ldr	x8, [x8, _P_MobjThinker@GOTPAGEOFF]
Lloh26:
	ldr	x8, [x8]
	mov	x0, x19
	str	x8, [x0, #16]!
	bl	_P_AddThinker
	mov	x0, x19
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_PU_LEVEL,4,2                   ; @PU_LEVEL
	.comm	_mobjinfo,8,3                   ; @mobjinfo
	.comm	_gameskill,8,3                  ; @gameskill
	.comm	_sk_nightmare,8,3               ; @sk_nightmare
	.comm	_MAXPLAYERS,4,2                 ; @MAXPLAYERS
	.comm	_states,8,3                     ; @states
	.comm	_ONFLOORZ,8,3                   ; @ONFLOORZ
	.comm	_ONCEILINGZ,8,3                 ; @ONCEILINGZ
	.comm	_P_MobjThinker,8,3              ; @P_MobjThinker
.subsections_via_symbols
