	.file	"471086.c"
	.intel_syntax noprefix
	.text
	.globl	prompt
	.data
	.type	prompt, @object
	.size	prompt, 6
prompt:
	.string	"tsh> "
	.globl	verbose
	.bss
	.align 4
	.type	verbose, @object
	.size	verbose, 4
verbose:
	.zero	4
	.globl	nextjid
	.data
	.align 4
	.type	nextjid, @object
	.size	nextjid, 4
nextjid:
	.long	1
	.globl	sbuf
	.bss
	.align 32
	.type	sbuf, @object
	.size	sbuf, 1024
sbuf:
	.zero	1024
	.globl	fg
	.align 4
	.type	fg, @object
	.size	fg, 4
fg:
	.zero	4
	.globl	jobs
	.align 32
	.type	jobs, @object
	.size	jobs, 16576
jobs:
	.zero	16576
	.section	.rodata
.LC0:
	.string	"hvp"
.LC1:
	.string	"%s"
.LC2:
	.string	"fgets error"
	.text
	.globl	main
	.type	main, @function
main:
.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, 1072
	mov	DWORD PTR -1060[rbp], edi
	mov	QWORD PTR -1072[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -1044[rbp], 1
	mov	esi, 2
	mov	edi, 1
	call	dup2@PLT
	jmp	.L2
.L7:
	movsx	eax, BYTE PTR -1045[rbp]
	cmp	eax, 118
	je	.L3
	cmp	eax, 118
	jg	.L4
	cmp	eax, 104
	je	.L5
	cmp	eax, 112
	je	.L6
	jmp	.L4
.L5:
	call	usage
	jmp	.L2
.L3:
	mov	DWORD PTR verbose[rip], 1
	jmp	.L2
.L6:
	mov	DWORD PTR -1044[rbp], 0
	jmp	.L2
.L4:
	call	usage
.L2:
	mov	rcx, QWORD PTR -1072[rbp]
	mov	eax, DWORD PTR -1060[rbp]
	lea	rdx, .LC0[rip]
	mov	rsi, rcx
	mov	edi, eax
	call	getopt@PLT
	mov	BYTE PTR -1045[rbp], al
	cmp	BYTE PTR -1045[rbp], -1
	jne	.L7
	lea	rsi, sigint_handler[rip]
	mov	edi, 2
	call	Signal
	lea	rsi, sigtstp_handler[rip]
	mov	edi, 20
	call	Signal
	lea	rsi, sigchld_handler[rip]
	mov	edi, 17
	call	Signal
	lea	rsi, sigquit_handler[rip]
	mov	edi, 3
	call	Signal
	lea	rdi, jobs[rip]
	call	initjobs
.L11:
	cmp	DWORD PTR -1044[rbp], 0
	je	.L8
	lea	rsi, prompt[rip]
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR stdout[rip]
	mov	rdi, rax
	call	fflush@PLT
.L8:
	mov	rdx, QWORD PTR stdin[rip]
	lea	rax, -1040[rbp]
	mov	esi, 1024
	mov	rdi, rax
	call	fgets@PLT
	test	rax, rax
	jne	.L9
	mov	rax, QWORD PTR stdin[rip]
	mov	rdi, rax
	call	ferror@PLT
	test	eax, eax
	je	.L9
	lea	rdi, .LC2[rip]
	call	app_error
.L9:
	mov	rax, QWORD PTR stdin[rip]
	mov	rdi, rax
	call	feof@PLT
	test	eax, eax
	je	.L10
	mov	rax, QWORD PTR stdout[rip]
	mov	rdi, rax
	call	fflush@PLT
	mov	edi, 0
	call	exit@PLT
.L10:
	lea	rax, -1040[rbp]
	mov	rdi, rax
	call	eval
	mov	rax, QWORD PTR stdout[rip]
	mov	rdi, rax
	call	fflush@PLT
	mov	rax, QWORD PTR stdout[rip]
	mov	rdi, rax
	call	fflush@PLT
	jmp	.L11
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
.LC3:
	.string	"setpgid failed.\n"
.LC4:
	.string	"%s: Command not found.\n"
.LC5:
	.string	"[%d] (%d) %s\n"
	.text
	.globl	eval
	.type	eval, @function
eval:
.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, 2480
	mov	QWORD PTR -2472[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, -2448[rbp]
	mov	rdi, rax
	call	sigfillset@PLT
	lea	rax, -2320[rbp]
	mov	rdi, rax
	call	sigemptyset@PLT
	lea	rax, -2320[rbp]
	mov	esi, 17
	mov	rdi, rax
	call	sigaddset@PLT
	mov	rdx, QWORD PTR -2472[rbp]
	lea	rax, -1040[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcpy@PLT
	lea	rdx, -2064[rbp]
	lea	rax, -1040[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	parseline
	mov	DWORD PTR -2456[rbp], eax
	mov	rax, QWORD PTR -2064[rbp]
	test	rax, rax
	je	.L25
	lea	rax, -2064[rbp]
	mov	rdi, rax
	call	builtin_cmd
	test	eax, eax
	jne	.L26
	lea	rdx, -2192[rbp]
	lea	rax, -2320[rbp]
	mov	rsi, rax
	mov	edi, 0
	call	sigprocmask@PLT
	call	fork@PLT
	cmp	DWORD PTR -2452[rbp], eax
	je	.L17
	lea	rax, -2192[rbp]
	mov	edx, 0
	mov	rsi, rax
	mov	edi, 2
	call	sigprocmask@PLT
	mov	esi, 0
	mov	edi, 0
	call	setpgid@PLT
	test	eax, eax
	jns	.L18
	lea	rdi, .LC3[rip]
	call	unix_error
.L18:
	mov	rdx, QWORD PTR environ[rip]
	mov	rax, QWORD PTR -2064[rbp]
	lea	rcx, -2064[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	execve@PLT
	test	eax, eax
	jns	.L19
	mov	rax, QWORD PTR -2064[rbp]
	mov	rsi, rax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
.L19:
	mov	edi, 0
	call	exit@PLT
.L17:
	cmp	DWORD PTR -2456[rbp], 0
	jne	.L20
	lea	rdx, -1040[rbp]
	mov	eax, DWORD PTR -2452[rbp]
	mov	rcx, rdx
	mov	edx, 1
	mov	esi, eax
	lea	rdi, jobs[rip]
	call	addjob
	jmp	.L21
.L20:
	lea	rdx, -1040[rbp]
	mov	eax, DWORD PTR -2452[rbp]
	mov	rcx, rdx
	mov	edx, 2
	mov	esi, eax
	lea	rdi, jobs[rip]
	call	addjob
.L21:
	lea	rax, -2192[rbp]
	mov	edx, 0
	mov	rsi, rax
	mov	edi, 2
	call	sigprocmask@PLT
	cmp	DWORD PTR -2456[rbp], 0
	jne	.L22
	mov	eax, DWORD PTR -2452[rbp]
	mov	edi, eax
	call	waitfg
	jmp	.L26
.L22:
	mov	eax, DWORD PTR -2452[rbp]
	mov	edi, eax
	call	pid2jid
	mov	esi, eax
	mov	rdx, QWORD PTR -2472[rbp]
	mov	eax, DWORD PTR -2452[rbp]
	mov	rcx, rdx
	mov	edx, eax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L26
.L25:
	nop
	jmp	.L13
.L26:
	nop
.L13:
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L24
	call	__stack_chk_fail@PLT
.L24:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	eval, .-eval
	.globl	parseline
	.type	parseline, @function
parseline:
.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, 48
	mov	QWORD PTR -40[rbp], rdi
	mov	QWORD PTR -48[rbp], rsi
	lea	rax, array.0[rip]
	mov	QWORD PTR -16[rbp], rax
	mov	rdx, QWORD PTR -40[rbp]
	mov	rax, QWORD PTR -16[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcpy@PLT
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	strlen@PLT
	lea	rdx, -1[rax]
	mov	rax, QWORD PTR -16[rbp]
	add	rax, rdx
	mov	BYTE PTR [rax], 32
	jmp	.L28
.L30:
	add	QWORD PTR -16[rbp], 1
.L28:
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	je	.L29
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	je	.L30
.L29:
	mov	DWORD PTR -24[rbp], 0
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 39
	jne	.L31
	add	QWORD PTR -16[rbp], 1
	mov	rax, QWORD PTR -16[rbp]
	mov	esi, 39
	mov	rdi, rax
	call	strchr@PLT
	mov	QWORD PTR -8[rbp], rax
	jmp	.L33
.L31:
	mov	rax, QWORD PTR -16[rbp]
	mov	esi, 32
	mov	rdi, rax
	call	strchr@PLT
	mov	QWORD PTR -8[rbp], rax
	jmp	.L33
.L38:
	mov	eax, DWORD PTR -24[rbp]
	lea	edx, 1[rax]
	mov	DWORD PTR -24[rbp], edx
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rdx, rax
	mov	rax, QWORD PTR -16[rbp]
	mov	QWORD PTR [rdx], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	BYTE PTR [rax], 0
	mov	rax, QWORD PTR -8[rbp]
	add	rax, 1
	mov	QWORD PTR -16[rbp], rax
	jmp	.L34
.L36:
	add	QWORD PTR -16[rbp], 1
.L34:
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	je	.L35
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 32
	je	.L36
.L35:
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 39
	jne	.L37
	add	QWORD PTR -16[rbp], 1
	mov	rax, QWORD PTR -16[rbp]
	mov	esi, 39
	mov	rdi, rax
	call	strchr@PLT
	mov	QWORD PTR -8[rbp], rax
	jmp	.L33
.L37:
	mov	rax, QWORD PTR -16[rbp]
	mov	esi, 32
	mov	rdi, rax
	call	strchr@PLT
	mov	QWORD PTR -8[rbp], rax
.L33:
	cmp	QWORD PTR -8[rbp], 0
	jne	.L38
	mov	eax, DWORD PTR -24[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	QWORD PTR [rax], 0
	cmp	DWORD PTR -24[rbp], 0
	jne	.L39
	mov	eax, 1
	jmp	.L40
.L39:
	mov	eax, DWORD PTR -24[rbp]
	cdqe
	sal	rax, 3
	lea	rdx, -8[rax]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 38
	sete	al
	movzx	eax, al
	mov	DWORD PTR -20[rbp], eax
	cmp	DWORD PTR -20[rbp], 0
	je	.L41
	sub	DWORD PTR -24[rbp], 1
	mov	eax, DWORD PTR -24[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	QWORD PTR [rax], 0
.L41:
	mov	eax, DWORD PTR -20[rbp]
.L40:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	parseline, .-parseline
	.section	.rodata
.LC6:
	.string	"quit"
.LC7:
	.string	"bg"
.LC8:
	.string	"fg"
.LC9:
	.string	"jobs"
	.text
	.globl	builtin_cmd
	.type	builtin_cmd, @function
builtin_cmd:
.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
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC6[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L43
	mov	edi, 0
	call	exit@PLT
.L43:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	je	.L44
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC8[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L45
.L44:
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	do_bgfg
	mov	eax, 1
	jmp	.L46
.L45:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC9[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L47
	lea	rdi, jobs[rip]
	call	listjobs
	mov	eax, 1
	jmp	.L46
.L47:
	mov	eax, 0
.L46:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	builtin_cmd, .-builtin_cmd
	.section	.rodata
	.align 8
.LC10:
	.string	"%s:argument must be a PID or %%jobid.\n"
.LC11:
	.string	"(%s): No such process.\n"
.LC12:
	.string	"[%d] (%d) %s"
.LC13:
	.string	"Can't handle this situation.\n"
	.text
	.globl	do_bgfg
	.type	do_bgfg, @function
do_bgfg:
.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, 320
	mov	QWORD PTR -312[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -312[rbp]
	mov	rax, QWORD PTR [rax]
	mov	QWORD PTR -296[rbp], rax
	mov	rax, QWORD PTR -312[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	QWORD PTR -288[rbp], rax
	lea	rax, -272[rbp]
	mov	rdi, rax
	call	sigfillset@PLT
	mov	rax, QWORD PTR -288[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 37
	jne	.L49
	mov	rax, QWORD PTR -288[rbp]
	add	rax, 1
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR -304[rbp], eax
	cmp	DWORD PTR -304[rbp], 0
	jne	.L50
	mov	rax, QWORD PTR -296[rbp]
	mov	rsi, rax
	lea	rdi, .LC10[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L48
.L49:
	mov	rax, QWORD PTR -288[rbp]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR -300[rbp], eax
	cmp	DWORD PTR -304[rbp], 0
	jne	.L52
	mov	rax, QWORD PTR -296[rbp]
	mov	rsi, rax
	lea	rdi, .LC10[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L48
.L52:
	lea	rdx, -144[rbp]
	lea	rax, -272[rbp]
	mov	rsi, rax
	mov	edi, 0
	call	sigprocmask@PLT
	mov	eax, DWORD PTR -300[rbp]
	mov	edi, eax
	call	pid2jid
	mov	DWORD PTR -304[rbp], eax
.L50:
	lea	rdx, -144[rbp]
	lea	rax, -272[rbp]
	mov	rsi, rax
	mov	edi, 0
	call	sigprocmask@PLT
	mov	eax, DWORD PTR -304[rbp]
	mov	esi, eax
	lea	rdi, jobs[rip]
	call	getjobjid
	mov	QWORD PTR -280[rbp], rax
	cmp	QWORD PTR -280[rbp], 0
	jne	.L53
	mov	rax, QWORD PTR -288[rbp]
	mov	rsi, rax
	lea	rdi, .LC11[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -144[rbp]
	mov	edx, 0
	mov	rsi, rax
	mov	edi, 2
	call	sigprocmask@PLT
	jmp	.L48
.L53:
	mov	rax, QWORD PTR -296[rbp]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L54
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR 8[rax]
	cmp	eax, 2
	je	.L63
	cmp	eax, 3
	jne	.L56
	mov	rax, QWORD PTR -280[rbp]
	mov	DWORD PTR 8[rax], 2
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR [rax]
	neg	eax
	mov	esi, 18
	mov	edi, eax
	call	kill@PLT
	mov	rax, QWORD PTR -280[rbp]
	lea	rcx, 12[rax]
	mov	rax, QWORD PTR -280[rbp]
	mov	edx, DWORD PTR [rax]
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR 4[rax]
	mov	esi, eax
	lea	rdi, .LC12[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L58
.L56:
	lea	rdi, .LC13[rip]
	call	unix_error
	jmp	.L58
.L54:
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR 8[rax]
	cmp	eax, 2
	je	.L59
	cmp	eax, 3
	jne	.L60
	mov	rax, QWORD PTR -280[rbp]
	mov	DWORD PTR 8[rax], 1
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR [rax]
	neg	eax
	mov	esi, 18
	mov	edi, eax
	call	kill@PLT
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	waitfg
	jmp	.L58
.L59:
	mov	rax, QWORD PTR -280[rbp]
	mov	DWORD PTR 8[rax], 1
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	waitfg
	jmp	.L58
.L60:
	lea	rdi, .LC13[rip]
	call	unix_error
	jmp	.L58
.L63:
	nop
.L58:
	lea	rax, -144[rbp]
	mov	edx, 0
	mov	rsi, rax
	mov	edi, 2
	call	sigprocmask@PLT
	nop
.L48:
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L62
	call	__stack_chk_fail@PLT
.L62:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	do_bgfg, .-do_bgfg
	.globl	waitfg
	.type	waitfg, @function
waitfg:
.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, 160
	mov	DWORD PTR -148[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, -144[rbp]
	mov	rdi, rax
	call	sigemptyset@PLT
	mov	DWORD PTR fg[rip], 0
	jmp	.L65
.L66:
	lea	rax, -144[rbp]
	mov	rdi, rax
	call	sigsuspend@PLT
.L65:
	mov	eax, DWORD PTR fg[rip]
	test	eax, eax
	je	.L66
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L68
	call	__stack_chk_fail@PLT
.L68:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	waitfg, .-waitfg
	.section	.rodata
	.align 8
.LC14:
	.string	"Job [%d] (%d) terminated by a signal %d\n"
	.align 8
.LC15:
	.string	"Job [%d] (%d) terminated by signal %d\n"
	.text
	.globl	sigchld_handler
	.type	sigchld_handler, @function
sigchld_handler:
.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, 320
	mov	DWORD PTR -308[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -288[rbp], eax
	lea	rax, -272[rbp]
	mov	rdi, rax
	call	sigfillset@PLT
	jmp	.L70
.L75:
	lea	rdx, -144[rbp]
	lea	rax, -272[rbp]
	mov	rsi, rax
	mov	edi, 0
	call	sigprocmask@PLT
	mov	eax, DWORD PTR -284[rbp]
	mov	esi, eax
	lea	rdi, jobs[rip]
	call	getjobpid
	mov	QWORD PTR -280[rbp], rax
	lea	rdi, jobs[rip]
	call	fgpid
	cmp	DWORD PTR -284[rbp], eax
	jne	.L71
	mov	DWORD PTR fg[rip], 1
.L71:
	mov	eax, DWORD PTR -292[rbp]
	movzx	eax, al
	cmp	eax, 127
	jne	.L72
	mov	rax, QWORD PTR -280[rbp]
	mov	DWORD PTR 8[rax], 3
	mov	eax, DWORD PTR -292[rbp]
	sar	eax, 8
	movzx	ecx, al
	mov	rax, QWORD PTR -280[rbp]
	mov	edx, DWORD PTR [rax]
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR 4[rax]
	mov	esi, eax
	lea	rdi, .LC14[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L73
.L72:
	mov	eax, DWORD PTR -292[rbp]
	and	eax, 127
	add	eax, 1
	sar	al
	test	al, al
	jle	.L74
	mov	eax, DWORD PTR -292[rbp]
	and	eax, 127
	mov	ecx, eax
	mov	rax, QWORD PTR -280[rbp]
	mov	edx, DWORD PTR [rax]
	mov	rax, QWORD PTR -280[rbp]
	mov	eax, DWORD PTR 4[rax]
	mov	esi, eax
	lea	rdi, .LC15[rip]
	mov	eax, 0
	call	printf@PLT
.L74:
	mov	eax, DWORD PTR -284[rbp]
	mov	esi, eax
	lea	rdi, jobs[rip]
	call	deletejob
.L73:
	lea	rax, -144[rbp]
	mov	edx, 0
	mov	rsi, rax
	mov	edi, 2
	call	sigprocmask@PLT
.L70:
	lea	rax, -292[rbp]
	mov	edx, 3
	mov	rsi, rax
	mov	edi, -1
	call	waitpid@PLT
	mov	DWORD PTR -284[rbp], eax
	cmp	DWORD PTR -284[rbp], 0
	jg	.L75
	call	__errno_location@PLT
	mov	edx, DWORD PTR -288[rbp]
	mov	DWORD PTR [rax], edx
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L76
	call	__stack_chk_fail@PLT
.L76:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	sigchld_handler, .-sigchld_handler
	.globl	sigint_handler
	.type	sigint_handler, @function
sigint_handler:
.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, 304
	mov	DWORD PTR -292[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -280[rbp], eax
	lea	rax, -272[rbp]
	mov	rdi, rax
	call	sigfillset@PLT
	lea	rdx, -144[rbp]
	lea	rax, -272[rbp]
	mov	rsi, rax
	mov	edi, 0
	call	sigprocmask@PLT
	lea	rdi, jobs[rip]
	call	fgpid
	mov	DWORD PTR -276[rbp], eax
	lea	rax, -144[rbp]
	mov	edx, 0
	mov	rsi, rax
	mov	edi, 2
	call	sigprocmask@PLT
	cmp	DWORD PTR -276[rbp], 0
	je	.L78
	mov	eax, DWORD PTR -276[rbp]
	neg	eax
	mov	esi, 2
	mov	edi, eax
	call	kill@PLT
.L78:
	call	__errno_location@PLT
	mov	edx, DWORD PTR -280[rbp]
	mov	DWORD PTR [rax], edx
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L80
	call	__stack_chk_fail@PLT
.L80:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	sigint_handler, .-sigint_handler
	.globl	sigtstp_handler
	.type	sigtstp_handler, @function
sigtstp_handler:
.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, 304
	mov	DWORD PTR -292[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -280[rbp], eax
	lea	rax, -272[rbp]
	mov	rdi, rax
	call	sigfillset@PLT
	lea	rdx, -144[rbp]
	lea	rax, -272[rbp]
	mov	rsi, rax
	mov	edi, 0
	call	sigprocmask@PLT
	lea	rdi, jobs[rip]
	call	fgpid
	mov	DWORD PTR -276[rbp], eax
	lea	rax, -144[rbp]
	mov	edx, 0
	mov	rsi, rax
	mov	edi, 2
	call	sigprocmask@PLT
	cmp	DWORD PTR -276[rbp], 0
	je	.L82
	mov	eax, DWORD PTR -276[rbp]
	neg	eax
	mov	esi, 20
	mov	edi, eax
	call	kill@PLT
.L82:
	call	__errno_location@PLT
	mov	edx, DWORD PTR -280[rbp]
	mov	DWORD PTR [rax], edx
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L84
	call	__stack_chk_fail@PLT
.L84:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	sigtstp_handler, .-sigtstp_handler
	.globl	clearjob
	.type	clearjob, @function
clearjob:
.LFB15:
	.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 -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR [rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4[rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 8[rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	BYTE PTR 12[rax], 0
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	clearjob, .-clearjob
	.globl	initjobs
	.type	initjobs, @function
initjobs:
.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, 24
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -4[rbp], 0
	jmp	.L87
.L88:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	rdi, rax
	call	clearjob
	add	DWORD PTR -4[rbp], 1
.L87:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L88
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE16:
	.size	initjobs, .-initjobs
	.globl	maxjid
	.type	maxjid, @function
maxjid:
.LFB17:
	.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	DWORD PTR -4[rbp], 0
	mov	DWORD PTR -8[rbp], 0
	jmp	.L90
.L92:
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR 4[rax]
	cmp	DWORD PTR -4[rbp], eax
	jge	.L91
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR 4[rax]
	mov	DWORD PTR -4[rbp], eax
.L91:
	add	DWORD PTR -8[rbp], 1
.L90:
	cmp	DWORD PTR -8[rbp], 15
	jle	.L92
	mov	eax, DWORD PTR -4[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE17:
	.size	maxjid, .-maxjid
	.section	.rodata
.LC16:
	.string	"Added job [%d] %d %s\n"
.LC17:
	.string	"Tried to create too many jobs"
	.text
	.globl	addjob
	.type	addjob, @function
addjob:
.LFB18:
	.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 -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	DWORD PTR -32[rbp], edx
	mov	QWORD PTR -40[rbp], rcx
	cmp	DWORD PTR -28[rbp], 0
	jg	.L95
	mov	eax, 0
	jmp	.L96
.L95:
	mov	DWORD PTR -4[rbp], 0
	jmp	.L97
.L101:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	jne	.L98
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -28[rbp]
	mov	DWORD PTR [rdx], eax
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -32[rbp]
	mov	DWORD PTR 8[rdx], eax
	mov	eax, DWORD PTR nextjid[rip]
	lea	edx, 1[rax]
	mov	DWORD PTR nextjid[rip], edx
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	imul	rcx, rdx, 1036
	mov	rdx, QWORD PTR -24[rbp]
	add	rdx, rcx
	mov	DWORD PTR 4[rdx], eax
	mov	eax, DWORD PTR nextjid[rip]
	cmp	eax, 16
	jle	.L99
	mov	DWORD PTR nextjid[rip], 1
.L99:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	lea	rdx, 12[rax]
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rax
	mov	rdi, rdx
	call	strcpy@PLT
	mov	eax, DWORD PTR verbose[rip]
	test	eax, eax
	je	.L100
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	lea	rcx, 12[rax]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	edx, DWORD PTR [rax]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rsi, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rsi
	mov	eax, DWORD PTR 4[rax]
	mov	esi, eax
	lea	rdi, .LC16[rip]
	mov	eax, 0
	call	printf@PLT
.L100:
	mov	eax, 1
	jmp	.L96
.L98:
	add	DWORD PTR -4[rbp], 1
.L97:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L101
	lea	rdi, .LC17[rip]
	call	puts@PLT
	mov	eax, 0
.L96:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE18:
	.size	addjob, .-addjob
	.globl	deletejob
	.type	deletejob, @function
deletejob:
.LFB19:
	.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 -28[rbp], esi
	cmp	DWORD PTR -28[rbp], 0
	jg	.L103
	mov	eax, 0
	jmp	.L104
.L103:
	mov	DWORD PTR -4[rbp], 0
	jmp	.L105
.L107:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	DWORD PTR -28[rbp], eax
	jne	.L106
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	rdi, rax
	call	clearjob
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	maxjid
	add	eax, 1
	mov	DWORD PTR nextjid[rip], eax
	mov	eax, 1
	jmp	.L104
.L106:
	add	DWORD PTR -4[rbp], 1
.L105:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L107
	mov	eax, 0
.L104:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE19:
	.size	deletejob, .-deletejob
	.globl	fgpid
	.type	fgpid, @function
fgpid:
.LFB20:
	.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	DWORD PTR -4[rbp], 0
	jmp	.L109
.L112:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR 8[rax]
	cmp	eax, 1
	jne	.L110
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	jmp	.L111
.L110:
	add	DWORD PTR -4[rbp], 1
.L109:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L112
	mov	eax, 0
.L111:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE20:
	.size	fgpid, .-fgpid
	.globl	getjobpid
	.type	getjobpid, @function
getjobpid:
.LFB21:
	.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	DWORD PTR -28[rbp], esi
	cmp	DWORD PTR -28[rbp], 0
	jg	.L114
	mov	eax, 0
	jmp	.L115
.L114:
	mov	DWORD PTR -4[rbp], 0
	jmp	.L116
.L118:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	DWORD PTR -28[rbp], eax
	jne	.L117
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	jmp	.L115
.L117:
	add	DWORD PTR -4[rbp], 1
.L116:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L118
	mov	eax, 0
.L115:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE21:
	.size	getjobpid, .-getjobpid
	.globl	getjobjid
	.type	getjobjid, @function
getjobjid:
.LFB22:
	.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	DWORD PTR -28[rbp], esi
	cmp	DWORD PTR -28[rbp], 0
	jg	.L120
	mov	eax, 0
	jmp	.L121
.L120:
	mov	DWORD PTR -4[rbp], 0
	jmp	.L122
.L124:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR 4[rax]
	cmp	DWORD PTR -28[rbp], eax
	jne	.L123
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	jmp	.L121
.L123:
	add	DWORD PTR -4[rbp], 1
.L122:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L124
	mov	eax, 0
.L121:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE22:
	.size	getjobjid, .-getjobjid
	.globl	pid2jid
	.type	pid2jid, @function
pid2jid:
.LFB23:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	cmp	DWORD PTR -20[rbp], 0
	jg	.L126
	mov	eax, 0
	jmp	.L127
.L126:
	mov	DWORD PTR -4[rbp], 0
	jmp	.L128
.L130:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rax, rax, 1036
	lea	rdx, jobs[rip]
	mov	eax, DWORD PTR [rax+rdx]
	cmp	DWORD PTR -20[rbp], eax
	jne	.L129
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rax, rax, 1036
	lea	rdx, jobs[rip+4]
	mov	eax, DWORD PTR [rax+rdx]
	jmp	.L127
.L129:
	add	DWORD PTR -4[rbp], 1
.L128:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L130
	mov	eax, 0
.L127:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE23:
	.size	pid2jid, .-pid2jid
	.section	.rodata
.LC18:
	.string	"[%d] (%d) "
.LC19:
	.string	"Running "
.LC20:
	.string	"Foreground "
.LC21:
	.string	"Stopped "
	.align 8
.LC22:
	.string	"listjobs: Internal error: job[%d].state=%d "
	.text
	.globl	listjobs
	.type	listjobs, @function
listjobs:
.LFB24:
	.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 -4[rbp], 0
	jmp	.L132
.L138:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	je	.L133
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	edx, DWORD PTR [rax]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rcx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rcx
	mov	eax, DWORD PTR 4[rax]
	mov	esi, eax
	lea	rdi, .LC18[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR 8[rax]
	cmp	eax, 3
	je	.L134
	cmp	eax, 3
	jg	.L135
	cmp	eax, 1
	je	.L136
	cmp	eax, 2
	jne	.L135
	lea	rdi, .LC19[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L137
.L136:
	lea	rdi, .LC20[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L137
.L134:
	lea	rdi, .LC21[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L137
.L135:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	edx, DWORD PTR 8[rax]
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC22[rip]
	mov	eax, 0
	call	printf@PLT
.L137:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	imul	rdx, rax, 1036
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	add	rax, 12
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
.L133:
	add	DWORD PTR -4[rbp], 1
.L132:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L138
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE24:
	.size	listjobs, .-listjobs
	.section	.rodata
.LC23:
	.string	"Usage: shell [-hvp]"
.LC24:
	.string	"   -h   print this message"
	.align 8
.LC25:
	.string	"   -v   print additional diagnostic information"
	.align 8
.LC26:
	.string	"   -p   do not emit a command prompt"
	.text
	.globl	usage
	.type	usage, @function
usage:
.LFB25:
	.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
	lea	rdi, .LC24[rip]
	call	puts@PLT
	lea	rdi, .LC25[rip]
	call	puts@PLT
	lea	rdi, .LC26[rip]
	call	puts@PLT
	mov	edi, 1
	call	exit@PLT
	.cfi_endproc
.LFE25:
	.size	usage, .-usage
	.section	.rodata
.LC27:
	.string	"%s: %s\n"
	.text
	.globl	unix_error
	.type	unix_error, @function
unix_error:
.LFB26:
	.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	QWORD PTR -8[rbp], rdi
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rcx, rax
	mov	rax, QWORD PTR stdout[rip]
	mov	rdx, QWORD PTR -8[rbp]
	lea	rsi, .LC27[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
	.cfi_endproc
.LFE26:
	.size	unix_error, .-unix_error
	.section	.rodata
.LC28:
	.string	"%s\n"
	.text
	.globl	app_error
	.type	app_error, @function
app_error:
.LFB27:
	.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	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR stdout[rip]
	mov	rdx, QWORD PTR -8[rbp]
	lea	rsi, .LC28[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
	.cfi_endproc
.LFE27:
	.size	app_error, .-app_error
	.section	.rodata
.LC29:
	.string	"Signal error"
	.text
	.globl	Signal
	.type	Signal, @function
Signal:
.LFB28:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 336
	mov	DWORD PTR -324[rbp], edi
	mov	QWORD PTR -336[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -336[rbp]
	mov	QWORD PTR -320[rbp], rax
	lea	rax, -320[rbp]
	add	rax, 8
	mov	rdi, rax
	call	sigemptyset@PLT
	mov	DWORD PTR -184[rbp], 268435456
	lea	rdx, -160[rbp]
	lea	rcx, -320[rbp]
	mov	eax, DWORD PTR -324[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	sigaction@PLT
	test	eax, eax
	jns	.L143
	lea	rdi, .LC29[rip]
	call	unix_error
.L143:
	mov	rax, QWORD PTR -160[rbp]
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L145
	call	__stack_chk_fail@PLT
.L145:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE28:
	.size	Signal, .-Signal
	.section	.rodata
	.align 8
.LC30:
	.string	"Terminating after receipt of SIGQUIT signal"
	.text
	.globl	sigquit_handler
	.type	sigquit_handler, @function
sigquit_handler:
.LFB29:
	.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
	lea	rdi, .LC30[rip]
	call	puts@PLT
	mov	edi, 1
	call	exit@PLT
	.cfi_endproc
.LFE29:
	.size	sigquit_handler, .-sigquit_handler
	.local	array.0
	.comm	array.0,1024,32
	.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	"471086.c"
	.text
	.global	prompt
	.data
	.align	2
	.type	prompt, %object
	.size	prompt, 6
prompt:
	.ascii	"tsh> \000"
	.global	verbose
	.bss
	.align	2
	.type	verbose, %object
	.size	verbose, 4
verbose:
	.space	4
	.global	nextjid
	.data
	.align	2
	.type	nextjid, %object
	.size	nextjid, 4
nextjid:
	.word	1
	.comm	sbuf,1024,4
	.comm	fg,4,4
	.comm	jobs,16576,4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"hvp\000"
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 1048
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #1040
	sub	sp, sp, #8
	str	r0, [fp, #-1048]
	str	r1, [fp, #-1052]
	ldr	r3, .L10
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #1
	str	r3, [fp, #-1036]
	mov	r1, #2
	mov	r0, #1
	bl	dup2
	b	.L2
.L9:
	cmp	r3, #118
	bgt	.L4
	cmp	r3, #104
	beq	.L5
	cmp	r3, #112
	beq	.L6
	b	.L4
.L5:
	bl	usage
	b	.L2
.L3:
	ldr	r3, .L10+4
	mov	r2, #1
	str	r2, [r3]
	b	.L2
.L6:
	mov	r3, #0
	str	r3, [fp, #-1036]
	b	.L2
.L4:
	bl	usage
.L2:
	ldr	r2, .L10+8
	ldr	r1, [fp, #-1052]
	ldr	r0, [fp, #-1048]
	bl	getopt
	mov	r3, r0
	strb	r3, [fp, #-1037]
	ldrb	r3, [fp, #-1037]	@ zero_extendqisi2
	cmp	r3, #118
	beq	.L3
	b	.L9
.L11:
	.align	2
.L10:
	.word	.LC1
	.word	verbose
	.word	.LC0
	.size	main, .-main
	.section	.rodata
	.align	2
.LC2:
	.ascii	"setpgid failed.\012\000"
	.align	2
.LC3:
	.ascii	"%s: Command not found.\012\000"
	.align	2
.LC4:
	.ascii	"[%d] (%d) %s\012\000"
	.align	2
.LC5:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	eval
	.syntax unified
	.arm
	.fpu softvfp
	.type	eval, %function
eval:
	@ args = 0, pretend = 0, frame = 1944
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #1936
	sub	sp, sp, #8
	str	r0, [fp, #-1944]
	ldr	r3, .L26
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #1920
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r0, r3
	bl	sigfillset
	sub	r3, fp, #1792
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r0, r3
	bl	sigemptyset
	sub	r3, fp, #1792
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, #17
	mov	r0, r3
	bl	sigaddset
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #4
	ldr	r1, [fp, #-1944]
	mov	r0, r3
	bl	strcpy
	sub	r2, fp, #1536
	sub	r2, r2, #4
	sub	r2, r2, #4
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	parseline
	str	r0, [fp, #-1936]
	ldr	r3, [fp, #-1544]
	cmp	r3, #0
	beq	.L24
	sub	r3, fp, #1536
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r0, r3
	bl	builtin_cmd
	mov	r3, r0
	cmp	r3, #0
	bne	.L25
	sub	r2, fp, #1664
	sub	r2, r2, #4
	sub	r2, r2, #4
	sub	r3, fp, #1792
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r3
	mov	r0, #0
	bl	sigprocmask
	bl	fork
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-1932]
	cmp	r3, r2
	beq	.L16
	sub	r3, fp, #1664
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #0
	mov	r1, r3
	mov	r0, #2
	bl	sigprocmask
	mov	r1, #0
	mov	r0, #0
	bl	setpgid
	mov	r3, r0
	cmp	r3, #0
	bge	.L17
	ldr	r0, .L26+4
	bl	unix_error
.L17:
	ldr	r0, [fp, #-1544]
	ldr	r3, .L26+8
	ldr	r2, [r3]
	sub	r3, fp, #1536
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r3
	bl	execve
	mov	r3, r0
	cmp	r3, #0
	bge	.L18
	ldr	r3, [fp, #-1544]
	mov	r1, r3
	ldr	r0, .L26+12
	bl	printf
.L18:
	mov	r0, #0
	bl	exit
.L16:
	ldr	r3, [fp, #-1936]
	cmp	r3, #0
	bne	.L19
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #1
	ldr	r1, [fp, #-1932]
	ldr	r0, .L26+16
	bl	addjob
	b	.L20
.L19:
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #2
	ldr	r1, [fp, #-1932]
	ldr	r0, .L26+16
	bl	addjob
.L20:
	sub	r3, fp, #1664
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #0
	mov	r1, r3
	mov	r0, #2
	bl	sigprocmask
	ldr	r3, [fp, #-1936]
	cmp	r3, #0
	bne	.L21
	ldr	r0, [fp, #-1932]
	bl	waitfg
	b	.L25
.L21:
	ldr	r0, [fp, #-1932]
	bl	pid2jid
	mov	r1, r0
	ldr	r3, [fp, #-1944]
	ldr	r2, [fp, #-1932]
	ldr	r0, .L26+20
	bl	printf
	b	.L25
.L24:
	nop
	b	.L12
.L25:
	nop
.L12:
	ldr	r3, .L26
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L23
	bl	__stack_chk_fail
.L23:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L27:
	.align	2
.L26:
	.word	.LC5
	.word	.LC2
	.word	environ
	.word	.LC3
	.word	jobs
	.word	.LC4
	.size	eval, .-eval
	.align	2
	.global	parseline
	.syntax unified
	.arm
	.fpu softvfp
	.type	parseline, %function
parseline:
	@ 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]
	str	r1, [fp, #-28]
	ldr	r3, .L43
	str	r3, [fp, #-20]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-20]
	bl	strcpy
	ldr	r0, [fp, #-20]
	bl	strlen
	mov	r3, r0
	sub	r3, r3, #1
	ldr	r2, [fp, #-20]
	add	r3, r2, r3
	mov	r2, #32
	strb	r2, [r3]
	b	.L29
.L31:
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L29:
	ldr	r3, [fp, #-20]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L30
	ldr	r3, [fp, #-20]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	beq	.L31
.L30:
	mov	r3, #0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-20]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #39
	bne	.L32
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
	mov	r1, #39
	ldr	r0, [fp, #-20]
	bl	strchr
	str	r0, [fp, #-16]
	b	.L34
.L32:
	mov	r1, #32
	ldr	r0, [fp, #-20]
	bl	strchr
	str	r0, [fp, #-16]
	b	.L34
.L39:
	ldr	r3, [fp, #-12]
	add	r2, r3, #1
	str	r2, [fp, #-12]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldr	r2, [fp, #-20]
	str	r2, [r3]
	ldr	r3, [fp, #-16]
	mov	r2, #0
	strb	r2, [r3]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-20]
	b	.L35
.L37:
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L35:
	ldr	r3, [fp, #-20]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L36
	ldr	r3, [fp, #-20]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #32
	beq	.L37
.L36:
	ldr	r3, [fp, #-20]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #39
	bne	.L38
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
	mov	r1, #39
	ldr	r0, [fp, #-20]
	bl	strchr
	str	r0, [fp, #-16]
	b	.L34
.L38:
	mov	r1, #32
	ldr	r0, [fp, #-20]
	bl	strchr
	str	r0, [fp, #-16]
.L34:
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L39
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	mov	r2, #0
	str	r2, [r3]
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	bne	.L40
	mov	r3, #1
	b	.L41
.L40:
	ldr	r3, [fp, #-12]
	sub	r3, r3, #-1073741823
	lsl	r3, r3, #2
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldr	r3, [r3]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #38
	moveq	r3, #1
	movne	r3, #0
	and	r3, r3, #255
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L42
	ldr	r3, [fp, #-12]
	sub	r3, r3, #1
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	mov	r2, #0
	str	r2, [r3]
.L42:
	ldr	r3, [fp, #-8]
.L41:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L44:
	.align	2
.L43:
	.word	array.6468
	.size	parseline, .-parseline
	.section	.rodata
	.align	2
.LC6:
	.ascii	"quit\000"
	.align	2
.LC7:
	.ascii	"bg\000"
	.align	2
.LC8:
	.ascii	"fg\000"
	.align	2
.LC9:
	.ascii	"jobs\000"
	.text
	.align	2
	.global	builtin_cmd
	.syntax unified
	.arm
	.fpu softvfp
	.type	builtin_cmd, %function
builtin_cmd:
	@ 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]
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	ldr	r1, .L51
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L46
	mov	r0, #0
	bl	exit
.L46:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	ldr	r1, .L51+4
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	beq	.L47
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	ldr	r1, .L51+8
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L48
.L47:
	ldr	r0, [fp, #-8]
	bl	do_bgfg
	mov	r3, #1
	b	.L49
.L48:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	ldr	r1, .L51+12
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L50
	ldr	r0, .L51+16
	bl	listjobs
	mov	r3, #1
	b	.L49
.L50:
	mov	r3, #0
.L49:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L52:
	.align	2
.L51:
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.word	jobs
	.size	builtin_cmd, .-builtin_cmd
	.section	.rodata
	.align	2
.LC10:
	.ascii	"%s:argument must be a PID or %%jobid.\012\000"
	.align	2
.LC11:
	.ascii	"(%s): No such process.\012\000"
	.align	2
.LC12:
	.ascii	"[%d] (%d) %s\000"
	.align	2
.LC13:
	.ascii	"Can't handle this situation.\012\000"
	.align	2
.LC14:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	do_bgfg
	.syntax unified
	.arm
	.fpu softvfp
	.type	do_bgfg, %function
do_bgfg:
	@ args = 0, pretend = 0, frame = 288
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #288
	str	r0, [fp, #-288]
	ldr	r3, .L69
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-288]
	ldr	r3, [r3]
	str	r3, [fp, #-280]
	ldr	r3, [fp, #-288]
	ldr	r3, [r3, #4]
	str	r3, [fp, #-276]
	sub	r3, fp, #264
	mov	r0, r3
	bl	sigfillset
	ldr	r3, [fp, #-276]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #37
	bne	.L54
	ldr	r3, [fp, #-276]
	add	r3, r3, #1
	mov	r0, r3
	bl	atoi
	str	r0, [fp, #-284]
	ldr	r3, [fp, #-284]
	cmp	r3, #0
	bne	.L55
	ldr	r1, [fp, #-280]
	ldr	r0, .L69+4
	bl	printf
	b	.L53
.L54:
	ldr	r0, [fp, #-276]
	bl	atoi
	str	r0, [fp, #-272]
	ldr	r3, [fp, #-284]
	cmp	r3, #0
	bne	.L57
	ldr	r1, [fp, #-280]
	ldr	r0, .L69+4
	bl	printf
	b	.L53
.L57:
	sub	r2, fp, #136
	sub	r3, fp, #264
	mov	r1, r3
	mov	r0, #0
	bl	sigprocmask
	ldr	r0, [fp, #-272]
	bl	pid2jid
	str	r0, [fp, #-284]
.L55:
	sub	r2, fp, #136
	sub	r3, fp, #264
	mov	r1, r3
	mov	r0, #0
	bl	sigprocmask
	ldr	r1, [fp, #-284]
	ldr	r0, .L69+8
	bl	getjobjid
	str	r0, [fp, #-268]
	ldr	r3, [fp, #-268]
	cmp	r3, #0
	bne	.L58
	ldr	r1, [fp, #-276]
	ldr	r0, .L69+12
	bl	printf
	sub	r3, fp, #136
	mov	r2, #0
	mov	r1, r3
	mov	r0, #2
	bl	sigprocmask
	b	.L53
.L58:
	ldr	r1, .L69+16
	ldr	r0, [fp, #-280]
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L59
	ldr	r3, [fp, #-268]
	ldr	r3, [r3, #8]
	cmp	r3, #2
	beq	.L68
	cmp	r3, #3
	bne	.L61
	ldr	r3, [fp, #-268]
	mov	r2, #2
	str	r2, [r3, #8]
	ldr	r3, [fp, #-268]
	ldr	r3, [r3]
	rsb	r3, r3, #0
	mov	r1, #18
	mov	r0, r3
	bl	kill
	ldr	r3, [fp, #-268]
	ldr	r1, [r3, #4]
	ldr	r3, [fp, #-268]
	ldr	r2, [r3]
	ldr	r3, [fp, #-268]
	add	r3, r3, #12
	ldr	r0, .L69+20
	bl	printf
	b	.L63
.L61:
	ldr	r0, .L69+24
	bl	unix_error
	b	.L63
.L59:
	ldr	r3, [fp, #-268]
	ldr	r3, [r3, #8]
	cmp	r3, #2
	beq	.L64
	cmp	r3, #3
	bne	.L65
	ldr	r3, [fp, #-268]
	mov	r2, #1
	str	r2, [r3, #8]
	ldr	r3, [fp, #-268]
	ldr	r3, [r3]
	rsb	r3, r3, #0
	mov	r1, #18
	mov	r0, r3
	bl	kill
	ldr	r3, [fp, #-268]
	ldr	r3, [r3]
	mov	r0, r3
	bl	waitfg
	b	.L63
.L64:
	ldr	r3, [fp, #-268]
	mov	r2, #1
	str	r2, [r3, #8]
	ldr	r3, [fp, #-268]
	ldr	r3, [r3]
	mov	r0, r3
	bl	waitfg
	b	.L63
.L65:
	ldr	r0, .L69+24
	bl	unix_error
	b	.L63
.L68:
	nop
.L63:
	sub	r3, fp, #136
	mov	r2, #0
	mov	r1, r3
	mov	r0, #2
	bl	sigprocmask
	nop
.L53:
	ldr	r3, .L69
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L67
	bl	__stack_chk_fail
.L67:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L70:
	.align	2
.L69:
	.word	.LC14
	.word	.LC10
	.word	jobs
	.word	.LC11
	.word	.LC7
	.word	.LC12
	.word	.LC13
	.size	do_bgfg, .-do_bgfg
	.section	.rodata
	.align	2
.LC15:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	waitfg
	.syntax unified
	.arm
	.fpu softvfp
	.type	waitfg, %function
waitfg:
	@ args = 0, pretend = 0, frame = 144
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #144
	str	r0, [fp, #-144]
	ldr	r3, .L76
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #136
	mov	r0, r3
	bl	sigemptyset
	ldr	r3, .L76+4
	mov	r2, #0
	str	r2, [r3]
	b	.L72
.L73:
	sub	r3, fp, #136
	mov	r0, r3
	bl	sigsuspend
.L72:
	ldr	r3, .L76+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L73
	nop
	ldr	r3, .L76
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L75
	bl	__stack_chk_fail
.L75:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L77:
	.align	2
.L76:
	.word	.LC15
	.word	fg
	.size	waitfg, .-waitfg
	.section	.rodata
	.align	2
.LC16:
	.ascii	"Job [%d] (%d) terminated by a signal %d\012\000"
	.align	2
.LC17:
	.ascii	"Job [%d] (%d) terminated by signal %d\012\000"
	.align	2
.LC18:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	sigchld_handler
	.syntax unified
	.arm
	.fpu softvfp
	.type	sigchld_handler, %function
sigchld_handler:
	@ args = 0, pretend = 0, frame = 288
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #288
	str	r0, [fp, #-288]
	ldr	r3, .L86
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	str	r3, [fp, #-276]
	sub	r3, fp, #264
	mov	r0, r3
	bl	sigfillset
	b	.L79
.L84:
	sub	r2, fp, #136
	sub	r3, fp, #264
	mov	r1, r3
	mov	r0, #0
	bl	sigprocmask
	ldr	r1, [fp, #-272]
	ldr	r0, .L86+4
	bl	getjobpid
	str	r0, [fp, #-268]
	ldr	r0, .L86+4
	bl	fgpid
	mov	r2, r0
	ldr	r3, [fp, #-272]
	cmp	r3, r2
	bne	.L80
	ldr	r3, .L86+8
	mov	r2, #1
	str	r2, [r3]
.L80:
	ldr	r3, [fp, #-280]
	and	r3, r3, #255
	cmp	r3, #127
	bne	.L81
	ldr	r3, [fp, #-268]
	mov	r2, #3
	str	r2, [r3, #8]
	ldr	r3, [fp, #-268]
	ldr	r1, [r3, #4]
	ldr	r3, [fp, #-268]
	ldr	r2, [r3]
	ldr	r3, [fp, #-280]
	asr	r3, r3, #8
	and	r3, r3, #255
	ldr	r0, .L86+12
	bl	printf
	b	.L82
.L81:
	ldr	r3, [fp, #-280]
	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	.L83
	ldr	r3, [fp, #-268]
	ldr	r1, [r3, #4]
	ldr	r3, [fp, #-268]
	ldr	r2, [r3]
	ldr	r3, [fp, #-280]
	and	r3, r3, #127
	ldr	r0, .L86+16
	bl	printf
.L83:
	ldr	r1, [fp, #-272]
	ldr	r0, .L86+4
	bl	deletejob
.L82:
	sub	r3, fp, #136
	mov	r2, #0
	mov	r1, r3
	mov	r0, #2
	bl	sigprocmask
.L79:
	sub	r3, fp, #280
	mov	r2, #3
	mov	r1, r3
	mvn	r0, #0
	bl	waitpid
	str	r0, [fp, #-272]
	ldr	r3, [fp, #-272]
	cmp	r3, #0
	bgt	.L84
	bl	__errno_location
	mov	r2, r0
	ldr	r3, [fp, #-276]
	str	r3, [r2]
	nop
	ldr	r3, .L86
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L85
	bl	__stack_chk_fail
.L85:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L87:
	.align	2
.L86:
	.word	.LC18
	.word	jobs
	.word	fg
	.word	.LC16
	.word	.LC17
	.size	sigchld_handler, .-sigchld_handler
	.section	.rodata
	.align	2
.LC19:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	sigint_handler
	.syntax unified
	.arm
	.fpu softvfp
	.type	sigint_handler, %function
sigint_handler:
	@ args = 0, pretend = 0, frame = 280
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #280
	str	r0, [fp, #-280]
	ldr	r3, .L92
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	str	r3, [fp, #-272]
	sub	r3, fp, #264
	mov	r0, r3
	bl	sigfillset
	sub	r2, fp, #136
	sub	r3, fp, #264
	mov	r1, r3
	mov	r0, #0
	bl	sigprocmask
	ldr	r0, .L92+4
	bl	fgpid
	str	r0, [fp, #-268]
	sub	r3, fp, #136
	mov	r2, #0
	mov	r1, r3
	mov	r0, #2
	bl	sigprocmask
	ldr	r3, [fp, #-268]
	cmp	r3, #0
	beq	.L89
	ldr	r3, [fp, #-268]
	rsb	r3, r3, #0
	mov	r1, #2
	mov	r0, r3
	bl	kill
.L89:
	bl	__errno_location
	mov	r2, r0
	ldr	r3, [fp, #-272]
	str	r3, [r2]
	nop
	ldr	r3, .L92
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L91
	bl	__stack_chk_fail
.L91:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L93:
	.align	2
.L92:
	.word	.LC19
	.word	jobs
	.size	sigint_handler, .-sigint_handler
	.section	.rodata
	.align	2
.LC20:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	sigtstp_handler
	.syntax unified
	.arm
	.fpu softvfp
	.type	sigtstp_handler, %function
sigtstp_handler:
	@ args = 0, pretend = 0, frame = 280
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #280
	str	r0, [fp, #-280]
	ldr	r3, .L98
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	str	r3, [fp, #-272]
	sub	r3, fp, #264
	mov	r0, r3
	bl	sigfillset
	sub	r2, fp, #136
	sub	r3, fp, #264
	mov	r1, r3
	mov	r0, #0
	bl	sigprocmask
	ldr	r0, .L98+4
	bl	fgpid
	str	r0, [fp, #-268]
	sub	r3, fp, #136
	mov	r2, #0
	mov	r1, r3
	mov	r0, #2
	bl	sigprocmask
	ldr	r3, [fp, #-268]
	cmp	r3, #0
	beq	.L95
	ldr	r3, [fp, #-268]
	rsb	r3, r3, #0
	mov	r1, #20
	mov	r0, r3
	bl	kill
.L95:
	bl	__errno_location
	mov	r2, r0
	ldr	r3, [fp, #-272]
	str	r3, [r2]
	nop
	ldr	r3, .L98
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L97
	bl	__stack_chk_fail
.L97:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L99:
	.align	2
.L98:
	.word	.LC20
	.word	jobs
	.size	sigtstp_handler, .-sigtstp_handler
	.align	2
	.global	clearjob
	.syntax unified
	.arm
	.fpu softvfp
	.type	clearjob, %function
clearjob:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	str	r2, [r3]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	str	r2, [r3, #8]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	strb	r2, [r3, #12]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	clearjob, .-clearjob
	.align	2
	.global	initjobs
	.syntax unified
	.arm
	.fpu softvfp
	.type	initjobs, %function
initjobs:
	@ 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, #-8]
	b	.L102
.L103:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	mov	r0, r3
	bl	clearjob
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L102:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L103
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	initjobs, .-initjobs
	.align	2
	.global	maxjid
	.syntax unified
	.arm
	.fpu softvfp
	.type	maxjid, %function
maxjid:
	@ 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]
	mov	r3, #0
	str	r3, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L105
.L107:
	ldr	r2, [fp, #-12]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3, #4]
	ldr	r2, [fp, #-8]
	cmp	r2, r3
	bge	.L106
	ldr	r2, [fp, #-12]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3, #4]
	str	r3, [fp, #-8]
.L106:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L105:
	ldr	r3, [fp, #-12]
	cmp	r3, #15
	ble	.L107
	ldr	r3, [fp, #-8]
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	maxjid, .-maxjid
	.section	.rodata
	.align	2
.LC21:
	.ascii	"Added job [%d] %d %s\012\000"
	.align	2
.LC22:
	.ascii	"Tried to create too many jobs\000"
	.text
	.align	2
	.global	addjob
	.syntax unified
	.arm
	.fpu softvfp
	.type	addjob, %function
addjob:
	@ 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, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	str	r3, [fp, #-28]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bgt	.L110
	mov	r3, #0
	b	.L111
.L110:
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L112
.L116:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L113
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r2, [fp, #-20]
	str	r2, [r3]
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r2, [fp, #-24]
	str	r2, [r3, #8]
	ldr	r3, .L117
	ldr	r1, [r3]
	add	r3, r1, #1
	ldr	r2, .L117
	str	r3, [r2]
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	str	r1, [r3, #4]
	ldr	r3, .L117
	ldr	r3, [r3]
	cmp	r3, #16
	ble	.L114
	ldr	r3, .L117
	mov	r2, #1
	str	r2, [r3]
.L114:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	add	r3, r3, #12
	ldr	r1, [fp, #-28]
	mov	r0, r3
	bl	strcpy
	ldr	r3, .L117+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L115
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r1, [r3, #4]
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r0, [r3]
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	add	r3, r3, #12
	mov	r2, r0
	ldr	r0, .L117+8
	bl	printf
.L115:
	mov	r3, #1
	b	.L111
.L113:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L112:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L116
	ldr	r0, .L117+12
	bl	puts
	mov	r3, #0
.L111:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L118:
	.align	2
.L117:
	.word	nextjid
	.word	verbose
	.word	.LC21
	.word	.LC22
	.size	addjob, .-addjob
	.align	2
	.global	deletejob
	.syntax unified
	.arm
	.fpu softvfp
	.type	deletejob, %function
deletejob:
	@ 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]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bgt	.L120
	mov	r3, #0
	b	.L121
.L120:
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L122
.L124:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3]
	ldr	r2, [fp, #-20]
	cmp	r2, r3
	bne	.L123
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	mov	r0, r3
	bl	clearjob
	ldr	r0, [fp, #-16]
	bl	maxjid
	mov	r3, r0
	add	r3, r3, #1
	ldr	r2, .L125
	str	r3, [r2]
	mov	r3, #1
	b	.L121
.L123:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L122:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L124
	mov	r3, #0
.L121:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L126:
	.align	2
.L125:
	.word	nextjid
	.size	deletejob, .-deletejob
	.align	2
	.global	fgpid
	.syntax unified
	.arm
	.fpu softvfp
	.type	fgpid, %function
fgpid:
	@ 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]
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L128
.L131:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3, #8]
	cmp	r3, #1
	bne	.L129
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3]
	b	.L130
.L129:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L128:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L131
	mov	r3, #0
.L130:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	fgpid, .-fgpid
	.align	2
	.global	getjobpid
	.syntax unified
	.arm
	.fpu softvfp
	.type	getjobpid, %function
getjobpid:
	@ 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]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bgt	.L133
	mov	r3, #0
	b	.L134
.L133:
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L135
.L137:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3]
	ldr	r2, [fp, #-20]
	cmp	r2, r3
	bne	.L136
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	b	.L134
.L136:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L135:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L137
	mov	r3, #0
.L134:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	getjobpid, .-getjobpid
	.align	2
	.global	getjobjid
	.syntax unified
	.arm
	.fpu softvfp
	.type	getjobjid, %function
getjobjid:
	@ 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]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bgt	.L139
	mov	r3, #0
	b	.L140
.L139:
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L141
.L143:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3, #4]
	ldr	r2, [fp, #-20]
	cmp	r2, r3
	bne	.L142
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	b	.L140
.L142:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L141:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L143
	mov	r3, #0
.L140:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	getjobjid, .-getjobjid
	.align	2
	.global	pid2jid
	.syntax unified
	.arm
	.fpu softvfp
	.type	pid2jid, %function
pid2jid:
	@ 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]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bgt	.L145
	mov	r3, #0
	b	.L146
.L145:
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L147
.L149:
	ldr	r1, .L150
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	ldr	r3, [r3]
	ldr	r2, [fp, #-16]
	cmp	r2, r3
	bne	.L148
	ldr	r1, .L150
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, r3, #4
	ldr	r3, [r3]
	b	.L146
.L148:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L147:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L149
	mov	r3, #0
.L146:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L151:
	.align	2
.L150:
	.word	jobs
	.size	pid2jid, .-pid2jid
	.section	.rodata
	.align	2
.LC23:
	.ascii	"[%d] (%d) \000"
	.align	2
.LC24:
	.ascii	"Running \000"
	.align	2
.LC25:
	.ascii	"Foreground \000"
	.align	2
.LC26:
	.ascii	"Stopped \000"
	.align	2
.LC27:
	.ascii	"listjobs: Internal error: job[%d].state=%d \000"
	.align	2
.LC28:
	.ascii	"%s\000"
	.text
	.align	2
	.global	listjobs
	.syntax unified
	.arm
	.fpu softvfp
	.type	listjobs, %function
listjobs:
	@ 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, #-8]
	b	.L153
.L159:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L154
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r1, [r3, #4]
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r0, .L160
	bl	printf
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3, #8]
	cmp	r3, #3
	beq	.L155
	cmp	r3, #3
	bgt	.L156
	cmp	r3, #1
	beq	.L157
	cmp	r3, #2
	bne	.L156
	ldr	r0, .L160+4
	bl	printf
	b	.L158
.L157:
	ldr	r0, .L160+8
	bl	printf
	b	.L158
.L155:
	ldr	r0, .L160+12
	bl	printf
	b	.L158
.L156:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r3, [r3, #8]
	mov	r2, r3
	ldr	r1, [fp, #-8]
	ldr	r0, .L160+16
	bl	printf
.L158:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #7
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	add	r3, r3, #12
	mov	r1, r3
	ldr	r0, .L160+20
	bl	printf
.L154:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L153:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L159
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L161:
	.align	2
.L160:
	.word	.LC23
	.word	.LC24
	.word	.LC25
	.word	.LC26
	.word	.LC27
	.word	.LC28
	.size	listjobs, .-listjobs
	.section	.rodata
	.align	2
.LC29:
	.ascii	"Usage: shell [-hvp]\000"
	.align	2
.LC30:
	.ascii	"   -h   print this message\000"
	.align	2
.LC31:
	.ascii	"   -v   print additional diagnostic information\000"
	.align	2
.LC32:
	.ascii	"   -p   do not emit a command prompt\000"
	.text
	.align	2
	.global	usage
	.syntax unified
	.arm
	.fpu softvfp
	.type	usage, %function
usage:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L163
	bl	puts
	ldr	r0, .L163+4
	bl	puts
	ldr	r0, .L163+8
	bl	puts
	ldr	r0, .L163+12
	bl	puts
	mov	r0, #1
	bl	exit
.L164:
	.align	2
.L163:
	.word	.LC29
	.word	.LC30
	.word	.LC31
	.word	.LC32
	.size	usage, .-usage
	.section	.rodata
	.align	2
.LC33:
	.ascii	"%s: %s\012\000"
	.text
	.align	2
	.global	unix_error
	.syntax unified
	.arm
	.fpu softvfp
	.type	unix_error, %function
unix_error:
	@ 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
	str	r0, [fp, #-16]
	ldr	r3, .L166
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r3, r0
	ldr	r2, [fp, #-16]
	ldr	r1, .L166+4
	mov	r0, r4
	bl	fprintf
	mov	r0, #1
	bl	exit
.L167:
	.align	2
.L166:
	.word	stdout
	.word	.LC33
	.size	unix_error, .-unix_error
	.section	.rodata
	.align	2
.LC34:
	.ascii	"%s\012\000"
	.text
	.align	2
	.global	app_error
	.syntax unified
	.arm
	.fpu softvfp
	.type	app_error, %function
app_error:
	@ 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]
	ldr	r3, .L169
	ldr	r3, [r3]
	ldr	r2, [fp, #-8]
	ldr	r1, .L169+4
	mov	r0, r3
	bl	fprintf
	mov	r0, #1
	bl	exit
.L170:
	.align	2
.L169:
	.word	stdout
	.word	.LC34
	.size	app_error, .-app_error
	.section	.rodata
	.align	2
.LC35:
	.ascii	"Signal error\000"
	.align	2
.LC36:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	Signal
	.syntax unified
	.arm
	.fpu softvfp
	.type	Signal, %function
Signal:
	@ args = 0, pretend = 0, frame = 296
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #296
	str	r0, [fp, #-296]
	str	r1, [fp, #-300]
	ldr	r3, .L175
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-300]
	str	r3, [fp, #-288]
	sub	r3, fp, #288
	add	r3, r3, #4
	mov	r0, r3
	bl	sigemptyset
	mov	r3, #268435456
	str	r3, [fp, #-156]
	sub	r2, fp, #148
	sub	r3, fp, #288
	mov	r1, r3
	ldr	r0, [fp, #-296]
	bl	sigaction
	mov	r3, r0
	cmp	r3, #0
	bge	.L172
	ldr	r0, .L175+4
	bl	unix_error
.L172:
	ldr	r3, [fp, #-148]
	ldr	r2, .L175
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L174
	bl	__stack_chk_fail
.L174:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L176:
	.align	2
.L175:
	.word	.LC36
	.word	.LC35
	.size	Signal, .-Signal
	.section	.rodata
	.align	2
.LC37:
	.ascii	"Terminating after receipt of SIGQUIT signal\000"
	.text
	.align	2
	.global	sigquit_handler
	.syntax unified
	.arm
	.fpu softvfp
	.type	sigquit_handler, %function
sigquit_handler:
	@ 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]
	ldr	r0, .L178
	bl	puts
	mov	r0, #1
	bl	exit
.L179:
	.align	2
.L178:
	.word	.LC37
	.size	sigquit_handler, .-sigquit_handler
	.local	array.6468
	.comm	array.6468,1024,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
