	.file	"802440.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"sig = %d\n"
.LC1:
	.string	"l got a signal"
	.text
	.globl	handler
	.type	handler, @function
handler:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rdi, .LC1[rip]
	call	puts@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	handler, .-handler
	.section	.rodata
.LC2:
	.string	"fork fail\n"
.LC3:
	.string	"parent process is working"
.LC4:
	.string	"waitpid normal return "
.LC5:
	.string	"parent exit"
.LC6:
	.string	"pause fail\n"
.LC7:
	.string	"chlid process is killed"
.LC8:
	.string	"chile exit"
	.text
	.globl	main
	.type	main, @function
main:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	call	fork@PLT
	mov	DWORD PTR -20[rbp], eax
	cmp	DWORD PTR -20[rbp], -1
	jne	.L3
	lea	rdi, .LC2[rip]
	call	perror@PLT
	mov	eax, -1
	jmp	.L9
.L3:
	cmp	DWORD PTR -20[rbp], 0
	jle	.L5
	lea	rdi, .LC3[rip]
	call	puts@PLT
	mov	edi, 8
	call	sleep@PLT
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, 18
	mov	edi, eax
	call	kill@PLT
	lea	rcx, -24[rbp]
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, 2
	mov	rsi, rcx
	mov	edi, eax
	call	waitpid@PLT
	mov	DWORD PTR -12[rbp], eax
	mov	eax, DWORD PTR -12[rbp]
	cmp	eax, DWORD PTR -20[rbp]
	jne	.L6
	lea	rdi, .LC4[rip]
	call	puts@PLT
.L6:
	lea	rdi, .LC5[rip]
	call	puts@PLT
	mov	edi, 0
	call	exit@PLT
.L5:
	cmp	DWORD PTR -20[rbp], 0
	jne	.L7
	lea	rsi, handler[rip]
	mov	edi, 18
	call	signal@PLT
	call	pause@PLT
	mov	DWORD PTR -16[rbp], eax
	cmp	DWORD PTR -16[rbp], -1
	jne	.L8
	lea	rdi, .LC6[rip]
	call	perror@PLT
	mov	eax, -1
	jmp	.L9
.L8:
	lea	rdi, .LC7[rip]
	call	puts@PLT
	lea	rdi, .LC8[rip]
	call	puts@PLT
	mov	edi, 0
	call	exit@PLT
.L7:
	mov	eax, 0
.L9:
	mov	rdx, QWORD PTR -8[rbp]
	sub	rdx, QWORD PTR fs:40
	je	.L10
	call	__stack_chk_fail@PLT
.L10:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"802440.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"sig = %d\012\000"
	.align	2
.LC1:
	.ascii	"l got a signal\000"
	.text
	.align	2
	.global	handler
	.syntax unified
	.arm
	.fpu softvfp
	.type	handler, %function
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	r1, [fp, #-8]
	ldr	r0, .L2
	bl	printf
	ldr	r0, .L2+4
	bl	puts
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L3:
	.align	2
.L2:
	.word	.LC0
	.word	.LC1
	.size	handler, .-handler
	.section	.rodata
	.align	2
.LC2:
	.ascii	"fork fail\012\000"
	.align	2
.LC3:
	.ascii	"parent process is working\000"
	.align	2
.LC4:
	.ascii	"waitpid normal return \000"
	.align	2
.LC5:
	.ascii	"parent exit\000"
	.align	2
.LC6:
	.ascii	"pause fail\012\000"
	.align	2
.LC7:
	.ascii	"chlid process is killed\000"
	.align	2
.LC8:
	.ascii	"chile exit\000"
	.align	2
.LC9:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	ldr	r3, .L13
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmn	r3, #1
	bne	.L5
	ldr	r0, .L13+4
	bl	perror
	mvn	r3, #0
	b	.L11
.L5:
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	ble	.L7
	ldr	r0, .L13+8
	bl	puts
	mov	r0, #8
	bl	sleep
	mov	r1, #18
	ldr	r0, [fp, #-20]
	bl	kill
	sub	r3, fp, #24
	mov	r2, #2
	mov	r1, r3
	ldr	r0, [fp, #-20]
	bl	waitpid
	str	r0, [fp, #-12]
	ldr	r2, [fp, #-12]
	ldr	r3, [fp, #-20]
	cmp	r2, r3
	bne	.L8
	ldr	r0, .L13+12
	bl	puts
.L8:
	ldr	r0, .L13+16
	bl	puts
	mov	r0, #0
	bl	exit
.L7:
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bne	.L9
	ldr	r1, .L13+20
	mov	r0, #18
	bl	signal
	bl	pause
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmn	r3, #1
	bne	.L10
	ldr	r0, .L13+24
	bl	perror
	mvn	r3, #0
	b	.L11
.L10:
	ldr	r0, .L13+28
	bl	puts
	ldr	r0, .L13+32
	bl	puts
	mov	r0, #0
	bl	exit
.L9:
	mov	r3, #0
.L11:
	ldr	r2, .L13
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L12
	bl	__stack_chk_fail
.L12:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L14:
	.align	2
.L13:
	.word	.LC9
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	handler
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
