	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_madrpc_init                    ## -- Begin function madrpc_init
	.p2align	4, 0x90
_madrpc_init:                           ## @madrpc_init
	.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	%ecx, %r14d
	movq	%rdx, %r15
	movl	%esi, %ebx
	movq	%rdi, %r13
	xorl	%eax, %eax
	callq	_umad_init
	testq	%rax, %rax
	jns	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_IBPANIC
LBB0_2:
	movq	%r13, %rdi
	movl	%ebx, %esi
	callq	_umad_open_port
	movl	%eax, %r12d
	testl	%eax, %eax
	jns	LBB0_4
## %bb.3:
	testq	%r13, %r13
	leaq	L_.str.2(%rip), %rsi
	cmovneq	%r13, %rsi
	leaq	L_.str.1(%rip), %rdi
	movl	%ebx, %edx
	xorl	%eax, %eax
	callq	_IBPANIC
LBB0_4:
	movq	_MAX_CLASS@GOTPCREL(%rip), %rax
	cmpl	%r14d, (%rax)
	jg	LBB0_6
## %bb.5:
	leaq	L_.str.3(%rip), %rdi
	movl	%r14d, %esi
	xorl	%eax, %eax
	callq	_IBPANIC
LBB0_6:
	movq	_ibmp@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	%r12d, (%rax)
	movl	4(%rax), %edi
	movl	$255, %esi
	movl	$4, %edx
	callq	_memset
	testl	%r14d, %r14d
	je	LBB0_11
## %bb.7:
	movl	%r14d, %r12d
	movq	_IB_SA_CLASS@GOTPCREL(%rip), %r14
	xorl	%r13d, %r13d
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_8 Depth=1
	incq	%r13
	cmpl	%r13d, %r12d
	je	LBB0_11
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r15,%r13,4), %ebx
	xorl	%esi, %esi
	cmpl	(%r14), %ebx
	sete	%sil
	movq	_ibmp@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movl	%ebx, %edi
	callq	_mad_register_client_via
	testq	%rax, %rax
	jns	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	leaq	L_.str.4(%rip), %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_IBPANIC
	jmp	LBB0_10
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"can't init UMAD library"

L_.str.1:                               ## @.str.1
	.asciz	"can't open UMAD port (%s:%d)"

L_.str.2:                               ## @.str.2
	.asciz	"(nil)"

	.comm	_MAX_CLASS,4,2                  ## @MAX_CLASS
L_.str.3:                               ## @.str.3
	.asciz	"too many classes %d requested"

	.comm	_ibmp,8,3                       ## @ibmp
	.comm	_IB_SA_CLASS,4,2                ## @IB_SA_CLASS
L_.str.4:                               ## @.str.4
	.asciz	"client_register for mgmt class %d failed"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_madrpc_init                    ; -- Begin function madrpc_init
	.p2align	2
_madrpc_init:                           ; @madrpc_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x3
	mov	x20, x2
	mov	x22, x1
	mov	x23, x0
	bl	_umad_init
	tbz	x0, #63, LBB0_2
; %bb.1:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_IBPANIC
LBB0_2:
	mov	x0, x23
	mov	x1, x22
	bl	_umad_open_port
	mov	x21, x0
	tbz	w0, #31, LBB0_4
; %bb.3:
Lloh2:
	adrp	x8, l_.str.2@PAGE
Lloh3:
	add	x8, x8, l_.str.2@PAGEOFF
	cmp	x23, #0
	csel	x8, x8, x23, eq
	stp	x8, x22, [sp]
Lloh4:
	adrp	x0, l_.str.1@PAGE
Lloh5:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_IBPANIC
LBB0_4:
Lloh6:
	adrp	x8, _MAX_CLASS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MAX_CLASS@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmp	w8, w19
	b.gt	LBB0_6
; %bb.5:
	str	x19, [sp]
Lloh9:
	adrp	x0, l_.str.3@PAGE
Lloh10:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_IBPANIC
LBB0_6:
Lloh11:
	adrp	x23, _ibmp@GOTPAGE
Lloh12:
	ldr	x23, [x23, _ibmp@GOTPAGEOFF]
	ldr	x8, [x23]
	str	w21, [x8]
	ldr	w0, [x8, #4]
	mov	w1, #255
	mov	w2, #4
	bl	_memset
	cbz	w19, LBB0_11
; %bb.7:
Lloh13:
	adrp	x24, _IB_SA_CLASS@GOTPAGE
Lloh14:
	ldr	x24, [x24, _IB_SA_CLASS@GOTPAGEOFF]
Lloh15:
	adrp	x21, l_.str.4@PAGE
Lloh16:
	add	x21, x21, l_.str.4@PAGEOFF
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	cbz	w19, LBB0_11
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	sub	w19, w19, #1
	ldr	w22, [x20], #4
	ldr	w8, [x24]
	cmp	w22, w8
	cset	w1, eq
	ldr	x2, [x23]
	mov	x0, x22
	bl	_mad_register_client_via
	tbz	x0, #63, LBB0_8
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	str	x22, [sp]
	mov	x0, x21
	bl	_IBPANIC
	b	LBB0_8
LBB0_11:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"can't init UMAD library"

l_.str.1:                               ; @.str.1
	.asciz	"can't open UMAD port (%s:%d)"

l_.str.2:                               ; @.str.2
	.asciz	"(nil)"

	.comm	_MAX_CLASS,4,2                  ; @MAX_CLASS
l_.str.3:                               ; @.str.3
	.asciz	"too many classes %d requested"

	.comm	_ibmp,8,3                       ; @ibmp
	.comm	_IB_SA_CLASS,4,2                ; @IB_SA_CLASS
l_.str.4:                               ; @.str.4
	.asciz	"client_register for mgmt class %d failed"

.subsections_via_symbols
