	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_octeon_i2c_set_clock           ## -- Begin function octeon_i2c_set_clock
	.p2align	4, 0x90
_octeon_i2c_set_clock:                  ## @octeon_i2c_set_clock
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	(%rdi), %r10d
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movl	4(%rdi), %r8d
	movl	%r10d, %eax
	shll	$5, %eax
	leal	(%rax,%rax,4), %eax
	movl	%eax, -56(%rbp)                 ## 4-byte Spill
	leal	(%r10,%r10), %eax
	leal	(%rax,%rax,4), %r11d
	movl	$24, -44(%rbp)                  ## 4-byte Folded Spill
	movl	$2, -52(%rbp)                   ## 4-byte Folded Spill
	movl	$0, -48(%rbp)                   ## 4-byte Folded Spill
	movl	$1000000, %ebx                  ## imm = 0xF4240
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_2 Depth 2
	movl	$1, %r13d
	shll	%cl, %r13d
	movl	$15, %r14d
	movl	-56(%rbp), %r9d                 ## 4-byte Reload
	.p2align	4, 0x90
LBB0_2:                                 ##   Parent Loop BB0_1 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	leal	1(%r14), %r15d
	movl	%r9d, %edi
	shll	%cl, %edi
	addl	%edi, %edi
	movl	%r8d, %eax
	cltd
	idivl	%edi
	movl	%eax, %edi
	leal	-257(%rdi), %eax
	cmpl	$-251, %eax
	jb	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=2
	leal	(%rdi,%rdi), %r12d
	movl	%r8d, %eax
	cltd
	idivl	%r12d
	cltd
	idivl	%r13d
	cltd
	idivl	%r15d
	cltq
	imulq	$1717986919, %rax, %rdx         ## imm = 0x66666667
	movq	%rdx, %rax
	shrq	$63, %rax
	sarq	$34, %rdx
	addl	%eax, %edx
	subl	%r10d, %edx
	movl	%edx, %eax
	negl	%eax
	cmovsl	%edx, %eax
	cmpl	%ebx, %eax
	jge	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=2
	leal	-1(%rdi), %edx
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movl	%r14d, %edx
	movl	%r14d, -52(%rbp)                ## 4-byte Spill
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	movl	%eax, %ebx
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=2
	leal	-256(%rdi), %eax
	cmpl	$-251, %eax
	jb	LBB0_8
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=2
	leal	(%rdi,%rdi), %esi
	addl	$2, %esi
	movl	%r8d, %eax
	cltd
	idivl	%esi
	cltd
	idivl	%r13d
	cltd
	idivl	%r15d
	cltq
	imulq	$1717986919, %rax, %rdx         ## imm = 0x66666667
	movq	%rdx, %rax
	shrq	$63, %rax
	sarq	$34, %rdx
	addl	%eax, %edx
	subl	%r10d, %edx
	movl	%edx, %eax
	negl	%eax
	cmovsl	%edx, %eax
	cmpl	%ebx, %eax
	jge	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=2
	movl	%edi, %edx
	movl	%edi, -44(%rbp)                 ## 4-byte Spill
	movl	%r14d, %edx
	movl	%r14d, -52(%rbp)                ## 4-byte Spill
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	movl	%eax, %ebx
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=2
	cmpl	$3, %r14d
	jb	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=2
	decl	%r14d
	subl	%r11d, %r9d
	testl	%ebx, %ebx
	jne	LBB0_2
LBB0_10:                                ##   in Loop: Header=BB0_1 Depth=1
	cmpl	$6, %ecx
	ja	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_1 Depth=1
	incl	%ecx
	testl	%ebx, %ebx
	jne	LBB0_1
LBB0_12:
	movq	_SW_TWSI_OP_TWSI_CLK@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	callq	_octeon_i2c_reg_write
	movq	_SW_TWSI_EOP_TWSI_CLKCTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	shll	$3, %edx
	orl	-48(%rbp), %edx                 ## 4-byte Folded Reload
	movq	%rbx, %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_octeon_i2c_reg_write           ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SW_TWSI_OP_TWSI_CLK,4,2        ## @SW_TWSI_OP_TWSI_CLK
	.comm	_SW_TWSI_EOP_TWSI_CLKCTL,4,2    ## @SW_TWSI_EOP_TWSI_CLKCTL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_octeon_i2c_set_clock           ; -- Begin function octeon_i2c_set_clock
	.p2align	2
_octeon_i2c_set_clock:                  ; @octeon_i2c_set_clock
	.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
	mov	x19, x0
	mov	w20, #0
	mov	w8, #0
	ldp	w9, w10, [x0]
	add	w12, w9, w9, lsl #2
	lsl	w11, w12, #5
	lsl	w12, w12, #1
	mov	w2, #24
	mov	w21, #2
	mov	w15, #16960
	movk	w15, #15, lsl #16
	mov	w13, #1
	mov	w14, #26215
	movk	w14, #26214, lsl #16
LBB0_1:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_2 Depth 2
	lsl	w16, w13, w8
	mov	w17, #15
	mov	x0, x11
LBB0_2:                                 ;   Parent Loop BB0_1 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	w3, w17, #1
	lsl	w1, w0, w8
	lsl	w1, w1, #1
	sdiv	w1, w10, w1
	sub	w5, w1, #257
	lsl	w4, w1, #1
	cmn	w5, #251
	b.lo	LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=2
	sdiv	w5, w10, w4
	sdiv	w5, w5, w16
	sdiv	w5, w5, w3
	smull	x5, w5, w14
	lsr	x6, x5, #63
	asr	x5, x5, #34
	add	w5, w5, w6
	subs	w5, w5, w9
	cneg	w5, w5, mi
	cmp	w5, w15
	b.ge	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=2
	sub	w2, w1, #1
	mov	x21, x17
	mov	x20, x8
	mov	x15, x5
LBB0_5:                                 ;   in Loop: Header=BB0_2 Depth=2
	sub	w5, w1, #256
	cmn	w5, #251
	b.lo	LBB0_8
; %bb.6:                                ;   in Loop: Header=BB0_2 Depth=2
	add	w4, w4, #2
	sdiv	w4, w10, w4
	sdiv	w4, w4, w16
	sdiv	w3, w4, w3
	smull	x3, w3, w14
	lsr	x4, x3, #63
	asr	x3, x3, #34
	add	w3, w3, w4
	subs	w3, w3, w9
	cneg	w3, w3, mi
	cmp	w3, w15
	b.ge	LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_2 Depth=2
	mov	x2, x1
	mov	x21, x17
	mov	x20, x8
	mov	x15, x3
LBB0_8:                                 ;   in Loop: Header=BB0_2 Depth=2
	cmp	w17, #3
	b.lo	LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_2 Depth=2
	sub	w17, w17, #1
	sub	w0, w0, w12
	cbnz	w15, LBB0_2
LBB0_10:                                ;   in Loop: Header=BB0_1 Depth=1
	cmp	w8, #6
	b.hi	LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_1 Depth=1
	add	w8, w8, #1
	cbnz	w15, LBB0_1
LBB0_12:
Lloh0:
	adrp	x8, _SW_TWSI_OP_TWSI_CLK@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SW_TWSI_OP_TWSI_CLK@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_octeon_i2c_reg_write
Lloh3:
	adrp	x8, _SW_TWSI_EOP_TWSI_CLKCTL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SW_TWSI_EOP_TWSI_CLKCTL@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	orr	w2, w20, w21, lsl #3
	mov	x0, x19
	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	_octeon_i2c_reg_write
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_SW_TWSI_OP_TWSI_CLK,4,2        ; @SW_TWSI_OP_TWSI_CLK
	.comm	_SW_TWSI_EOP_TWSI_CLKCTL,4,2    ; @SW_TWSI_EOP_TWSI_CLKCTL
.subsections_via_symbols
