	.file	"34513505.c"
	.intel_syntax noprefix
	.text
	.globl	argv
	.bss
	.align 32
	.type	argv, @object
	.size	argv, 400
argv:
	.zero	400
	.globl	argv2
	.align 32
	.type	argv2, @object
	.size	argv2, 400
argv2:
	.zero	400
	.globl	line
	.align 32
	.type	line, @object
	.size	line, 100
line:
	.zero	100
	.globl	numberOfArguments
	.align 4
	.type	numberOfArguments, @object
	.size	numberOfArguments, 4
numberOfArguments:
	.zero	4
	.globl	status
	.align 4
	.type	status, @object
	.size	status, 4
status:
	.zero	4
	.globl	pid
	.align 4
	.type	pid, @object
	.size	pid, 4
pid:
	.zero	4
	.globl	died
	.align 4
	.type	died, @object
	.size	died, 4
died:
	.zero	4
	.globl	path
	.align 8
	.type	path, @object
	.size	path, 8
path:
	.zero	8
	.section	.rodata
.LC0:
	.string	" "
	.text
	.globl	readLine
	.type	readLine, @function
readLine:
.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, 24
	.cfi_offset 3, -24
	mov	DWORD PTR -20[rbp], 0
	jmp	.L2
.L4:
	add	DWORD PTR -20[rbp], 1
.L2:
	cmp	DWORD PTR -20[rbp], 99
	jg	.L3
	call	getchar@PLT
	mov	ecx, eax
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, line[rip]
	mov	BYTE PTR [rax+rdx], cl
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, line[rip]
	movzx	eax, BYTE PTR [rax+rdx]
	cmp	al, 10
	jne	.L4
.L3:
	cmp	DWORD PTR -20[rbp], 100
	jne	.L5
	mov	BYTE PTR line[rip+99], 0
	nop
.L6:
	call	getchar@PLT
	cmp	eax, 10
	jne	.L6
	jmp	.L7
.L5:
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, line[rip]
	mov	BYTE PTR [rax+rdx], 0
.L7:
	lea	rsi, .LC0[rip]
	lea	rdi, line[rip]
	call	strtok@PLT
	mov	QWORD PTR argv[rip], rax
	mov	DWORD PTR numberOfArguments[rip], 1
	mov	ebx, DWORD PTR numberOfArguments[rip]
	lea	rsi, .LC0[rip]
	mov	edi, 0
	call	strtok@PLT
	movsx	rdx, ebx
	lea	rcx, 0[0+rdx*8]
	lea	rdx, argv[rip]
	mov	QWORD PTR [rcx+rdx], rax
	jmp	.L8
.L9:
	mov	eax, DWORD PTR numberOfArguments[rip]
	add	eax, 1
	mov	DWORD PTR numberOfArguments[rip], eax
	mov	ebx, DWORD PTR numberOfArguments[rip]
	lea	rsi, .LC0[rip]
	mov	edi, 0
	call	strtok@PLT
	movsx	rdx, ebx
	lea	rcx, 0[0+rdx*8]
	lea	rdx, argv[rip]
	mov	QWORD PTR [rcx+rdx], rax
.L8:
	mov	eax, DWORD PTR numberOfArguments[rip]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	test	rax, rax
	jne	.L9
	nop
	nop
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	readLine, .-readLine
	.globl	extractCommand
	.type	extractCommand, @function
extractCommand:
.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, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -8[rbp], 0
	mov	DWORD PTR -4[rbp], 0
	mov	DWORD PTR -8[rbp], 0
	jmp	.L11
.L15:
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	mov	rdx, QWORD PTR -24[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L12
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	QWORD PTR [rdx+rax], 0
	jmp	.L13
.L14:
	mov	eax, DWORD PTR -8[rbp]
	add	eax, 1
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	lea	rcx, 0[0+rdx*8]
	lea	rdx, argv2[rip]
	mov	QWORD PTR [rcx+rdx], rax
	mov	eax, DWORD PTR -8[rbp]
	add	eax, 1
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	QWORD PTR [rdx+rax], 0
	add	DWORD PTR -8[rbp], 1
	add	DWORD PTR -4[rbp], 1
.L13:
	mov	eax, DWORD PTR -8[rbp]
	add	eax, 1
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	test	rax, rax
	jne	.L14
.L12:
	add	DWORD PTR -8[rbp], 1
.L11:
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	test	rax, rax
	jne	.L15
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	extractCommand, .-extractCommand
	.section	.rodata
.LC1:
	.string	">"
.LC2:
	.string	"fork"
.LC3:
	.string	"execv"
.LC4:
	.string	"Done "
.LC5:
	.string	"."
	.text
	.globl	outRedirection
	.type	outRedirection, @function
outRedirection:
.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, 16
	lea	rdi, .LC1[rip]
	call	extractCommand
	call	fork@PLT
	mov	DWORD PTR pid[rip], eax
	mov	eax, DWORD PTR pid[rip]
	cmp	eax, -1
	jne	.L17
	lea	rdi, .LC2[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L17:
	mov	eax, DWORD PTR pid[rip]
	test	eax, eax
	jne	.L18
	mov	edi, 1
	call	close@PLT
	mov	rax, QWORD PTR argv2[rip]
	mov	esi, 420
	mov	rdi, rax
	call	creat@PLT
	mov	DWORD PTR -4[rbp], eax
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, argv[rip]
	mov	rdi, rax
	call	execvp@PLT
	lea	rdi, .LC3[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L18:
	mov	eax, DWORD PTR pid[rip]
	test	eax, eax
	je	.L20
	mov	edi, 0
	mov	eax, 0
	call	wait@PLT
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR argv[rip]
	mov	rdi, rax
	mov	eax, 0
	call	printf@PLT
	lea	rdi, .LC5[rip]
	call	puts@PLT
.L20:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	outRedirection, .-outRedirection
	.section	.rodata
.LC6:
	.string	"<"
	.text
	.globl	inRedirection
	.type	inRedirection, @function
inRedirection:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	lea	rdi, .LC6[rip]
	call	extractCommand
	call	fork@PLT
	mov	DWORD PTR pid[rip], eax
	mov	eax, DWORD PTR pid[rip]
	cmp	eax, -1
	jne	.L22
	lea	rdi, .LC2[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L22:
	mov	eax, DWORD PTR pid[rip]
	test	eax, eax
	jne	.L23
	mov	edi, 0
	call	close@PLT
	mov	rax, QWORD PTR argv2[rip]
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -4[rbp], eax
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, argv[rip]
	mov	rdi, rax
	call	execvp@PLT
	lea	rdi, .LC3[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L23:
	mov	eax, DWORD PTR pid[rip]
	test	eax, eax
	je	.L25
	mov	edi, 0
	mov	eax, 0
	call	wait@PLT
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR argv[rip]
	mov	rdi, rax
	mov	eax, 0
	call	printf@PLT
	lea	rdi, .LC5[rip]
	call	puts@PLT
.L25:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	inRedirection, .-inRedirection
	.section	.rodata
.LC7:
	.string	"&"
.LC8:
	.string	"panic: can't fork"
.LC9:
	.string	"Command %s not found\n"
	.text
	.globl	backgrounding
	.type	backgrounding, @function
backgrounding:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC7[rip]
	call	extractCommand
	call	fork@PLT
	mov	DWORD PTR pid[rip], eax
	mov	eax, DWORD PTR pid[rip]
	cmp	eax, -1
	je	.L27
	test	eax, eax
	je	.L28
	jmp	.L30
.L27:
	lea	rdi, .LC8[rip]
	call	puts@PLT
	mov	edi, -1
	call	exit@PLT
.L28:
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, argv[rip]
	mov	rdi, rax
	call	execvp@PLT
	mov	rax, QWORD PTR argv[rip]
	mov	rsi, rax
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 1
	call	exit@PLT
.L30:
	mov	edi, 10000
	call	usleep@PLT
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE10:
	.size	backgrounding, .-backgrounding
	.section	.rodata
.LC10:
	.string	"|"
.LC11:
	.string	"Cannot get a pipe"
.LC12:
	.string	"Unable to fork"
	.text
	.globl	piping
	.type	piping, @function
piping:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rdi, .LC10[rip]
	call	extractCommand
	lea	rax, -16[rbp]
	mov	rdi, rax
	call	pipe@PLT
	test	eax, eax
	jns	.L32
	lea	rdi, .LC11[rip]
	call	puts@PLT
.L32:
	call	fork@PLT
	mov	DWORD PTR pid[rip], eax
	mov	eax, DWORD PTR pid[rip]
	test	eax, eax
	jne	.L33
	mov	edi, 1
	call	close@PLT
	mov	eax, DWORD PTR -12[rbp]
	mov	edi, eax
	call	dup@PLT
	mov	eax, DWORD PTR -16[rbp]
	mov	edi, eax
	call	close@PLT
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, argv[rip]
	mov	rdi, rax
	call	execvp@PLT
	jmp	.L37
.L33:
	mov	eax, DWORD PTR pid[rip]
	test	eax, eax
	jle	.L35
	mov	edi, 0
	call	close@PLT
	mov	eax, DWORD PTR -16[rbp]
	mov	edi, eax
	call	dup@PLT
	mov	eax, DWORD PTR -12[rbp]
	mov	edi, eax
	call	close@PLT
	mov	rax, QWORD PTR argv2[rip]
	lea	rsi, argv2[rip]
	mov	rdi, rax
	call	execvp@PLT
	jmp	.L37
.L35:
	lea	rdi, .LC12[rip]
	call	puts@PLT
.L37:
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L36
	call	__stack_chk_fail@PLT
.L36:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	piping, .-piping
	.globl	process
	.type	process, @function
process:
.LFB12:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	DWORD PTR -4[rbp], edi
	call	fork@PLT
	mov	DWORD PTR pid[rip], eax
	mov	eax, DWORD PTR pid[rip]
	cmp	eax, -1
	je	.L39
	test	eax, eax
	je	.L40
	jmp	.L41
.L39:
	lea	rdi, .LC8[rip]
	call	puts@PLT
	mov	edi, -1
	call	exit@PLT
.L40:
	cmp	DWORD PTR -4[rbp], 0
	jne	.L42
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, argv[rip]
	mov	rdi, rax
	call	execvp@PLT
	mov	rax, QWORD PTR argv[rip]
	mov	rsi, rax
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 0
	call	exit@PLT
.L42:
	cmp	DWORD PTR -4[rbp], 1
	jne	.L43
	call	backgrounding
	jmp	.L41
.L43:
	cmp	DWORD PTR -4[rbp], 2
	jne	.L41
	call	piping
.L41:
	lea	rdi, status[rip]
	mov	eax, 0
	call	wait@PLT
	mov	DWORD PTR died[rip], eax
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	process, .-process
	.section	.rodata
.LC13:
	.string	"="
.LC14:
	.string	"Environment set successfully"
.LC15:
	.string	"Error in setting environment"
	.text
	.globl	setEnv
	.type	setEnv, @function
setEnv:
.LFB13:
	.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	DWORD PTR -36[rbp], edi
	mov	eax, DWORD PTR -36[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	lea	rsi, .LC13[rip]
	mov	rdi, rax
	call	strtok@PLT
	mov	QWORD PTR -16[rbp], rax
	lea	rsi, .LC0[rip]
	mov	edi, 0
	call	strtok@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rcx, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR -16[rbp]
	mov	edx, 1
	mov	rsi, rcx
	mov	rdi, rax
	call	setenv@PLT
	mov	DWORD PTR -20[rbp], eax
	cmp	DWORD PTR -20[rbp], 0
	jne	.L45
	lea	rdi, .LC14[rip]
	call	puts@PLT
	jmp	.L47
.L45:
	lea	rdi, .LC15[rip]
	call	puts@PLT
.L47:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	setEnv, .-setEnv
	.section	.rodata
	.align 8
.LC16:
	.string	"Environment variable %s unset successfully\n"
	.align 8
.LC17:
	.string	"Error in unsetting environment"
	.text
	.globl	unsetEnv
	.type	unsetEnv, @function
unsetEnv:
.LFB14:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	rax, QWORD PTR argv[rip+8]
	mov	rdi, rax
	call	unsetenv@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	jne	.L49
	mov	rax, QWORD PTR argv[rip+8]
	mov	rsi, rax
	lea	rdi, .LC16[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L51
.L49:
	lea	rdi, .LC17[rip]
	call	puts@PLT
.L51:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	unsetEnv, .-unsetEnv
	.section	.rodata
.LC18:
	.string	"PWD"
.LC19:
	.string	"OLDPWD"
.LC20:
	.string	"HOME"
.LC21:
	.string	"Error in changing directory"
.LC22:
	.string	"Current directory: %s\n"
	.text
	.globl	changeDirectory
	.type	changeDirectory, @function
changeDirectory:
.LFB15:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	lea	rdi, .LC18[rip]
	call	getenv@PLT
	mov	edx, 1
	mov	rsi, rax
	lea	rdi, .LC19[rip]
	call	setenv@PLT
	mov	rax, QWORD PTR argv[rip+8]
	test	rax, rax
	je	.L53
	mov	rax, QWORD PTR argv[rip+8]
	mov	rdi, rax
	call	chdir@PLT
	mov	DWORD PTR -12[rbp], eax
	mov	eax, 0
	call	get_current_dir_name@PLT
	cdqe
	mov	edx, 1
	mov	rsi, rax
	lea	rdi, .LC18[rip]
	call	setenv@PLT
	jmp	.L54
.L53:
	lea	rdi, .LC20[rip]
	call	getenv@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	chdir@PLT
	mov	DWORD PTR -12[rbp], eax
	lea	rdi, .LC20[rip]
	call	getenv@PLT
	mov	edx, 1
	mov	rsi, rax
	lea	rdi, .LC18[rip]
	call	setenv@PLT
.L54:
	cmp	DWORD PTR -12[rbp], 0
	je	.L55
	lea	rdi, .LC21[rip]
	call	puts@PLT
	jmp	.L57
.L55:
	lea	rdi, .LC18[rip]
	call	getenv@PLT
	mov	rsi, rax
	lea	rdi, .LC22[rip]
	mov	eax, 0
	call	printf@PLT
.L57:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	changeDirectory, .-changeDirectory
	.globl	stringCompare
	.type	stringCompare, @function
stringCompare:
.LFB16:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	DWORD PTR -4[rbp], 0
	jmp	.L59
.L65:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L60
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	movzx	eax, BYTE PTR [rax]
	jmp	.L61
.L60:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	lea	rsi, .LC6[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L62
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	movzx	eax, BYTE PTR [rax]
	jmp	.L61
.L62:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	lea	rsi, .LC10[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L63
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	movzx	eax, BYTE PTR [rax]
	jmp	.L61
.L63:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L64
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	movzx	eax, BYTE PTR [rax]
	jmp	.L61
.L64:
	add	DWORD PTR -4[rbp], 1
.L59:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	lea	rax, argv[rip]
	mov	rax, QWORD PTR [rdx+rax]
	test	rax, rax
	jne	.L65
	mov	eax, 0
.L61:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE16:
	.size	stringCompare, .-stringCompare
	.section	.rodata
.LC23:
	.string	"Initializing shell: "
.LC24:
	.string	"myshell$ "
.LC25:
	.string	"exit"
.LC26:
	.string	"export"
.LC27:
	.string	"unset"
.LC28:
	.string	"cd"
	.text
	.globl	main
	.type	main, @function
main:
.LFB17:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC23[rip]
	call	puts@PLT
.L78:
	lea	rdi, .LC24[rip]
	mov	eax, 0
	call	printf@PLT
	call	readLine
	mov	rax, QWORD PTR argv[rip]
	test	rax, rax
	je	.L79
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, .LC25[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L69
	mov	edi, 0
	call	exit@PLT
.L69:
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, .LC26[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L70
	mov	edi, 1
	call	setEnv
	jmp	.L78
.L70:
	mov	rax, QWORD PTR argv[rip]
	mov	esi, 61
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	je	.L71
	mov	edi, 0
	call	setEnv
	jmp	.L78
.L71:
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, .LC27[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L72
	call	unsetEnv
	jmp	.L78
.L72:
	mov	rax, QWORD PTR argv[rip]
	lea	rsi, .LC28[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L73
	call	changeDirectory
	jmp	.L78
.L73:
	call	stringCompare
	movsx	eax, al
	cmp	eax, 124
	je	.L74
	cmp	eax, 124
	jg	.L75
	cmp	eax, 62
	je	.L76
	cmp	eax, 62
	jg	.L75
	cmp	eax, 38
	je	.L77
	cmp	eax, 60
	jne	.L75
	call	inRedirection
	jmp	.L68
.L76:
	call	outRedirection
	jmp	.L68
.L74:
	mov	edi, 2
	call	process
	jmp	.L68
.L77:
	mov	edi, 1
	call	process
	jmp	.L68
.L75:
	mov	edi, 0
	call	process
	jmp	.L68
.L79:
	nop
.L68:
	jmp	.L78
	.cfi_endproc
.LFE17:
	.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	"34513505.c"
	.text
	.comm	argv,200,4
	.comm	argv2,200,4
	.comm	line,100,4
	.comm	numberOfArguments,4,4
	.comm	status,4,4
	.comm	pid,4,4
	.comm	died,4,4
	.comm	path,4,4
	.section	.rodata
	.align	2
.LC0:
	.ascii	" \000"
	.text
	.align	2
	.global	readLine
	.syntax unified
	.arm
	.fpu softvfp
	.type	readLine, %function
readLine:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L2
.L4:
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L2:
	ldr	r3, [fp, #-16]
	cmp	r3, #99
	bgt	.L3
	bl	getchar
	mov	r3, r0
	and	r1, r3, #255
	ldr	r2, .L10
	ldr	r3, [fp, #-16]
	add	r3, r2, r3
	mov	r2, r1
	strb	r2, [r3]
	ldr	r2, .L10
	ldr	r3, [fp, #-16]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #10
	bne	.L4
.L3:
	ldr	r3, [fp, #-16]
	cmp	r3, #100
	bne	.L5
	ldr	r3, .L10
	mov	r2, #0
	strb	r2, [r3, #99]
	nop
.L6:
	bl	getchar
	mov	r3, r0
	cmp	r3, #10
	bne	.L6
	b	.L7
.L5:
	ldr	r2, .L10
	ldr	r3, [fp, #-16]
	add	r3, r2, r3
	mov	r2, #0
	strb	r2, [r3]
.L7:
	ldr	r1, .L10+4
	ldr	r0, .L10
	bl	strtok
	mov	r3, r0
	ldr	r2, .L10+8
	str	r3, [r2]
	ldr	r3, .L10+12
	mov	r2, #1
	str	r2, [r3]
	ldr	r3, .L10+12
	ldr	r4, [r3]
	ldr	r1, .L10+4
	mov	r0, #0
	bl	strtok
	mov	r3, r0
	ldr	r2, .L10+8
	str	r3, [r2, r4, lsl #2]
	b	.L8
.L9:
	ldr	r3, .L10+12
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L10+12
	str	r3, [r2]
	ldr	r3, .L10+12
	ldr	r4, [r3]
	ldr	r1, .L10+4
	mov	r0, #0
	bl	strtok
	mov	r3, r0
	ldr	r2, .L10+8
	str	r3, [r2, r4, lsl #2]
.L8:
	ldr	r3, .L10+12
	ldr	r3, [r3]
	ldr	r2, .L10+8
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #0
	bne	.L9
	nop
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L11:
	.align	2
.L10:
	.word	line
	.word	.LC0
	.word	argv
	.word	numberOfArguments
	.size	readLine, .-readLine
	.align	2
	.global	extractCommand
	.syntax unified
	.arm
	.fpu softvfp
	.type	extractCommand, %function
extractCommand:
	@ 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]
	mov	r3, #0
	str	r3, [fp, #-12]
	mov	r3, #0
	str	r3, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L13
.L17:
	ldr	r2, .L18
	ldr	r3, [fp, #-12]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r1, [fp, #-16]
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L14
	ldr	r2, .L18
	ldr	r3, [fp, #-12]
	mov	r1, #0
	str	r1, [r2, r3, lsl #2]
	b	.L15
.L16:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	ldr	r2, .L18
	ldr	r2, [r2, r3, lsl #2]
	ldr	r1, .L18+4
	ldr	r3, [fp, #-8]
	str	r2, [r1, r3, lsl #2]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	ldr	r2, .L18
	mov	r1, #0
	str	r1, [r2, r3, lsl #2]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L15:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	ldr	r2, .L18
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #0
	bne	.L16
.L14:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L13:
	ldr	r2, .L18
	ldr	r3, [fp, #-12]
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #0
	bne	.L17
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L19:
	.align	2
.L18:
	.word	argv
	.word	argv2
	.size	extractCommand, .-extractCommand
	.section	.rodata
	.align	2
.LC1:
	.ascii	">\000"
	.align	2
.LC2:
	.ascii	"fork\000"
	.align	2
.LC3:
	.ascii	"execv\000"
	.align	2
.LC4:
	.ascii	"Done \000"
	.align	2
.LC5:
	.ascii	".\000"
	.text
	.align	2
	.global	outRedirection
	.syntax unified
	.arm
	.fpu softvfp
	.type	outRedirection, %function
outRedirection:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r0, .L25
	bl	extractCommand
	bl	fork
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L25+4
	str	r2, [r3]
	ldr	r3, .L25+4
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L21
	ldr	r0, .L25+8
	bl	perror
	mov	r0, #1
	bl	exit
.L21:
	ldr	r3, .L25+4
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L22
	mov	r0, #1
	bl	close
	ldr	r3, .L25+12
	ldr	r3, [r3]
	mov	r1, #420
	mov	r0, r3
	bl	creat
	str	r0, [fp, #-8]
	ldr	r3, .L25+16
	ldr	r3, [r3]
	ldr	r1, .L25+16
	mov	r0, r3
	bl	execvp
	ldr	r0, .L25+20
	bl	perror
	mov	r0, #1
	bl	exit
.L22:
	ldr	r3, .L25+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L24
	mov	r0, #0
	bl	wait
	ldr	r0, .L25+24
	bl	printf
	ldr	r3, .L25+16
	ldr	r3, [r3]
	mov	r0, r3
	bl	printf
	ldr	r0, .L25+28
	bl	puts
.L24:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L26:
	.align	2
.L25:
	.word	.LC1
	.word	pid
	.word	.LC2
	.word	argv2
	.word	argv
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.size	outRedirection, .-outRedirection
	.section	.rodata
	.align	2
.LC6:
	.ascii	"<\000"
	.text
	.align	2
	.global	inRedirection
	.syntax unified
	.arm
	.fpu softvfp
	.type	inRedirection, %function
inRedirection:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r0, .L32
	bl	extractCommand
	bl	fork
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L32+4
	str	r2, [r3]
	ldr	r3, .L32+4
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L28
	ldr	r0, .L32+8
	bl	perror
	mov	r0, #1
	bl	exit
.L28:
	ldr	r3, .L32+4
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L29
	mov	r0, #0
	bl	close
	ldr	r3, .L32+12
	ldr	r3, [r3]
	mov	r1, #0
	mov	r0, r3
	bl	open
	str	r0, [fp, #-8]
	ldr	r3, .L32+16
	ldr	r3, [r3]
	ldr	r1, .L32+16
	mov	r0, r3
	bl	execvp
	ldr	r0, .L32+20
	bl	perror
	mov	r0, #1
	bl	exit
.L29:
	ldr	r3, .L32+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L31
	mov	r0, #0
	bl	wait
	ldr	r0, .L32+24
	bl	printf
	ldr	r3, .L32+16
	ldr	r3, [r3]
	mov	r0, r3
	bl	printf
	ldr	r0, .L32+28
	bl	puts
.L31:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L33:
	.align	2
.L32:
	.word	.LC6
	.word	pid
	.word	.LC2
	.word	argv2
	.word	argv
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.size	inRedirection, .-inRedirection
	.section	.rodata
	.align	2
.LC7:
	.ascii	"&\000"
	.align	2
.LC8:
	.ascii	"panic: can't fork\000"
	.align	2
.LC9:
	.ascii	"Command %s not found\012\000"
	.text
	.align	2
	.global	backgrounding
	.syntax unified
	.arm
	.fpu softvfp
	.type	backgrounding, %function
backgrounding:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L39
	bl	extractCommand
	bl	fork
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L39+4
	str	r2, [r3]
	ldr	r3, .L39+4
	ldr	r3, [r3]
	cmn	r3, #1
	beq	.L35
	cmp	r3, #0
	beq	.L36
	b	.L38
.L35:
	ldr	r0, .L39+8
	bl	puts
	mvn	r0, #0
	bl	exit
.L36:
	ldr	r3, .L39+12
	ldr	r3, [r3]
	ldr	r1, .L39+12
	mov	r0, r3
	bl	execvp
	ldr	r3, .L39+12
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L39+16
	bl	printf
	mov	r0, #1
	bl	exit
.L38:
	ldr	r0, .L39+20
	bl	usleep
	mov	r0, #0
	bl	exit
.L40:
	.align	2
.L39:
	.word	.LC7
	.word	pid
	.word	.LC8
	.word	argv
	.word	.LC9
	.word	10000
	.size	backgrounding, .-backgrounding
	.section	.rodata
	.align	2
.LC10:
	.ascii	"|\000"
	.align	2
.LC11:
	.ascii	"Cannot get a pipe\000"
	.align	2
.LC12:
	.ascii	"Unable to fork\000"
	.align	2
.LC13:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	piping
	.syntax unified
	.arm
	.fpu softvfp
	.type	piping, %function
piping:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	ldr	r3, .L48
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r0, .L48+4
	bl	extractCommand
	sub	r3, fp, #16
	mov	r0, r3
	bl	pipe
	mov	r3, r0
	cmp	r3, #0
	bge	.L42
	ldr	r0, .L48+8
	bl	puts
.L42:
	bl	fork
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L48+12
	str	r2, [r3]
	ldr	r3, .L48+12
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L43
	mov	r0, #1
	bl	close
	ldr	r3, [fp, #-12]
	mov	r0, r3
	bl	dup
	ldr	r3, [fp, #-16]
	mov	r0, r3
	bl	close
	ldr	r3, .L48+16
	ldr	r3, [r3]
	ldr	r1, .L48+16
	mov	r0, r3
	bl	execvp
	b	.L47
.L43:
	ldr	r3, .L48+12
	ldr	r3, [r3]
	cmp	r3, #0
	ble	.L45
	mov	r0, #0
	bl	close
	ldr	r3, [fp, #-16]
	mov	r0, r3
	bl	dup
	ldr	r3, [fp, #-12]
	mov	r0, r3
	bl	close
	ldr	r3, .L48+20
	ldr	r3, [r3]
	ldr	r1, .L48+20
	mov	r0, r3
	bl	execvp
	b	.L47
.L45:
	ldr	r0, .L48+24
	bl	puts
.L47:
	nop
	ldr	r3, .L48
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L46
	bl	__stack_chk_fail
.L46:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L49:
	.align	2
.L48:
	.word	.LC13
	.word	.LC10
	.word	.LC11
	.word	pid
	.word	argv
	.word	argv2
	.word	.LC12
	.size	piping, .-piping
	.align	2
	.global	process
	.syntax unified
	.arm
	.fpu softvfp
	.type	process, %function
process:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	bl	fork
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L56
	str	r2, [r3]
	ldr	r3, .L56
	ldr	r3, [r3]
	cmn	r3, #1
	beq	.L51
	cmp	r3, #0
	beq	.L52
	b	.L53
.L51:
	ldr	r0, .L56+4
	bl	puts
	mvn	r0, #0
	bl	exit
.L52:
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L54
	ldr	r3, .L56+8
	ldr	r3, [r3]
	ldr	r1, .L56+8
	mov	r0, r3
	bl	execvp
	ldr	r3, .L56+8
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L56+12
	bl	printf
	mov	r0, #0
	bl	exit
.L54:
	ldr	r3, [fp, #-8]
	cmp	r3, #1
	bne	.L55
	bl	backgrounding
	b	.L53
.L55:
	ldr	r3, [fp, #-8]
	cmp	r3, #2
	bne	.L53
	bl	piping
.L53:
	ldr	r0, .L56+16
	bl	wait
	mov	r3, r0
	ldr	r2, .L56+20
	str	r3, [r2]
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L57:
	.align	2
.L56:
	.word	pid
	.word	.LC8
	.word	argv
	.word	.LC9
	.word	status
	.word	died
	.size	process, .-process
	.section	.rodata
	.align	2
.LC14:
	.ascii	"=\000"
	.align	2
.LC15:
	.ascii	"Environment set successfully\000"
	.align	2
.LC16:
	.ascii	"Error in setting environment\000"
	.text
	.align	2
	.global	setEnv
	.syntax unified
	.arm
	.fpu softvfp
	.type	setEnv, %function
setEnv:
	@ 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	r2, .L62
	ldr	r3, [fp, #-24]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r1, .L62+4
	mov	r0, r3
	bl	strtok
	str	r0, [fp, #-16]
	ldr	r1, .L62+8
	mov	r0, #0
	bl	strtok
	str	r0, [fp, #-12]
	mov	r2, #1
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-16]
	bl	setenv
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L59
	ldr	r0, .L62+12
	bl	puts
	b	.L61
.L59:
	ldr	r0, .L62+16
	bl	puts
.L61:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L63:
	.align	2
.L62:
	.word	argv
	.word	.LC14
	.word	.LC0
	.word	.LC15
	.word	.LC16
	.size	setEnv, .-setEnv
	.section	.rodata
	.align	2
.LC17:
	.ascii	"Environment variable %s unset successfully\012\000"
	.align	2
.LC18:
	.ascii	"Error in unsetting environment\000"
	.text
	.align	2
	.global	unsetEnv
	.syntax unified
	.arm
	.fpu softvfp
	.type	unsetEnv, %function
unsetEnv:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r3, .L68
	ldr	r3, [r3, #4]
	mov	r0, r3
	bl	unsetenv
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L65
	ldr	r3, .L68
	ldr	r3, [r3, #4]
	mov	r1, r3
	ldr	r0, .L68+4
	bl	printf
	b	.L67
.L65:
	ldr	r0, .L68+8
	bl	puts
.L67:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L69:
	.align	2
.L68:
	.word	argv
	.word	.LC17
	.word	.LC18
	.size	unsetEnv, .-unsetEnv
	.section	.rodata
	.align	2
.LC19:
	.ascii	"PWD\000"
	.align	2
.LC20:
	.ascii	"OLDPWD\000"
	.align	2
.LC21:
	.ascii	"HOME\000"
	.align	2
.LC22:
	.ascii	"Error in changing directory\000"
	.align	2
.LC23:
	.ascii	"Current directory: %s\012\000"
	.text
	.align	2
	.global	changeDirectory
	.syntax unified
	.arm
	.fpu softvfp
	.type	changeDirectory, %function
changeDirectory:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r0, .L76
	bl	getenv
	mov	r3, r0
	mov	r2, #1
	mov	r1, r3
	ldr	r0, .L76+4
	bl	setenv
	ldr	r3, .L76+8
	ldr	r3, [r3, #4]
	cmp	r3, #0
	beq	.L71
	ldr	r3, .L76+8
	ldr	r3, [r3, #4]
	mov	r0, r3
	bl	chdir
	str	r0, [fp, #-12]
	bl	get_current_dir_name
	mov	r3, r0
	mov	r2, #1
	mov	r1, r3
	ldr	r0, .L76
	bl	setenv
	b	.L72
.L71:
	ldr	r0, .L76+12
	bl	getenv
	str	r0, [fp, #-8]
	ldr	r0, [fp, #-8]
	bl	chdir
	str	r0, [fp, #-12]
	ldr	r0, .L76+12
	bl	getenv
	mov	r3, r0
	mov	r2, #1
	mov	r1, r3
	ldr	r0, .L76
	bl	setenv
.L72:
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	beq	.L73
	ldr	r0, .L76+16
	bl	puts
	b	.L75
.L73:
	ldr	r0, .L76
	bl	getenv
	mov	r3, r0
	mov	r1, r3
	ldr	r0, .L76+20
	bl	printf
.L75:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L77:
	.align	2
.L76:
	.word	.LC19
	.word	.LC20
	.word	argv
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.size	changeDirectory, .-changeDirectory
	.align	2
	.global	stringCompare
	.syntax unified
	.arm
	.fpu softvfp
	.type	stringCompare, %function
stringCompare:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L79
.L85:
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r1, .L86+4
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L80
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldrb	r3, [r3]	@ zero_extendqisi2
	b	.L81
.L80:
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r1, .L86+8
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L82
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldrb	r3, [r3]	@ zero_extendqisi2
	b	.L81
.L82:
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r1, .L86+12
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L83
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldrb	r3, [r3]	@ zero_extendqisi2
	b	.L81
.L83:
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r1, .L86+16
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L84
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldrb	r3, [r3]	@ zero_extendqisi2
	b	.L81
.L84:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L79:
	ldr	r2, .L86
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #0
	bne	.L85
	mov	r3, #0
.L81:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L87:
	.align	2
.L86:
	.word	argv
	.word	.LC1
	.word	.LC6
	.word	.LC10
	.word	.LC7
	.size	stringCompare, .-stringCompare
	.section	.rodata
	.align	2
.LC24:
	.ascii	"Initializing shell: \000"
	.align	2
.LC25:
	.ascii	"myshell$ \000"
	.align	2
.LC26:
	.ascii	"exit\000"
	.align	2
.LC27:
	.ascii	"export\000"
	.align	2
.LC28:
	.ascii	"unset\000"
	.align	2
.LC29:
	.ascii	"cd\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L102
	bl	puts
.L100:
	ldr	r0, .L102+4
	bl	printf
	bl	readLine
	ldr	r3, .L102+8
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L101
	ldr	r3, .L102+8
	ldr	r3, [r3]
	ldr	r1, .L102+12
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L91
	mov	r0, #0
	bl	exit
.L91:
	ldr	r3, .L102+8
	ldr	r3, [r3]
	ldr	r1, .L102+16
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L92
	mov	r0, #1
	bl	setEnv
	b	.L100
.L92:
	ldr	r3, .L102+8
	ldr	r3, [r3]
	mov	r1, #61
	mov	r0, r3
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	beq	.L93
	mov	r0, #0
	bl	setEnv
	b	.L100
.L93:
	ldr	r3, .L102+8
	ldr	r3, [r3]
	ldr	r1, .L102+20
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L94
	bl	unsetEnv
	b	.L100
.L94:
	ldr	r3, .L102+8
	ldr	r3, [r3]
	ldr	r1, .L102+24
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L95
	bl	changeDirectory
	b	.L100
.L95:
	bl	stringCompare
	mov	r3, r0
	cmp	r3, #124
	beq	.L96
	cmp	r3, #124
	bgt	.L97
	cmp	r3, #62
	beq	.L98
	cmp	r3, #62
	bgt	.L97
	cmp	r3, #38
	beq	.L99
	cmp	r3, #60
	bne	.L97
	bl	inRedirection
	b	.L90
.L98:
	bl	outRedirection
	b	.L90
.L96:
	mov	r0, #2
	bl	process
	b	.L90
.L99:
	mov	r0, #1
	bl	process
	b	.L90
.L97:
	mov	r0, #0
	bl	process
	b	.L90
.L101:
	nop
.L90:
	b	.L100
.L103:
	.align	2
.L102:
	.word	.LC24
	.word	.LC25
	.word	argv
	.word	.LC26
	.word	.LC27
	.word	.LC28
	.word	.LC29
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
