	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function atmif_get_mode
_atmif_get_mode:                        ## @atmif_get_mode
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	leaq	-24(%rbp), %r14
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movl	-20(%rbp), %edi
	movq	8(%rbx), %rax
	movl	(%rax), %esi
	callq	_strcpy
	movq	_mib_netsock@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SIOCGIFMEDIA@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdx
	callq	_ioctl
	testq	%rax, %rax
	js	LBB0_1
## %bb.2:
	movq	_IFM_ATM_SDH@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -24(%rbp)
	jne	LBB0_3
## %bb.4:
	movq	_ATMIF_SUNI_MODE_SONET@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_1:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_syslog
	movq	_SNMP_ERR_GENERR@GOTPCREL(%rip), %rcx
	movq	_ATMIF_SUNI_MODE_UNKNOWN@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_3:
	movq	_ATMIF_SUNI_MODE_SDH@GOTPCREL(%rip), %rax
LBB0_5:
	movq	_SNMP_ERR_NOERROR@GOTPCREL(%rip), %rcx
LBB0_6:
	movl	(%rax), %eax
	movl	%eax, (%rbx)
	movl	(%rcx), %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_mib_netsock,4,2                ## @mib_netsock
	.comm	_SIOCGIFMEDIA,4,2               ## @SIOCGIFMEDIA
	.comm	_LOG_ERR,4,2                    ## @LOG_ERR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SIOCGIFMEDIA: %m"

	.comm	_ATMIF_SUNI_MODE_UNKNOWN,4,2    ## @ATMIF_SUNI_MODE_UNKNOWN
	.comm	_SNMP_ERR_GENERR,4,2            ## @SNMP_ERR_GENERR
	.comm	_IFM_ATM_SDH,4,2                ## @IFM_ATM_SDH
	.comm	_ATMIF_SUNI_MODE_SDH,4,2        ## @ATMIF_SUNI_MODE_SDH
	.comm	_ATMIF_SUNI_MODE_SONET,4,2      ## @ATMIF_SUNI_MODE_SONET
	.comm	_SNMP_ERR_NOERROR,4,2           ## @SNMP_ERR_NOERROR
	.no_dead_strip	_atmif_get_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function atmif_get_mode
_atmif_get_mode:                        ; @atmif_get_mode
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #8
	bl	_memset
	ldr	w0, [sp, #12]
	ldr	x8, [x19, #8]
	ldr	w1, [x8]
	bl	_strcpy
Lloh0:
	adrp	x8, _mib_netsock@GOTPAGE
Lloh1:
	ldr	x8, [x8, _mib_netsock@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x8, _SIOCGIFMEDIA@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SIOCGIFMEDIA@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x2, sp, #8
	bl	_ioctl
	tbnz	x0, #63, LBB0_2
; %bb.1:
	ldr	w8, [sp, #8]
Lloh6:
	adrp	x9, _IFM_ATM_SDH@GOTPAGE
Lloh7:
	ldr	x9, [x9, _IFM_ATM_SDH@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
Lloh9:
	adrp	x10, _ATMIF_SUNI_MODE_SDH@GOTPAGE
Lloh10:
	ldr	x10, [x10, _ATMIF_SUNI_MODE_SDH@GOTPAGEOFF]
Lloh11:
	adrp	x11, _ATMIF_SUNI_MODE_SONET@GOTPAGE
Lloh12:
	ldr	x11, [x11, _ATMIF_SUNI_MODE_SONET@GOTPAGEOFF]
	tst	w9, w8
	csel	x9, x11, x10, eq
Lloh13:
	adrp	x8, _SNMP_ERR_NOERROR@GOTPAGE
Lloh14:
	ldr	x8, [x8, _SNMP_ERR_NOERROR@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:
Lloh15:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh16:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
Lloh18:
	adrp	x1, l_.str@PAGE
Lloh19:
	add	x1, x1, l_.str@PAGEOFF
	bl	_syslog
Lloh20:
	adrp	x8, _SNMP_ERR_GENERR@GOTPAGE
Lloh21:
	ldr	x8, [x8, _SNMP_ERR_GENERR@GOTPAGEOFF]
Lloh22:
	adrp	x9, _ATMIF_SUNI_MODE_UNKNOWN@GOTPAGE
Lloh23:
	ldr	x9, [x9, _ATMIF_SUNI_MODE_UNKNOWN@GOTPAGEOFF]
LBB0_3:
	ldr	w9, [x9]
	str	w9, [x19]
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_mib_netsock,4,2                ; @mib_netsock
	.comm	_SIOCGIFMEDIA,4,2               ; @SIOCGIFMEDIA
	.comm	_LOG_ERR,4,2                    ; @LOG_ERR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SIOCGIFMEDIA: %m"

	.comm	_ATMIF_SUNI_MODE_UNKNOWN,4,2    ; @ATMIF_SUNI_MODE_UNKNOWN
	.comm	_SNMP_ERR_GENERR,4,2            ; @SNMP_ERR_GENERR
	.comm	_IFM_ATM_SDH,4,2                ; @IFM_ATM_SDH
	.comm	_ATMIF_SUNI_MODE_SDH,4,2        ; @ATMIF_SUNI_MODE_SDH
	.comm	_ATMIF_SUNI_MODE_SONET,4,2      ; @ATMIF_SUNI_MODE_SONET
	.comm	_SNMP_ERR_NOERROR,4,2           ; @SNMP_ERR_NOERROR
	.no_dead_strip	_atmif_get_mode
.subsections_via_symbols
