	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ubi_change_vtbl_record         ## -- Begin function ubi_change_vtbl_record
	.p2align	4, 0x90
_ubi_change_vtbl_record:                ## @ubi_change_vtbl_record
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movl	%esi, %r12d
	movq	%rdi, %r13
	xorl	%edi, %edi
	testl	%esi, %esi
	js	LBB0_2
## %bb.1:
	cmpl	%r12d, (%r13)
	setg	%dil
LBB0_2:
	callq	_ubi_assert
	movq	16(%r13), %rbx
	movq	_UBI_LAYOUT_VOLUME_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_vol_id2idx
	movq	(%rbx,%rax,8), %r14
	testq	%r15, %r15
	je	LBB0_3
## %bb.4:
	movq	_UBI_CRC32_INIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_UBI_VTBL_RECORD_SIZE_CRC@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rsi
	callq	_crc32
	movl	%eax, %edi
	callq	_cpu_to_be32
	movl	%eax, (%r15)
	jmp	LBB0_5
LBB0_3:
	movq	_empty_vtbl_record@GOTPCREL(%rip), %r15
LBB0_5:
	movslq	%r12d, %rdi
	shlq	$2, %rdi
	addq	8(%r13), %rdi
	movq	%r15, %rsi
	movl	$4, %edx
	callq	_memcpy
	movq	_UBI_LAYOUT_VOLUME_EBS@GOTPCREL(%rip), %r15
	cmpl	$0, (%r15)
	jle	LBB0_10
## %bb.6:
	xorl	%ebx, %ebx
	movq	_UBI_LONGTERM@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	movq	%r14, %rsi
	movl	%ebx, %edx
	callq	_ubi_eba_unmap_leb
	testl	%eax, %eax
	jne	LBB0_11
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movq	8(%r13), %rcx
	movl	4(%r13), %r9d
	movl	(%r12), %eax
	movl	%eax, (%rsp)
	movq	%r13, %rdi
	movq	%r14, %rsi
	movl	%ebx, %edx
	xorl	%r8d, %r8d
	callq	_ubi_eba_write_leb
	testl	%eax, %eax
	jne	LBB0_11
## %bb.7:                               ##   in Loop: Header=BB0_8 Depth=1
	incl	%ebx
	cmpl	(%r15), %ebx
	jl	LBB0_8
LBB0_10:
	movq	%r13, %rdi
	callq	_paranoid_vtbl_check
	xorl	%eax, %eax
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_UBI_LAYOUT_VOLUME_ID,4,2       ## @UBI_LAYOUT_VOLUME_ID
	.comm	_empty_vtbl_record,4,2          ## @empty_vtbl_record
	.comm	_UBI_CRC32_INIT,4,2             ## @UBI_CRC32_INIT
	.comm	_UBI_VTBL_RECORD_SIZE_CRC,4,2   ## @UBI_VTBL_RECORD_SIZE_CRC
	.comm	_UBI_LAYOUT_VOLUME_EBS,4,2      ## @UBI_LAYOUT_VOLUME_EBS
	.comm	_UBI_LONGTERM,4,2               ## @UBI_LONGTERM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ubi_change_vtbl_record         ; -- Begin function ubi_change_vtbl_record
	.p2align	2
_ubi_change_vtbl_record:                ; @ubi_change_vtbl_record
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	tbnz	w1, #31, LBB0_2
; %bb.1:
	ldr	w8, [x19]
	cmp	w8, w22
	cset	w0, gt
	b	LBB0_3
LBB0_2:
	mov	w0, #0
LBB0_3:
	bl	_ubi_assert
	ldr	x20, [x19, #16]
Lloh0:
	adrp	x8, _UBI_LAYOUT_VOLUME_ID@GOTPAGE
Lloh1:
	ldr	x8, [x8, _UBI_LAYOUT_VOLUME_ID@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_vol_id2idx
	ldr	x20, [x20, x0, lsl #3]
	cbz	x21, LBB0_5
; %bb.4:
Lloh3:
	adrp	x8, _UBI_CRC32_INIT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _UBI_CRC32_INIT@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
Lloh6:
	adrp	x8, _UBI_VTBL_RECORD_SIZE_CRC@GOTPAGE
Lloh7:
	ldr	x8, [x8, _UBI_VTBL_RECORD_SIZE_CRC@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	mov	x1, x21
	bl	_crc32
	bl	_cpu_to_be32
	str	w0, [x21]
	b	LBB0_6
LBB0_5:
Lloh9:
	adrp	x21, _empty_vtbl_record@GOTPAGE
Lloh10:
	ldr	x21, [x21, _empty_vtbl_record@GOTPAGEOFF]
LBB0_6:
	ldr	x8, [x19, #8]
	add	x0, x8, w22, sxtw #2
	mov	x1, x21
	mov	w2, #4
	bl	_memcpy
Lloh11:
	adrp	x22, _UBI_LAYOUT_VOLUME_EBS@GOTPAGE
Lloh12:
	ldr	x22, [x22, _UBI_LAYOUT_VOLUME_EBS@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_11
; %bb.7:
	mov	w21, #0
Lloh13:
	adrp	x23, _UBI_LONGTERM@GOTPAGE
Lloh14:
	ldr	x23, [x23, _UBI_LONGTERM@GOTPAGEOFF]
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	bl	_ubi_eba_unmap_leb
	cbnz	w0, LBB0_12
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	ldr	x3, [x19, #8]
	ldr	w5, [x19, #4]
	ldr	w6, [x23]
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	mov	w4, #0
	bl	_ubi_eba_write_leb
	cbnz	w0, LBB0_12
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	add	w21, w21, #1
	ldr	w8, [x22]
	cmp	w21, w8
	b.lt	LBB0_8
LBB0_11:
	mov	x0, x19
	bl	_paranoid_vtbl_check
	mov	w0, #0
LBB0_12:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_UBI_LAYOUT_VOLUME_ID,4,2       ; @UBI_LAYOUT_VOLUME_ID
	.comm	_empty_vtbl_record,4,2          ; @empty_vtbl_record
	.comm	_UBI_CRC32_INIT,4,2             ; @UBI_CRC32_INIT
	.comm	_UBI_VTBL_RECORD_SIZE_CRC,4,2   ; @UBI_VTBL_RECORD_SIZE_CRC
	.comm	_UBI_LAYOUT_VOLUME_EBS,4,2      ; @UBI_LAYOUT_VOLUME_EBS
	.comm	_UBI_LONGTERM,4,2               ; @UBI_LONGTERM
.subsections_via_symbols
