	.file	"extr_enginetest.c_test_redirect.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"EVP_PKEY_encrypt test: no redirection"
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC1:
	.string	"Test redirect engine"
	.section	.rodata.str1.8
	.align 8
.LC2:
	.string	"EVP_PKEY_encrypt test: redirection via EVP_PKEY_CTX_new()"
	.align 8
.LC3:
	.string	"EVP_PKEY_encrypt test: redirection via EVP_PKEY_set1_engine()"
	.text
	.p2align 4
	.type	test_redirect, @function
test_redirect:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 56
	.cfi_def_cfa_offset 112
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 40[rsp], rax
	xor	eax, eax
	mov	DWORD PTR 35[rsp], 174353522
	movabs	rax, 8022916924116329800
	mov	QWORD PTR 27[rsp], rax
	xor	eax, eax
	mov	BYTE PTR 39[rsp], 0
	call	get_test_pkey@PLT
	mov	rdi, rax
	mov	rbp, rax
	call	TEST_ptr@PLT
	test	eax, eax
	jne	.L72
	mov	r12d, eax
	xor	r14d, r14d
	xor	r15d, r15d
	xor	r13d, r13d
.L2:
	mov	rdi, r15
	call	EVP_PKEY_CTX_free@PLT
	mov	rdi, rbp
	call	EVP_PKEY_free@PLT
	mov	rdi, r14
	call	ENGINE_free@PLT
	mov	rdi, r13
	call	OPENSSL_free@PLT
	mov	rax, QWORD PTR 40[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L73
	add	rsp, 56
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L72:
	.cfi_restore_state
	mov	rdi, rbp
	call	EVP_PKEY_size@PLT
	mov	rdi, rax
	mov	QWORD PTR 16[rsp], rax
	call	OPENSSL_malloc@PLT
	mov	rdi, rax
	mov	r13, rax
	call	TEST_ptr@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L5
	xor	esi, esi
	mov	rdi, rbp
	xor	r14d, r14d
	call	EVP_PKEY_CTX_new@PLT
	mov	rdi, rax
	mov	r15, rax
	call	TEST_ptr@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	lea	rdi, .LC0[rip]
	call	TEST_info@PLT
	mov	rdi, r15
	call	EVP_PKEY_encrypt_init@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_gt@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	lea	rax, 27[rsp]
	lea	rbx, 16[rsp]
	mov	rsi, r13
	mov	rdi, r15
	mov	r8d, 13
	mov	rcx, rax
	mov	rdx, rbx
	mov	QWORD PTR 8[rsp], rax
	call	EVP_PKEY_encrypt@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_gt@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, QWORD PTR called_encrypt[rip]
	call	TEST_false@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, r15
	xor	r15d, r15d
	call	EVP_PKEY_CTX_free@PLT
	xor	eax, eax
	call	ENGINE_new@PLT
	mov	rdi, rax
	mov	r14, rax
	call	TEST_ptr@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	lea	rsi, .LC1[rip]
	mov	rdi, r14
	call	ENGINE_set_id@PLT
	mov	rdi, rax
	call	TEST_true@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	lea	rsi, .LC1[rip]
	mov	rdi, r14
	call	ENGINE_set_name@PLT
	mov	rdi, rax
	call	TEST_true@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rsi, r14
	mov	rdi, rbp
	call	EVP_PKEY_CTX_new@PLT
	mov	rdi, rax
	mov	r15, rax
	call	TEST_ptr_null@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rsi, r14
	mov	rdi, rbp
	call	EVP_PKEY_set1_engine@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_le@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	edi, DWORD PTR EVP_PKEY_RSA[rip]
	xor	esi, esi
	call	EVP_PKEY_meth_new@PLT
	mov	rdi, rax
	mov	QWORD PTR test_rsa[rip], rax
	call	TEST_ptr@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	esi, DWORD PTR test_pkey_meths[rip]
	mov	rdi, r14
	call	ENGINE_set_pkey_meths@PLT
	mov	rsi, r14
	mov	rdi, rbp
	call	EVP_PKEY_CTX_new@PLT
	mov	rdi, rax
	mov	r15, rax
	call	TEST_ptr@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, r15
	call	EVP_PKEY_encrypt_init@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_le@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, r15
	call	EVP_PKEY_CTX_free@PLT
	mov	edx, DWORD PTR test_encrypt[rip]
	mov	rdi, QWORD PTR test_rsa[rip]
	xor	esi, esi
	call	EVP_PKEY_meth_set_encrypt@PLT
	lea	rdi, .LC2[rip]
	call	TEST_info@PLT
	mov	rsi, r14
	mov	rdi, rbp
	call	EVP_PKEY_CTX_new@PLT
	mov	rdi, rax
	mov	r15, rax
	call	TEST_ptr@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, r15
	call	EVP_PKEY_encrypt_init@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_gt@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rcx, QWORD PTR 8[rsp]
	mov	rdx, rbx
	mov	rsi, r13
	mov	rdi, r15
	mov	r8d, 13
	call	EVP_PKEY_encrypt@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_gt@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, QWORD PTR called_encrypt[rip]
	call	TEST_true@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, r15
	call	EVP_PKEY_CTX_free@PLT
	xor	esi, esi
	mov	rdi, rbp
	mov	QWORD PTR called_encrypt[rip], 0
	call	EVP_PKEY_CTX_new@PLT
	mov	rdi, rax
	mov	r15, rax
	call	TEST_ptr@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, r15
	call	EVP_PKEY_encrypt_init@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_gt@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rcx, QWORD PTR 8[rsp]
	mov	rdx, rbx
	mov	rsi, r13
	mov	rdi, r15
	mov	r8d, 13
	call	EVP_PKEY_encrypt@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_gt@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, QWORD PTR called_encrypt[rip]
	call	TEST_false@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, r15
	xor	r15d, r15d
	call	EVP_PKEY_CTX_free@PLT
	mov	rsi, r14
	mov	rdi, rbp
	call	EVP_PKEY_set1_engine@PLT
	mov	rdi, rax
	call	TEST_true@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	lea	rdi, .LC3[rip]
	call	TEST_info@PLT
	xor	esi, esi
	mov	rdi, rbp
	call	EVP_PKEY_CTX_new@PLT
	mov	rdi, rax
	mov	r15, rax
	call	TEST_ptr@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, r15
	call	EVP_PKEY_encrypt_init@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_gt@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rcx, QWORD PTR 8[rsp]
	mov	rdx, rbx
	mov	rsi, r13
	mov	rdi, r15
	mov	r8d, 13
	call	EVP_PKEY_encrypt@PLT
	xor	esi, esi
	mov	rdi, rax
	call	TEST_int_gt@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L2
	mov	rdi, QWORD PTR called_encrypt[rip]
	xor	r12d, r12d
	call	TEST_true@PLT
	test	eax, eax
	setne	r12b
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L5:
	xor	r14d, r14d
	xor	r15d, r15d
	jmp	.L2
.L73:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	test_redirect, .-test_redirect
	.comm	test_rsa,8,8
	.comm	test_pkey_meths,4,4
	.comm	test_encrypt,4,4
	.comm	called_encrypt,8,8
	.comm	EVP_PKEY_RSA,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.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, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_enginetest.c_test_redirect.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC1:
	.ascii	"EVP_PKEY_encrypt test: no redirection\000"
	.align	2
.LC2:
	.ascii	"Test redirect engine\000"
	.align	2
.LC3:
	.ascii	"EVP_PKEY_encrypt test: redirection via EVP_PKEY_CTX"
	.ascii	"_new()\000"
	.align	2
.LC4:
	.ascii	"EVP_PKEY_encrypt test: redirection via EVP_PKEY_set"
	.ascii	"1_engine()\000"
	.align	2
.LC0:
	.ascii	"Hello World\012\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC5:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	test_redirect, %function
test_redirect:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r2, .L67
	sub	sp, sp, #32
	ldr	r3, .L67+4
	add	ip, sp, #12
	ldr	r2, [r2]
	str	r2, [sp, #28]
	mov	r2,#0
	ldm	r3, {r0, r1, r2, r3}
	stmia	ip!, {r0, r1, r2}
	strb	r3, [ip]
	bl	get_test_pkey
	mov	r5, r0
	bl	TEST_ptr
	subs	r4, r0, #0
	bne	.L64
	mov	r9, r4
	mov	r7, r4
	mov	r6, r4
.L2:
	mov	r0, r7
	bl	EVP_PKEY_CTX_free
	mov	r0, r5
	bl	EVP_PKEY_free
	mov	r0, r9
	bl	ENGINE_free
	mov	r0, r6
	bl	OPENSSL_free
	ldr	r3, .L67
	ldr	r2, [r3]
	ldr	r3, [sp, #28]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L65
	mov	r0, r4
	add	sp, sp, #32
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L64:
	mov	r0, r5
	bl	EVP_PKEY_size
	str	r0, [sp, #8]
	bl	OPENSSL_malloc
	mov	r6, r0
	bl	TEST_ptr
	subs	r4, r0, #0
	moveq	r9, r4
	moveq	r7, r4
	beq	.L2
	mov	r1, #0
	mov	r0, r5
	bl	EVP_PKEY_CTX_new
	mov	r7, r0
	bl	TEST_ptr
	subs	r4, r0, #0
	bne	.L66
.L9:
	mov	r9, r4
	b	.L2
.L66:
	ldr	r0, .L67+8
	bl	TEST_info
	mov	r0, r7
	bl	EVP_PKEY_encrypt_init
	mov	r1, #0
	bl	TEST_int_gt
	subs	r4, r0, #0
	beq	.L9
	mov	r3, #13
	mov	r1, r6
	str	r3, [sp]
	add	r2, sp, #8
	add	r3, sp, #12
	mov	r0, r7
	bl	EVP_PKEY_encrypt
	mov	r1, #0
	bl	TEST_int_gt
	subs	r4, r0, #0
	beq	.L9
	ldr	r8, .L67+12
	ldr	r0, [r8]
	bl	TEST_false
	subs	r4, r0, #0
	beq	.L9
	mov	r0, r7
	bl	EVP_PKEY_CTX_free
	bl	ENGINE_new
	mov	r9, r0
	bl	TEST_ptr
	subs	r4, r0, #0
	beq	.L13
	ldr	r1, .L67+16
	mov	r0, r9
	bl	ENGINE_set_id
	bl	TEST_true
	subs	r4, r0, #0
	beq	.L13
	ldr	r1, .L67+16
	mov	r0, r9
	bl	ENGINE_set_name
	bl	TEST_true
	subs	r4, r0, #0
	beq	.L13
	mov	r1, r9
	mov	r0, r5
	bl	EVP_PKEY_CTX_new
	mov	r7, r0
	bl	TEST_ptr_null
	subs	r4, r0, #0
	beq	.L2
	mov	r1, r9
	mov	r0, r5
	bl	EVP_PKEY_set1_engine
	mov	r1, #0
	bl	TEST_int_le
	subs	r4, r0, #0
	beq	.L2
	ldr	r3, .L67+20
	mov	r1, #0
	ldr	r0, [r3]
	bl	EVP_PKEY_meth_new
	ldr	r10, .L67+24
	str	r0, [r10]
	bl	TEST_ptr
	subs	r4, r0, #0
	beq	.L2
	ldr	r3, .L67+28
	mov	r0, r9
	ldr	r1, [r3]
	bl	ENGINE_set_pkey_meths
	mov	r1, r9
	mov	r0, r5
	bl	EVP_PKEY_CTX_new
	mov	r7, r0
	bl	TEST_ptr
	subs	r4, r0, #0
	beq	.L2
	mov	r0, r7
	bl	EVP_PKEY_encrypt_init
	mov	r1, #0
	bl	TEST_int_le
	subs	r4, r0, #0
	beq	.L2
	mov	r0, r7
	bl	EVP_PKEY_CTX_free
	ldr	r3, .L67+32
	mov	r1, #0
	ldr	r2, [r3]
	ldr	r0, [r10]
	bl	EVP_PKEY_meth_set_encrypt
	ldr	r0, .L67+36
	bl	TEST_info
	mov	r1, r9
	mov	r0, r5
	bl	EVP_PKEY_CTX_new
	mov	r7, r0
	bl	TEST_ptr
	subs	r4, r0, #0
	beq	.L2
	mov	r0, r7
	bl	EVP_PKEY_encrypt_init
	mov	r1, #0
	bl	TEST_int_gt
	subs	r4, r0, #0
	beq	.L2
	mov	r2, #13
	mov	r1, r6
	add	r3, sp, #12
	str	r2, [sp]
	mov	r0, r7
	add	r2, sp, #8
	bl	EVP_PKEY_encrypt
	mov	r1, #0
	bl	TEST_int_gt
	subs	r4, r0, #0
	beq	.L2
	ldr	r0, [r8]
	bl	TEST_true
	subs	r4, r0, #0
	beq	.L2
	mov	r10, #0
	mov	r0, r7
	bl	EVP_PKEY_CTX_free
	mov	r1, r10
	mov	r0, r5
	str	r10, [r8]
	bl	EVP_PKEY_CTX_new
	mov	r7, r0
	bl	TEST_ptr
	subs	r4, r0, #0
	beq	.L2
	mov	r0, r7
	bl	EVP_PKEY_encrypt_init
	mov	r1, r10
	bl	TEST_int_gt
	subs	r4, r0, #0
	beq	.L2
	mov	r10, #13
	mov	r1, r6
	add	r3, sp, #12
	add	r2, sp, #8
	mov	r0, r7
	str	r10, [sp]
	bl	EVP_PKEY_encrypt
	mov	r1, #0
	bl	TEST_int_gt
	subs	r4, r0, #0
	beq	.L2
	ldr	r0, [r8]
	bl	TEST_false
	subs	r4, r0, #0
	beq	.L2
	mov	r0, r7
	bl	EVP_PKEY_CTX_free
	mov	r1, r9
	mov	r0, r5
	bl	EVP_PKEY_set1_engine
	bl	TEST_true
	subs	r4, r0, #0
	beq	.L13
	ldr	r0, .L67+40
	bl	TEST_info
	mov	r1, #0
	mov	r0, r5
	bl	EVP_PKEY_CTX_new
	mov	r7, r0
	bl	TEST_ptr
	subs	r4, r0, #0
	beq	.L2
	mov	r0, r7
	bl	EVP_PKEY_encrypt_init
	mov	r1, #0
	bl	TEST_int_gt
	subs	r4, r0, #0
	beq	.L2
	mov	r1, r6
	add	r3, sp, #12
	add	r2, sp, #8
	mov	r0, r7
	str	r10, [sp]
	bl	EVP_PKEY_encrypt
	mov	r1, #0
	bl	TEST_int_gt
	subs	r4, r0, #0
	beq	.L2
	ldr	r0, [r8]
	bl	TEST_true
	subs	r4, r0, #0
	movne	r4, #1
	b	.L2
.L13:
	mov	r7, r4
	b	.L2
.L65:
	bl	__stack_chk_fail
.L68:
	.align	2
.L67:
	.word	.LC5
	.word	.LC0
	.word	.LC1
	.word	called_encrypt
	.word	.LC2
	.word	EVP_PKEY_RSA
	.word	test_rsa
	.word	test_pkey_meths
	.word	test_encrypt
	.word	.LC3
	.word	.LC4
	.size	test_redirect, .-test_redirect
	.comm	test_rsa,4,4
	.comm	test_pkey_meths,4,4
	.comm	test_encrypt,4,4
	.comm	called_encrypt,4,4
	.comm	EVP_PKEY_RSA,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
