	.file	"1194827.c"
	.intel_syntax noprefix
	.text
	.local	uctx_main
	.comm	uctx_main,968,32
	.local	uctx_func1
	.comm	uctx_func1,968,32
	.local	uctx_func2
	.comm	uctx_func2,968,32
	.section	.rodata
.LC0:
	.string	"func1: started"
.LC1:
	.string	"swapcontext"
.LC2:
	.string	"func1: returning"
	.text
	.type	func1, @function
func1:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC0[rip]
	call	puts@PLT
	lea	rsi, uctx_func2[rip]
	lea	rdi, uctx_func1[rip]
	call	swapcontext@PLT
	endbr64
	cmp	eax, -1
	jne	.L2
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	lea	rdi, .LC2[rip]
	call	puts@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	func1, .-func1
	.section	.rodata
.LC3:
	.string	"func2: started"
.LC4:
	.string	"func2: returning"
	.text
	.type	func2, @function
func2:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC3[rip]
	call	puts@PLT
	lea	rsi, uctx_func1[rip]
	lea	rdi, uctx_func2[rip]
	call	swapcontext@PLT
	endbr64
	cmp	eax, -1
	jne	.L4
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L4:
	lea	rdi, .LC4[rip]
	call	puts@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	func2, .-func2
	.section	.rodata
.LC5:
	.string	"getcontext"
.LC6:
	.string	"main: exiting"
	.text
	.globl	main
	.type	main, @function
main:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	r11, -32768[rsp]
.LPSRL0:
	sub	rsp, 4096
	or	DWORD PTR [rsp], 0
	cmp	rsp, r11
	jne	.LPSRL0
	sub	rsp, 32
	mov	DWORD PTR -32788[rbp], edi
	mov	QWORD PTR -32800[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rdi, uctx_func1[rip]
	call	getcontext@PLT
	endbr64
	cmp	eax, -1
	jne	.L7
	lea	rdi, .LC5[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L7:
	lea	rax, -32784[rbp]
	mov	QWORD PTR uctx_func1[rip+16], rax
	mov	QWORD PTR uctx_func1[rip+32], 16384
	lea	rax, uctx_main[rip]
	mov	QWORD PTR uctx_func1[rip+8], rax
	mov	edx, 0
	lea	rsi, func1[rip]
	lea	rdi, uctx_func1[rip]
	mov	eax, 0
	call	makecontext@PLT
	lea	rdi, uctx_func2[rip]
	call	getcontext@PLT
	endbr64
	cmp	eax, -1
	jne	.L8
	lea	rdi, .LC5[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L8:
	lea	rax, -16400[rbp]
	mov	QWORD PTR uctx_func2[rip+16], rax
	mov	QWORD PTR uctx_func2[rip+32], 16384
	cmp	DWORD PTR -32788[rbp], 1
	jg	.L9
	lea	rax, uctx_func1[rip]
	jmp	.L10
.L9:
	mov	eax, 0
.L10:
	mov	QWORD PTR uctx_func2[rip+8], rax
	mov	edx, 0
	lea	rsi, func2[rip]
	lea	rdi, uctx_func2[rip]
	mov	eax, 0
	call	makecontext@PLT
	lea	rsi, uctx_func2[rip]
	lea	rdi, uctx_main[rip]
	call	swapcontext@PLT
	endbr64
	cmp	eax, -1
	jne	.L11
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L11:
	lea	rdi, .LC6[rip]
	call	puts@PLT
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"1194827.c"
	.text
	.local	uctx_main
	.comm	uctx_main,744,8
	.local	uctx_func1
	.comm	uctx_func1,744,8
	.local	uctx_func2
	.comm	uctx_func2,744,8
	.section	.rodata
	.align	2
.LC0:
	.ascii	"func1: started\000"
	.align	2
.LC1:
	.ascii	"swapcontext\000"
	.align	2
.LC2:
	.ascii	"func1: returning\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	func1, %function
func1:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L3
	bl	puts
	ldr	r1, .L3+4
	ldr	r0, .L3+8
	bl	swapcontext
	mov	r3, r0
	cmn	r3, #1
	bne	.L2
	ldr	r0, .L3+12
	bl	perror
	mov	r0, #1
	bl	exit
.L2:
	ldr	r0, .L3+16
	bl	puts
	nop
	pop	{fp, pc}
.L4:
	.align	2
.L3:
	.word	.LC0
	.word	uctx_func2
	.word	uctx_func1
	.word	.LC1
	.word	.LC2
	.size	func1, .-func1
	.section	.rodata
	.align	2
.LC3:
	.ascii	"func2: started\000"
	.align	2
.LC4:
	.ascii	"func2: returning\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	func2, %function
func2:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L7
	bl	puts
	ldr	r1, .L7+4
	ldr	r0, .L7+8
	bl	swapcontext
	mov	r3, r0
	cmn	r3, #1
	bne	.L6
	ldr	r0, .L7+12
	bl	perror
	mov	r0, #1
	bl	exit
.L6:
	ldr	r0, .L7+16
	bl	puts
	nop
	pop	{fp, pc}
.L8:
	.align	2
.L7:
	.word	.LC3
	.word	uctx_func1
	.word	uctx_func2
	.word	.LC1
	.word	.LC4
	.size	func2, .-func2
	.section	.rodata
	.align	2
.LC5:
	.ascii	"getcontext\000"
	.align	2
.LC6:
	.ascii	"main: exiting\000"
	.align	2
.LC7:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 32784
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32768
	sub	sp, sp, #16
	sub	r3, fp, #32768
	sub	r3, r3, #4
	str	r0, [r3, #-12]
	sub	r3, fp, #32768
	sub	r3, r3, #4
	str	r1, [r3, #-16]
	ldr	r3, .L18
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r0, .L18+4
	bl	getcontext
	mov	r3, r0
	cmn	r3, #1
	bne	.L11
	ldr	r0, .L18+8
	bl	perror
	mov	r0, #1
	bl	exit
.L11:
	ldr	r2, .L18+4
	sub	r3, fp, #32768
	sub	r3, r3, #4
	sub	r3, r3, #4
	str	r3, [r2, #8]
	ldr	r3, .L18+4
	mov	r2, #16384
	str	r2, [r3, #16]
	ldr	r3, .L18+4
	ldr	r2, .L18+12
	str	r2, [r3, #4]
	mov	r2, #0
	ldr	r1, .L18+16
	ldr	r0, .L18+4
	bl	makecontext
	ldr	r0, .L18+20
	bl	getcontext
	mov	r3, r0
	cmn	r3, #1
	bne	.L12
	ldr	r0, .L18+8
	bl	perror
	mov	r0, #1
	bl	exit
.L12:
	ldr	r2, .L18+20
	sub	r3, fp, #16384
	sub	r3, r3, #4
	sub	r3, r3, #4
	str	r3, [r2, #8]
	ldr	r3, .L18+20
	mov	r2, #16384
	str	r2, [r3, #16]
	sub	r3, fp, #32768
	sub	r3, r3, #4
	ldr	r3, [r3, #-12]
	cmp	r3, #1
	bgt	.L13
	ldr	r3, .L18+4
	b	.L14
.L13:
	mov	r3, #0
.L14:
	ldr	r2, .L18+20
	str	r3, [r2, #4]
	mov	r2, #0
	ldr	r1, .L18+24
	ldr	r0, .L18+20
	bl	makecontext
	ldr	r1, .L18+20
	ldr	r0, .L18+12
	bl	swapcontext
	mov	r3, r0
	cmn	r3, #1
	bne	.L15
	ldr	r0, .L18+28
	bl	perror
	mov	r0, #1
	bl	exit
.L15:
	ldr	r0, .L18+32
	bl	puts
	mov	r3, #0
	ldr	r2, .L18
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L17
	bl	__stack_chk_fail
.L17:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L19:
	.align	2
.L18:
	.word	.LC7
	.word	uctx_func1
	.word	.LC5
	.word	uctx_main
	.word	func1
	.word	uctx_func2
	.word	func2
	.word	.LC1
	.word	.LC6
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
