aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2001-03-09 01:13:23 +0000
committerRichard Levitte <levitte@openssl.org>2001-03-09 01:13:23 +0000
commit754d494bef083e7f4c8733e7142555726ca7efef (patch)
tree744095e414c419ece7064e9d128dace7c9fc8895
parent42909e39681bcbaaada696c901bbff472d71dbe2 (diff)
downloadopenssl-754d494bef083e7f4c8733e7142555726ca7efef.zip
openssl-754d494bef083e7f4c8733e7142555726ca7efef.tar.gz
openssl-754d494bef083e7f4c8733e7142555726ca7efef.tar.bz2
Bug fixes.
-rw-r--r--crypto/bn/asm/vms.mar15
1 files changed, 8 insertions, 7 deletions
diff --git a/crypto/bn/asm/vms.mar b/crypto/bn/asm/vms.mar
index 754ab53..5eab242 100644
--- a/crypto/bn/asm/vms.mar
+++ b/crypto/bn/asm/vms.mar
@@ -261,6 +261,7 @@ d=12 ;(AP) d by value (input)
movl #0,r5
movl #0,r8
movl #0,r0
+; movl #0,r1
rotl #-1,r2,r6 ; a20 = l >> 1 (almost)
rotl #-1,r3,r7 ; a21 = h >> 1 (almost)
@@ -278,17 +279,17 @@ d=12 ;(AP) d by value (input)
xorl2 #^X80000000,r7 ; fixup a21 so highest bit is 1
2$:
tstl r9
- bgeq 666$ ; Uh-oh, the divisor is 0...
+ beq 666$ ; Uh-oh, the divisor is 0...
bgtr 3$
- xorl2 #^X80000000,r9 ; fixup b2 so highest bit is 1
- incl r8
+ xorl2 #^X80000000,r9 ; fixup b2 so highest bit is 0
+ incl r8 ; b' = 1
3$:
tstl r9
- bneq 4$ ; if b2 is 0, we know that bprim is 1
- tstl r7
+ bneq 4$ ; if b2 is 0, we know that b' is 1
+ tstl r3
bneq 666$ ; if higher half isn't 0, we overflow
- movl r0,r6 ; otherwise, we have our result
- brb 42$
+ movl r2,r10 ; otherwise, we have our result
+ brb 42$ ; This is a success, really.
4$:
ediv r9,r6,r10,r11