	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_oled_advance_page              ## -- Begin function oled_advance_page
	.p2align	4, 0x90
_oled_advance_page:                     ## @oled_advance_page
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	_oled_cursor@GOTPCREL(%rip), %r8
	movq	(%r8), %rsi
	movq	_oled_buffer@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	subq	%rbx, %rsi
	sarq	$2, %rsi
	movq	_oled_rotation_width@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	%rsi, %rax
	orq	%rcx, %rax
	shrq	$32, %rax
	je	LBB0_1
## %bb.2:
	movq	%rsi, %rax
	xorl	%edx, %edx
	divq	%rcx
	jmp	LBB0_3
LBB0_1:
	movl	%esi, %eax
	xorl	%edx, %edx
	divl	%ecx
                                        ## kill: def $edx killed $edx def $rdx
LBB0_3:
	subq	%rdx, %rcx
	testl	%edi, %edi
	je	LBB0_9
## %bb.4:
	movq	_OLED_FONT_WIDTH@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	cmpq	%rcx, %rsi
	ja	LBB0_10
## %bb.5:
	movq	%rcx, %rax
	orq	%rsi, %rax
	shrq	$32, %rax
	je	LBB0_6
## %bb.7:
	movq	%rcx, %rax
	xorl	%edx, %edx
	divq	%rsi
	movq	%rax, %rbx
	jmp	LBB0_8
LBB0_9:
	addq	%rcx, %rsi
	movq	_OLED_MATRIX_SIZE@GOTPCREL(%rip), %rax
	xorl	%ecx, %ecx
	cmpq	(%rax), %rsi
	cmovbq	%rsi, %rcx
	leaq	(%rbx,%rcx,4), %rax
	movq	%rax, (%r8)
	jmp	LBB0_10
LBB0_6:
	movl	%ecx, %eax
	xorl	%edx, %edx
	divl	%esi
	movl	%eax, %ebx
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movl	$32, %edi
	xorl	%esi, %esi
	callq	_oled_write_char
	decq	%rbx
	jne	LBB0_8
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_oled_cursor,8,3                ## @oled_cursor
	.comm	_oled_buffer,8,3                ## @oled_buffer
	.comm	_oled_rotation_width,8,3        ## @oled_rotation_width
	.comm	_OLED_FONT_WIDTH,8,3            ## @OLED_FONT_WIDTH
	.comm	_OLED_MATRIX_SIZE,8,3           ## @OLED_MATRIX_SIZE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_oled_advance_page              ; -- Begin function oled_advance_page
	.p2align	2
_oled_advance_page:                     ; @oled_advance_page
	.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, _oled_cursor@GOTPAGE
Lloh1:
	ldr	x8, [x8, _oled_cursor@GOTPAGEOFF]
	ldr	x10, [x8]
Lloh2:
	adrp	x9, _oled_buffer@GOTPAGE
Lloh3:
	ldr	x9, [x9, _oled_buffer@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
	sub	x10, x10, x9
Lloh5:
	adrp	x12, _oled_rotation_width@GOTPAGE
Lloh6:
	ldr	x12, [x12, _oled_rotation_width@GOTPAGEOFF]
	asr	x11, x10, #2
Lloh7:
	ldr	x10, [x12]
	udiv	x12, x11, x10
	neg	x13, x11
	madd	x12, x12, x10, x13
	add	x10, x10, x12
	cbz	w0, LBB0_4
; %bb.1:
Lloh8:
	adrp	x8, _OLED_FONT_WIDTH@GOTPAGE
Lloh9:
	ldr	x8, [x8, _OLED_FONT_WIDTH@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	cmp	x8, x10
	b.hi	LBB0_5
; %bb.2:
	udiv	x19, x10, x8
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	sub	x19, x19, #1
	mov	w0, #32
	mov	w1, #0
	bl	_oled_write_char
	cbnz	x19, LBB0_3
	b	LBB0_5
LBB0_4:
Lloh11:
	adrp	x12, _OLED_MATRIX_SIZE@GOTPAGE
Lloh12:
	ldr	x12, [x12, _OLED_MATRIX_SIZE@GOTPAGEOFF]
Lloh13:
	ldr	x12, [x12]
	add	x10, x11, x10
	cmp	x10, x12
	csel	x10, x10, xzr, lo
	add	x9, x9, x10, lsl #2
	str	x9, [x8]
LBB0_5:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_oled_cursor,8,3                ; @oled_cursor
	.comm	_oled_buffer,8,3                ; @oled_buffer
	.comm	_oled_rotation_width,8,3        ; @oled_rotation_width
	.comm	_OLED_FONT_WIDTH,8,3            ; @OLED_FONT_WIDTH
	.comm	_OLED_MATRIX_SIZE,8,3           ; @OLED_MATRIX_SIZE
.subsections_via_symbols
