	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function set_ad_sump
LCPI0_0:
	.quad	0x3df0000000000000              ## double 2.3283064365386963E-10
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_set_ad_sump:                           ## @set_ad_sump
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_targeting_disabled@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	cmpq	$0, (%rcx)
	jne	LBB0_7
## %bb.1:
	movq	%rdi, %rbx
	movl	32(%rdi), %edi
	xorl	%r15d, %r15d
	xorl	%esi, %esi
	callq	_get_ad_f
	movq	%rax, %r14
	movl	$0, %edi
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	xorl	%edi, %edi
	cmpq	$0, (%r14)
	setg	%dil
LBB0_3:
	callq	_assert
	movq	(%rbx), %rax
	movq	_LEV_TARG_AD_SETSUMP@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_assert
	cmpq	$0, 8(%rbx)
	js	LBB0_6
## %bb.4:
	cmpq	$0, 16(%rbx)
	js	LBB0_6
## %bb.5:
	movq	24(%rbx), %r15
	shrq	$63, %r15
	xorl	$1, %r15d
LBB0_6:
	movl	%r15d, %edi
	callq	_assert
	cvtsi2sdq	8(%rbx), %xmm0
	movsd	LCPI0_0(%rip), %xmm1            ## xmm1 = mem[0],zero
	mulsd	%xmm1, %xmm0
	movsd	%xmm0, 8(%r14)
	xorps	%xmm0, %xmm0
	cvtsi2sdq	16(%rbx), %xmm0
	mulsd	%xmm1, %xmm0
	movsd	%xmm0, 16(%r14)
	xorps	%xmm0, %xmm0
	cvtsi2sdq	24(%rbx), %xmm0
	mulsd	%xmm1, %xmm0
	movsd	%xmm0, 24(%r14)
	movq	%r14, %rdi
	callq	_compute_estimated_gain
	movl	$1, %eax
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_targeting_disabled,8,3         ## @targeting_disabled
	.comm	_LEV_TARG_AD_SETSUMP,8,3        ## @LEV_TARG_AD_SETSUMP
	.no_dead_strip	_set_ad_sump
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_ad_sump
_set_ad_sump:                           ; @set_ad_sump
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
Lloh0:
	adrp	x8, _targeting_disabled@GOTPAGE
Lloh1:
	ldr	x8, [x8, _targeting_disabled@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cbz	x8, LBB0_2
; %bb.1:
	mov	w0, #0
	b	LBB0_9
LBB0_2:
	mov	x19, x0
	ldr	w0, [x0, #32]
	mov	w1, #0
	bl	_get_ad_f
	mov	x20, x0
	cbz	x0, LBB0_4
; %bb.3:
	ldr	x8, [x20]
	cmp	x8, #0
	cset	w0, gt
LBB0_4:
	bl	_assert
	ldr	x8, [x19]
Lloh3:
	adrp	x9, _LEV_TARG_AD_SETSUMP@GOTPAGE
Lloh4:
	ldr	x9, [x9, _LEV_TARG_AD_SETSUMP@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, eq
	bl	_assert
	ldr	x8, [x19, #8]
	tbnz	x8, #63, LBB0_7
; %bb.5:
	ldr	x8, [x19, #16]
	tbnz	x8, #63, LBB0_7
; %bb.6:
	ldr	x8, [x19, #24]
	lsr	x8, x8, #63
	eor	w0, w8, #0x1
	b	LBB0_8
LBB0_7:
	mov	w0, #0
LBB0_8:
	bl	_assert
	ldur	q0, [x19, #8]
	scvtf.2d	v0, v0
	mov	x8, #4463067230724161536
	dup.2d	v1, x8
	fmul.2d	v0, v0, v1
	stur	q0, [x20, #8]
	ldr	d0, [x19, #24]
	scvtf	d0, d0
	fmov	d1, x8
	fmul	d0, d0, d1
	str	d0, [x20, #24]
	mov	x0, x20
	bl	_compute_estimated_gain
	mov	w0, #1
LBB0_9:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_targeting_disabled,8,3         ; @targeting_disabled
	.comm	_LEV_TARG_AD_SETSUMP,8,3        ; @LEV_TARG_AD_SETSUMP
	.no_dead_strip	_set_ad_sump
.subsections_via_symbols
