	.file	"67325548.c"
	.intel_syntax noprefix
	.text
	.globl	separator
	.section	.rodata
	.align 32
	.type	separator, @object
	.size	separator, 53
separator:
	.string	"----------------------------------------------------"
	.align 8
.LC0:
	.string	"failed to allocate memory for buddy allocator"
	.text
	.globl	buddy_allocator_create
	.type	buddy_allocator_create, @function
buddy_allocator_create:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	mov	edi, 48
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L2
	lea	rdi, .LC0[rip]
	call	puts@PLT
	jmp	.L3
.L2:
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	mov	QWORD PTR [rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -32[rbp]
	mov	QWORD PTR 8[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -32[rbp]
	mov	QWORD PTR 24[rax], rdx
.L3:
	mov	rax, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	buddy_allocator_create, .-buddy_allocator_create
	.globl	buddy_allocator_destroy
	.type	buddy_allocator_destroy, @function
buddy_allocator_destroy:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	QWORD PTR -8[rbp], rdi
	cmp	QWORD PTR -8[rbp], 0
	je	.L8
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	free@PLT
	nop
.L8:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	buddy_allocator_destroy, .-buddy_allocator_destroy
	.globl	allocRecurse
	.type	allocRecurse, @function
allocRecurse:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 88
	.cfi_offset 3, -24
	mov	QWORD PTR -72[rbp], rdi
	mov	QWORD PTR -80[rbp], rsi
	mov	DWORD PTR -84[rbp], edx
	mov	QWORD PTR -96[rbp], rcx
	mov	BYTE PTR -48[rbp], 0
	mov	QWORD PTR -40[rbp], 0
	mov	QWORD PTR -24[rbp], 0
	cmp	DWORD PTR -84[rbp], 4
	jg	.L10
	cmp	QWORD PTR -80[rbp], 0
	jne	.L11
.L10:
	mov	BYTE PTR -48[rbp], 0
	mov	rax, QWORD PTR -48[rbp]
	mov	rdx, QWORD PTR -40[rbp]
	jmp	.L25
.L11:
	mov	rax, QWORD PTR -72[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	edx, DWORD PTR -84[rbp]
	sub	edx, 1
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	movsx	rbx, edx
	mov	edx, 0
	div	rbx
	mov	QWORD PTR -64[rbp], rax
	mov	rax, QWORD PTR -72[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	edx, DWORD PTR -84[rbp]
	sub	edx, 1
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	add	edx, edx
	movsx	rbx, edx
	mov	edx, 0
	div	rbx
	mov	QWORD PTR -56[rbp], rax
	mov	rax, QWORD PTR -56[rbp]
	cmp	rax, QWORD PTR -80[rbp]
	jnb	.L13
	mov	rax, QWORD PTR -80[rbp]
	cmp	rax, QWORD PTR -64[rbp]
	jbe	.L14
.L13:
	cmp	DWORD PTR -84[rbp], 4
	jne	.L15
	mov	rax, QWORD PTR -80[rbp]
	cmp	rax, QWORD PTR -56[rbp]
	ja	.L15
.L14:
	mov	rax, QWORD PTR -96[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -72[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -96[rbp]
	add	rax, rax
	sub	rax, 1
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L16
	mov	rax, QWORD PTR -96[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, rax
	mov	rax, QWORD PTR -72[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -96[rbp]
	sub	rax, 1
	add	rax, rax
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L16
	mov	BYTE PTR -48[rbp], 0
	mov	rax, QWORD PTR -48[rbp]
	mov	rdx, QWORD PTR -40[rbp]
	jmp	.L25
.L16:
	mov	rax, QWORD PTR -96[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, QWORD PTR -72[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -96[rbp]
	add	rdx, rdx
	sub	rdx, 1
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	or	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -72[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -72[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
	je	.L18
	mov	rax, QWORD PTR -96[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, QWORD PTR -72[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -96[rbp]
	sub	rdx, 1
	add	rdx, rdx
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	or	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -72[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -72[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
.L18:
	mov	BYTE PTR -48[rbp], 1
	mov	rax, QWORD PTR -72[rbp]
	mov	rdx, QWORD PTR 32[rax]
	mov	rax, QWORD PTR -80[rbp]
	add	rdx, rax
	mov	rax, QWORD PTR -72[rbp]
	mov	QWORD PTR 32[rax], rdx
	mov	rax, QWORD PTR -72[rbp]
	mov	rdx, QWORD PTR 16[rax]
	mov	rax, QWORD PTR -64[rbp]
	add	rdx, rax
	mov	rax, QWORD PTR -72[rbp]
	mov	QWORD PTR 16[rax], rdx
	mov	rax, QWORD PTR -72[rbp]
	mov	rax, QWORD PTR 24[rax]
	sub	rax, QWORD PTR -64[rbp]
	mov	rdx, rax
	mov	rax, QWORD PTR -72[rbp]
	mov	QWORD PTR 24[rax], rdx
	mov	rax, QWORD PTR -48[rbp]
	mov	rdx, QWORD PTR -40[rbp]
	jmp	.L25
.L15:
	mov	rax, QWORD PTR -96[rbp]
	lea	rcx, [rax+rax]
	mov	eax, DWORD PTR -84[rbp]
	lea	edx, 1[rax]
	mov	rsi, QWORD PTR -80[rbp]
	mov	rax, QWORD PTR -72[rbp]
	mov	rdi, rax
	call	allocRecurse
	mov	ecx, eax
	mov	rax, rdx
	mov	DWORD PTR -32[rbp], ecx
	mov	QWORD PTR -24[rbp], rax
	movzx	eax, BYTE PTR -32[rbp]
	xor	eax, 1
	test	al, al
	je	.L19
	mov	rax, QWORD PTR -96[rbp]
	add	rax, rax
	lea	rcx, 1[rax]
	mov	eax, DWORD PTR -84[rbp]
	lea	edx, 1[rax]
	mov	rsi, QWORD PTR -80[rbp]
	mov	rax, QWORD PTR -72[rbp]
	mov	rdi, rax
	call	allocRecurse
	mov	ecx, eax
	mov	rax, rdx
	mov	DWORD PTR -32[rbp], ecx
	mov	QWORD PTR -24[rbp], rax
	movzx	eax, BYTE PTR -32[rbp]
	xor	eax, 1
	test	al, al
	je	.L20
	mov	rax, QWORD PTR -32[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	jmp	.L25
.L20:
	mov	rax, QWORD PTR -96[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, QWORD PTR -72[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -96[rbp]
	add	rdx, rdx
	sub	rdx, 1
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	or	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -72[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -72[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
	je	.L22
	mov	rax, QWORD PTR -96[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, QWORD PTR -72[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -96[rbp]
	sub	rdx, 1
	add	rdx, rdx
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	not	edx
	and	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -72[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -72[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
.L22:
	mov	rsi, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -72[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	edx, DWORD PTR -84[rbp]
	mov	edi, 1
	mov	ecx, edx
	sal	edi, cl
	mov	edx, edi
	movsx	rbx, edx
	mov	edx, 0
	div	rbx
	add	rax, rsi
	mov	QWORD PTR -24[rbp], rax
	mov	rax, QWORD PTR -32[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	jmp	.L25
.L19:
	mov	rax, QWORD PTR -96[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, QWORD PTR -72[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -96[rbp]
	add	rdx, rdx
	sub	rdx, 1
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	or	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -72[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -72[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
	je	.L24
	mov	rax, QWORD PTR -96[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, QWORD PTR -72[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -96[rbp]
	sub	rdx, 1
	add	rdx, rdx
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	not	edx
	and	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -72[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -72[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
.L24:
	mov	rax, QWORD PTR -32[rbp]
	mov	rdx, QWORD PTR -24[rbp]
.L25:
	mov	rcx, rax
	mov	rbx, rdx
	mov	eax, ecx
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	allocRecurse, .-allocRecurse
	.globl	freeRecurse
	.type	freeRecurse, @function
freeRecurse:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	QWORD PTR -40[rbp], rdi
	mov	QWORD PTR -48[rbp], rsi
	mov	DWORD PTR -52[rbp], edx
	mov	QWORD PTR -64[rbp], rcx
	cmp	DWORD PTR -52[rbp], 4
	jle	.L27
	mov	BYTE PTR -17[rbp], 0
	movzx	eax, BYTE PTR -17[rbp]
	jmp	.L26
.L27:
	mov	rax, QWORD PTR -40[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	edx, DWORD PTR -52[rbp]
	sub	edx, 1
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	add	edx, edx
	movsx	rdi, edx
	mov	edx, 0
	div	rdi
	mov	QWORD PTR -16[rbp], rax
	mov	rax, QWORD PTR -40[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	edx, DWORD PTR -52[rbp]
	sub	edx, 1
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	movsx	rdi, edx
	mov	edx, 0
	div	rdi
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -48[rbp]
	cmp	rax, QWORD PTR -8[rbp]
	ja	.L29
	mov	rax, QWORD PTR -48[rbp]
	cmp	rax, QWORD PTR -16[rbp]
	jbe	.L29
	mov	rax, QWORD PTR -48[rbp]
	mov	edx, 0
	div	QWORD PTR -16[rbp]
	mov	rax, rdx
	test	rax, rax
	jne	.L29
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L30
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	add	rax, rax
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L30
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, QWORD PTR -40[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -64[rbp]
	add	rdx, rdx
	sub	rdx, 1
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	not	edx
	and	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -40[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
	je	.L32
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, QWORD PTR -40[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -64[rbp]
	sub	rdx, 1
	add	rdx, rdx
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	not	edx
	and	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -40[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
.L32:
	mov	BYTE PTR -17[rbp], 1
	mov	rax, QWORD PTR -40[rbp]
	mov	rax, QWORD PTR 16[rax]
	sub	rax, QWORD PTR -8[rbp]
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	mov	QWORD PTR 16[rax], rdx
	mov	rax, QWORD PTR -40[rbp]
	mov	rdx, QWORD PTR 24[rax]
	mov	rax, QWORD PTR -8[rbp]
	add	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	mov	QWORD PTR 24[rax], rdx
	movzx	eax, BYTE PTR -17[rbp]
	jmp	.L26
.L30:
	mov	rax, QWORD PTR -64[rbp]
	lea	rcx, [rax+rax]
	mov	eax, DWORD PTR -52[rbp]
	lea	edx, 1[rax]
	mov	rsi, QWORD PTR -48[rbp]
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	freeRecurse
	mov	BYTE PTR -17[rbp], al
	movzx	eax, BYTE PTR -17[rbp]
	xor	eax, 1
	test	al, al
	je	.L33
	mov	rax, QWORD PTR -48[rbp]
	cmp	rax, QWORD PTR -16[rbp]
	jb	.L33
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	lea	rcx, 1[rax]
	mov	eax, DWORD PTR -52[rbp]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -48[rbp]
	sub	rax, QWORD PTR -16[rbp]
	mov	rsi, rax
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	freeRecurse
	mov	BYTE PTR -17[rbp], al
.L33:
	movzx	eax, BYTE PTR -17[rbp]
	test	al, al
	je	.L34
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	sub	rax, 1
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	jne	.L34
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	sub	rax, 2
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	sub	rax, 2
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	jne	.L34
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	add	rax, 1
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	add	rax, 1
	add	rax, rax
	sub	rax, 1
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	jne	.L34
	mov	rax, QWORD PTR -64[rbp]
	mov	rdx, rax
	shr	rdx, 63
	add	rax, rdx
	sar	rax
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	jne	.L34
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, QWORD PTR -40[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -64[rbp]
	add	rdx, rdx
	sub	rdx, 1
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	not	edx
	and	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -40[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
	je	.L34
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, QWORD PTR -40[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -64[rbp]
	sub	rdx, 1
	add	rdx, rdx
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	not	edx
	and	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -40[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
.L34:
	movzx	eax, BYTE PTR -17[rbp]
	jmp	.L26
.L29:
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L36
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	add	rax, rax
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L37
.L36:
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L38
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	add	rax, rax
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L38
.L37:
	mov	rax, QWORD PTR -64[rbp]
	lea	rcx, [rax+rax]
	mov	eax, DWORD PTR -52[rbp]
	lea	edx, 1[rax]
	mov	rsi, QWORD PTR -48[rbp]
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	freeRecurse
	mov	BYTE PTR -17[rbp], al
	movzx	eax, BYTE PTR -17[rbp]
	xor	eax, 1
	test	al, al
	je	.L39
	mov	rax, QWORD PTR -48[rbp]
	cmp	rax, QWORD PTR -16[rbp]
	jb	.L39
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	lea	rcx, 1[rax]
	mov	eax, DWORD PTR -52[rbp]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -48[rbp]
	sub	rax, QWORD PTR -16[rbp]
	mov	rsi, rax
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	freeRecurse
	mov	BYTE PTR -17[rbp], al
.L39:
	movzx	eax, BYTE PTR -17[rbp]
	test	al, al
	je	.L40
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	sub	rax, 1
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	jne	.L40
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	sub	rax, 2
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	sub	rax, 2
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	jne	.L40
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	add	rax, 1
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	add	rax, 1
	add	rax, rax
	sub	rax, 1
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	jne	.L40
	mov	rax, QWORD PTR -64[rbp]
	mov	rdx, rax
	shr	rdx, 63
	add	rax, rdx
	sar	rax
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rax+rdx]
	movzx	edx, al
	mov	rax, QWORD PTR -64[rbp]
	sal	rax, 2
	mov	rcx, rax
	sar	rcx, 63
	shr	rcx, 61
	add	rax, rcx
	and	eax, 7
	sub	rax, rcx
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	jne	.L40
	mov	rax, QWORD PTR -64[rbp]
	add	rax, rax
	sub	rax, 1
	lea	rdx, 7[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 3
	mov	rdx, QWORD PTR -40[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -64[rbp]
	add	rdx, rdx
	sub	rdx, 1
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	not	edx
	and	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -40[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
	je	.L40
	mov	rax, QWORD PTR -64[rbp]
	sub	rax, 1
	lea	rdx, 3[rax]
	test	rax, rax
	cmovs	rax, rdx
	sar	rax, 2
	mov	rdx, QWORD PTR -40[rbp]
	movzx	edx, BYTE PTR 40[rdx+rax]
	mov	edi, edx
	mov	rdx, QWORD PTR -64[rbp]
	sub	rdx, 1
	add	rdx, rdx
	mov	rcx, rdx
	sar	rcx, 63
	shr	rcx, 61
	add	rdx, rcx
	and	edx, 7
	sub	rdx, rcx
	mov	esi, 1
	mov	ecx, edx
	sal	esi, cl
	mov	edx, esi
	not	edx
	and	edx, edi
	mov	ecx, edx
	mov	rdx, QWORD PTR -40[rbp]
	mov	BYTE PTR 40[rdx+rax], cl
	mov	rdx, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
.L40:
	movzx	eax, BYTE PTR -17[rbp]
	jmp	.L26
.L38:
.L26:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	freeRecurse, .-freeRecurse
	.globl	buddy_allocator_alloc
	.type	buddy_allocator_alloc, @function
buddy_allocator_alloc:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	mov	rsi, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, 1
	mov	edx, 1
	mov	rdi, rax
	call	allocRecurse
	mov	ecx, eax
	mov	rax, rdx
	mov	DWORD PTR -16[rbp], ecx
	mov	QWORD PTR -8[rbp], rax
	movzx	eax, BYTE PTR -16[rbp]
	test	al, al
	je	.L44
	mov	rax, QWORD PTR -24[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -8[rbp]
	add	rax, rdx
	jmp	.L46
.L44:
	mov	eax, 0
.L46:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	buddy_allocator_alloc, .-buddy_allocator_alloc
	.section	.rodata
.LC1:
	.string	"free on null requested\n"
	.align 8
.LC2:
	.string	"free on range not belonging to the allocator"
	.text
	.globl	buddy_allocator_free
	.type	buddy_allocator_free, @function
buddy_allocator_free:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	cmp	QWORD PTR -32[rbp], 0
	jne	.L48
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 23
	mov	esi, 1
	lea	rdi, .LC1[rip]
	call	fwrite@PLT
	jmp	.L47
.L48:
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR [rax]
	cmp	QWORD PTR -32[rbp], rax
	jb	.L50
	mov	rax, QWORD PTR -24[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR 8[rax]
	add	rax, rdx
	cmp	QWORD PTR -32[rbp], rax
	jb	.L51
.L50:
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 44
	mov	esi, 1
	lea	rdi, .LC2[rip]
	call	fwrite@PLT
	jmp	.L47
.L51:
	mov	rax, QWORD PTR -24[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -32[rbp]
	sub	rax, rdx
	mov	rsi, rax
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, 1
	mov	edx, 1
	mov	rdi, rax
	call	freeRecurse
.L47:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	buddy_allocator_free, .-buddy_allocator_free
	.section	.rodata
	.align 8
.LC3:
	.string	"start @%p\tsize:%zd\tinuse:%zd\trequessted:%zd\tfree:%zd\n"
.LC4:
	.string	"[%c%c%c%c%c%c%c%c],"
	.text
	.globl	buddy_allocator_print
	.type	buddy_allocator_print, @function
buddy_allocator_print:
.LFB12:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, QWORD PTR 24[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, QWORD PTR 32[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rcx, QWORD PTR 16[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rdx, QWORD PTR 8[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR [rax]
	mov	r9, rdi
	mov	r8, rsi
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -4[rbp], 3
	jmp	.L54
.L71:
	mov	rdx, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR 40[rdx+rax]
	movzx	eax, al
	and	eax, 1
	test	eax, eax
	je	.L55
	mov	r9d, 49
	jmp	.L56
.L55:
	mov	r9d, 48
.L56:
	mov	rdx, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR 40[rdx+rax]
	movzx	eax, al
	and	eax, 2
	test	eax, eax
	je	.L57
	mov	r8d, 49
	jmp	.L58
.L57:
	mov	r8d, 48
.L58:
	mov	rdx, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR 40[rdx+rax]
	movzx	eax, al
	and	eax, 4
	test	eax, eax
	je	.L59
	mov	edi, 49
	jmp	.L60
.L59:
	mov	edi, 48
.L60:
	mov	rdx, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR 40[rdx+rax]
	movzx	eax, al
	and	eax, 8
	test	eax, eax
	je	.L61
	mov	r11d, 49
	jmp	.L62
.L61:
	mov	r11d, 48
.L62:
	mov	rdx, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR 40[rdx+rax]
	movzx	eax, al
	and	eax, 16
	test	eax, eax
	je	.L63
	mov	r10d, 49
	jmp	.L64
.L63:
	mov	r10d, 48
.L64:
	mov	rdx, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR 40[rdx+rax]
	movzx	eax, al
	and	eax, 32
	test	eax, eax
	je	.L65
	mov	ecx, 49
	jmp	.L66
.L65:
	mov	ecx, 48
.L66:
	mov	rdx, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR 40[rdx+rax]
	movzx	eax, al
	and	eax, 64
	test	eax, eax
	je	.L67
	mov	esi, 49
	jmp	.L68
.L67:
	mov	esi, 48
.L68:
	mov	rdx, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR 40[rdx+rax]
	test	al, al
	jns	.L69
	mov	eax, 49
	jmp	.L70
.L69:
	mov	eax, 48
.L70:
	sub	rsp, 8
	push	r9
	push	r8
	push	rdi
	mov	r9d, r11d
	mov	r8d, r10d
	mov	edx, esi
	mov	esi, eax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	add	rsp, 32
	sub	DWORD PTR -4[rbp], 1
.L54:
	cmp	DWORD PTR -4[rbp], 0
	jns	.L71
	mov	edi, 10
	call	putchar@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	buddy_allocator_print, .-buddy_allocator_print
	.section	.rodata
	.align 8
.LC5:
	.string	"compiled for %d levels which provides %ld allocation cells\n"
.LC6:
	.string	" %c"
.LC7:
	.string	"how many?\n>"
.LC8:
	.string	" %zd"
.LC9:
	.string	"Alloc @ %p\n"
.LC10:
	.string	"which addr?\n>"
.LC11:
	.string	" %p"
	.align 8
.LC12:
	.string	"Q to quit, A to allocate, F to free, P to print"
	.text
	.globl	repl
	.type	repl, @function
repl:
.LFB13:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	QWORD PTR -56[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -40[rbp], 1
	mov	DWORD PTR -36[rbp], 0
	mov	QWORD PTR -16[rbp], 1
	jmp	.L73
.L74:
	sal	DWORD PTR -40[rbp]
	mov	eax, DWORD PTR -40[rbp]
	cdqe
	add	QWORD PTR -16[rbp], rax
.L73:
	add	DWORD PTR -36[rbp], 1
	cmp	DWORD PTR -36[rbp], 3
	jle	.L74
	mov	rax, QWORD PTR -16[rbp]
	mov	rdx, rax
	mov	esi, 4
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
.L82:
	mov	edi, 62
	call	putchar@PLT
	lea	rax, -41[rbp]
	mov	rsi, rax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	movzx	eax, BYTE PTR -41[rbp]
	movsx	eax, al
	cmp	eax, 81
	je	.L85
	cmp	eax, 81
	jg	.L76
	cmp	eax, 80
	je	.L77
	cmp	eax, 80
	jg	.L76
	cmp	eax, 65
	je	.L78
	cmp	eax, 70
	je	.L79
	jmp	.L76
.L78:
	lea	rdi, .LC7[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -32[rbp]
	mov	rsi, rax
	lea	rdi, .LC8[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	rax, QWORD PTR -32[rbp]
	mov	rdx, rax
	mov	rax, QWORD PTR -56[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	buddy_allocator_alloc
	mov	rsi, rax
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L81
.L79:
	lea	rdi, .LC10[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC11[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	rdx, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -56[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	buddy_allocator_free
	jmp	.L81
.L77:
	mov	rax, QWORD PTR -56[rbp]
	mov	rdi, rax
	call	buddy_allocator_print
	jmp	.L81
.L76:
	lea	rdi, .LC12[rip]
	call	puts@PLT
	nop
.L81:
	jmp	.L82
.L85:
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L84
	call	__stack_chk_fail@PLT
.L84:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	repl, .-repl
	.section	.rodata
.LC13:
	.string	"usage:budalloc bytenumber\n"
	.text
	.globl	usage
	.type	usage, @function
usage:
.LFB14:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 26
	mov	esi, 1
	lea	rdi, .LC13[rip]
	call	fwrite@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	usage, .-usage
	.section	.rodata
.LC14:
	.string	"num range"
.LC15:
	.string	"invalid arena size requested\n"
	.align 8
.LC16:
	.string	"failed to allocate %lld bytes\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB15:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	DWORD PTR -52[rbp], edi
	mov	QWORD PTR -64[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -52[rbp], 2
	je	.L88
	mov	eax, 0
	call	usage
	mov	eax, 1
	jmp	.L96
.L88:
	mov	rax, QWORD PTR -64[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rcx, -40[rbp]
	mov	edx, 10
	mov	rsi, rcx
	mov	rdi, rax
	call	strtoll@PLT
	mov	QWORD PTR -32[rbp], rax
	mov	rax, QWORD PTR -64[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	je	.L90
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	je	.L91
.L90:
	mov	eax, 0
	call	usage
.L91:
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 34
	jne	.L92
	movabs	rax, 9223372036854775807
	cmp	QWORD PTR -32[rbp], rax
	je	.L93
	movabs	rax, -9223372036854775808
	cmp	QWORD PTR -32[rbp], rax
	jne	.L92
.L93:
	lea	rdi, .LC14[rip]
	mov	eax, 0
	call	warnx@PLT
.L92:
	cmp	QWORD PTR -32[rbp], 0
	jg	.L94
	lea	rdi, .LC15[rip]
	mov	eax, 0
	call	warnx@PLT
.L94:
	mov	rax, QWORD PTR -32[rbp]
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR -24[rbp], rax
	cmp	QWORD PTR -24[rbp], 0
	jne	.L95
	mov	rax, QWORD PTR -32[rbp]
	mov	rsi, rax
	lea	rdi, .LC16[rip]
	mov	eax, 0
	call	warnx@PLT
.L95:
	mov	rdx, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	buddy_allocator_create
	mov	QWORD PTR -16[rbp], rax
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	repl
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	buddy_allocator_destroy
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	eax, 0
.L96:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L97
	call	__stack_chk_fail@PLT
.L97:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"67325548.c"
	.text
	.global	separator
	.section	.rodata
	.align	2
	.type	separator, %object
	.size	separator, 53
separator:
	.ascii	"---------------------------------------------------"
	.ascii	"-\000"
	.align	2
.LC0:
	.ascii	"failed to allocate memory for buddy allocator\000"
	.text
	.align	2
	.global	buddy_allocator_create
	.syntax unified
	.arm
	.fpu softvfp
	.type	buddy_allocator_create, %function
buddy_allocator_create:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	mov	r0, #24
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L2
	ldr	r0, .L5
	bl	puts
	b	.L3
.L2:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	str	r2, [r3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	str	r2, [r3, #12]
.L3:
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L6:
	.align	2
.L5:
	.word	.LC0
	.size	buddy_allocator_create, .-buddy_allocator_create
	.align	2
	.global	buddy_allocator_destroy
	.syntax unified
	.arm
	.fpu softvfp
	.type	buddy_allocator_destroy, %function
buddy_allocator_destroy:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L10
	ldr	r0, [fp, #-8]
	bl	free
	nop
.L10:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	buddy_allocator_destroy, .-buddy_allocator_destroy
	.global	__aeabi_uidiv
	.section	.rodata
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	allocRecurse
	.syntax unified
	.arm
	.fpu softvfp
	.type	allocRecurse, %function
allocRecurse:
	@ args = 4, pretend = 0, frame = 56
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #64
	str	r0, [fp, #-40]
	str	r1, [fp, #-44]
	str	r2, [fp, #-48]
	str	r3, [fp, #-52]
	ldr	r3, .L29
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	strb	r3, [fp, #-24]
	mov	r3, #0
	str	r3, [fp, #-20]
	mov	r3, #0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-52]
	cmp	r3, #4
	bgt	.L12
	ldr	r3, [fp, #-48]
	cmp	r3, #0
	bne	.L13
.L12:
	mov	r3, #0
	strb	r3, [fp, #-24]
	ldr	r3, [fp, #-40]
	mov	r2, r3
	sub	r3, fp, #24
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
	b	.L11
.L13:
	ldr	r3, [fp, #-44]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-52]
	sub	r3, r3, #1
	lsr	r3, r2, r3
	str	r3, [fp, #-32]
	ldr	r3, [fp, #-44]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-52]
	sub	r3, r3, #1
	mov	r1, #1
	lsl	r3, r1, r3
	lsl	r3, r3, #1
	mov	r1, r3
	mov	r0, r2
	bl	__aeabi_uidiv
	mov	r3, r0
	str	r3, [fp, #-28]
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-48]
	cmp	r2, r3
	bcs	.L15
	ldr	r2, [fp, #-48]
	ldr	r3, [fp, #-32]
	cmp	r2, r3
	bls	.L16
.L15:
	ldr	r3, [fp, #-52]
	cmp	r3, #4
	bne	.L17
	ldr	r2, [fp, #-48]
	ldr	r3, [fp, #-28]
	cmp	r2, r3
	bhi	.L17
.L16:
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L18
	ldr	r3, [fp, #4]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #4]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L18
	mov	r3, #0
	strb	r3, [fp, #-24]
	ldr	r3, [fp, #-40]
	mov	r2, r3
	sub	r3, fp, #24
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
	b	.L11
.L18:
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	orr	r3, r1, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L20
	ldr	r3, [fp, #4]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #4]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	orr	r3, r1, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
.L20:
	mov	r3, #1
	strb	r3, [fp, #-24]
	ldr	r3, [fp, #-44]
	ldr	r2, [r3, #16]
	ldr	r3, [fp, #-48]
	add	r2, r2, r3
	ldr	r3, [fp, #-44]
	str	r2, [r3, #16]
	ldr	r3, [fp, #-44]
	ldr	r2, [r3, #8]
	ldr	r3, [fp, #-32]
	add	r2, r2, r3
	ldr	r3, [fp, #-44]
	str	r2, [r3, #8]
	ldr	r3, [fp, #-44]
	ldr	r2, [r3, #12]
	ldr	r3, [fp, #-32]
	sub	r2, r2, r3
	ldr	r3, [fp, #-44]
	str	r2, [r3, #12]
	ldr	r3, [fp, #-40]
	mov	r2, r3
	sub	r3, fp, #24
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
	b	.L11
.L17:
	ldr	r3, [fp, #-52]
	add	r2, r3, #1
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r0, fp, #16
	str	r3, [sp]
	mov	r3, r2
	ldr	r2, [fp, #-48]
	ldr	r1, [fp, #-44]
	bl	allocRecurse
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L21
	ldr	r3, [fp, #-52]
	add	r2, r3, #1
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	add	r3, r3, #1
	sub	r0, fp, #60
	str	r3, [sp]
	mov	r3, r2
	ldr	r2, [fp, #-48]
	ldr	r1, [fp, #-44]
	bl	allocRecurse
	sub	r3, fp, #16
	sub	r2, fp, #60
	ldm	r2, {r0, r1}
	stm	r3, {r0, r1}
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L22
	ldr	r3, [fp, #-40]
	mov	r2, r3
	sub	r3, fp, #16
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
	b	.L11
.L22:
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	orr	r3, r1, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L24
	ldr	r3, [fp, #4]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #4]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	mvn	r3, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r3, r3, r1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
.L24:
	ldr	r2, [fp, #-12]
	ldr	r3, [fp, #-44]
	ldr	r1, [r3, #4]
	ldr	r3, [fp, #-52]
	lsr	r3, r1, r3
	add	r3, r2, r3
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-40]
	mov	r2, r3
	sub	r3, fp, #16
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
	b	.L11
.L21:
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #4]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	orr	r3, r1, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L26
	ldr	r3, [fp, #4]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #4]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	mvn	r3, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r3, r3, r1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-44]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
.L26:
	ldr	r3, [fp, #-40]
	mov	r2, r3
	sub	r3, fp, #16
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
.L11:
	ldr	r3, .L29
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L28
	bl	__stack_chk_fail
.L28:
	ldr	r0, [fp, #-40]
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L30:
	.align	2
.L29:
	.word	.LC1
	.size	allocRecurse, .-allocRecurse
	.global	__aeabi_uidivmod
	.align	2
	.global	freeRecurse
	.syntax unified
	.arm
	.fpu softvfp
	.type	freeRecurse, %function
freeRecurse:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	str	r3, [fp, #-36]
	ldr	r3, [fp, #-32]
	cmp	r3, #4
	ble	.L32
	mov	r3, #0
	strb	r3, [fp, #-16]
	ldrb	r3, [fp, #-16]
	b	.L31
.L32:
	ldr	r3, [fp, #-24]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-32]
	sub	r3, r3, #1
	mov	r1, #1
	lsl	r3, r1, r3
	lsl	r3, r3, #1
	mov	r1, r3
	mov	r0, r2
	bl	__aeabi_uidiv
	mov	r3, r0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-24]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-32]
	sub	r3, r3, #1
	lsr	r3, r2, r3
	str	r3, [fp, #-8]
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-8]
	cmp	r2, r3
	bhi	.L34
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-12]
	cmp	r2, r3
	bls	.L34
	ldr	r3, [fp, #-28]
	ldr	r1, [fp, #-12]
	mov	r0, r3
	bl	__aeabi_uidivmod
	mov	r3, r1
	cmp	r3, #0
	bne	.L34
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L35
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L35
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	mvn	r3, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r3, r3, r1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L37
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	mvn	r3, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r3, r3, r1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
.L37:
	mov	r3, #1
	strb	r3, [fp, #-16]
	ldr	r3, [fp, #-24]
	ldr	r2, [r3, #8]
	ldr	r3, [fp, #-8]
	sub	r2, r2, r3
	ldr	r3, [fp, #-24]
	str	r2, [r3, #8]
	ldr	r3, [fp, #-24]
	ldr	r2, [r3, #12]
	ldr	r3, [fp, #-8]
	add	r2, r2, r3
	ldr	r3, [fp, #-24]
	str	r2, [r3, #12]
	ldrb	r3, [fp, #-16]
	b	.L31
.L35:
	ldr	r3, [fp, #-32]
	add	r2, r3, #1
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	bl	freeRecurse
	mov	r3, r0
	strb	r3, [fp, #-16]
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L38
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-12]
	cmp	r2, r3
	bcc	.L38
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-12]
	sub	r1, r2, r3
	ldr	r3, [fp, #-32]
	add	r2, r3, #1
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	add	r3, r3, #1
	ldr	r0, [fp, #-24]
	bl	freeRecurse
	mov	r3, r0
	strb	r3, [fp, #-16]
.L38:
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L39
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	sub	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	bne	.L39
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	sub	r3, r3, #2
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	sub	r3, r3, #2
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	bne	.L39
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	add	r3, r3, #1
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	add	r3, r3, #1
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	bne	.L39
	ldr	r3, [fp, #-36]
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	bne	.L39
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	mvn	r3, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r3, r3, r1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L39
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	mvn	r3, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r3, r3, r1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
.L39:
	ldrb	r3, [fp, #-16]
	b	.L31
.L34:
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L41
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L42
.L41:
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L43
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L43
.L42:
	ldr	r3, [fp, #-32]
	add	r2, r3, #1
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	bl	freeRecurse
	mov	r3, r0
	strb	r3, [fp, #-16]
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L44
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-12]
	cmp	r2, r3
	bcc	.L44
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-12]
	sub	r1, r2, r3
	ldr	r3, [fp, #-32]
	add	r2, r3, #1
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	add	r3, r3, #1
	ldr	r0, [fp, #-24]
	bl	freeRecurse
	mov	r3, r0
	strb	r3, [fp, #-16]
.L44:
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L45
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	sub	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	bne	.L45
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	sub	r3, r3, #2
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	sub	r3, r3, #2
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	bne	.L45
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	add	r3, r3, #1
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	add	r3, r3, #1
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	bne	.L45
	ldr	r3, [fp, #-36]
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #2
	rsbs	r2, r3, #0
	and	r3, r3, #7
	and	r2, r2, #7
	rsbpl	r3, r2, #0
	asr	r3, r1, r3
	and	r3, r3, #1
	cmp	r3, #0
	bne	.L45
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #-36]
	lsl	r3, r3, #1
	sub	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	mvn	r3, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r3, r3, r1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L45
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r1, r3, #24
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	lsl	r3, r3, #1
	rsbs	r0, r3, #0
	and	r3, r3, #7
	and	r0, r0, #7
	rsbpl	r3, r0, #0
	mov	r0, #1
	lsl	r3, r0, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	mvn	r3, r3
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r3, r3, r1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	and	r1, r3, #255
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	strb	r1, [r3, #20]
	ldr	r3, [fp, #-24]
	add	r3, r3, r2
	ldrb	r3, [r3, #20]	@ zero_extendqisi2
	cmp	r3, #0
.L45:
	ldrb	r3, [fp, #-16]
	b	.L31
.L43:
.L31:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	freeRecurse, .-freeRecurse
	.section	.rodata
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	buddy_allocator_alloc
	.syntax unified
	.arm
	.fpu softvfp
	.type	buddy_allocator_alloc, %function
buddy_allocator_alloc:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	ldr	r3, .L53
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r0, fp, #16
	mov	r3, #1
	str	r3, [sp]
	mov	r3, #1
	ldr	r2, [fp, #-28]
	ldr	r1, [fp, #-24]
	bl	allocRecurse
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L49
	ldr	r3, [fp, #-24]
	ldr	r2, [r3]
	ldr	r3, [fp, #-12]
	add	r3, r2, r3
	b	.L51
.L49:
	mov	r3, #0
.L51:
	ldr	r2, .L53
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L52
	bl	__stack_chk_fail
.L52:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L54:
	.align	2
.L53:
	.word	.LC2
	.size	buddy_allocator_alloc, .-buddy_allocator_alloc
	.section	.rodata
	.align	2
.LC3:
	.ascii	"free on null requested\012\000"
	.align	2
.LC4:
	.ascii	"free on range not belonging to the allocator\000"
	.text
	.align	2
	.global	buddy_allocator_free
	.syntax unified
	.arm
	.fpu softvfp
	.type	buddy_allocator_free, %function
buddy_allocator_free:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bne	.L56
	ldr	r3, .L61
	ldr	r3, [r3]
	mov	r2, #23
	mov	r1, #1
	ldr	r0, .L61+4
	bl	fwrite
	b	.L55
.L56:
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	ldr	r2, [fp, #-20]
	cmp	r2, r3
	bcc	.L58
	ldr	r3, [fp, #-16]
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	ldr	r3, [r3, #4]
	add	r3, r2, r3
	ldr	r2, [fp, #-20]
	cmp	r2, r3
	bcc	.L59
.L58:
	ldr	r3, .L61
	ldr	r3, [r3]
	mov	r2, #44
	mov	r1, #1
	ldr	r0, .L61+8
	bl	fwrite
	b	.L55
.L59:
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	ldr	r2, [fp, #-20]
	sub	r3, r2, r3
	mov	r1, r3
	mov	r3, #1
	mov	r2, #1
	ldr	r0, [fp, #-16]
	bl	freeRecurse
.L55:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L62:
	.align	2
.L61:
	.word	stderr
	.word	.LC3
	.word	.LC4
	.size	buddy_allocator_free, .-buddy_allocator_free
	.section	.rodata
	.align	2
.LC5:
	.ascii	"start @%p\011size:%zd\011inuse:%zd\011requessted:%z"
	.ascii	"d\011free:%zd\012\000"
	.align	2
.LC6:
	.ascii	"[%c%c%c%c%c%c%c%c],\000"
	.text
	.align	2
	.global	buddy_allocator_print
	.syntax unified
	.arm
	.fpu softvfp
	.type	buddy_allocator_print, %function
buddy_allocator_print:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, r6, fp, lr}
	add	fp, sp, #16
	sub	sp, sp, #44
	str	r0, [fp, #-32]
	ldr	r3, [fp, #-32]
	ldr	r1, [r3]
	ldr	r3, [fp, #-32]
	ldr	r0, [r3, #4]
	ldr	r3, [fp, #-32]
	ldr	ip, [r3, #8]
	ldr	r3, [fp, #-32]
	ldr	r3, [r3, #16]
	ldr	r2, [fp, #-32]
	ldr	r2, [r2, #12]
	str	r2, [sp, #4]
	str	r3, [sp]
	mov	r3, ip
	mov	r2, r0
	ldr	r0, .L82
	bl	printf
	mov	r3, #3
	str	r3, [fp, #-24]
	b	.L64
.L81:
	ldr	r2, [fp, #-32]
	ldr	r3, [fp, #-24]
	add	r3, r2, r3
	add	r3, r3, #20
	ldrb	r3, [r3]	@ zero_extendqisi2
	lsl	r3, r3, #24
	asr	r3, r3, #24
	cmp	r3, #0
	bge	.L65
	mov	r4, #49
	b	.L66
.L65:
	mov	r4, #48
.L66:
	ldr	r2, [fp, #-32]
	ldr	r3, [fp, #-24]
	add	r3, r2, r3
	add	r3, r3, #20
	ldrb	r3, [r3]	@ zero_extendqisi2
	and	r3, r3, #64
	cmp	r3, #0
	beq	.L67
	mov	r5, #49
	b	.L68
.L67:
	mov	r5, #48
.L68:
	ldr	r2, [fp, #-32]
	ldr	r3, [fp, #-24]
	add	r3, r2, r3
	add	r3, r3, #20
	ldrb	r3, [r3]	@ zero_extendqisi2
	and	r3, r3, #32
	cmp	r3, #0
	beq	.L69
	mov	r6, #49
	b	.L70
.L69:
	mov	r6, #48
.L70:
	ldr	r2, [fp, #-32]
	ldr	r3, [fp, #-24]
	add	r3, r2, r3
	add	r3, r3, #20
	ldrb	r3, [r3]	@ zero_extendqisi2
	and	r3, r3, #16
	cmp	r3, #0
	beq	.L71
	mov	r3, #49
	b	.L72
.L71:
	mov	r3, #48
.L72:
	ldr	r1, [fp, #-32]
	ldr	r2, [fp, #-24]
	add	r2, r1, r2
	add	r2, r2, #20
	ldrb	r2, [r2]	@ zero_extendqisi2
	and	r2, r2, #8
	cmp	r2, #0
	beq	.L73
	mov	r2, #49
	b	.L74
.L73:
	mov	r2, #48
.L74:
	ldr	r0, [fp, #-32]
	ldr	r1, [fp, #-24]
	add	r1, r0, r1
	add	r1, r1, #20
	ldrb	r1, [r1]	@ zero_extendqisi2
	and	r1, r1, #4
	cmp	r1, #0
	beq	.L75
	mov	r1, #49
	b	.L76
.L75:
	mov	r1, #48
.L76:
	ldr	ip, [fp, #-32]
	ldr	r0, [fp, #-24]
	add	r0, ip, r0
	add	r0, r0, #20
	ldrb	r0, [r0]	@ zero_extendqisi2
	and	r0, r0, #2
	cmp	r0, #0
	beq	.L77
	mov	r0, #49
	b	.L78
.L77:
	mov	r0, #48
.L78:
	ldr	lr, [fp, #-32]
	ldr	ip, [fp, #-24]
	add	ip, lr, ip
	add	ip, ip, #20
	ldrb	ip, [ip]	@ zero_extendqisi2
	and	ip, ip, #1
	cmp	ip, #0
	beq	.L79
	mov	ip, #49
	b	.L80
.L79:
	mov	ip, #48
.L80:
	str	ip, [sp, #16]
	str	r0, [sp, #12]
	str	r1, [sp, #8]
	str	r2, [sp, #4]
	str	r3, [sp]
	mov	r3, r6
	mov	r2, r5
	mov	r1, r4
	ldr	r0, .L82+4
	bl	printf
	ldr	r3, [fp, #-24]
	sub	r3, r3, #1
	str	r3, [fp, #-24]
.L64:
	ldr	r3, [fp, #-24]
	cmp	r3, #0
	bge	.L81
	mov	r0, #10
	bl	putchar
	nop
	sub	sp, fp, #16
	@ sp needed
	pop	{r4, r5, r6, fp, pc}
.L83:
	.align	2
.L82:
	.word	.LC5
	.word	.LC6
	.size	buddy_allocator_print, .-buddy_allocator_print
	.section	.rodata
	.align	2
.LC7:
	.ascii	"compiled for %d levels which provides %ld allocatio"
	.ascii	"n cells\012\000"
	.align	2
.LC8:
	.ascii	" %c\000"
	.align	2
.LC9:
	.ascii	"how many?\012>\000"
	.align	2
.LC10:
	.ascii	" %zd\000"
	.align	2
.LC11:
	.ascii	"Alloc @ %p\012\000"
	.align	2
.LC12:
	.ascii	"which addr?\012>\000"
	.align	2
.LC13:
	.ascii	" %p\000"
	.align	2
.LC14:
	.ascii	"Q to quit, A to allocate, F to free, P to print\000"
	.align	2
.LC15:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	repl
	.syntax unified
	.arm
	.fpu softvfp
	.type	repl, %function
repl:
	@ args = 0, pretend = 0, frame = 40
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #40
	str	r0, [fp, #-40]
	ldr	r3, .L99
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #1
	str	r3, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-12]
	mov	r3, #1
	str	r3, [fp, #-20]
	b	.L85
.L86:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #1
	str	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	ldr	r3, [fp, #-16]
	add	r3, r2, r3
	str	r3, [fp, #-20]
.L85:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmp	r3, #3
	ble	.L86
	ldr	r2, [fp, #-20]
	mov	r1, #4
	ldr	r0, .L99+4
	bl	printf
.L95:
	mov	r0, #62
	bl	putchar
	sub	r3, fp, #29
	mov	r1, r3
	ldr	r0, .L99+8
	bl	__isoc99_scanf
	ldrb	r3, [fp, #-29]	@ zero_extendqisi2
	sub	r3, r3, #65
	cmp	r3, #16
	ldrls	pc, [pc, r3, asl #2]
	b	.L87
.L89:
	.word	.L92
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L91
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L87
	.word	.L90
	.word	.L98
.L92:
	ldr	r0, .L99+12
	bl	printf
	sub	r3, fp, #28
	mov	r1, r3
	ldr	r0, .L99+16
	bl	__isoc99_scanf
	ldr	r3, [fp, #-28]
	mov	r1, r3
	ldr	r0, [fp, #-40]
	bl	buddy_allocator_alloc
	mov	r3, r0
	mov	r1, r3
	ldr	r0, .L99+20
	bl	printf
	b	.L94
.L91:
	ldr	r0, .L99+24
	bl	printf
	sub	r3, fp, #24
	mov	r1, r3
	ldr	r0, .L99+28
	bl	__isoc99_scanf
	ldr	r3, [fp, #-24]
	mov	r1, r3
	ldr	r0, [fp, #-40]
	bl	buddy_allocator_free
	b	.L94
.L90:
	ldr	r0, [fp, #-40]
	bl	buddy_allocator_print
	b	.L94
.L87:
	ldr	r0, .L99+32
	bl	puts
	nop
.L94:
	b	.L95
.L98:
	nop
	ldr	r3, .L99
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L97
	bl	__stack_chk_fail
.L97:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L100:
	.align	2
.L99:
	.word	.LC15
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.size	repl, .-repl
	.section	.rodata
	.align	2
.LC16:
	.ascii	"usage:budalloc bytenumber\012\000"
	.text
	.align	2
	.global	usage
	.syntax unified
	.arm
	.fpu softvfp
	.type	usage, %function
usage:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r3, .L102
	ldr	r3, [r3]
	mov	r2, #26
	mov	r1, #1
	ldr	r0, .L102+4
	bl	fwrite
	nop
	pop	{fp, pc}
.L103:
	.align	2
.L102:
	.word	stderr
	.word	.LC16
	.size	usage, .-usage
	.section	.rodata
	.align	2
.LC17:
	.ascii	"num range\000"
	.align	2
.LC18:
	.ascii	"invalid arena size requested\012\000"
	.align	2
.LC19:
	.ascii	"failed to allocate %lld bytes\012\000"
	.align	2
.LC20:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 40
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #40
	str	r0, [fp, #-40]
	str	r1, [fp, #-44]
	ldr	r3, .L116
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-40]
	cmp	r3, #2
	beq	.L105
	bl	usage
	mov	r3, #1
	b	.L114
.L105:
	ldr	r3, [fp, #-44]
	add	r3, r3, #4
	ldr	r3, [r3]
	sub	r1, fp, #32
	mov	r2, #10
	mov	r0, r3
	bl	strtoll
	str	r0, [fp, #-20]
	str	r1, [fp, #-16]
	ldr	r3, [fp, #-44]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L107
	ldr	r3, [fp, #-32]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L108
.L107:
	bl	usage
.L108:
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #34
	bne	.L109
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	mvn	r0, #0
	mvn	r1, #-2147483648
	cmp	r3, r1
	cmpeq	r2, r0
	beq	.L110
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	cmp	r3, #-2147483648
	cmpeq	r2, #0
	bne	.L109
.L110:
	ldr	r0, .L116+4
	bl	warnx
.L109:
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	mvn	r0, #0
	mov	r1, #0
	cmp	r0, r2
	sbcs	r3, r1, r3
	blt	.L111
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	cmp	r2, #1
	sbcs	r3, r3, #0
	bge	.L112
.L111:
	ldr	r0, .L116+8
	bl	warnx
.L112:
	ldr	r3, [fp, #-20]
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bne	.L113
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	ldr	r0, .L116+12
	bl	warnx
.L113:
	ldr	r3, [fp, #-20]
	mov	r1, r3
	ldr	r0, [fp, #-28]
	bl	buddy_allocator_create
	str	r0, [fp, #-24]
	ldr	r0, [fp, #-24]
	bl	repl
	ldr	r0, [fp, #-24]
	bl	buddy_allocator_destroy
	ldr	r0, [fp, #-28]
	bl	free
	mov	r3, #0
.L114:
	ldr	r2, .L116
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L115
	bl	__stack_chk_fail
.L115:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L117:
	.align	2
.L116:
	.word	.LC20
	.word	.LC17
	.word	.LC18
	.word	.LC19
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
