	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ada_search_struct_field        ## -- Begin function ada_search_struct_field
	.p2align	4, 0x90
_ada_search_struct_field:               ## @ada_search_struct_field
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %rbx
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	movq	%rcx, %rdi
	callq	_CHECK_TYPEDEF
	movq	%rbx, %rdi
	callq	_TYPE_NFIELDS
	testl	%eax, %eax
	jle	LBB0_7
## %bb.1:
	movl	%eax, %r12d
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_TYPE_FIELD_BITPOS
                                        ## kill: def $eax killed $eax def $rax
	leal	7(%rax), %ebx
	testl	%eax, %eax
	cmovnsl	%eax, %ebx
	sarl	$3, %ebx
	addl	-44(%rbp), %ebx                 ## 4-byte Folded Reload
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_TYPE_FIELD_TYPE
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	movl	%ebx, %edx
	movq	%rax, %rcx
	callq	_ada_search_struct_field
	testq	%rax, %rax
	jne	LBB0_12
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$1, -80(%rbp)                   ## 4-byte Folded Reload
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	jle	LBB0_7
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_10 Depth 2
	movl	%r12d, %ecx
	movq	%rcx, -80(%rbp)                 ## 8-byte Spill
	leal	-1(%rcx), %r12d
	movq	%rbx, %rdi
	movl	%r12d, %esi
	callq	_TYPE_FIELD_NAME
	testq	%rax, %rax
	je	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, %rdi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	callq	_field_name_match
	testq	%rax, %rax
	jne	LBB0_13
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_ada_is_wrapper_field
	testq	%rax, %rax
	jne	LBB0_5
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_ada_is_variant_part
	testq	%rax, %rax
	je	LBB0_6
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movl	%r12d, %esi
	callq	_TYPE_FIELD_TYPE
	movq	%rax, %rdi
	callq	_check_typedef
	movq	%rax, %r14
	movq	%rbx, %rdi
	movl	%r12d, %esi
	callq	_TYPE_FIELD_BITPOS
                                        ## kill: def $eax killed $eax def $rax
	leal	7(%rax), %r13d
	testl	%eax, %eax
	cmovnsl	%eax, %r13d
	sarl	$3, %r13d
	addl	-44(%rbp), %r13d                ## 4-byte Folded Reload
	movq	%r14, %rdi
	callq	_TYPE_NFIELDS
	movl	%eax, %r15d
	.p2align	4, 0x90
LBB0_10:                                ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	testl	%r15d, %r15d
	jle	LBB0_6
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=2
	decl	%r15d
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_TYPE_FIELD_BITPOS
                                        ## kill: def $eax killed $eax def $rax
	leal	7(%rax), %ebx
	testl	%eax, %eax
	cmovnsl	%eax, %ebx
	sarl	$3, %ebx
	addl	%r13d, %ebx
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_TYPE_FIELD_TYPE
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	movl	%ebx, %edx
	movq	%rax, %rcx
	callq	_ada_search_struct_field
	testq	%rax, %rax
	je	LBB0_10
	jmp	LBB0_12
LBB0_7:
	xorl	%eax, %eax
LBB0_12:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	movl	%r12d, %edx
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ada_value_primitive_field      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ada_search_struct_field        ; -- Begin function ada_search_struct_field
	.p2align	2
_ada_search_struct_field:               ; @ada_search_struct_field
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x3
	mov	x20, x2
	mov	x21, x1
	mov	x22, x0
	mov	x0, x3
	bl	_CHECK_TYPEDEF
	mov	x0, x19
	bl	_TYPE_NFIELDS
	cmp	w0, #1
	b.lt	LBB0_11
; %bb.1:
	mov	x23, x0
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	mov	x1, x23
	bl	_TYPE_FIELD_BITPOS
	add	w8, w0, #7
	cmp	w0, #0
	csel	w8, w8, w0, lt
	add	w24, w20, w8, asr #3
	mov	x0, x19
	mov	x1, x23
	bl	_TYPE_FIELD_TYPE
	mov	x3, x0
	mov	x0, x22
	mov	x1, x21
	mov	x2, x24
	bl	_ada_search_struct_field
	cbnz	x0, LBB0_12
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	cmp	w27, #1
	b.le	LBB0_11
LBB0_4:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_9 Depth 2
	mov	x27, x23
	sub	w23, w23, #1
	mov	x0, x19
	mov	x1, x23
	bl	_TYPE_FIELD_NAME
	cbz	x0, LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x1, x22
	bl	_field_name_match
	cbnz	x0, LBB0_13
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	mov	x1, x23
	bl	_ada_is_wrapper_field
	cbnz	x0, LBB0_2
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	mov	x1, x23
	bl	_ada_is_variant_part
	cbz	x0, LBB0_3
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x0, x19
	mov	x1, x23
	bl	_TYPE_FIELD_TYPE
	bl	_check_typedef
	mov	x24, x0
	mov	x0, x19
	mov	x1, x23
	bl	_TYPE_FIELD_BITPOS
	add	w8, w0, #7
	cmp	w0, #0
	csel	w8, w8, w0, lt
	add	w28, w20, w8, asr #3
	mov	x0, x24
	bl	_TYPE_NFIELDS
	mov	x25, x0
LBB0_9:                                 ;   Parent Loop BB0_4 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	subs	w25, w25, #1
	b.lt	LBB0_3
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=2
	mov	x0, x24
	mov	x1, x25
	bl	_TYPE_FIELD_BITPOS
	add	w8, w0, #7
	cmp	w0, #0
	csel	w8, w8, w0, lt
	add	w26, w28, w8, asr #3
	mov	x0, x24
	mov	x1, x25
	bl	_TYPE_FIELD_TYPE
	mov	x3, x0
	mov	x0, x22
	mov	x1, x21
	mov	x2, x26
	bl	_ada_search_struct_field
	cbz	x0, LBB0_9
	b	LBB0_12
LBB0_11:
	mov	x0, #0
LBB0_12:
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_13:
	mov	x0, x21
	mov	x1, x20
	mov	x2, x23
	mov	x3, x19
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_ada_value_primitive_field
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
