	.file	"72013892.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
	.align 8
.LC0:
	.string	"Child process start, pid: %d, ppid: %d.\n"
.LC1:
	.string	"Hello from child process."
.LC2:
	.string	"Child process end."
	.text
	.globl	childproc_function
	.type	childproc_function, @function
childproc_function:
.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
	call	getppid@PLT
	mov	ebx, eax
	call	getpid@PLT
	mov	edx, ebx
	mov	esi, eax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -20[rbp], 0
	jmp	.L2
.L3:
	lea	rdi, .LC1[rip]
	call	puts@PLT
	mov	edi, 1
	call	sleep@PLT
	add	DWORD PTR -20[rbp], 1
.L2:
	cmp	DWORD PTR -20[rbp], 4
	jle	.L3
	lea	rdi, .LC2[rip]
	call	puts@PLT
	mov	eax, 0
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	childproc_function, .-childproc_function
	.section	.rodata
	.align 8
.LC3:
	.string	"Parent process start, pid: %d, child pid: %d.\n"
.LC4:
	.string	"This parent process."
.LC5:
	.string	"Parent process end."
	.text
	.globl	process_function
	.type	process_function, @function
process_function:
.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	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -4[rbp], 0
	call	getpid@PLT
	mov	ecx, eax
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, eax
	mov	esi, ecx
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -4[rbp], 0
	jmp	.L6
.L7:
	lea	rdi, .LC4[rip]
	call	puts@PLT
	mov	edi, 1
	call	sleep@PLT
	add	DWORD PTR -4[rbp], 1
.L6:
	cmp	DWORD PTR -4[rbp], 4
	jle	.L7
	lea	rdi, .LC5[rip]
	call	puts@PLT
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	process_function, .-process_function
	.globl	main
	.type	main, @function
main:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	call	vfork@PLT
	endbr64
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	je	.L10
	cmp	DWORD PTR -4[rbp], 0
	je	.L11
	jmp	.L13
.L10:
	mov	edi, 0
	call	exit@PLT
.L11:
	call	childproc_function
	mov	edi, 0
	call	exit@PLT
.L13:
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	process_function
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE8:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"72013892.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Child process start, pid: %d, ppid: %d.\012\000"
	.align	2
.LC1:
	.ascii	"Hello from child process.\000"
	.align	2
.LC2:
	.ascii	"Child process end.\000"
	.text
	.align	2
	.global	childproc_function
	.syntax unified
	.arm
	.fpu softvfp
	.type	childproc_function, %function
childproc_function:
	@ 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]
	bl	getpid
	mov	r4, r0
	bl	getppid
	mov	r3, r0
	mov	r2, r3
	mov	r1, r4
	ldr	r0, .L5
	bl	printf
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L2
.L3:
	ldr	r0, .L5+4
	bl	puts
	mov	r0, #1
	bl	sleep
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L2:
	ldr	r3, [fp, #-16]
	cmp	r3, #4
	ble	.L3
	ldr	r0, .L5+8
	bl	puts
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L6:
	.align	2
.L5:
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.size	childproc_function, .-childproc_function
	.section	.rodata
	.align	2
.LC3:
	.ascii	"Parent process start, pid: %d, child pid: %d.\012\000"
	.align	2
.LC4:
	.ascii	"This parent process.\000"
	.align	2
.LC5:
	.ascii	"Parent process end.\000"
	.text
	.align	2
	.global	process_function
	.syntax unified
	.arm
	.fpu softvfp
	.type	process_function, %function
process_function:
	@ 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]
	bl	getpid
	mov	r3, r0
	ldr	r2, [fp, #-16]
	mov	r1, r3
	ldr	r0, .L11
	bl	printf
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L8
.L9:
	ldr	r0, .L11+4
	bl	puts
	mov	r0, #1
	bl	sleep
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L8:
	ldr	r3, [fp, #-8]
	cmp	r3, #4
	ble	.L9
	ldr	r0, .L11+8
	bl	puts
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L12:
	.align	2
.L11:
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.size	process_function, .-process_function
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	bl	vfork
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	beq	.L14
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L15
	b	.L17
.L14:
	mov	r0, #0
	bl	exit
.L15:
	bl	childproc_function
	mov	r0, #0
	bl	exit
.L17:
	ldr	r0, [fp, #-8]
	bl	process_function
	mov	r0, #0
	bl	exit
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
