	.file	"150143089.c"
	.intel_syntax noprefix
	.text
	.globl	THREADS
	.data
	.align 4
	.type	THREADS, @object
	.size	THREADS, 4
THREADS:
	.long	10
	.globl	args
	.bss
	.align 8
	.type	args, @object
	.size	args, 8
args:
	.zero	8
	.globl	done
	.align 4
	.type	done, @object
	.size	done, 4
done:
	.zero	4
	.text
	.globl	thread_function
	.type	thread_function, @function
thread_function:
.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, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	rax, QWORD PTR -24[rbp]
	mov	DWORD PTR -12[rbp], eax
	mov	rdx, QWORD PTR args[rip]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	sal	rax, 2
	add	rax, rdx
	mov	QWORD PTR -8[rbp], rax
	jmp	.L2
.L4:
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR [rax]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR [rax], edx
.L2:
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	jle	.L3
	mov	eax, DWORD PTR done[rip]
	test	eax, eax
	je	.L4
.L3:
	mov	eax, DWORD PTR done[rip]
	test	eax, eax
	je	.L5
	mov	edi, 100
	call	usleep@PLT
.L5:
	mov	edi, 0
	call	pthread_exit@PLT
	.cfi_endproc
.LFE6:
	.size	thread_function, .-thread_function
	.globl	main
	.type	main, @function
main:
.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, 64
	mov	DWORD PTR -52[rbp], edi
	mov	QWORD PTR -64[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -24[rbp], 0
	mov	eax, DWORD PTR THREADS[rip]
	cdqe
	sal	rax, 3
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR -16[rbp], rax
	mov	eax, DWORD PTR THREADS[rip]
	cdqe
	sal	rax, 2
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR args[rip], rax
	mov	QWORD PTR -24[rbp], 0
	jmp	.L7
.L8:
	mov	rdx, QWORD PTR args[rip]
	mov	rax, QWORD PTR -24[rbp]
	sal	rax, 2
	add	rax, rdx
	mov	DWORD PTR [rax], 1
	mov	rax, QWORD PTR -24[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	lea	rcx, 0[0+rdx*8]
	mov	rdx, QWORD PTR -16[rbp]
	lea	rdi, [rcx+rdx]
	mov	rcx, rax
	lea	rdx, thread_function[rip]
	mov	esi, 0
	call	pthread_create@PLT
	mov	DWORD PTR -36[rbp], eax
	add	QWORD PTR -24[rbp], 1
.L7:
	mov	eax, DWORD PTR THREADS[rip]
	cdqe
	cmp	QWORD PTR -24[rbp], rax
	jl	.L8
	mov	QWORD PTR -24[rbp], 0
	jmp	.L9
.L10:
	mov	rax, QWORD PTR -24[rbp]
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -16[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	lea	rdx, -32[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	pthread_join@PLT
	add	QWORD PTR -24[rbp], 1
.L9:
	mov	eax, DWORD PTR THREADS[rip]
	cdqe
	cmp	QWORD PTR -24[rbp], rax
	jl	.L10
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE7:
	.size	main, .-main
	.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	"150143089.c"
	.text
	.global	THREADS
	.data
	.align	2
	.type	THREADS, %object
	.size	THREADS, 4
THREADS:
	.word	10
	.comm	args,4,4
	.global	done
	.bss
	.align	2
	.type	done, %object
	.size	done, 4
done:
	.space	4
	.text
	.align	2
	.global	thread_function
	.syntax unified
	.arm
	.fpu softvfp
	.type	thread_function, %function
thread_function:
	@ 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]
	ldr	r3, [fp, #-16]
	str	r3, [fp, #-12]
	ldr	r3, .L6
	ldr	r2, [r3]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #2
	add	r3, r2, r3
	str	r3, [fp, #-8]
	b	.L2
.L4:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	add	r2, r3, #1
	ldr	r3, [fp, #-8]
	str	r2, [r3]
.L2:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	cmp	r3, #0
	ble	.L3
	ldr	r3, .L6+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L4
.L3:
	ldr	r3, .L6+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L5
	mov	r0, #100
	bl	usleep
.L5:
	mov	r0, #0
	bl	pthread_exit
.L7:
	.align	2
.L6:
	.word	args
	.word	done
	.size	thread_function, .-thread_function
	.section	.rodata
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ 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, #-32]
	str	r1, [fp, #-36]
	ldr	r3, .L14
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-20]
	ldr	r3, .L14+4
	ldr	r3, [r3]
	lsl	r3, r3, #2
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-16]
	ldr	r3, .L14+4
	ldr	r3, [r3]
	lsl	r3, r3, #2
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L14+8
	str	r2, [r3]
	mov	r3, #0
	str	r3, [fp, #-20]
	b	.L9
.L10:
	ldr	r3, .L14+8
	ldr	r2, [r3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #2
	add	r3, r2, r3
	mov	r2, #1
	str	r2, [r3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-16]
	add	r0, r2, r3
	ldr	r3, [fp, #-20]
	ldr	r2, .L14+12
	mov	r1, #0
	bl	pthread_create
	str	r0, [fp, #-12]
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L9:
	ldr	r3, .L14+4
	ldr	r3, [r3]
	ldr	r2, [fp, #-20]
	cmp	r2, r3
	blt	.L10
	mov	r3, #0
	str	r3, [fp, #-20]
	b	.L11
.L12:
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	ldr	r3, [r3]
	sub	r2, fp, #24
	mov	r1, r2
	mov	r0, r3
	bl	pthread_join
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L11:
	ldr	r3, .L14+4
	ldr	r3, [r3]
	ldr	r2, [fp, #-20]
	cmp	r2, r3
	blt	.L12
	mov	r0, #0
	bl	exit
.L15:
	.align	2
.L14:
	.word	.LC0
	.word	THREADS
	.word	args
	.word	thread_function
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
