	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function TOOLBAR_MeasureString
_TOOLBAR_MeasureString:                 ## @TOOLBAR_MeasureString
	.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, %r14d
	movq	$0, (%rcx)
	xorl	%edx, %edx
	cmpq	$0, (%rdi)
	jle	LBB0_3
## %bb.1:
	movq	%rsi, %r15
	movq	_TBSTATE_HIDDEN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rsi)
	je	LBB0_4
LBB0_3:
	xorl	%esi, %esi
LBB0_11:
	leaq	L_.str(%rip), %rdi
	callq	_TRACE
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	%rcx, %rbx
	movq	_TBSTYLE_EX_MIXEDBUTTONS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 8(%rdi)
	je	LBB0_6
## %bb.5:
	movq	_BTNS_SHOWTEXT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	$0, %esi
	testl	%eax, 4(%r15)
	je	LBB0_11
LBB0_6:
	movq	%r15, %rsi
	callq	_TOOLBAR_GetText
	testq	%rax, %rax
	je	LBB0_10
## %bb.7:
	movq	%rax, %r12
	movq	%rax, %rdi
	callq	_strlenW
	movl	%r14d, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	movq	%rbx, %rcx
	callq	_GetTextExtentPoint32W
	movl	(%rbx), %r8d
	movl	4(%rbx), %ecx
	leaq	-48(%rbp), %r13
	movq	%r13, %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_SetRect
	movq	_DT_VCENTER@GOTPCREL(%rip), %rax
	movq	_DT_SINGLELINE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r8d
	orl	(%rax), %r8d
	movq	_DT_CALCRECT@GOTPCREL(%rip), %rax
	orl	(%rax), %r8d
	movq	_BTNS_NOPREFIX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	4(%r15), %eax
	je	LBB0_9
## %bb.8:
	movq	_DT_NOPREFIX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_9:
	orl	%eax, %r8d
	movl	%r14d, %edi
	movq	%r12, %rsi
	movl	$-1, %edx
	movq	%r13, %rcx
	callq	_DrawTextW
	movl	-44(%rbp), %esi
	movl	%esi, 4(%rbx)
	movl	-48(%rbp), %edx
	movl	%edx, (%rbx)
	jmp	LBB0_11
LBB0_10:
	movl	(%rbx), %edx
	movl	4(%rbx), %esi
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_TBSTATE_HIDDEN,4,2             ## @TBSTATE_HIDDEN
	.comm	_TBSTYLE_EX_MIXEDBUTTONS,4,2    ## @TBSTYLE_EX_MIXEDBUTTONS
	.comm	_BTNS_SHOWTEXT,4,2              ## @BTNS_SHOWTEXT
	.comm	_DT_VCENTER,4,2                 ## @DT_VCENTER
	.comm	_DT_SINGLELINE,4,2              ## @DT_SINGLELINE
	.comm	_DT_CALCRECT,4,2                ## @DT_CALCRECT
	.comm	_BTNS_NOPREFIX,4,2              ## @BTNS_NOPREFIX
	.comm	_DT_NOPREFIX,4,2                ## @DT_NOPREFIX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"string size %d x %d!\n"

	.no_dead_strip	_TOOLBAR_MeasureString
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function TOOLBAR_MeasureString
_TOOLBAR_MeasureString:                 ; @TOOLBAR_MeasureString
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	str	xzr, [x3]
	ldr	x8, [x0]
	cmp	x8, #1
	b.lt	LBB0_2
; %bb.1:
	mov	x21, x1
	ldr	w8, [x1]
Lloh0:
	adrp	x9, _TBSTATE_HIDDEN@GOTPAGE
Lloh1:
	ldr	x9, [x9, _TBSTATE_HIDDEN@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
LBB0_2:
	mov	w2, #0
	mov	w1, #0
LBB0_3:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_TRACE
	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
	add	sp, sp, #64
	ret
LBB0_4:
	mov	x19, x3
	mov	x20, x2
	ldr	w8, [x0, #8]
Lloh5:
	adrp	x9, _TBSTYLE_EX_MIXEDBUTTONS@GOTPAGE
Lloh6:
	ldr	x9, [x9, _TBSTYLE_EX_MIXEDBUTTONS@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_6
; %bb.5:
	ldr	w8, [x21, #4]
Lloh8:
	adrp	x9, _BTNS_SHOWTEXT@GOTPAGE
Lloh9:
	ldr	x9, [x9, _BTNS_SHOWTEXT@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_2
LBB0_6:
	mov	x1, x21
	bl	_TOOLBAR_GetText
	cbz	x0, LBB0_8
; %bb.7:
	mov	x22, x0
	bl	_strlenW
	mov	x2, x0
	mov	x0, x20
	mov	x1, x22
	mov	x3, x19
	bl	_GetTextExtentPoint32W
	ldp	w4, w3, [x19]
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #0
	bl	_SetRect
Lloh11:
	adrp	x8, _DT_VCENTER@GOTPAGE
Lloh12:
	ldr	x8, [x8, _DT_VCENTER@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
Lloh14:
	adrp	x9, _DT_SINGLELINE@GOTPAGE
Lloh15:
	ldr	x9, [x9, _DT_SINGLELINE@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh17:
	adrp	x9, _DT_CALCRECT@GOTPAGE
Lloh18:
	ldr	x9, [x9, _DT_CALCRECT@GOTPAGEOFF]
Lloh19:
	ldr	w9, [x9]
	orr	w8, w8, w9
	ldr	w9, [x21, #4]
Lloh20:
	adrp	x10, _BTNS_NOPREFIX@GOTPAGE
Lloh21:
	ldr	x10, [x10, _BTNS_NOPREFIX@GOTPAGEOFF]
Lloh22:
	ldr	w10, [x10]
Lloh23:
	adrp	x11, _DT_NOPREFIX@GOTPAGE
Lloh24:
	ldr	x11, [x11, _DT_NOPREFIX@GOTPAGEOFF]
Lloh25:
	ldr	w11, [x11]
	tst	w10, w9
	csel	w9, wzr, w11, eq
	orr	w4, w8, w9
	add	x3, sp, #8
	mov	x0, x20
	mov	x1, x22
	mov	w2, #-1
	bl	_DrawTextW
	ldp	w2, w1, [sp, #8]
	stp	w2, w1, [x19]
	b	LBB0_3
LBB0_8:
	ldp	w2, w1, [x19]
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_TBSTATE_HIDDEN,4,2             ; @TBSTATE_HIDDEN
	.comm	_TBSTYLE_EX_MIXEDBUTTONS,4,2    ; @TBSTYLE_EX_MIXEDBUTTONS
	.comm	_BTNS_SHOWTEXT,4,2              ; @BTNS_SHOWTEXT
	.comm	_DT_VCENTER,4,2                 ; @DT_VCENTER
	.comm	_DT_SINGLELINE,4,2              ; @DT_SINGLELINE
	.comm	_DT_CALCRECT,4,2                ; @DT_CALCRECT
	.comm	_BTNS_NOPREFIX,4,2              ; @BTNS_NOPREFIX
	.comm	_DT_NOPREFIX,4,2                ; @DT_NOPREFIX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"string size %d x %d!\n"

	.no_dead_strip	_TOOLBAR_MeasureString
.subsections_via_symbols
