	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function thread_db_new_objfile
_thread_db_new_objfile:                 ## @thread_db_new_objfile
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	cmpb	$0, _thread_db_new_objfile.dejavu(%rip)
	jne	LBB0_6
## %bb.1:
	movq	_td_ta_new_p@GOTPCREL(%rip), %rdi
	leaq	-32(%rbp), %rsi
	callq	_dladdr
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	-32(%rbp), %rax
LBB0_3:
	testq	%rax, %rax
	jne	LBB0_5
## %bb.4:
	movq	_LIBTHREAD_DB_SO@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
LBB0_5:
	leaq	L_.str(%rip), %rdi
	movq	%rax, %rsi
	xorl	%eax, %eax
	callq	_printf_unfiltered
	movb	$1, _thread_db_new_objfile.dejavu(%rip)
LBB0_6:
	movq	_using_thread_db@GOTPCREL(%rip), %r15
	movl	(%r15), %eax
	testq	%rbx, %rbx
	je	LBB0_8
## %bb.7:
	movq	_target_has_execution@GOTPCREL(%rip), %rcx
	cmpl	$0, (%rcx)
	je	LBB0_8
## %bb.11:
	testl	%eax, %eax
	jne	LBB0_19
## %bb.12:
	movq	_inferior_ptid@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_GET_PID
	movq	_proc_handle@GOTPCREL(%rip), %r14
	movq	%rax, (%r14)
	movq	_thread_agent@GOTPCREL(%rip), %rsi
	movq	%r14, %rdi
	callq	_td_ta_new_p
	cmpl	$129, %eax
	je	LBB0_19
## %bb.13:
	cmpl	$128, %eax
	jne	LBB0_18
## %bb.14:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_printf_unfiltered
	movq	_thread_db_ops@GOTPCREL(%rip), %rdi
	callq	_push_target
	movl	$1, (%r15)
	movq	_symfile_objfile@GOTPCREL(%rip), %rax
	cmpq	%rbx, (%rax)
	jne	LBB0_16
## %bb.15:
	xorl	%edi, %edi
	cmpq	$0, (%r14)
	sete	%dil
	callq	_gdb_assert
	movq	_keep_thread_db@GOTPCREL(%rip), %rax
	movl	$1, (%rax)
LBB0_16:
	cmpq	$0, (%r14)
	je	LBB0_19
## %bb.17:
	xorl	%eax, %eax
	callq	_enable_thread_event_reporting
	xorl	%eax, %eax
	callq	_thread_db_find_new_threads
	jmp	LBB0_19
LBB0_8:
	testl	%eax, %eax
	je	LBB0_10
## %bb.9:
	movq	_proc_handle@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpq	$0, (%rax)
	sete	%dil
	callq	_gdb_assert
	movq	_thread_db_ops@GOTPCREL(%rip), %rdi
	callq	_unpush_target
	movl	$0, (%r15)
LBB0_10:
	movq	_keep_thread_db@GOTPCREL(%rip), %rax
	movl	$0, (%rax)
LBB0_19:
	movq	%rbx, %rdi
	callq	_target_new_objfile_chain
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	movl	%eax, %edi
	callq	_thread_db_err_str
	leaq	L_.str.2(%rip), %rdi
	movl	%eax, %esi
	callq	_warning
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
.zerofill __DATA,__bss,_thread_db_new_objfile.dejavu,1,2 ## @thread_db_new_objfile.dejavu
	.comm	_LIBTHREAD_DB_SO,8,3            ## @LIBTHREAD_DB_SO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Using host libthread_db library \"%s\".\n"

	.comm	_target_has_execution,4,2       ## @target_has_execution
	.comm	_using_thread_db,4,2            ## @using_thread_db
	.comm	_proc_handle,8,3                ## @proc_handle
	.comm	_thread_db_ops,4,2              ## @thread_db_ops
	.comm	_keep_thread_db,4,2             ## @keep_thread_db
	.comm	_inferior_ptid,4,2              ## @inferior_ptid
	.comm	_thread_agent,4,2               ## @thread_agent
L_.str.1:                               ## @.str.1
	.asciz	"[Thread debugging using libthread_db enabled]\n"

	.comm	_symfile_objfile,8,3            ## @symfile_objfile
L_.str.2:                               ## @.str.2
	.asciz	"Cannot initialize thread debugging library: %s"

	.no_dead_strip	_thread_db_new_objfile
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function thread_db_new_objfile
_thread_db_new_objfile:                 ; @thread_db_new_objfile
	.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
	mov	x19, x0
	adrp	x20, _thread_db_new_objfile.dejavu@PAGE
	ldrb	w8, [x20, _thread_db_new_objfile.dejavu@PAGEOFF]
	tbnz	w8, #0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x0, _td_ta_new_p@GOTPAGE
Lloh1:
	ldr	x0, [x0, _td_ta_new_p@GOTPAGEOFF]
	add	x1, sp, #8
	bl	_dladdr
	ldr	x8, [sp, #8]
	cmp	x0, #0
	csel	x8, xzr, x8, eq
Lloh2:
	adrp	x9, _LIBTHREAD_DB_SO@GOTPAGE
Lloh3:
	ldr	x9, [x9, _LIBTHREAD_DB_SO@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
	cmp	x8, #0
	csel	x8, x9, x8, eq
	str	x8, [sp]
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
	bl	_printf_unfiltered
	mov	w8, #1
	strb	w8, [x20, _thread_db_new_objfile.dejavu@PAGEOFF]
LBB0_2:
Lloh7:
	adrp	x21, _using_thread_db@GOTPAGE
Lloh8:
	ldr	x21, [x21, _using_thread_db@GOTPAGEOFF]
	ldr	w8, [x21]
	cbz	x19, LBB0_11
; %bb.3:
Lloh9:
	adrp	x9, _target_has_execution@GOTPAGE
Lloh10:
	ldr	x9, [x9, _target_has_execution@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	cbz	w9, LBB0_11
; %bb.4:
	cbnz	w8, LBB0_14
; %bb.5:
Lloh12:
	adrp	x8, _inferior_ptid@GOTPAGE
Lloh13:
	ldr	x8, [x8, _inferior_ptid@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	bl	_GET_PID
Lloh15:
	adrp	x20, _proc_handle@GOTPAGE
Lloh16:
	ldr	x20, [x20, _proc_handle@GOTPAGEOFF]
	str	x0, [x20]
Lloh17:
	adrp	x1, _thread_agent@GOTPAGE
Lloh18:
	ldr	x1, [x1, _thread_agent@GOTPAGEOFF]
	mov	x0, x20
	bl	_td_ta_new_p
	cmp	w0, #129
	b.eq	LBB0_14
; %bb.6:
	cmp	w0, #128
	b.ne	LBB0_15
; %bb.7:
Lloh19:
	adrp	x0, l_.str.1@PAGE
Lloh20:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_printf_unfiltered
Lloh21:
	adrp	x0, _thread_db_ops@GOTPAGE
Lloh22:
	ldr	x0, [x0, _thread_db_ops@GOTPAGEOFF]
	bl	_push_target
	mov	w22, #1
	str	w22, [x21]
Lloh23:
	adrp	x8, _symfile_objfile@GOTPAGE
Lloh24:
	ldr	x8, [x8, _symfile_objfile@GOTPAGEOFF]
Lloh25:
	ldr	x8, [x8]
	cmp	x8, x19
	b.ne	LBB0_9
; %bb.8:
	ldr	x8, [x20]
	cmp	x8, #0
	cset	w0, eq
	bl	_gdb_assert
Lloh26:
	adrp	x8, _keep_thread_db@GOTPAGE
Lloh27:
	ldr	x8, [x8, _keep_thread_db@GOTPAGEOFF]
Lloh28:
	str	w22, [x8]
LBB0_9:
	ldr	x8, [x20]
	cbz	x8, LBB0_14
; %bb.10:
	bl	_enable_thread_event_reporting
	bl	_thread_db_find_new_threads
	b	LBB0_14
LBB0_11:
	cbz	w8, LBB0_13
; %bb.12:
Lloh29:
	adrp	x8, _proc_handle@GOTPAGE
Lloh30:
	ldr	x8, [x8, _proc_handle@GOTPAGEOFF]
Lloh31:
	ldr	x8, [x8]
	cmp	x8, #0
	cset	w0, eq
	bl	_gdb_assert
Lloh32:
	adrp	x0, _thread_db_ops@GOTPAGE
Lloh33:
	ldr	x0, [x0, _thread_db_ops@GOTPAGEOFF]
	bl	_unpush_target
	str	wzr, [x21]
LBB0_13:
Lloh34:
	adrp	x8, _keep_thread_db@GOTPAGE
Lloh35:
	ldr	x8, [x8, _keep_thread_db@GOTPAGEOFF]
Lloh36:
	str	wzr, [x8]
LBB0_14:
	mov	x0, x19
	bl	_target_new_objfile_chain
	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_15:
	bl	_thread_db_err_str
	mov	x1, x0
Lloh37:
	adrp	x0, l_.str.2@PAGE
Lloh38:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_warning
	b	LBB0_14
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotStr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotStr	Lloh34, Lloh35, Lloh36
	.loh AdrpAdd	Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
.zerofill __DATA,__bss,_thread_db_new_objfile.dejavu,1,2 ; @thread_db_new_objfile.dejavu
	.comm	_LIBTHREAD_DB_SO,8,3            ; @LIBTHREAD_DB_SO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Using host libthread_db library \"%s\".\n"

	.comm	_target_has_execution,4,2       ; @target_has_execution
	.comm	_using_thread_db,4,2            ; @using_thread_db
	.comm	_proc_handle,8,3                ; @proc_handle
	.comm	_thread_db_ops,4,2              ; @thread_db_ops
	.comm	_keep_thread_db,4,2             ; @keep_thread_db
	.comm	_inferior_ptid,4,2              ; @inferior_ptid
	.comm	_thread_agent,4,2               ; @thread_agent
l_.str.1:                               ; @.str.1
	.asciz	"[Thread debugging using libthread_db enabled]\n"

	.comm	_symfile_objfile,8,3            ; @symfile_objfile
l_.str.2:                               ; @.str.2
	.asciz	"Cannot initialize thread debugging library: %s"

	.no_dead_strip	_thread_db_new_objfile
.subsections_via_symbols
