	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function abx500_gpio_to_irq
_abx500_gpio_to_irq:                    ## @abx500_gpio_to_irq
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movl	%esi, %ebx
	callq	_gpiochip_get_data
	movl	(%rax), %edx
	testl	%edx, %edx
	jle	LBB0_5
## %bb.1:
	incl	%ebx
	movq	16(%rax), %rcx
	shlq	$2, %rdx
	leaq	(%rdx,%rdx,2), %rdi
	xorl	%edx, %edx
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	addq	$12, %rdx
	cmpq	%rdx, %rdi
	je	LBB0_5
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ebx, %esi
	subl	(%rcx,%rdx), %esi
	jl	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	4(%rcx,%rdx), %ebx
	jg	LBB0_4
## %bb.6:
	addl	8(%rcx,%rdx), %esi
	movq	8(%rax), %rax
	movl	(%rax), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_irq_create_mapping             ## TAILCALL
LBB0_5:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_abx500_gpio_to_irq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function abx500_gpio_to_irq
_abx500_gpio_to_irq:                    ; @abx500_gpio_to_irq
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	bl	_gpiochip_get_data
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.1:
	add	w9, w19, #1
	ldr	x10, [x0, #16]
	add	x10, x10, #8
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x10, x10, #12
	subs	x8, x8, #1
	b.eq	LBB0_6
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldur	w11, [x10, #-8]
	subs	w11, w9, w11
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldur	w12, [x10, #-4]
	cmp	w9, w12
	b.gt	LBB0_2
; %bb.5:
	ldr	w8, [x10]
	add	w1, w11, w8
	ldr	x8, [x0, #8]
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_irq_create_mapping
LBB0_6:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_abx500_gpio_to_irq
.subsections_via_symbols
