	.file	"386851.c"
	.intel_syntax noprefix
	.text
	.globl	line
	.bss
	.align 32
	.type	line, @object
	.size	line, 1024
line:
	.zero	1024
	.globl	parameters
	.align 32
	.type	parameters, @object
	.size	parameters, 512
parameters:
	.zero	512
	.globl	input
	.align 16
	.type	input, @object
	.size	input, 16
input:
	.zero	16
	.globl	stuff
	.align 8
	.type	stuff, @object
	.size	stuff, 8
stuff:
	.zero	8
	.globl	fd
	.align 4
	.type	fd, @object
	.size	fd, 4
fd:
	.zero	4
	.local	writeflag
	.comm	writeflag,4,4
	.local	readflag
	.comm	readflag,4,4
	.text
	.globl	inputParser
	.type	inputParser, @function
inputParser:
.LFB6:
	.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 -4[rbp], 0
	jmp	.L2
.L4:
	mov	rax, QWORD PTR -24[rbp]
	lea	rdx, 1[rax]
	mov	QWORD PTR -24[rbp], rdx
	mov	BYTE PTR [rax], 0
.L3:
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 10
	je	.L4
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	je	.L4
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 62
	jne	.L5
	mov	DWORD PTR writeflag[rip], 1
.L5:
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 60
	jne	.L6
	mov	DWORD PTR readflag[rip], 1
.L6:
	mov	rax, QWORD PTR -32[rbp]
	lea	rdx, 8[rax]
	mov	QWORD PTR -32[rbp], rdx
	mov	rdx, QWORD PTR -24[rbp]
	mov	QWORD PTR [rax], rdx
	jmp	.L7
.L8:
	add	QWORD PTR -24[rbp], 1
.L7:
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	je	.L2
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 10
	je	.L2
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	jne	.L8
.L2:
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L3
	mov	rax, QWORD PTR -32[rbp]
	mov	QWORD PTR [rax], 0
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	inputParser, .-inputParser
	.section	.rodata
.LC0:
	.string	"Error executing process"
	.text
	.globl	runProgram
	.type	runProgram, @function
runProgram:
.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, 48
	mov	QWORD PTR -40[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	call	fork@PLT
	mov	DWORD PTR -16[rbp], eax
	cmp	DWORD PTR -16[rbp], 0
	jne	.L11
	mov	rax, QWORD PTR -40[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdx, QWORD PTR -40[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	execvp@PLT
	cmp	eax, -1
	jne	.L12
	lea	rdi, .LC0[rip]
	call	puts@PLT
.L12:
	mov	edi, 0
	call	exit@PLT
.L11:
	cmp	DWORD PTR -16[rbp], 0
	jns	.L13
	lea	rdi, .LC0[rip]
	call	puts@PLT
	jmp	.L14
.L13:
	lea	rcx, -20[rbp]
	mov	eax, DWORD PTR -16[rbp]
	mov	edx, 2
	mov	rsi, rcx
	mov	edi, eax
	call	waitpid@PLT
	mov	DWORD PTR -12[rbp], eax
	mov	eax, DWORD PTR -20[rbp]
	and	eax, 127
	test	eax, eax
	je	.L14
	mov	eax, DWORD PTR -20[rbp]
	and	eax, 127
	add	eax, 1
	sar	al
	test	al, al
	jle	.L13
.L14:
	mov	eax, 1
	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	runProgram, .-runProgram
	.section	.rodata
.LC1:
	.string	"uofmsh > "
.LC2:
	.string	"exit"
.LC3:
	.string	"cd"
	.text
	.globl	main
	.type	main, @function
main:
.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, 2080
	mov	DWORD PTR -2068[rbp], edi
	mov	QWORD PTR -2080[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
.L24:
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR stdin[rip]
	mov	rdx, rax
	mov	esi, 20
	lea	rdi, line[rip]
	call	fgets@PLT
	lea	rax, line[rip]
	mov	QWORD PTR input[rip], rax
	mov	QWORD PTR input[rip+8], 0
	lea	rax, input[rip]
	mov	QWORD PTR stuff[rip], rax
	mov	rax, QWORD PTR -2080[rbp]
	mov	rsi, rax
	lea	rdi, line[rip]
	call	inputParser
	mov	rax, QWORD PTR -2080[rbp]
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L18
	mov	edi, 0
	call	exit@PLT
.L18:
	mov	rax, QWORD PTR -2080[rbp]
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L19
	mov	rax, QWORD PTR -2080[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	chdir@PLT
	jmp	.L20
.L19:
	mov	eax, DWORD PTR writeflag[rip]
	cmp	eax, 1
	jne	.L21
	mov	rax, QWORD PTR -2080[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	edx, 420
	mov	esi, 1089
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR fd[rip], eax
	mov	rax, QWORD PTR stuff[rip]
	mov	rdi, rax
	call	runProgram
	mov	eax, DWORD PTR fd[rip]
	mov	esi, 1
	mov	edi, eax
	call	dup2@PLT
	mov	eax, DWORD PTR fd[rip]
	mov	edi, eax
	call	close@PLT
	mov	DWORD PTR writeflag[rip], 0
	jmp	.L22
.L21:
	mov	eax, DWORD PTR readflag[rip]
	cmp	eax, 1
	jne	.L23
	mov	rax, QWORD PTR -2080[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	edx, 420
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR fd[rip], eax
	mov	eax, DWORD PTR fd[rip]
	lea	rcx, -2064[rbp]
	mov	edx, 128
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	eax, DWORD PTR fd[rip]
	mov	edi, eax
	call	close@PLT
	mov	DWORD PTR readflag[rip], 0
	lea	rax, -2064[rbp]
	mov	rdi, rax
	call	puts@PLT
	jmp	.L22
.L23:
	mov	rax, QWORD PTR stuff[rip]
	mov	rdi, rax
	call	runProgram
.L20:
	jmp	.L24
.L22:
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L26
	call	__stack_chk_fail@PLT
.L26:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.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	"386851.c"
	.text
	.comm	line,1024,4
	.comm	parameters,256,4
	.comm	input,8,4
	.comm	stuff,4,4
	.comm	fd,4,4
	.local	writeflag
	.comm	writeflag,4,4
	.local	readflag
	.comm	readflag,4,4
	.align	2
	.global	inputParser
	.syntax unified
	.arm
	.fpu softvfp
	.type	inputParser, %function
inputParser:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L2
.L4:
	ldr	r3, [fp, #-16]
	add	r2, r3, #1
	str	r2, [fp, #-16]
	mov	r2, #0
	strb	r2, [r3]
.L3:
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #10
	beq	.L4
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	beq	.L4
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #62
	bne	.L5
	ldr	r3, .L10
	mov	r2, #1
	str	r2, [r3]
.L5:
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #60
	bne	.L6
	ldr	r3, .L10+4
	mov	r2, #1
	str	r2, [r3]
.L6:
	ldr	r3, [fp, #-20]
	add	r2, r3, #4
	str	r2, [fp, #-20]
	ldr	r2, [fp, #-16]
	str	r2, [r3]
	b	.L7
.L8:
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L7:
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L2
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #10
	beq	.L2
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	bne	.L8
.L2:
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L3
	ldr	r3, [fp, #-20]
	mov	r2, #0
	str	r2, [r3]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L11:
	.align	2
.L10:
	.word	writeflag
	.word	readflag
	.size	inputParser, .-inputParser
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Error executing process\000"
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	runProgram
	.syntax unified
	.arm
	.fpu softvfp
	.type	runProgram, %function
runProgram:
	@ 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, .L19
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L13
	ldr	r3, [fp, #-24]
	ldr	r3, [r3]
	ldr	r1, [fp, #-24]
	mov	r0, r3
	bl	execvp
	mov	r3, r0
	cmn	r3, #1
	bne	.L14
	ldr	r0, .L19+4
	bl	puts
.L14:
	mov	r0, #0
	bl	exit
.L13:
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bge	.L15
	ldr	r0, .L19+4
	bl	puts
	b	.L16
.L15:
	sub	r3, fp, #20
	mov	r2, #2
	mov	r1, r3
	ldr	r0, [fp, #-16]
	bl	waitpid
	str	r0, [fp, #-12]
	ldr	r3, [fp, #-20]
	and	r3, r3, #127
	cmp	r3, #0
	beq	.L16
	ldr	r3, [fp, #-20]
	and	r3, r3, #255
	and	r3, r3, #127
	and	r3, r3, #255
	add	r3, r3, #1
	and	r3, r3, #255
	lsl	r3, r3, #24
	asr	r3, r3, #24
	asr	r3, r3, #1
	lsl	r3, r3, #24
	asr	r3, r3, #24
	cmp	r3, #0
	ble	.L15
.L16:
	mov	r3, #1
	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	.LC1
	.word	.LC0
	.size	runProgram, .-runProgram
	.section	.rodata
	.align	2
.LC2:
	.ascii	"uofmsh > \000"
	.align	2
.LC3:
	.ascii	"exit\000"
	.align	2
.LC4:
	.ascii	"cd\000"
	.align	2
.LC5:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 2064
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #2064
	str	r0, [fp, #-2064]
	str	r1, [fp, #-2068]
	ldr	r3, .L31
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
.L28:
	ldr	r0, .L31+4
	bl	printf
	ldr	r3, .L31+8
	ldr	r3, [r3]
	mov	r2, r3
	mov	r1, #20
	ldr	r0, .L31+12
	bl	fgets
	ldr	r3, .L31+16
	ldr	r2, .L31+12
	str	r2, [r3]
	ldr	r3, .L31+16
	mov	r2, #0
	str	r2, [r3, #4]
	ldr	r3, .L31+20
	ldr	r2, .L31+16
	str	r2, [r3]
	ldr	r1, [fp, #-2068]
	ldr	r0, .L31+12
	bl	inputParser
	ldr	r3, [fp, #-2068]
	ldr	r3, [r3]
	ldr	r1, .L31+24
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L22
	mov	r0, #0
	bl	exit
.L22:
	ldr	r3, [fp, #-2068]
	ldr	r3, [r3]
	ldr	r1, .L31+28
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L23
	ldr	r3, [fp, #-2068]
	add	r3, r3, #4
	ldr	r3, [r3]
	mov	r0, r3
	bl	chdir
	b	.L24
.L23:
	ldr	r3, .L31+32
	ldr	r3, [r3]
	cmp	r3, #1
	bne	.L25
	ldr	r3, [fp, #-2068]
	add	r3, r3, #8
	ldr	r3, [r3]
	mov	r2, #420
	ldr	r1, .L31+36
	mov	r0, r3
	bl	open
	mov	r3, r0
	ldr	r2, .L31+40
	str	r3, [r2]
	ldr	r3, .L31+20
	ldr	r3, [r3]
	mov	r0, r3
	bl	runProgram
	ldr	r3, .L31+40
	ldr	r3, [r3]
	mov	r1, #1
	mov	r0, r3
	bl	dup2
	ldr	r3, .L31+40
	ldr	r3, [r3]
	mov	r0, r3
	bl	close
	ldr	r3, .L31+32
	mov	r2, #0
	str	r2, [r3]
	b	.L26
.L25:
	ldr	r3, .L31+44
	ldr	r3, [r3]
	cmp	r3, #1
	bne	.L27
	ldr	r3, [fp, #-2068]
	add	r3, r3, #8
	ldr	r3, [r3]
	mov	r2, #420
	mov	r1, #0
	mov	r0, r3
	bl	open
	mov	r3, r0
	ldr	r2, .L31+40
	str	r3, [r2]
	ldr	r3, .L31+40
	ldr	r0, [r3]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #128
	mov	r1, r3
	bl	read
	ldr	r3, .L31+40
	ldr	r3, [r3]
	mov	r0, r3
	bl	close
	ldr	r3, .L31+44
	mov	r2, #0
	str	r2, [r3]
	sub	r3, fp, #2048
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r0, r3
	bl	puts
	b	.L26
.L27:
	ldr	r3, .L31+20
	ldr	r3, [r3]
	mov	r0, r3
	bl	runProgram
.L24:
	b	.L28
.L26:
	mov	r3, #0
	ldr	r2, .L31
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L30
	bl	__stack_chk_fail
.L30:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L32:
	.align	2
.L31:
	.word	.LC5
	.word	.LC2
	.word	stdin
	.word	line
	.word	input
	.word	stuff
	.word	.LC3
	.word	.LC4
	.word	writeflag
	.word	1089
	.word	fd
	.word	readflag
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
