	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_HPDF_CMapEncoder_AddCMap       ## -- Begin function HPDF_CMapEncoder_AddCMap
	.p2align	4, 0x90
_HPDF_CMapEncoder_AddCMap:              ## @HPDF_CMapEncoder_AddCMap
	.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	%rsi, %rbx
	movq	%rdi, %r14
	movslq	24(%rdi), %r13
	leaq	L_.str(%rip), %rdi
	callq	_HPDF_PTRACE
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_6 Depth 2
	movslq	(%rbx), %rax
	cmpq	$65535, %rax                    ## imm = 0xFFFF
	jne	LBB0_3
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	cmpl	$65535, 4(%rbx)                 ## imm = 0xFFFF
	je	LBB0_11
LBB0_3:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	(%r14), %rcx
	movq	_HPDF_CMapEncoder_ToUnicode@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_7
## %bb.4:                               ##   in Loop: Header=BB0_1 Depth=1
	cmpl	4(%rbx), %eax
	jg	LBB0_7
## %bb.5:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	8(%rbx), %ecx
	movq	(%r13), %r8
	movq	%rax, %rsi
	decq	%rsi
	.p2align	4, 0x90
LBB0_6:                                 ##   Parent Loop BB0_1 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	%eax, %edi
	sarl	$8, %edi
	movslq	%edi, %rdi
	movq	8(%r8,%rsi,8), %rdx
	movl	%ecx, (%rdx,%rdi,4)
	incl	%ecx
	movslq	4(%rbx), %rdx
	incq	%rsi
	incl	%eax
	cmpq	%rdx, %rsi
	jl	LBB0_6
LBB0_7:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	8(%r14), %edi
	movl	$12, %esi
	callq	_HPDF_GetMem
	testq	%rax, %rax
	je	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	%rax, %r15
	movl	(%rbx), %eax
	movl	%eax, (%r15)
	movl	4(%rbx), %eax
	movl	%eax, 4(%r15)
	movl	8(%rbx), %eax
	movl	%eax, 8(%r15)
	movl	8(%r13), %edi
	movq	%r15, %rsi
	callq	_HPDF_List_Add
	movl	%eax, %r12d
	addq	$12, %rbx
	movq	_HPDF_OK@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r12d
	je	LBB0_1
## %bb.10:
	movl	8(%r14), %edi
	movq	%r15, %rsi
	callq	_HPDF_FreeMem
	jmp	LBB0_13
LBB0_8:
	movq	16(%r14), %rax
	jmp	LBB0_12
LBB0_11:
	movq	_HPDF_OK@GOTPCREL(%rip), %rax
LBB0_12:
	movl	(%rax), %r12d
LBB0_13:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	" HPDF_CMapEncoder_AddCMap\n"

	.comm	_HPDF_CMapEncoder_ToUnicode,8,3 ## @HPDF_CMapEncoder_ToUnicode
	.comm	_HPDF_OK,4,2                    ## @HPDF_OK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_HPDF_CMapEncoder_AddCMap       ; -- Begin function HPDF_CMapEncoder_AddCMap
	.p2align	2
_HPDF_CMapEncoder_AddCMap:              ; @HPDF_CMapEncoder_AddCMap
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x1
	mov	x19, x0
	ldrsw	x23, [x0, #24]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_HPDF_PTRACE
	mov	w24, #65535
Lloh2:
	adrp	x25, _HPDF_CMapEncoder_ToUnicode@GOTPAGE
Lloh3:
	ldr	x25, [x25, _HPDF_CMapEncoder_ToUnicode@GOTPAGEOFF]
Lloh4:
	adrp	x26, _HPDF_OK@GOTPAGE
Lloh5:
	ldr	x26, [x26, _HPDF_OK@GOTPAGEOFF]
LBB0_1:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_6 Depth 2
	ldrsw	x8, [x20]
	cmp	w8, w24
	b.ne	LBB0_3
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	ldr	w9, [x20, #4]
	cmp	w9, w24
	b.eq	LBB0_11
LBB0_3:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	x9, [x19]
	ldr	x10, [x25]
	cmp	x9, x10
	b.ne	LBB0_7
; %bb.4:                                ;   in Loop: Header=BB0_1 Depth=1
	ldr	w9, [x20, #4]
	cmp	w8, w9
	b.gt	LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_1 Depth=1
	ldr	w9, [x20, #8]
	ldr	x10, [x23]
LBB0_6:                                 ;   Parent Loop BB0_1 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	asr	w11, w8, #8
	ldr	x12, [x10, x8, lsl #3]
	str	w9, [x12, w11, sxtw #2]
	add	x11, x8, #1
	add	w9, w9, #1
	ldrsw	x12, [x20, #4]
	cmp	x8, x12
	mov	x8, x11
	b.lt	LBB0_6
LBB0_7:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	w0, [x19, #8]
	mov	w1, #12
	bl	_HPDF_GetMem
	cbz	x0, LBB0_10
; %bb.8:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x21, x0
	ldr	d0, [x20]
	str	d0, [x0]
	ldr	w8, [x20, #8]
	str	w8, [x0, #8]
	ldr	w0, [x23, #8]
	mov	x1, x21
	bl	_HPDF_List_Add
	ldr	w8, [x26]
	add	x20, x20, #12
	cmp	w0, w8
	b.eq	LBB0_1
; %bb.9:
	mov	x22, x0
	ldr	w0, [x19, #8]
	mov	x1, x21
	bl	_HPDF_FreeMem
	b	LBB0_12
LBB0_10:
	ldr	x8, [x19, #16]
	ldr	w22, [x8]
	b	LBB0_12
LBB0_11:
	ldr	w22, [x26]
LBB0_12:
	mov	x0, x22
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	" HPDF_CMapEncoder_AddCMap\n"

	.comm	_HPDF_CMapEncoder_ToUnicode,8,3 ; @HPDF_CMapEncoder_ToUnicode
	.comm	_HPDF_OK,4,2                    ; @HPDF_OK
.subsections_via_symbols
