	.file	"extr_bn_exp.c_BN_mod_exp.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	BN_mod_exp
	.type	BN_mod_exp, @function
BN_mod_exp:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	mov	r14, rdi
	mov	rdi, rsi
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	mov	r13, rdx
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12, rcx
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rsi
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	rbx, r8
	call	bn_check_top@PLT
	mov	rdi, r13
	call	bn_check_top@PLT
	mov	rdi, r12
	call	bn_check_top@PLT
	mov	rdi, r12
	call	BN_is_odd@PLT
	test	rax, rax
	je	.L2
	cmp	DWORD PTR 0[rbp], 1
	jne	.L3
	mov	eax, DWORD PTR 16[rbp]
	test	eax, eax
	je	.L7
.L3:
	mov	rcx, r12
	xor	r9d, r9d
	mov	r8, rbx
	mov	rdx, r13
	mov	rsi, rbp
	mov	rdi, r14
	call	BN_mod_exp_mont@PLT
	mov	r12d, eax
.L4:
	mov	rdi, r14
	call	bn_check_top@PLT
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	mov	rcx, r12
	mov	r8, rbx
	mov	rdx, r13
	mov	rsi, rbp
	mov	rdi, r14
	call	BN_mod_exp_recp@PLT
	mov	r12d, eax
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L7:
	mov	esi, DWORD PTR BN_FLG_CONSTTIME[rip]
	mov	rdi, r13
	call	BN_get_flags@PLT
	test	rax, rax
	jne	.L3
	mov	esi, DWORD PTR BN_FLG_CONSTTIME[rip]
	mov	rdi, rbp
	call	BN_get_flags@PLT
	test	rax, rax
	jne	.L3
	mov	esi, DWORD PTR BN_FLG_CONSTTIME[rip]
	mov	rdi, r12
	call	BN_get_flags@PLT
	test	rax, rax
	jne	.L3
	mov	rax, QWORD PTR 8[rbp]
	mov	rcx, r12
	xor	r9d, r9d
	mov	r8, rbx
	mov	rdx, r13
	mov	rdi, r14
	mov	esi, DWORD PTR [rax]
	call	BN_mod_exp_mont_word@PLT
	mov	r12d, eax
	jmp	.L4
	.cfi_endproc
.LFE0:
	.size	BN_mod_exp, .-BN_mod_exp
	.comm	BN_FLG_CONSTTIME,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_bn_exp.c_BN_mod_exp.c"
	.text
	.align	2
	.global	BN_mod_exp
	.syntax unified
	.arm
	.fpu softvfp
	.type	BN_mod_exp, %function
BN_mod_exp:
	@ args = 4, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r7, r2
	mov	r5, r3
	sub	sp, sp, #8
	mov	r6, r0
	mov	r0, r1
	mov	r4, r1
	bl	bn_check_top
	mov	r0, r7
	bl	bn_check_top
	mov	r0, r5
	bl	bn_check_top
	mov	r0, r5
	bl	BN_is_odd
	cmp	r0, #0
	beq	.L2
	ldr	r3, [r4]
	cmp	r3, #1
	bne	.L3
	ldr	r3, [r4, #8]
	cmp	r3, #0
	beq	.L7
.L3:
	mov	r0, #0
	ldr	r3, [sp, #32]
	mov	r1, r4
	str	r3, [sp]
	str	r0, [sp, #4]
	mov	r3, r5
	mov	r2, r7
	mov	r0, r6
	bl	BN_mod_exp_mont
	mov	r4, r0
.L4:
	mov	r0, r6
	bl	bn_check_top
	mov	r0, r4
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, pc}
.L2:
	ldr	r3, [sp, #32]
	mov	r1, r4
	str	r3, [sp]
	mov	r2, r7
	mov	r3, r5
	mov	r0, r6
	bl	BN_mod_exp_recp
	mov	r4, r0
	b	.L4
.L7:
	ldr	r8, .L8
	mov	r0, r7
	ldr	r1, [r8]
	bl	BN_get_flags
	cmp	r0, #0
	bne	.L3
	mov	r0, r4
	ldr	r1, [r8]
	bl	BN_get_flags
	cmp	r0, #0
	bne	.L3
	mov	r0, r5
	ldr	r1, [r8]
	bl	BN_get_flags
	cmp	r0, #0
	bne	.L3
	ldr	r2, [r4, #4]
	mov	r3, r5
	ldr	r1, [r2]
	str	r0, [sp, #4]
	ldr	r0, [sp, #32]
	mov	r2, r7
	str	r0, [sp]
	mov	r0, r6
	bl	BN_mod_exp_mont_word
	mov	r4, r0
	b	.L4
.L9:
	.align	2
.L8:
	.word	BN_FLG_CONSTTIME
	.size	BN_mod_exp, .-BN_mod_exp
	.comm	BN_FLG_CONSTTIME,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
