	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_HPDF_Type1FontDef_SetWidths    ## -- Begin function HPDF_Type1FontDef_SetWidths
	.p2align	4, 0x90
_HPDF_Type1FontDef_SetWidths:           ## @HPDF_Type1FontDef_SetWidths
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movslq	12(%rdi), %r12
	leaq	L_.str(%rip), %rdi
	callq	_HPDF_PTRACE
	movq	%r14, %rdi
	callq	_FreeWidth
	xorl	%eax, %eax
	cmpl	$65535, (%r15)                  ## imm = 0xFFFF
	je	LBB0_3
## %bb.1:
	leaq	12(%r15), %rcx
	xorl	%eax, %eax
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	incl	%eax
	cmpl	$65535, (%rcx)                  ## imm = 0xFFFF
	leaq	12(%rcx), %rcx
	jne	LBB0_2
LBB0_3:
	movl	%eax, (%r12)
	movl	8(%r14), %edi
	shll	$2, %eax
	leal	(%rax,%rax,2), %esi
	callq	_HPDF_GetMem
	testq	%rax, %rax
	je	LBB0_16
## %bb.4:
	movq	%rax, %rbx
	movl	(%r12), %eax
	shll	$2, %eax
	leal	(%rax,%rax,2), %edx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_HPDF_MemSet
	movq	%rbx, 8(%r12)
	movl	(%r12), %eax
	testl	%eax, %eax
	jle	LBB0_15
## %bb.5:
	cmpl	$1, %eax
	jne	LBB0_6
LBB0_12:
	testb	$1, %al
	je	LBB0_15
## %bb.13:
	movl	8(%r15), %eax
	movl	%eax, 8(%rbx)
	movl	(%r15), %eax
	movl	%eax, (%rbx)
	movl	4(%r15), %ecx
	movl	%ecx, 4(%rbx)
	cmpl	$32, %eax
	jne	LBB0_15
## %bb.14:
	movl	4(%r15), %eax
	movl	%eax, (%r14)
LBB0_15:
	movq	_HPDF_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_16:
	movl	4(%r14), %edi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_HPDF_Error_GetCode             ## TAILCALL
LBB0_6:
	movl	%eax, %ecx
	andl	$-2, %ecx
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_7 Depth=1
	addq	$24, %r15
	addq	$24, %rbx
	addl	$-2, %ecx
	je	LBB0_12
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movl	8(%r15), %edx
	movl	%edx, 8(%rbx)
	movl	(%r15), %edx
	movl	%edx, (%rbx)
	movl	4(%r15), %esi
	movl	%esi, 4(%rbx)
	cmpl	$32, %edx
	jne	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	4(%r15), %edx
	movl	%edx, (%r14)
LBB0_9:                                 ##   in Loop: Header=BB0_7 Depth=1
	movl	20(%r15), %edx
	movl	%edx, 20(%rbx)
	movl	12(%r15), %edx
	movl	%edx, 12(%rbx)
	movl	16(%r15), %esi
	movl	%esi, 16(%rbx)
	cmpl	$32, %edx
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_7 Depth=1
	movl	16(%r15), %edx
	movl	%edx, (%r14)
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	" HPDF_Type1FontDef_SetWidths\n"

	.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_Type1FontDef_SetWidths    ; -- Begin function HPDF_Type1FontDef_SetWidths
	.p2align	2
_HPDF_Type1FontDef_SetWidths:           ; @HPDF_Type1FontDef_SetWidths
	.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	x21, x1
	mov	x19, x0
	ldrsw	x22, [x0, #12]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_HPDF_PTRACE
	mov	x0, x19
	bl	_FreeWidth
	ldr	w8, [x21]
	mov	w9, #65535
	cmp	w8, w9
	b.ne	LBB0_2
; %bb.1:
	mov	w8, #0
	b	LBB0_4
LBB0_2:
	mov	w8, #0
	add	x10, x21, #12
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	add	w8, w8, #1
	ldr	w11, [x10], #12
	cmp	w11, w9
	b.ne	LBB0_3
LBB0_4:
	str	w8, [x22]
	ldr	w0, [x19, #8]
	add	w8, w8, w8, lsl #1
	lsl	w1, w8, #2
	bl	_HPDF_GetMem
	cbz	x0, LBB0_8
; %bb.5:
	mov	x20, x0
	ldr	w8, [x22]
	add	w8, w8, w8, lsl #1
	lsl	w2, w8, #2
	mov	w1, #0
	bl	_HPDF_MemSet
	str	x20, [x22, #8]
	ldr	w8, [x22]
	subs	w10, w8, #1
	b.lt	LBB0_28
; %bb.6:
	cmp	w10, #3
	b.hs	LBB0_9
; %bb.7:
	mov	w9, #0
	b	LBB0_22
LBB0_8:
	ldr	w0, [x19, #4]
	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	_HPDF_Error_GetCode
LBB0_9:
	mov	w9, #0
	mov	w11, #12
	umull	x11, w10, w11
	add	x11, x11, #12
	add	x13, x19, #4
	add	x12, x21, x11
	cmp	x20, x12
	add	x14, x20, x11
	ccmp	x14, x21, #0, lo
	cset	w11, hi
	cmp	x12, x19
	ccmp	x13, x21, #0, hi
	cset	w12, hi
	cmp	x14, x19
	ccmp	x20, x13, #2, hi
	b.lo	LBB0_22
; %bb.10:
	tbnz	w11, #0, LBB0_22
; %bb.11:
	tbnz	w12, #0, LBB0_22
; %bb.12:
	add	x11, x10, #1
	mov	x12, x20
	and	x9, x11, #0x1fffffffc
	add	x10, x9, x9, lsl #1
	lsl	x10, x10, #2
	add	x20, x20, x10
	add	x10, x21, x10
	add	x13, x21, #28
	movi.4s	v0, #32
	mov	x14, x9
	b	LBB0_14
LBB0_13:                                ;   in Loop: Header=BB0_14 Depth=1
	add	x13, x13, #48
	add	x12, x12, #48
	subs	x14, x14, #4
	b.eq	LBB0_27
LBB0_14:                                ; =>This Inner Loop Header: Depth=1
	ldur	q1, [x13, #4]
	ldur	q2, [x13, #-28]
	mov.16b	v3, v2
	mov.s	v3[1], v2[3]
	ldur	q4, [x13, #-12]
	mov.s	v3[2], v4[2]
	mov.s	v3[3], v1[1]
	stp	q2, q4, [x12]
	str	q1, [x12, #32]
	cmeq.4s	v1, v3, v0
	xtn.4h	v1, v1
	umov.h	w15, v1[0]
	tbz	w15, #0, LBB0_18
; %bb.15:                               ;   in Loop: Header=BB0_14 Depth=1
	ldur	w15, [x13, #-24]
	str	w15, [x19]
	umov.h	w15, v1[1]
	tbnz	w15, #0, LBB0_19
LBB0_16:                                ;   in Loop: Header=BB0_14 Depth=1
	umov.h	w15, v1[2]
	tbz	w15, #0, LBB0_20
LBB0_17:                                ;   in Loop: Header=BB0_14 Depth=1
	ldr	w15, [x13]
	str	w15, [x19]
	umov.h	w15, v1[3]
	tbz	w15, #0, LBB0_13
	b	LBB0_21
LBB0_18:                                ;   in Loop: Header=BB0_14 Depth=1
	umov.h	w15, v1[1]
	tbz	w15, #0, LBB0_16
LBB0_19:                                ;   in Loop: Header=BB0_14 Depth=1
	ldur	w15, [x13, #-12]
	str	w15, [x19]
	umov.h	w15, v1[2]
	tbnz	w15, #0, LBB0_17
LBB0_20:                                ;   in Loop: Header=BB0_14 Depth=1
	umov.h	w15, v1[3]
	tbz	w15, #0, LBB0_13
LBB0_21:                                ;   in Loop: Header=BB0_14 Depth=1
	ldr	w15, [x13, #12]
	str	w15, [x19]
	b	LBB0_13
LBB0_22:
	mov	x10, x21
LBB0_23:
	sub	w8, w8, w9
	add	x9, x20, #8
	add	x10, x10, #8
	b	LBB0_25
LBB0_24:                                ;   in Loop: Header=BB0_25 Depth=1
	add	x9, x9, #12
	add	x10, x10, #12
	subs	w8, w8, #1
	b.eq	LBB0_28
LBB0_25:                                ; =>This Inner Loop Header: Depth=1
	ldr	w11, [x10]
	str	w11, [x9]
	ldur	d0, [x10, #-8]
	stur	d0, [x9, #-8]
	fmov	w11, s0
	cmp	w11, #32
	b.ne	LBB0_24
; %bb.26:                               ;   in Loop: Header=BB0_25 Depth=1
	ldur	w11, [x10, #-4]
	str	w11, [x19]
	b	LBB0_24
LBB0_27:
	cmp	x11, x9
	b.ne	LBB0_23
LBB0_28:
Lloh2:
	adrp	x8, _HPDF_OK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _HPDF_OK@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	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
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	" HPDF_Type1FontDef_SetWidths\n"

	.comm	_HPDF_OK,4,2                    ; @HPDF_OK
.subsections_via_symbols
