	.file	"309467.c"
	.intel_syntax noprefix
	.text
	.globl	msr_get_count
	.type	msr_get_count, @function
msr_get_count:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	edi, 84
	call	sysconf@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jle	.L2
	mov	eax, 4294967295
	cmp	QWORD PTR -8[rbp], rax
	jle	.L3
.L2:
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 19
	mov	eax, 0
	jmp	.L4
.L3:
	mov	rax, QWORD PTR -8[rbp]
.L4:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	msr_get_count, .-msr_get_count
	.section	.rodata
.LC0:
	.string	"malloc"
	.text
	.globl	msr_alloc
	.type	msr_alloc, @function
msr_alloc:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	DWORD PTR -20[rbp], edi
	mov	edi, 8
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L6
	lea	rdi, .LC0[rip]
	call	perror@PLT
	mov	eax, 0
	jmp	.L7
.L6:
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -20[rbp]
	mov	DWORD PTR [rax], edx
	mov	rax, QWORD PTR -8[rbp]
.L7:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	msr_alloc, .-msr_alloc
	.globl	msr_free
	.type	msr_free, @function
msr_free:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	free@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	msr_free, .-msr_free
	.globl	msr_get_cpu
	.type	msr_get_cpu, @function
msr_get_cpu:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR [rax]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	msr_get_cpu, .-msr_get_cpu
	.section	.rodata
.LC1:
	.string	"/dev/cpu/%u/msr"
.LC2:
	.string	"%s: %s\n"
	.text
	.globl	msr_open
	.type	msr_open, @function
msr_open:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	QWORD PTR -56[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -56[rbp]
	mov	edx, DWORD PTR [rax]
	lea	rax, -48[rbp]
	mov	ecx, edx
	lea	rdx, .LC1[rip]
	mov	esi, 32
	mov	rdi, rax
	mov	eax, 0
	call	snprintf@PLT
	lea	rax, -48[rbp]
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	rdx, QWORD PTR -56[rbp]
	mov	DWORD PTR 4[rdx], eax
	mov	rax, QWORD PTR -56[rbp]
	mov	eax, DWORD PTR 4[rax]
	test	eax, eax
	jns	.L12
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rcx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rdx, -48[rbp]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, -1
	jmp	.L14
.L12:
	mov	eax, 0
.L14:
	mov	rsi, QWORD PTR -8[rbp]
	sub	rsi, QWORD PTR fs:40
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	msr_open, .-msr_open
	.section	.rodata
.LC3:
	.string	"close"
	.text
	.globl	msr_close
	.type	msr_close, @function
msr_close:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -4[rbp], 0
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4[rax]
	test	eax, eax
	jle	.L17
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4[rax]
	mov	edi, eax
	call	close@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	je	.L18
	lea	rdi, .LC3[rip]
	call	perror@PLT
.L18:
	mov	rax, QWORD PTR -24[rbp]
	mov	DWORD PTR 4[rax], 0
.L17:
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	msr_close, .-msr_close
	.globl	msr_read
	.type	msr_read, @function
msr_read:
.LFB12:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	QWORD PTR -24[rbp], rdx
	mov	edx, DWORD PTR -12[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4[rax]
	mov	rsi, QWORD PTR -24[rbp]
	mov	rcx, rdx
	mov	edx, 8
	mov	edi, eax
	call	pread@PLT
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	msr_read, .-msr_read
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"309467.c"
	.text
	.align	2
	.global	msr_get_count
	.syntax unified
	.arm
	.fpu softvfp
	.type	msr_get_count, %function
msr_get_count:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	mov	r0, #84
	bl	sysconf
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bgt	.L2
	bl	__errno_location
	mov	r3, r0
	mov	r2, #19
	str	r2, [r3]
	mov	r3, #0
	b	.L3
.L2:
	ldr	r3, [fp, #-8]
.L3:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	msr_get_count, .-msr_get_count
	.section	.rodata
	.align	2
.LC0:
	.ascii	"malloc\000"
	.text
	.align	2
	.global	msr_alloc
	.syntax unified
	.arm
	.fpu softvfp
	.type	msr_alloc, %function
msr_alloc:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	mov	r0, #8
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L5
	ldr	r0, .L7
	bl	perror
	mov	r3, #0
	b	.L6
.L5:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	str	r2, [r3]
	ldr	r3, [fp, #-8]
.L6:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L8:
	.align	2
.L7:
	.word	.LC0
	.size	msr_alloc, .-msr_alloc
	.align	2
	.global	msr_free
	.syntax unified
	.arm
	.fpu softvfp
	.type	msr_free, %function
msr_free:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r0, [fp, #-8]
	bl	free
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	msr_free, .-msr_free
	.align	2
	.global	msr_get_cpu
	.syntax unified
	.arm
	.fpu softvfp
	.type	msr_get_cpu, %function
msr_get_cpu:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	msr_get_cpu, .-msr_get_cpu
	.section	.rodata
	.align	2
.LC1:
	.ascii	"/dev/cpu/%u/msr\000"
	.align	2
.LC2:
	.ascii	"%s: %s\012\000"
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	msr_open
	.syntax unified
	.arm
	.fpu softvfp
	.type	msr_open, %function
msr_open:
	@ args = 0, pretend = 0, frame = 48
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #52
	str	r0, [fp, #-56]
	ldr	r3, .L17
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	ldr	r3, [fp, #-56]
	ldr	r3, [r3]
	sub	r0, fp, #48
	ldr	r2, .L17+4
	mov	r1, #32
	bl	snprintf
	sub	r3, fp, #48
	mov	r1, #0
	mov	r0, r3
	bl	open
	mov	r2, r0
	ldr	r3, [fp, #-56]
	str	r2, [r3, #4]
	ldr	r3, [fp, #-56]
	ldr	r3, [r3, #4]
	cmp	r3, #0
	bge	.L13
	ldr	r3, .L17+8
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	sub	r2, fp, #48
	ldr	r1, .L17+12
	mov	r0, r4
	bl	fprintf
	mvn	r3, #0
	b	.L15
.L13:
	mov	r3, #0
.L15:
	ldr	r2, .L17
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L16
	bl	__stack_chk_fail
.L16:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L18:
	.align	2
.L17:
	.word	.LC3
	.word	.LC1
	.word	stderr
	.word	.LC2
	.size	msr_open, .-msr_open
	.section	.rodata
	.align	2
.LC4:
	.ascii	"close\000"
	.text
	.align	2
	.global	msr_close
	.syntax unified
	.arm
	.fpu softvfp
	.type	msr_close, %function
msr_close:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-16]
	ldr	r3, [r3, #4]
	cmp	r3, #0
	ble	.L20
	ldr	r3, [fp, #-16]
	ldr	r3, [r3, #4]
	mov	r0, r3
	bl	close
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L21
	ldr	r0, .L23
	bl	perror
.L21:
	ldr	r3, [fp, #-16]
	mov	r2, #0
	str	r2, [r3, #4]
.L20:
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L24:
	.align	2
.L23:
	.word	.LC4
	.size	msr_close, .-msr_close
	.align	2
	.global	msr_read
	.syntax unified
	.arm
	.fpu softvfp
	.type	msr_read, %function
msr_read:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	str	r2, [fp, #-16]
	ldr	r3, [fp, #-8]
	ldr	r0, [r3, #4]
	ldr	r3, [fp, #-12]
	mov	r2, #8
	ldr	r1, [fp, #-16]
	bl	pread
	mov	r3, r0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	msr_read, .-msr_read
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
