	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_A_BrainScream                  ## -- Begin function A_BrainScream
	.p2align	4, 0x90
_A_BrainScream:                         ## @A_BrainScream
	.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
	movl	(%rdi), %ecx
	movq	_FRACUNIT@GOTPCREL(%rip), %r12
	movl	(%r12), %eax
	imull	$-196, %eax, %r15d
	addl	%ecx, %r15d
	shll	$6, %eax
	leal	(%rax,%rax,4), %eax
	addl	%eax, %ecx
	cmpl	%ecx, %r15d
	jge	LBB0_3
## %bb.1:
	movq	%rdi, %r14
	movl	$1, %r13d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	4(%r14), %ebx
	subl	%eax, %ebx
	xorl	%eax, %eax
	callq	_P_Random
                                        ## kill: def $eax killed $eax def $rax
	imull	(%r12), %eax
	leal	(%rax,%rax), %edx
	addl	$128, %edx
	movq	_MT_ROCKET@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%r15d, %edi
	movl	%ebx, %esi
	callq	_P_SpawnMobj
	movq	%rax, %rbx
	xorl	%eax, %eax
	callq	_P_Random
	shll	$9, %eax
	movl	%eax, 8(%rbx)
	movq	_S_BRAINEXPLODE1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_P_SetMobjState
	xorl	%eax, %eax
	callq	_P_Random
	andl	$7, %eax
	movl	12(%rbx), %ecx
	subl	%eax, %ecx
	cmpl	$2, %ecx
	cmovll	%r13d, %ecx
	movl	%ecx, 12(%rbx)
	movl	(%r12), %eax
	leal	(%r15,%rax,8), %r15d
	shll	$6, %eax
	leal	(%rax,%rax,4), %eax
	movl	(%r14), %ecx
	addl	%eax, %ecx
	cmpl	%ecx, %r15d
	jl	LBB0_2
LBB0_3:
	movq	_sfx_bosdth@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edi, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_S_StartSound                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_FRACUNIT,4,2                   ## @FRACUNIT
	.comm	_MT_ROCKET,4,2                  ## @MT_ROCKET
	.comm	_S_BRAINEXPLODE1,4,2            ## @S_BRAINEXPLODE1
	.comm	_sfx_bosdth,4,2                 ## @sfx_bosdth
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_A_BrainScream                  ; -- Begin function A_BrainScream
	.p2align	2
_A_BrainScream:                         ; @A_BrainScream
	.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
	ldr	w9, [x0]
Lloh0:
	adrp	x22, _FRACUNIT@GOTPAGE
Lloh1:
	ldr	x22, [x22, _FRACUNIT@GOTPAGEOFF]
	ldr	w8, [x22]
	mov	w10, #-196
	madd	w20, w8, w10, w9
	add	w8, w8, w8, lsl #2
	lsl	w8, w8, #6
	add	w9, w8, w9
	cmp	w20, w9
	b.ge	LBB0_3
; %bb.1:
	mov	x19, x0
Lloh2:
	adrp	x23, _MT_ROCKET@GOTPAGE
Lloh3:
	ldr	x23, [x23, _MT_ROCKET@GOTPAGEOFF]
Lloh4:
	adrp	x24, _S_BRAINEXPLODE1@GOTPAGE
Lloh5:
	ldr	x24, [x24, _S_BRAINEXPLODE1@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w9, [x19, #4]
	sub	w21, w9, w8
	bl	_P_Random
	ldr	w8, [x22]
	mul	w8, w0, w8
	lsl	w8, w8, #1
	add	w2, w8, #128
	ldr	w3, [x23]
	mov	x0, x20
	mov	x1, x21
	bl	_P_SpawnMobj
	mov	x21, x0
	bl	_P_Random
	lsl	w8, w0, #9
	str	w8, [x21, #8]
	ldr	w1, [x24]
	mov	x0, x21
	bl	_P_SetMobjState
	bl	_P_Random
	and	w8, w0, #0x7
	ldr	w9, [x21, #12]
	sub	w8, w9, w8
	cmp	w8, #1
	csinc	w8, w8, wzr, gt
	str	w8, [x21, #12]
	ldr	w8, [x22]
	add	w20, w20, w8, lsl #3
	ldr	w9, [x19]
	add	w8, w8, w8, lsl #2
	lsl	w8, w8, #6
	add	w9, w8, w9
	cmp	w20, w9
	b.lt	LBB0_2
LBB0_3:
Lloh6:
	adrp	x8, _sfx_bosdth@GOTPAGE
Lloh7:
	ldr	x8, [x8, _sfx_bosdth@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, #0
	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
	b	_S_StartSound
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_FRACUNIT,4,2                   ; @FRACUNIT
	.comm	_MT_ROCKET,4,2                  ; @MT_ROCKET
	.comm	_S_BRAINEXPLODE1,4,2            ; @S_BRAINEXPLODE1
	.comm	_sfx_bosdth,4,2                 ; @sfx_bosdth
.subsections_via_symbols
