	.file	"extr_pmu.c_perf_pmu__parse_scale.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%s/%s.scale"
	.text
	.p2align 4
	.type	perf_pmu__parse_scale, @function
perf_pmu__parse_scale:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	r14
	push	r13
	.cfi_offset 14, -24
	.cfi_offset 13, -32
	mov	r13, rdi
	push	r12
	sub	rsp, 168
	.cfi_offset 12, -40
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -40[rbp], rax
	xor	eax, eax
	movsx	rax, DWORD PTR PATH_MAX[rip]
	mov	rdi, rsp
	mov	r9, rax
	add	rax, 15
	mov	rcx, rax
	and	rax, -4096
	sub	rdi, rax
	and	rcx, -16
	mov	rax, rdi
	cmp	rsp, rax
	je	.L3
.L18:
	sub	rsp, 4096
	or	QWORD PTR 4088[rsp], 0
	cmp	rsp, rax
	jne	.L18
.L3:
	and	ecx, 4095
	sub	rsp, rcx
	test	rcx, rcx
	jne	.L19
.L4:
	mov	r8, rdx
	mov	rcx, rsi
	lea	rdx, .LC0[rip]
	mov	esi, r9d
	mov	rdi, rsp
	call	scnprintf@PLT
	mov	esi, DWORD PTR O_RDONLY[rip]
	mov	rdi, rsp
	call	open@PLT
	mov	r12d, eax
	cmp	eax, -1
	je	.L12
	lea	rsi, -180[rbp]
	mov	edi, eax
	call	fstat@PLT
	test	rax, rax
	js	.L8
	lea	r14, -176[rbp]
	mov	edx, 127
	mov	edi, r12d
	mov	rsi, r14
	call	read@PLT
	test	eax, eax
	js	.L8
	lea	edx, -1[rax]
	movsx	rdx, edx
	cmp	BYTE PTR -176[rbp+rdx], 10
	je	.L20
	cdqe
	mov	BYTE PTR -176[rbp+rax], 0
.L10:
	mov	rdx, r13
	xor	esi, esi
	mov	rdi, r14
	call	perf_pmu__convert_scale@PLT
	mov	r13d, eax
.L7:
	mov	edi, r12d
	call	close@PLT
.L1:
	mov	rax, QWORD PTR -40[rbp]
	xor	rax, QWORD PTR fs:40
	jne	.L21
	lea	rsp, -24[rbp]
	mov	eax, r13d
	pop	r12
	pop	r13
	pop	r14
	pop	rbp
	.cfi_remember_state
	.cfi_def_cfa 7, 8
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore_state
	mov	r13d, -1
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L19:
	or	QWORD PTR -8[rsp+rcx], 0
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L20:
	mov	BYTE PTR -176[rbp+rdx], 0
	jmp	.L10
.L12:
	mov	r13d, -1
	jmp	.L1
.L21:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	perf_pmu__parse_scale, .-perf_pmu__parse_scale
	.comm	PATH_MAX,4,4
	.comm	O_RDONLY,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.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, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_pmu.c_perf_pmu__parse_scale.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"%s/%s.scale\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	perf_pmu__parse_scale, %function
perf_pmu__parse_scale:
	@ args = 0, pretend = 0, frame = 136
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #144
	ldr	r3, .L13
	mov	r5, r0
	ldr	lr, [r3]
	mov	r3, r1
	add	ip, lr, #7
	bic	ip, ip, #7
	sub	sp, sp, ip
	mov	r4, sp
	ldr	ip, .L13+4
	str	r2, [r4], #8
	mov	r1, lr
	mov	r0, r4
	ldr	r2, .L13+8
	ldr	ip, [ip]
	str	ip, [fp, #-16]
	mov	ip,#0
	bl	scnprintf
	ldr	r3, .L13+12
	mov	r0, r4
	ldr	r1, [r3]
	bl	open
	cmn	r0, #1
	mov	r4, r0
	beq	.L9
	sub	r1, fp, #148
	bl	fstat
	cmp	r0, #0
	blt	.L5
	mov	r2, #127
	mov	r0, r4
	sub	r1, fp, #144
	bl	read
	subs	r3, r0, #0
	blt	.L5
	sub	r2, r3, #1
	sub	r1, fp, #12
	add	r2, r1, r2
	ldrb	r1, [r2, #-132]	@ zero_extendqisi2
	sub	r0, fp, #144
	cmp	r1, #10
	movne	r2, #0
	moveq	r3, #0
	subne	r1, fp, #12
	addne	r3, r1, r3
	strbeq	r3, [r2, #-132]
	strbne	r2, [r3, #-132]
	mov	r1, #0
	mov	r2, r5
	bl	perf_pmu__convert_scale
	mov	r5, r0
	b	.L4
.L5:
	mvn	r5, #0
.L4:
	mov	r0, r4
	bl	close
.L1:
	ldr	r3, .L13+4
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L12
	mov	r0, r5
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L9:
	mov	r5, r0
	b	.L1
.L12:
	bl	__stack_chk_fail
.L14:
	.align	2
.L13:
	.word	PATH_MAX
	.word	.LC1
	.word	.LC0
	.word	O_RDONLY
	.size	perf_pmu__parse_scale, .-perf_pmu__parse_scale
	.comm	PATH_MAX,4,4
	.comm	O_RDONLY,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
