	.file	"139841.c"
	.intel_syntax noprefix
	.text
	.globl	array_size
	.data
	.align 4
	.type	array_size, @object
	.size	array_size, 4
array_size:
	.long	10000000
	.text
	.globl	gen_array
	.type	gen_array, @function
gen_array:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 40
	.cfi_offset 3, -24
	mov	DWORD PTR -36[rbp], edi
	mov	eax, DWORD PTR -36[rbp]
	cdqe
	sal	rax, 3
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR -24[rbp], rax
	mov	DWORD PTR -28[rbp], 0
	jmp	.L2
.L3:
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	lea	rbx, [rdx+rax]
	call	drand48@PLT
	movq	rax, xmm0
	mov	QWORD PTR [rbx], rax
	add	DWORD PTR -28[rbp], 1
.L2:
	mov	eax, DWORD PTR -28[rbp]
	cmp	eax, DWORD PTR -36[rbp]
	jl	.L3
	mov	rax, QWORD PTR -24[rbp]
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	gen_array, .-gen_array
	.globl	dotp_naive
	.type	dotp_naive, @function
dotp_naive:
.LFB7:
	.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 -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	mov	DWORD PTR -36[rbp], edx
	pxor	xmm0, xmm0
	movsd	QWORD PTR -8[rbp], xmm0
	mov	DWORD PTR -12[rbp], 0
	jmp	.L6
.L7:
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	movsd	xmm1, QWORD PTR [rax]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -32[rbp]
	add	rax, rdx
	movsd	xmm0, QWORD PTR [rax]
	mulsd	xmm0, xmm1
	movsd	xmm1, QWORD PTR -8[rbp]
	addsd	xmm0, xmm1
	movsd	QWORD PTR -8[rbp], xmm0
	add	DWORD PTR -12[rbp], 1
.L6:
	mov	eax, DWORD PTR -12[rbp]
	cmp	eax, DWORD PTR -36[rbp]
	jl	.L7
	movsd	xmm0, QWORD PTR -8[rbp]
	movq	rax, xmm0
	movq	xmm0, rax
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	dotp_naive, .-dotp_naive
	.globl	dotp_manual_optimized
	.type	dotp_manual_optimized, @function
dotp_manual_optimized:
.LFB8:
	.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 -40[rbp], rdi
	mov	QWORD PTR -48[rbp], rsi
	mov	DWORD PTR -52[rbp], edx
	pxor	xmm0, xmm0
	movsd	QWORD PTR -8[rbp], xmm0
	pxor	xmm0, xmm0
	movsd	QWORD PTR -16[rbp], xmm0
	pxor	xmm0, xmm0
	movsd	QWORD PTR -16[rbp], xmm0
	mov	DWORD PTR -20[rbp], 0
	jmp	.L10
.L11:
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -40[rbp]
	add	rax, rdx
	movsd	xmm1, QWORD PTR [rax]
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	movsd	xmm0, QWORD PTR [rax]
	mulsd	xmm0, xmm1
	movsd	xmm1, QWORD PTR -16[rbp]
	addsd	xmm0, xmm1
	movsd	QWORD PTR -16[rbp], xmm0
	add	DWORD PTR -20[rbp], 1
.L10:
	mov	eax, DWORD PTR -20[rbp]
	cmp	eax, DWORD PTR -52[rbp]
	jl	.L11
	movsd	xmm0, QWORD PTR -8[rbp]
	addsd	xmm0, QWORD PTR -16[rbp]
	movsd	QWORD PTR -8[rbp], xmm0
	movsd	xmm0, QWORD PTR -8[rbp]
	movq	rax, xmm0
	movq	xmm0, rax
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	dotp_manual_optimized, .-dotp_manual_optimized
	.globl	dotp_reduction_optimized
	.type	dotp_reduction_optimized, @function
dotp_reduction_optimized:
.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 -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	mov	DWORD PTR -36[rbp], edx
	pxor	xmm0, xmm0
	movsd	QWORD PTR -8[rbp], xmm0
	mov	DWORD PTR -12[rbp], 0
	jmp	.L14
.L15:
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	movsd	xmm1, QWORD PTR [rax]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -32[rbp]
	add	rax, rdx
	movsd	xmm0, QWORD PTR [rax]
	mulsd	xmm0, xmm1
	movsd	xmm1, QWORD PTR -8[rbp]
	addsd	xmm0, xmm1
	movsd	QWORD PTR -8[rbp], xmm0
	add	DWORD PTR -12[rbp], 1
.L14:
	mov	eax, DWORD PTR -12[rbp]
	cmp	eax, DWORD PTR -36[rbp]
	jl	.L15
	movsd	xmm0, QWORD PTR -8[rbp]
	movq	rax, xmm0
	movq	xmm0, rax
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	dotp_reduction_optimized, .-dotp_reduction_optimized
	.section	.rodata
	.align 8
.LC1:
	.string	"Naive solution took %f seconds\n"
	.align 8
.LC2:
	.string	"Manual Optimized: %d thread(s) took %f seconds\n"
.LC5:
	.string	"Incorrect result!"
	.align 8
.LC6:
	.string	"Reduction Optimized: %d thread(s) took %f seconds\n"
	.align 8
.LC7:
	.string	"Naive: %d thread(s) took %f seconds\n"
	.text
	.globl	main
	.type	main, @function
main:
.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, 96
	mov	eax, DWORD PTR array_size[rip]
	mov	edi, eax
	call	gen_array
	mov	QWORD PTR -32[rbp], rax
	mov	eax, DWORD PTR array_size[rip]
	mov	edi, eax
	call	gen_array
	mov	QWORD PTR -24[rbp], rax
	mov	DWORD PTR -84[rbp], 0
	call	omp_get_wtime@PLT
	movq	rax, xmm0
	mov	QWORD PTR -16[rbp], rax
	mov	DWORD PTR -80[rbp], 0
	jmp	.L18
.L21:
	pxor	xmm0, xmm0
	movsd	QWORD PTR -48[rbp], xmm0
	mov	DWORD PTR -76[rbp], 0
	jmp	.L19
.L20:
	mov	eax, DWORD PTR -76[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -32[rbp]
	add	rax, rdx
	movsd	xmm1, QWORD PTR [rax]
	mov	eax, DWORD PTR -76[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	movsd	xmm0, QWORD PTR [rax]
	mulsd	xmm0, xmm1
	movsd	xmm1, QWORD PTR -48[rbp]
	addsd	xmm0, xmm1
	movsd	QWORD PTR -48[rbp], xmm0
	add	DWORD PTR -76[rbp], 1
.L19:
	mov	eax, DWORD PTR array_size[rip]
	cmp	DWORD PTR -76[rbp], eax
	jl	.L20
	add	DWORD PTR -80[rbp], 1
.L18:
	cmp	DWORD PTR -80[rbp], 99
	jle	.L21
	call	omp_get_wtime@PLT
	movq	rax, xmm0
	movq	xmm0, rax
	subsd	xmm0, QWORD PTR -16[rbp]
	movsd	QWORD PTR -8[rbp], xmm0
	mov	rax, QWORD PTR -8[rbp]
	movq	xmm0, rax
	lea	rdi, .LC1[rip]
	mov	eax, 1
	call	printf@PLT
	call	omp_get_max_threads@PLT
	mov	DWORD PTR -52[rbp], eax
	mov	DWORD PTR -72[rbp], 1
	jmp	.L22
.L28:
	mov	eax, DWORD PTR -72[rbp]
	mov	edi, eax
	call	omp_set_num_threads@PLT
	call	omp_get_wtime@PLT
	movq	rax, xmm0
	mov	QWORD PTR -16[rbp], rax
	mov	DWORD PTR -68[rbp], 0
	jmp	.L23
.L24:
	mov	edx, DWORD PTR array_size[rip]
	mov	rcx, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -32[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	dotp_manual_optimized
	movq	rax, xmm0
	mov	QWORD PTR -40[rbp], rax
	add	DWORD PTR -68[rbp], 1
.L23:
	cmp	DWORD PTR -68[rbp], 99
	jle	.L24
	call	omp_get_wtime@PLT
	movq	rax, xmm0
	movq	xmm0, rax
	subsd	xmm0, QWORD PTR -16[rbp]
	movsd	QWORD PTR -8[rbp], xmm0
	mov	rdx, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR -72[rbp]
	movq	xmm0, rdx
	mov	esi, eax
	lea	rdi, .LC2[rip]
	mov	eax, 1
	call	printf@PLT
	movsd	xmm0, QWORD PTR -48[rbp]
	subsd	xmm0, QWORD PTR -40[rbp]
	movq	xmm1, QWORD PTR .LC3[rip]
	andpd	xmm0, xmm1
	comisd	xmm0, QWORD PTR .LC4[rip]
	jbe	.L40
	lea	rdi, .LC5[rip]
	call	puts@PLT
	mov	DWORD PTR -84[rbp], -1
	jmp	.L27
.L40:
	add	DWORD PTR -72[rbp], 1
.L22:
	mov	eax, DWORD PTR -72[rbp]
	cmp	eax, DWORD PTR -52[rbp]
	jle	.L28
	mov	DWORD PTR -64[rbp], 1
	jmp	.L29
.L34:
	mov	eax, DWORD PTR -64[rbp]
	mov	edi, eax
	call	omp_set_num_threads@PLT
	call	omp_get_wtime@PLT
	movq	rax, xmm0
	mov	QWORD PTR -16[rbp], rax
	mov	DWORD PTR -60[rbp], 0
	jmp	.L30
.L31:
	mov	edx, DWORD PTR array_size[rip]
	mov	rcx, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -32[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	dotp_reduction_optimized
	movq	rax, xmm0
	mov	QWORD PTR -40[rbp], rax
	add	DWORD PTR -60[rbp], 1
.L30:
	cmp	DWORD PTR -60[rbp], 99
	jle	.L31
	call	omp_get_wtime@PLT
	movq	rax, xmm0
	movq	xmm0, rax
	subsd	xmm0, QWORD PTR -16[rbp]
	movsd	QWORD PTR -8[rbp], xmm0
	mov	rdx, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR -64[rbp]
	movq	xmm0, rdx
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 1
	call	printf@PLT
	movsd	xmm0, QWORD PTR -48[rbp]
	subsd	xmm0, QWORD PTR -40[rbp]
	movq	xmm1, QWORD PTR .LC3[rip]
	andpd	xmm0, xmm1
	comisd	xmm0, QWORD PTR .LC4[rip]
	jbe	.L41
	lea	rdi, .LC5[rip]
	call	puts@PLT
	mov	DWORD PTR -84[rbp], -1
	jmp	.L27
.L41:
	add	DWORD PTR -64[rbp], 1
.L29:
	mov	eax, DWORD PTR -64[rbp]
	cmp	eax, DWORD PTR -52[rbp]
	jle	.L34
	mov	edi, 1
	call	omp_set_num_threads@PLT
	call	omp_get_wtime@PLT
	movq	rax, xmm0
	mov	QWORD PTR -16[rbp], rax
	mov	DWORD PTR -56[rbp], 0
	jmp	.L35
.L36:
	mov	edx, DWORD PTR array_size[rip]
	mov	rcx, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -32[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	dotp_naive
	movq	rax, xmm0
	mov	QWORD PTR -40[rbp], rax
	add	DWORD PTR -56[rbp], 1
.L35:
	cmp	DWORD PTR -56[rbp], 99
	jle	.L36
	call	omp_get_wtime@PLT
	movq	rax, xmm0
	movq	xmm0, rax
	subsd	xmm0, QWORD PTR -16[rbp]
	movsd	QWORD PTR -8[rbp], xmm0
	mov	rax, QWORD PTR -8[rbp]
	movq	xmm0, rax
	mov	esi, 1
	lea	rdi, .LC7[rip]
	mov	eax, 1
	call	printf@PLT
.L27:
	mov	rax, QWORD PTR -32[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	eax, DWORD PTR -84[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	main, .-main
	.section	.rodata
	.align 16
.LC3:
	.long	-1
	.long	2147483647
	.long	0
	.long	0
	.align 8
.LC4:
	.long	-755914244
	.long	1062232653
	.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	"139841.c"
	.text
	.global	array_size
	.data
	.align	2
	.type	array_size, %object
	.size	array_size, 4
array_size:
	.word	10000000
	.text
	.align	2
	.global	gen_array
	.syntax unified
	.arm
	.fpu softvfp
	.type	gen_array, %function
gen_array:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #20
	str	r0, [fp, #-24]
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #3
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-20]
	b	.L2
.L3:
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-16]
	add	r4, r2, r3
	bl	drand48
	mov	r2, r0
	mov	r3, r1
	stm	r4, {r2-r3}
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L2:
	ldr	r2, [fp, #-20]
	ldr	r3, [fp, #-24]
	cmp	r2, r3
	blt	.L3
	ldr	r3, [fp, #-16]
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
	.size	gen_array, .-gen_array
	.global	__aeabi_dmul
	.global	__aeabi_dadd
	.align	2
	.global	dotp_naive
	.syntax unified
	.arm
	.fpu softvfp
	.type	dotp_naive, %function
dotp_naive:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	mov	r2, #0
	mov	r3, #0
	str	r2, [fp, #-12]
	str	r3, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L6
.L7:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-24]
	add	r3, r2, r3
	ldmia	r3, {r0-r1}
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	sub	r1, fp, #12
	ldmia	r1, {r0-r1}
	bl	__aeabi_dadd
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-12]
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L6:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-32]
	cmp	r2, r3
	blt	.L7
	sub	r3, fp, #12
	ldmia	r3, {r2-r3}
	mov	r0, r2
	mov	r1, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	dotp_naive, .-dotp_naive
	.align	2
	.global	dotp_manual_optimized
	.syntax unified
	.arm
	.fpu softvfp
	.type	dotp_manual_optimized, %function
dotp_manual_optimized:
	@ args = 0, pretend = 0, frame = 40
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #40
	str	r0, [fp, #-32]
	str	r1, [fp, #-36]
	str	r2, [fp, #-40]
	mov	r2, #0
	mov	r3, #0
	str	r2, [fp, #-12]
	str	r3, [fp, #-8]
	mov	r2, #0
	mov	r3, #0
	str	r2, [fp, #-20]
	str	r3, [fp, #-16]
	mov	r2, #0
	mov	r3, #0
	str	r2, [fp, #-20]
	str	r3, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-24]
	b	.L10
.L11:
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-32]
	add	r3, r2, r3
	ldmia	r3, {r0-r1}
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	sub	r1, fp, #20
	ldmia	r1, {r0-r1}
	bl	__aeabi_dadd
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-20]
	str	r3, [fp, #-16]
	ldr	r3, [fp, #-24]
	add	r3, r3, #1
	str	r3, [fp, #-24]
.L10:
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-40]
	cmp	r2, r3
	blt	.L11
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	sub	r1, fp, #12
	ldmia	r1, {r0-r1}
	bl	__aeabi_dadd
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-12]
	str	r3, [fp, #-8]
	sub	r3, fp, #12
	ldmia	r3, {r2-r3}
	mov	r0, r2
	mov	r1, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	dotp_manual_optimized, .-dotp_manual_optimized
	.align	2
	.global	dotp_reduction_optimized
	.syntax unified
	.arm
	.fpu softvfp
	.type	dotp_reduction_optimized, %function
dotp_reduction_optimized:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	mov	r2, #0
	mov	r3, #0
	str	r2, [fp, #-12]
	str	r3, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L14
.L15:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-24]
	add	r3, r2, r3
	ldmia	r3, {r0-r1}
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	sub	r1, fp, #12
	ldmia	r1, {r0-r1}
	bl	__aeabi_dadd
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-12]
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L14:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-32]
	cmp	r2, r3
	blt	.L15
	sub	r3, fp, #12
	ldmia	r3, {r2-r3}
	mov	r0, r2
	mov	r1, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	dotp_reduction_optimized, .-dotp_reduction_optimized
	.global	__aeabi_dsub
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Naive solution took %f seconds\012\000"
	.align	2
.LC1:
	.ascii	"Manual Optimized: %d thread(s) took %f seconds\012\000"
	.global	__aeabi_dcmpgt
	.align	2
.LC2:
	.ascii	"Incorrect result!\000"
	.align	2
.LC3:
	.ascii	"Reduction Optimized: %d thread(s) took %f seconds\012"
	.ascii	"\000"
	.align	2
.LC4:
	.ascii	"Naive: %d thread(s) took %f seconds\012\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 80
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, fp, lr}
	add	fp, sp, #20
	sub	sp, sp, #80
	ldr	r3, .L42
	ldr	r3, [r3]
	mov	r0, r3
	bl	gen_array
	str	r0, [fp, #-64]
	ldr	r3, .L42
	ldr	r3, [r3]
	mov	r0, r3
	bl	gen_array
	str	r0, [fp, #-60]
	mov	r3, #0
	str	r3, [fp, #-96]
	bl	omp_get_wtime
	str	r0, [fp, #-36]
	str	r1, [fp, #-32]
	mov	r3, #0
	str	r3, [fp, #-92]
	b	.L18
.L21:
	mov	r2, #0
	mov	r3, #0
	str	r2, [fp, #-52]
	str	r3, [fp, #-48]
	mov	r3, #0
	str	r3, [fp, #-88]
	b	.L19
.L20:
	ldr	r3, [fp, #-88]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-64]
	add	r3, r2, r3
	ldmia	r3, {r0-r1}
	ldr	r3, [fp, #-88]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-60]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	sub	r1, fp, #52
	ldmia	r1, {r0-r1}
	bl	__aeabi_dadd
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-52]
	str	r3, [fp, #-48]
	ldr	r3, [fp, #-88]
	add	r3, r3, #1
	str	r3, [fp, #-88]
.L19:
	ldr	r3, .L42
	ldr	r3, [r3]
	ldr	r2, [fp, #-88]
	cmp	r2, r3
	blt	.L20
	ldr	r3, [fp, #-92]
	add	r3, r3, #1
	str	r3, [fp, #-92]
.L18:
	ldr	r3, [fp, #-92]
	cmp	r3, #99
	ble	.L21
	bl	omp_get_wtime
	sub	r3, fp, #36
	ldmia	r3, {r2-r3}
	bl	__aeabi_dsub
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-28]
	str	r3, [fp, #-24]
	sub	r3, fp, #28
	ldmia	r3, {r2-r3}
	ldr	r0, .L42+4
	bl	printf
	bl	omp_get_max_threads
	str	r0, [fp, #-56]
	mov	r3, #1
	str	r3, [fp, #-84]
	b	.L22
.L28:
	ldr	r0, [fp, #-84]
	bl	omp_set_num_threads
	bl	omp_get_wtime
	str	r0, [fp, #-36]
	str	r1, [fp, #-32]
	mov	r3, #0
	str	r3, [fp, #-80]
	b	.L23
.L24:
	ldr	r3, .L42
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, [fp, #-60]
	ldr	r0, [fp, #-64]
	bl	dotp_manual_optimized
	str	r0, [fp, #-44]
	str	r1, [fp, #-40]
	ldr	r3, [fp, #-80]
	add	r3, r3, #1
	str	r3, [fp, #-80]
.L23:
	ldr	r3, [fp, #-80]
	cmp	r3, #99
	ble	.L24
	bl	omp_get_wtime
	sub	r3, fp, #36
	ldmia	r3, {r2-r3}
	bl	__aeabi_dsub
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-28]
	str	r3, [fp, #-24]
	sub	r3, fp, #28
	ldmia	r3, {r2-r3}
	ldr	r1, [fp, #-84]
	ldr	r0, .L42+8
	bl	printf
	sub	r3, fp, #44
	ldmia	r3, {r2-r3}
	sub	r1, fp, #52
	ldmia	r1, {r0-r1}
	bl	__aeabi_dsub
	mov	r2, r0
	mov	r3, r1
	mov	r6, r2
	bic	r7, r3, #-2147483648
	ldr	r2, .L42+12
	ldr	r3, .L42+16
	mov	r0, r6
	mov	r1, r7
	bl	__aeabi_dcmpgt
	mov	r3, r0
	cmp	r3, #0
	beq	.L40
	ldr	r0, .L42+20
	bl	puts
	mvn	r3, #0
	str	r3, [fp, #-96]
	b	.L27
.L40:
	ldr	r3, [fp, #-84]
	add	r3, r3, #1
	str	r3, [fp, #-84]
.L22:
	ldr	r2, [fp, #-84]
	ldr	r3, [fp, #-56]
	cmp	r2, r3
	ble	.L28
	mov	r3, #1
	str	r3, [fp, #-76]
	b	.L29
.L34:
	ldr	r0, [fp, #-76]
	bl	omp_set_num_threads
	bl	omp_get_wtime
	str	r0, [fp, #-36]
	str	r1, [fp, #-32]
	mov	r3, #0
	str	r3, [fp, #-72]
	b	.L30
.L31:
	ldr	r3, .L42
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, [fp, #-60]
	ldr	r0, [fp, #-64]
	bl	dotp_reduction_optimized
	str	r0, [fp, #-44]
	str	r1, [fp, #-40]
	ldr	r3, [fp, #-72]
	add	r3, r3, #1
	str	r3, [fp, #-72]
.L30:
	ldr	r3, [fp, #-72]
	cmp	r3, #99
	ble	.L31
	bl	omp_get_wtime
	sub	r3, fp, #36
	ldmia	r3, {r2-r3}
	bl	__aeabi_dsub
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-28]
	str	r3, [fp, #-24]
	sub	r3, fp, #28
	ldmia	r3, {r2-r3}
	ldr	r1, [fp, #-76]
	ldr	r0, .L42+24
	bl	printf
	sub	r3, fp, #44
	ldmia	r3, {r2-r3}
	sub	r1, fp, #52
	ldmia	r1, {r0-r1}
	bl	__aeabi_dsub
	mov	r2, r0
	mov	r3, r1
	mov	r4, r2
	bic	r5, r3, #-2147483648
	ldr	r2, .L42+12
	ldr	r3, .L42+16
	mov	r0, r4
	mov	r1, r5
	bl	__aeabi_dcmpgt
	mov	r3, r0
	cmp	r3, #0
	beq	.L41
	ldr	r0, .L42+20
	bl	puts
	mvn	r3, #0
	str	r3, [fp, #-96]
	b	.L27
.L41:
	ldr	r3, [fp, #-76]
	add	r3, r3, #1
	str	r3, [fp, #-76]
.L29:
	ldr	r2, [fp, #-76]
	ldr	r3, [fp, #-56]
	cmp	r2, r3
	ble	.L34
	mov	r0, #1
	bl	omp_set_num_threads
	bl	omp_get_wtime
	str	r0, [fp, #-36]
	str	r1, [fp, #-32]
	mov	r3, #0
	str	r3, [fp, #-68]
	b	.L35
.L36:
	ldr	r3, .L42
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, [fp, #-60]
	ldr	r0, [fp, #-64]
	bl	dotp_naive
	str	r0, [fp, #-44]
	str	r1, [fp, #-40]
	ldr	r3, [fp, #-68]
	add	r3, r3, #1
	str	r3, [fp, #-68]
.L35:
	ldr	r3, [fp, #-68]
	cmp	r3, #99
	ble	.L36
	bl	omp_get_wtime
	sub	r3, fp, #36
	ldmia	r3, {r2-r3}
	bl	__aeabi_dsub
	mov	r2, r0
	mov	r3, r1
	str	r2, [fp, #-28]
	str	r3, [fp, #-24]
	sub	r3, fp, #28
	ldmia	r3, {r2-r3}
	mov	r1, #1
	ldr	r0, .L42+28
	bl	printf
.L27:
	ldr	r0, [fp, #-64]
	bl	free
	ldr	r0, [fp, #-60]
	bl	free
	ldr	r3, [fp, #-96]
	mov	r0, r3
	sub	sp, fp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, fp, pc}
.L43:
	.align	2
.L42:
	.word	array_size
	.word	.LC0
	.word	.LC1
	.word	-755914244
	.word	1062232653
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
