	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dijkstra
_dijkstra:                              ## @dijkstra
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, %ebx
	movq	%rcx, %r12
	movq	%rdx, %r15
	movq	%rsi, %r13
	movl	$0, -52(%rbp)
	movq	$0, -48(%rbp)
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movl	(%rdi), %edi
	callq	_OSM_LOG_ENTER
	cmpq	$2, %r15
	jb	LBB0_3
## %bb.1:
	leaq	-1(%r15), %rax
	leaq	112(%r13), %rcx
	movq	_INF@GOTPCREL(%rip), %rdx
	movq	_UNDISCOVERED@GOTPCREL(%rip), %rsi
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	$0, (%rcx)
	movq	$0, -16(%rcx)
	movq	(%rdx), %rdi
	movq	%rdi, -48(%rcx)
	movq	(%rsi), %rdi
	movq	%rdi, -40(%rcx)
	addq	$64, %rcx
	decq	%rax
	jne	LBB0_2
LBB0_3:
	movq	(%r12), %rdi
	callq	_osm_node_get_type
	movq	_IB_NODE_TYPE_CA@GOTPCREL(%rip), %rcx
	movq	40(%r13), %r14
	cmpq	(%rcx), %rax
	jne	LBB0_19
## %bb.4:
	movq	%r13, %rdi
	callq	_set_default_vertex
	movq	(%r12), %rdi
	callq	_osm_node_get_node_guid
	movl	%eax, %edi
	callq	_cl_ntoh64
	movq	%rax, 16(%r13)
	movl	%ebx, 56(%r13)
	movq	%r14, 40(%r13)
	movq	8(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_18
## %bb.5:
	callq	_osm_link_is_healthy
	testq	%rax, %rax
	je	LBB0_18
## %bb.6:
	movq	(%r12), %rdi
	movq	8(%r12), %rax
	movl	(%rax), %esi
	leaq	-52(%rbp), %rdx
	callq	_osm_node_get_remote_node
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_osm_node_get_type
	movq	_IB_NODE_TYPE_SWITCH@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_7
## %bb.9:
	movq	40(%r13), %rdi
	testq	%rdi, %rdi
	jne	LBB0_13
## %bb.10:
	movl	$48, %edi
	callq	_malloc
	movq	%rax, %rdi
	movq	%rax, 40(%r13)
	testq	%rax, %rax
	je	LBB0_11
LBB0_13:
	callq	_set_default_link
	movq	%rbx, %rdi
	callq	_osm_node_get_node_guid
	movl	%eax, %edi
	callq	_cl_ntoh64
	movq	40(%r13), %rdx
	movq	%rax, (%rdx)
	movq	8(%r12), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 44(%rdx)
	movl	-52(%rbp), %ecx
	movl	%ecx, 40(%rdx)
	movl	$1, 8(%rdx)
	cmpq	$2, %r15
	jb	LBB0_7
## %bb.14:
	leaq	80(%r13), %rdi
	movl	$1, %esi
	xorl	%ecx, %ecx
	movq	_IB_NODE_TYPE_CA@GOTPCREL(%rip), %rbx
	.p2align	4, 0x90
LBB0_15:                                ## =>This Inner Loop Header: Depth=1
	cmpq	%rax, (%rdi)
	je	LBB0_16
## %bb.17:                              ##   in Loop: Header=BB0_15 Depth=1
	incq	%rsi
	addq	$64, %rdi
	cmpq	%rsi, %r15
	jne	LBB0_15
	jmp	LBB0_26
LBB0_19:
	testq	%r14, %r14
	je	LBB0_21
## %bb.20:
	movq	%r14, %rdi
	callq	_free
	movq	%r13, %rdi
	callq	_set_default_vertex
LBB0_21:
	movq	(%r12), %rdi
	callq	_osm_node_get_node_guid
	movl	%eax, %edi
	callq	_cl_ntoh64
	cmpq	$2, %r15
	movq	_IB_NODE_TYPE_CA@GOTPCREL(%rip), %rbx
	jb	LBB0_25
## %bb.22:
	leaq	80(%r13), %rdx
	movl	$1, %ecx
	.p2align	4, 0x90
LBB0_23:                                ## =>This Inner Loop Header: Depth=1
	cmpq	%rax, (%rdx)
	je	LBB0_26
## %bb.24:                              ##   in Loop: Header=BB0_23 Depth=1
	incq	%rcx
	addq	$64, %rdx
	cmpq	%rcx, %r15
	jne	LBB0_23
LBB0_25:
	xorl	%ecx, %ecx
	jmp	LBB0_26
LBB0_18:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	_OSM_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
LBB0_12:
	callq	_OSM_LOG
	movl	$1, %ebx
	jmp	LBB0_43
LBB0_7:
	xorl	%ecx, %ecx
	movq	_IB_NODE_TYPE_CA@GOTPCREL(%rip), %rbx
LBB0_26:
	shlq	$6, %rcx
	movq	$0, (%r13,%rcx)
	movq	_DISCOVERED@GOTPCREL(%rip), %r14
	movq	(%r14), %rax
	movq	%rax, 8(%r13,%rcx)
	movq	$0, 48(%r13,%rcx)
	movq	(%r12), %rdi
	callq	_osm_node_get_type
	cmpq	(%rbx), %rax
	jne	LBB0_28
## %bb.27:
	leaq	-48(%rbp), %rdx
	movq	%r13, %rdi
	jmp	LBB0_29
LBB0_28:
	leaq	64(%r13), %rdi
	decq	%r15
	leaq	-48(%rbp), %rdx
LBB0_29:
	movq	%r15, %rsi
	callq	_heap_create
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_31
## %bb.30:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	_OSM_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	callq	_OSM_LOG
	jmp	LBB0_43
LBB0_31:
	movq	-48(%rbp), %rdi
	callq	_heap_getmin
	testq	%rax, %rax
	je	LBB0_42
## %bb.32:
	movq	%rax, %r15
	jmp	LBB0_33
	.p2align	4, 0x90
LBB0_41:                                ##   in Loop: Header=BB0_33 Depth=1
	movq	-48(%rbp), %rdi
	callq	_heap_getmin
	movq	%rax, %r15
	testq	%rax, %rax
	je	LBB0_42
LBB0_33:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_36 Depth 2
	movq	(%r14), %rax
	movq	%rax, 8(%r15)
	movq	32(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_35
## %bb.34:                              ##   in Loop: Header=BB0_33 Depth=1
	movq	24(%rcx), %rcx
	shlq	$6, %rcx
	movq	48(%r13,%rcx), %rcx
	incq	%rcx
	movq	%rcx, 48(%r15)
LBB0_35:                                ##   in Loop: Header=BB0_33 Depth=1
	movq	40(%r15), %rbx
	testq	%rbx, %rbx
	je	LBB0_41
	.p2align	4, 0x90
LBB0_36:                                ##   Parent Loop BB0_33 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	16(%rbx), %rcx
	shlq	$6, %rcx
	cmpq	%rax, 8(%r13,%rcx)
	je	LBB0_39
## %bb.37:                              ##   in Loop: Header=BB0_36 Depth=2
	movslq	8(%rbx), %rax
	addq	(%r15), %rax
	cmpq	(%r13,%rcx), %rax
	jge	LBB0_39
## %bb.38:                              ##   in Loop: Header=BB0_36 Depth=2
	leaq	(%rcx,%r13), %rdx
	movq	%rbx, 32(%r13,%rcx)
	movq	%rax, (%rdx)
	movq	-48(%rbp), %rdi
	movl	24(%r13,%rcx), %esi
	callq	_heap_heapify
LBB0_39:                                ##   in Loop: Header=BB0_36 Depth=2
	movq	32(%rbx), %rbx
	testq	%rbx, %rbx
	je	LBB0_41
## %bb.40:                              ##   in Loop: Header=BB0_36 Depth=2
	movq	(%r14), %rax
	jmp	LBB0_36
LBB0_42:
	movq	-48(%rbp), %rdi
	callq	_heap_free
	movq	$0, -48(%rbp)
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	callq	_OSM_LOG_EXIT
	xorl	%ebx, %ebx
LBB0_43:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_16:
	movq	%rsi, 16(%rdx)
	jmp	LBB0_25
LBB0_11:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	_OSM_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_INF,8,3                        ## @INF
	.comm	_UNDISCOVERED,8,3               ## @UNDISCOVERED
	.comm	_IB_NODE_TYPE_CA,8,3            ## @IB_NODE_TYPE_CA
	.comm	_IB_NODE_TYPE_SWITCH,8,3        ## @IB_NODE_TYPE_SWITCH
	.comm	_OSM_LOG_ERROR,4,2              ## @OSM_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ERR AD07: cannot allocate memory for a link\n"

L_.str.1:                               ## @.str.1
	.asciz	"ERR AD0B: unsupported network state (CA with unhealthy link state discovered; should have been filtered out before already; gracefully shutdown this routing engine)\n"

	.comm	_DISCOVERED,8,3                 ## @DISCOVERED
L_.str.2:                               ## @.str.2
	.asciz	"ERR AD09: cannot allocate memory for heap or heap->node in heap_create(...)\n"

	.no_dead_strip	_dijkstra
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dijkstra
_dijkstra:                              ; @dijkstra
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x23, x4
	mov	x22, x3
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
	str	wzr, [sp, #12]
	str	xzr, [sp]
	ldr	w0, [x0]
	bl	_OSM_LOG_ENTER
	cmp	x21, #2
	b.lo	LBB0_3
; %bb.1:
	sub	x8, x21, #1
	add	x9, x20, #112
Lloh0:
	adrp	x10, _INF@GOTPAGE
Lloh1:
	ldr	x10, [x10, _INF@GOTPAGEOFF]
Lloh2:
	adrp	x11, _UNDISCOVERED@GOTPAGE
Lloh3:
	ldr	x11, [x11, _UNDISCOVERED@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	str	xzr, [x9]
	stur	xzr, [x9, #-16]
	ldr	x12, [x10]
	stur	x12, [x9, #-48]
	ldr	x12, [x11]
	stur	x12, [x9, #-40]
	add	x9, x9, #64
	subs	x8, x8, #1
	b.ne	LBB0_2
LBB0_3:
	ldr	x0, [x22]
	bl	_osm_node_get_type
Lloh4:
	adrp	x25, _IB_NODE_TYPE_CA@GOTPAGE
Lloh5:
	ldr	x25, [x25, _IB_NODE_TYPE_CA@GOTPAGEOFF]
	ldr	x8, [x25]
	ldr	x24, [x20, #40]
	cmp	x0, x8
	b.ne	LBB0_14
; %bb.4:
	mov	x0, x20
	bl	_set_default_vertex
	ldr	x0, [x22]
	bl	_osm_node_get_node_guid
	bl	_cl_ntoh64
	str	x0, [x20, #16]
	str	w23, [x20, #56]
	str	x24, [x20, #40]
	ldr	x0, [x22, #8]
	cbz	x0, LBB0_26
; %bb.5:
	bl	_osm_link_is_healthy
	cbz	x0, LBB0_26
; %bb.6:
	ldp	x0, x8, [x22]
	ldr	w1, [x8]
	add	x2, sp, #12
	bl	_osm_node_get_remote_node
	cbz	x0, LBB0_20
; %bb.7:
	mov	x23, x0
	bl	_osm_node_get_type
Lloh6:
	adrp	x8, _IB_NODE_TYPE_SWITCH@GOTPAGE
Lloh7:
	ldr	x8, [x8, _IB_NODE_TYPE_SWITCH@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_20
; %bb.8:
	ldr	x0, [x20, #40]
	cbnz	x0, LBB0_10
; %bb.9:
	mov	w0, #48
	bl	_malloc
	str	x0, [x20, #40]
	cbz	x0, LBB0_42
LBB0_10:
	bl	_set_default_link
	mov	x0, x23
	bl	_osm_node_get_node_guid
	bl	_cl_ntoh64
	ldr	x9, [x20, #40]
	str	x0, [x9]
	ldr	x8, [x22, #8]
	ldr	w8, [x8]
	ldr	w10, [sp, #12]
	stp	w10, w8, [x9, #40]
	mov	w8, #1
	str	w8, [x9, #8]
	cmp	x21, #2
	b.lo	LBB0_20
; %bb.11:
	add	x11, x20, #80
	mov	w10, #1
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x11]
	cmp	x8, x0
	b.eq	LBB0_41
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=1
	mov	x8, #0
	add	x10, x10, #1
	add	x11, x11, #64
	cmp	x21, x10
	b.ne	LBB0_12
	b	LBB0_21
LBB0_14:
	cbz	x24, LBB0_16
; %bb.15:
	mov	x0, x24
	bl	_free
	mov	x0, x20
	bl	_set_default_vertex
LBB0_16:
	ldr	x0, [x22]
	bl	_osm_node_get_node_guid
	bl	_cl_ntoh64
	cmp	x21, #2
	b.lo	LBB0_20
; %bb.17:
	add	x9, x20, #80
	mov	w8, #1
LBB0_18:                                ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x9]
	cmp	x10, x0
	b.eq	LBB0_21
; %bb.19:                               ;   in Loop: Header=BB0_18 Depth=1
	add	x8, x8, #1
	add	x9, x9, #64
	cmp	x21, x8
	b.ne	LBB0_18
LBB0_20:
	mov	x8, #0
LBB0_21:
	add	x8, x20, x8, lsl #6
	str	xzr, [x8]
Lloh9:
	adrp	x23, _DISCOVERED@GOTPAGE
Lloh10:
	ldr	x23, [x23, _DISCOVERED@GOTPAGEOFF]
	ldr	x9, [x23]
	str	x9, [x8, #8]
	str	xzr, [x8, #48]
	ldr	x0, [x22]
	bl	_osm_node_get_type
	ldr	x8, [x25]
	cmp	x0, x8
	b.ne	LBB0_23
; %bb.22:
	mov	x2, sp
	mov	x0, x20
	mov	x1, x21
	b	LBB0_24
LBB0_23:
	add	x0, x20, #64
	sub	x1, x21, #1
	mov	x2, sp
LBB0_24:
	bl	_heap_create
	mov	x21, x0
	cbz	w0, LBB0_28
; %bb.25:
	ldr	w0, [x19]
Lloh11:
	adrp	x8, _OSM_LOG_ERROR@GOTPAGE
Lloh12:
	ldr	x8, [x8, _OSM_LOG_ERROR@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
Lloh14:
	adrp	x2, l_.str.2@PAGE
Lloh15:
	add	x2, x2, l_.str.2@PAGEOFF
	bl	_OSM_LOG
	b	LBB0_40
LBB0_26:
	ldr	w0, [x19]
Lloh16:
	adrp	x8, _OSM_LOG_ERROR@GOTPAGE
Lloh17:
	ldr	x8, [x8, _OSM_LOG_ERROR@GOTPAGEOFF]
Lloh18:
	ldr	w1, [x8]
Lloh19:
	adrp	x2, l_.str.1@PAGE
Lloh20:
	add	x2, x2, l_.str.1@PAGEOFF
LBB0_27:
	bl	_OSM_LOG
	mov	w21, #1
	b	LBB0_40
LBB0_28:
	ldr	x0, [sp]
	bl	_heap_getmin
	cbz	x0, LBB0_39
; %bb.29:
	mov	x21, x0
	b	LBB0_31
LBB0_30:                                ;   in Loop: Header=BB0_31 Depth=1
	ldr	x0, [sp]
	bl	_heap_getmin
	mov	x21, x0
	cbz	x0, LBB0_39
LBB0_31:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_34 Depth 2
	ldr	x8, [x23]
	str	x8, [x21, #8]
	ldr	x9, [x21, #32]
	cbz	x9, LBB0_33
; %bb.32:                               ;   in Loop: Header=BB0_31 Depth=1
	ldr	x9, [x9, #24]
	add	x9, x20, x9, lsl #6
	ldr	x9, [x9, #48]
	add	x9, x9, #1
	str	x9, [x21, #48]
LBB0_33:                                ;   in Loop: Header=BB0_31 Depth=1
	ldr	x22, [x21, #40]
	cbz	x22, LBB0_30
LBB0_34:                                ;   Parent Loop BB0_31 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x10, [x22, #16]
	add	x9, x20, x10, lsl #6
	ldr	x11, [x9, #8]
	cmp	x11, x8
	b.eq	LBB0_37
; %bb.35:                               ;   in Loop: Header=BB0_34 Depth=2
	ldr	x8, [x21]
	ldrsw	x11, [x22, #8]
	ldr	x12, [x9]
	add	x8, x8, x11
	cmp	x8, x12
	b.ge	LBB0_37
; %bb.36:                               ;   in Loop: Header=BB0_34 Depth=2
	add	x10, x20, x10, lsl #6
	str	x22, [x10, #32]
	str	x8, [x9]
	ldr	x0, [sp]
	ldr	w1, [x10, #24]
	bl	_heap_heapify
LBB0_37:                                ;   in Loop: Header=BB0_34 Depth=2
	ldr	x22, [x22, #32]
	cbz	x22, LBB0_30
; %bb.38:                               ;   in Loop: Header=BB0_34 Depth=2
	ldr	x8, [x23]
	b	LBB0_34
LBB0_39:
	ldr	x0, [sp]
	bl	_heap_free
	str	xzr, [sp]
	ldr	w0, [x19]
	bl	_OSM_LOG_EXIT
	mov	w21, #0
LBB0_40:
	mov	x0, x21
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_41:
	mov	x8, #0
	str	x10, [x9, #16]
	b	LBB0_21
LBB0_42:
	ldr	w0, [x19]
Lloh21:
	adrp	x8, _OSM_LOG_ERROR@GOTPAGE
Lloh22:
	ldr	x8, [x8, _OSM_LOG_ERROR@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
Lloh24:
	adrp	x2, l_.str@PAGE
Lloh25:
	add	x2, x2, l_.str@PAGEOFF
	b	LBB0_27
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_INF,8,3                        ; @INF
	.comm	_UNDISCOVERED,8,3               ; @UNDISCOVERED
	.comm	_IB_NODE_TYPE_CA,8,3            ; @IB_NODE_TYPE_CA
	.comm	_IB_NODE_TYPE_SWITCH,8,3        ; @IB_NODE_TYPE_SWITCH
	.comm	_OSM_LOG_ERROR,4,2              ; @OSM_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ERR AD07: cannot allocate memory for a link\n"

l_.str.1:                               ; @.str.1
	.asciz	"ERR AD0B: unsupported network state (CA with unhealthy link state discovered; should have been filtered out before already; gracefully shutdown this routing engine)\n"

	.comm	_DISCOVERED,8,3                 ; @DISCOVERED
l_.str.2:                               ; @.str.2
	.asciz	"ERR AD09: cannot allocate memory for heap or heap->node in heap_create(...)\n"

	.no_dead_strip	_dijkstra
.subsections_via_symbols
