	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dump_msr_bitmap
_dump_msr_bitmap:                       ## @dump_msr_bitmap
	.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	%edx, %r13d
	movl	%esi, %r15d
	movl	%edi, %r14d
	movq	_MAP_FAILED@GOTPCREL(%rip), %rbx
	movq	(%rbx), %r12
	movq	_O_RDONLY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdi
	xorl	%edx, %edx
	callq	_open
	testl	%eax, %eax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	js	LBB0_1
## %bb.2:
	movl	%r14d, -44(%rbp)                ## 4-byte Spill
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rcx
	movl	%r15d, %r9d
	movl	(%rcx), %r15d
	leal	(%r15,%r15), %ecx
	testl	%r13d, %r13d
	movl	%r15d, %r14d
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	cmovel	%ecx, %r14d
	movq	_PROT_READ@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	_MAP_SHARED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	xorl	%edi, %edi
	movl	%r14d, %esi
	movl	%eax, %r8d
	callq	_mmap
	movq	%rax, %r12
	cmpq	(%rbx), %rax
	je	LBB0_3
## %bb.4:
	movq	%r12, %rdi
	testl	%r13d, %r13d
	je	LBB0_6
## %bb.5:
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	callq	_dump_intel_msr_pm
	xorl	%r13d, %r13d
	movl	%r15d, %r14d
	jmp	LBB0_7
LBB0_6:
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	callq	_dump_amd_msr_pm
	xorl	%r13d, %r13d
	movl	-48(%rbp), %r14d                ## 4-byte Reload
LBB0_7:
	movq	_MAP_FAILED@GOTPCREL(%rip), %rbx
	cmpq	(%rbx), %r12
	je	LBB0_10
LBB0_9:
	movq	%r12, %rdi
	movl	%r14d, %esi
	callq	_munmap
LBB0_10:
	movl	-52(%rbp), %edi                 ## 4-byte Reload
	testl	%edi, %edi
	js	LBB0_12
## %bb.11:
	callq	_close
LBB0_12:
	movl	%r13d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	leaq	L_.str.1(%rip), %rdi
	callq	_perror
	movl	$-1, %r13d
                                        ## implicit-def: $r14d
	cmpq	(%rbx), %r12
	jne	LBB0_9
	jmp	LBB0_10
LBB0_3:
	leaq	L_.str.2(%rip), %rdi
	callq	_perror
	movl	$-1, %r13d
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_MAP_FAILED,8,3                 ## @MAP_FAILED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"/dev/mem"

	.comm	_O_RDONLY,4,2                   ## @O_RDONLY
L_.str.1:                               ## @.str.1
	.asciz	"Couldn't open /dev/mem"

	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_PROT_READ,4,2                  ## @PROT_READ
	.comm	_MAP_SHARED,4,2                 ## @MAP_SHARED
L_.str.2:                               ## @.str.2
	.asciz	"mmap failed"

	.no_dead_strip	_dump_msr_bitmap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dump_msr_bitmap
_dump_msr_bitmap:                       ; @dump_msr_bitmap
	.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	x23, x2
	mov	x24, x1
	mov	x21, x0
Lloh0:
	adrp	x25, _MAP_FAILED@GOTPAGE
Lloh1:
	ldr	x25, [x25, _MAP_FAILED@GOTPAGEOFF]
	ldr	x20, [x25]
Lloh2:
	adrp	x8, _O_RDONLY@GOTPAGE
Lloh3:
	ldr	x8, [x8, _O_RDONLY@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
	mov	w2, #0
	bl	_open
	mov	x19, x0
	tbnz	w0, #31, LBB0_10
; %bb.1:
Lloh7:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh9:
	ldr	w26, [x8]
	lsl	w27, w26, #1
	cmp	w23, #0
	csel	w22, w27, w26, eq
Lloh10:
	adrp	x8, _PROT_READ@GOTPAGE
Lloh11:
	ldr	x8, [x8, _PROT_READ@GOTPAGEOFF]
Lloh12:
	ldr	w2, [x8]
Lloh13:
	adrp	x8, _MAP_SHARED@GOTPAGE
Lloh14:
	ldr	x8, [x8, _MAP_SHARED@GOTPAGEOFF]
Lloh15:
	ldr	w3, [x8]
	mov	x0, #0
	mov	x1, x22
	mov	x4, x19
	mov	x5, x24
	bl	_mmap
	mov	x20, x0
	ldr	x8, [x25]
	cmp	x0, x8
	b.eq	LBB0_11
; %bb.2:
	mov	x0, x20
	mov	x1, x21
	cbz	w23, LBB0_4
; %bb.3:
	bl	_dump_intel_msr_pm
	mov	w21, #0
	mov	x22, x26
	b	LBB0_5
LBB0_4:
	bl	_dump_amd_msr_pm
	mov	w21, #0
	mov	x22, x27
LBB0_5:
	ldr	x8, [x25]
	cmp	x20, x8
	b.eq	LBB0_7
; %bb.6:
	mov	x0, x20
	mov	x1, x22
	bl	_munmap
LBB0_7:
	tbnz	w19, #31, LBB0_9
; %bb.8:
	mov	x0, x19
	bl	_close
LBB0_9:
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_10:
Lloh16:
	adrp	x0, l_.str.1@PAGE
Lloh17:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_perror
	mov	w21, #-1
                                        ; implicit-def: $w22
	b	LBB0_5
LBB0_11:
Lloh18:
	adrp	x0, l_.str.2@PAGE
Lloh19:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_perror
	mov	w21, #-1
	b	LBB0_5
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_MAP_FAILED,8,3                 ; @MAP_FAILED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"/dev/mem"

	.comm	_O_RDONLY,4,2                   ; @O_RDONLY
l_.str.1:                               ; @.str.1
	.asciz	"Couldn't open /dev/mem"

	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_PROT_READ,4,2                  ; @PROT_READ
	.comm	_MAP_SHARED,4,2                 ; @MAP_SHARED
l_.str.2:                               ; @.str.2
	.asciz	"mmap failed"

	.no_dead_strip	_dump_msr_bitmap
.subsections_via_symbols
