	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_lkdtm_WRITE_BUDDY_AFTER_FREE   ## -- Begin function lkdtm_WRITE_BUDDY_AFTER_FREE
	.p2align	4, 0x90
_lkdtm_WRITE_BUDDY_AFTER_FREE:          ## @lkdtm_WRITE_BUDDY_AFTER_FREE
	.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	_GFP_KERNEL@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	callq	___get_free_page
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	leaq	L_.str.1(%rip), %rdi
	callq	_pr_info
	movq	_PAGE_SIZE@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	movq	%rbx, %rdi
	movl	$3, %esi
	callq	_memset
	movq	%rbx, %rdi
	callq	_free_page
	xorl	%eax, %eax
	callq	_schedule
	leaq	L_.str.2(%rip), %rdi
	callq	_pr_info
	movl	(%r15), %edx
	movq	%rbx, %rdi
	movl	$120, %esi
	callq	_memset
	movl	(%r14), %edi
	callq	___get_free_page
	movq	%rax, %rdi
	callq	_free_page
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_schedule                       ## TAILCALL
LBB0_1:
	leaq	L_.str(%rip), %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pr_info                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Unable to allocate free page\n"

L_.str.1:                               ## @.str.1
	.asciz	"Writing to the buddy page before free\n"

	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
L_.str.2:                               ## @.str.2
	.asciz	"Attempting bad write to the buddy page after free\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_lkdtm_WRITE_BUDDY_AFTER_FREE   ; -- Begin function lkdtm_WRITE_BUDDY_AFTER_FREE
	.p2align	2
_lkdtm_WRITE_BUDDY_AFTER_FREE:          ; @lkdtm_WRITE_BUDDY_AFTER_FREE
	.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
Lloh0:
	adrp	x20, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x20, [x20, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w0, [x20]
	bl	___get_free_page
	cbz	x0, LBB0_2
; %bb.1:
	mov	x19, x0
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pr_info
Lloh4:
	adrp	x21, _PAGE_SIZE@GOTPAGE
Lloh5:
	ldr	x21, [x21, _PAGE_SIZE@GOTPAGEOFF]
	ldr	w2, [x21]
	mov	x0, x19
	mov	w1, #3
	bl	_memset
	mov	x0, x19
	bl	_free_page
	bl	_schedule
Lloh6:
	adrp	x0, l_.str.2@PAGE
Lloh7:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_pr_info
	ldr	w2, [x21]
	mov	x0, x19
	mov	w1, #120
	bl	_memset
	ldr	w0, [x20]
	bl	___get_free_page
	bl	_free_page
	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
	b	_schedule
LBB0_2:
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	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
	b	_pr_info
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Unable to allocate free page\n"

l_.str.1:                               ; @.str.1
	.asciz	"Writing to the buddy page before free\n"

	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
l_.str.2:                               ; @.str.2
	.asciz	"Attempting bad write to the buddy page after free\n"

.subsections_via_symbols
