	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ubi_leb_map                    ## -- Begin function ubi_leb_map
	.p2align	4, 0x90
_ubi_leb_map:                           ## @ubi_leb_map
	.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
	movl	%edx, %r15d
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movq	8(%rdi), %r13
	movq	40(%r13), %r12
	movl	32(%r13), %esi
	leaq	L_.str(%rip), %rdi
	movl	%r14d, %edx
	callq	_dbg_gen
	movq	(%rbx), %rax
	movq	_UBI_READONLY@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_2
## %bb.1:
	movq	(%r13), %rax
	movq	_UBI_STATIC_VOLUME@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_4
LBB0_2:
	movq	_EROFS@GOTPCREL(%rip), %rcx
	jmp	LBB0_3
LBB0_4:
	testl	%r14d, %r14d
	js	LBB0_6
## %bb.5:
	cmpl	%r14d, 8(%r13)
	jle	LBB0_6
## %bb.7:
	movq	_UBI_LONGTERM@GOTPCREL(%rip), %rax
	cmpl	%r15d, (%rax)
	je	LBB0_10
## %bb.8:
	movq	_UBI_SHORTTERM@GOTPCREL(%rip), %rax
	cmpl	%r15d, (%rax)
	je	LBB0_10
## %bb.9:
	movq	_UBI_UNKNOWN@GOTPCREL(%rip), %rax
	cmpl	%r15d, (%rax)
	je	LBB0_10
LBB0_6:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_3:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_15:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	cmpq	$0, 24(%r13)
	je	LBB0_12
## %bb.11:
	movq	_EBADF@GOTPCREL(%rip), %rcx
	jmp	LBB0_3
LBB0_12:
	movq	16(%r13), %rax
	movl	%r14d, %ecx
	cmpq	$0, (%rax,%rcx,8)
	js	LBB0_14
## %bb.13:
	movq	_EBADMSG@GOTPCREL(%rip), %rcx
	jmp	LBB0_3
LBB0_14:
	movl	%r15d, (%rsp)
	movq	%r12, %rdi
	movq	%r13, %rsi
	movl	%r14d, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_ubi_eba_write_leb
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unmap LEB %d:%d"

	.comm	_UBI_READONLY,8,3               ## @UBI_READONLY
	.comm	_UBI_STATIC_VOLUME,8,3          ## @UBI_STATIC_VOLUME
	.comm	_EROFS,4,2                      ## @EROFS
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_UBI_LONGTERM,4,2               ## @UBI_LONGTERM
	.comm	_UBI_SHORTTERM,4,2              ## @UBI_SHORTTERM
	.comm	_UBI_UNKNOWN,4,2                ## @UBI_UNKNOWN
	.comm	_EBADF,4,2                      ## @EBADF
	.comm	_EBADMSG,4,2                    ## @EBADMSG
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ubi_leb_map                    ; -- Begin function ubi_leb_map
	.p2align	2
_ubi_leb_map:                           ; @ubi_leb_map
	.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	x19, x2
	mov	x20, x1
	mov	x23, x0
	ldr	x21, [x0, #8]
	ldr	x22, [x21, #40]
	ldr	w1, [x21, #32]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x2, x20
	bl	_dbg_gen
	ldr	x8, [x23]
Lloh2:
	adrp	x9, _UBI_READONLY@GOTPAGE
Lloh3:
	ldr	x9, [x9, _UBI_READONLY@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_2
; %bb.1:
	ldr	x8, [x21]
Lloh5:
	adrp	x9, _UBI_STATIC_VOLUME@GOTPAGE
Lloh6:
	ldr	x9, [x9, _UBI_STATIC_VOLUME@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_3
LBB0_2:
Lloh8:
	adrp	x8, _EROFS@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EROFS@GOTPAGEOFF]
	b	LBB0_9
LBB0_3:
	tbnz	w20, #31, LBB0_8
; %bb.4:
	ldr	w8, [x21, #8]
	cmp	w8, w20
	b.le	LBB0_8
; %bb.5:
Lloh10:
	adrp	x8, _UBI_LONGTERM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _UBI_LONGTERM@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
Lloh13:
	adrp	x9, _UBI_SHORTTERM@GOTPAGE
Lloh14:
	ldr	x9, [x9, _UBI_SHORTTERM@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
Lloh16:
	adrp	x10, _UBI_UNKNOWN@GOTPAGE
Lloh17:
	ldr	x10, [x10, _UBI_UNKNOWN@GOTPAGEOFF]
Lloh18:
	ldr	w10, [x10]
	cmp	w8, w19
	ccmp	w9, w19, #4, ne
	ccmp	w10, w19, #4, ne
	b.ne	LBB0_8
; %bb.6:
	ldr	x8, [x21, #24]
	cbz	x8, LBB0_10
; %bb.7:
Lloh19:
	adrp	x8, _EBADF@GOTPAGE
Lloh20:
	ldr	x8, [x8, _EBADF@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh21:
	adrp	x8, _EINVAL@GOTPAGE
Lloh22:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	neg	w0, w8
	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
LBB0_10:
	ldr	x8, [x21, #16]
	ldr	x8, [x8, w20, uxtw #3]
	tbnz	x8, #63, LBB0_12
; %bb.11:
Lloh23:
	adrp	x8, _EBADMSG@GOTPAGE
Lloh24:
	ldr	x8, [x8, _EBADMSG@GOTPAGEOFF]
	b	LBB0_9
LBB0_12:
	mov	x0, x22
	mov	x1, x21
	mov	x2, x20
	mov	x3, #0
	mov	w4, #0
	mov	w5, #0
	mov	x6, x19
	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
	b	_ubi_eba_write_leb
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unmap LEB %d:%d"

	.comm	_UBI_READONLY,8,3               ; @UBI_READONLY
	.comm	_UBI_STATIC_VOLUME,8,3          ; @UBI_STATIC_VOLUME
	.comm	_EROFS,4,2                      ; @EROFS
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_UBI_LONGTERM,4,2               ; @UBI_LONGTERM
	.comm	_UBI_SHORTTERM,4,2              ; @UBI_SHORTTERM
	.comm	_UBI_UNKNOWN,4,2                ; @UBI_UNKNOWN
	.comm	_EBADF,4,2                      ; @EBADF
	.comm	_EBADMSG,4,2                    ; @EBADMSG
.subsections_via_symbols
