	.file	"82949627.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"cat"
.LC1:
	.string	"wc"
	.text
	.globl	catwc
	.type	catwc, @function
catwc:
.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 fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	call	fork@PLT
	mov	DWORD PTR -12[rbp], eax
	cmp	DWORD PTR -12[rbp], 0
	jne	.L2
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, 0
	mov	rdx, rax
	lea	rsi, .LC0[rip]
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	execlp@PLT
	jmp	.L5
.L2:
	lea	rcx, -16[rbp]
	mov	eax, DWORD PTR -12[rbp]
	mov	edx, 0
	mov	rsi, rcx
	mov	edi, eax
	call	waitpid@PLT
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, 0
	mov	rdx, rax
	lea	rsi, .LC1[rip]
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	execlp@PLT
.L5:
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L4
	call	__stack_chk_fail@PLT
.L4:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	catwc, .-catwc
	.section	.rodata
.LC2:
	.string	"/tmp/catwc"
	.text
	.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, 1056
	mov	DWORD PTR -1044[rbp], edi
	mov	QWORD PTR -1056[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -1044[rbp], 1
	jne	.L7
	mov	esi, 1604
	lea	rdi, .LC2[rip]
	call	creat@PLT
	mov	DWORD PTR -1020[rbp], eax
	jmp	.L8
.L9:
	mov	rdx, QWORD PTR -1016[rbp]
	lea	rcx, -1008[rbp]
	mov	eax, DWORD PTR -1020[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
.L8:
	lea	rax, -1008[rbp]
	mov	edx, 1000
	mov	rsi, rax
	mov	edi, 0
	call	read@PLT
	mov	QWORD PTR -1016[rbp], rax
	cmp	QWORD PTR -1016[rbp], 0
	jne	.L9
	mov	eax, DWORD PTR -1020[rbp]
	mov	edi, eax
	call	close@PLT
	lea	rdi, .LC2[rip]
	call	catwc
	mov	edi, 0
	call	exit@PLT
.L7:
	mov	DWORD PTR -1028[rbp], 1
	jmp	.L10
.L12:
	call	fork@PLT
	test	eax, eax
	jne	.L11
	mov	eax, DWORD PTR -1028[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -1056[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	catwc
.L11:
	add	DWORD PTR -1028[rbp], 1
.L10:
	mov	eax, DWORD PTR -1028[rbp]
	cmp	eax, DWORD PTR -1044[rbp]
	jl	.L12
	mov	DWORD PTR -1024[rbp], 1
	jmp	.L13
.L14:
	lea	rax, -1032[rbp]
	mov	rdi, rax
	call	wait@PLT
	add	DWORD PTR -1024[rbp], 1
.L13:
	mov	eax, DWORD PTR -1024[rbp]
	cmp	eax, DWORD PTR -1044[rbp]
	jl	.L14
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L16
	call	__stack_chk_fail@PLT
.L16:
	leave
	.cfi_def_cfa 7, 8
	ret
	.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	"82949627.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"cat\000"
	.align	2
.LC1:
	.ascii	"wc\000"
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	catwc
	.syntax unified
	.arm
	.fpu softvfp
	.type	catwc, %function
catwc:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	str	r0, [fp, #-24]
	ldr	r3, .L6
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	bne	.L2
	mov	r3, #0
	ldr	r2, [fp, #-24]
	ldr	r1, .L6+4
	ldr	r0, .L6+4
	bl	execlp
	b	.L5
.L2:
	sub	r3, fp, #16
	mov	r2, #0
	mov	r1, r3
	ldr	r0, [fp, #-12]
	bl	waitpid
	mov	r3, #0
	ldr	r2, [fp, #-24]
	ldr	r1, .L6+8
	ldr	r0, .L6+8
	bl	execlp
.L5:
	nop
	ldr	r3, .L6
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L4
	bl	__stack_chk_fail
.L4:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L7:
	.align	2
.L6:
	.word	.LC2
	.word	.LC0
	.word	.LC1
	.size	catwc, .-catwc
	.section	.rodata
	.align	2
.LC3:
	.ascii	"/tmp/catwc\000"
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 1032
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #1024
	sub	sp, sp, #8
	str	r0, [fp, #-1032]
	str	r1, [fp, #-1036]
	ldr	r3, .L19
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-1032]
	cmp	r3, #1
	bne	.L9
	ldr	r1, .L19+4
	ldr	r0, .L19+8
	bl	creat
	str	r0, [fp, #-1016]
	b	.L10
.L11:
	ldr	r2, [fp, #-1012]
	sub	r3, fp, #1008
	mov	r1, r3
	ldr	r0, [fp, #-1016]
	bl	write
.L10:
	sub	r3, fp, #1008
	mov	r2, #1000
	mov	r1, r3
	mov	r0, #0
	bl	read
	str	r0, [fp, #-1012]
	ldr	r3, [fp, #-1012]
	cmp	r3, #0
	bne	.L11
	ldr	r0, [fp, #-1016]
	bl	close
	ldr	r0, .L19+8
	bl	catwc
	mov	r0, #0
	bl	exit
.L9:
	mov	r3, #1
	str	r3, [fp, #-1024]
	b	.L12
.L14:
	bl	fork
	mov	r3, r0
	cmp	r3, #0
	bne	.L13
	ldr	r3, [fp, #-1024]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-1036]
	add	r3, r2, r3
	ldr	r3, [r3]
	mov	r0, r3
	bl	catwc
.L13:
	ldr	r3, [fp, #-1024]
	add	r3, r3, #1
	str	r3, [fp, #-1024]
.L12:
	ldr	r2, [fp, #-1024]
	ldr	r3, [fp, #-1032]
	cmp	r2, r3
	blt	.L14
	mov	r3, #1
	str	r3, [fp, #-1020]
	b	.L15
.L16:
	sub	r3, fp, #1024
	sub	r3, r3, #4
	mov	r0, r3
	bl	wait
	ldr	r3, [fp, #-1020]
	add	r3, r3, #1
	str	r3, [fp, #-1020]
.L15:
	ldr	r2, [fp, #-1020]
	ldr	r3, [fp, #-1032]
	cmp	r2, r3
	blt	.L16
	mov	r3, #0
	ldr	r2, .L19
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L18
	bl	__stack_chk_fail
.L18:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L20:
	.align	2
.L19:
	.word	.LC4
	.word	1604
	.word	.LC3
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
