Big Number Test Failure for 0.9.7i

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Big Number Test Failure for 0.9.7i

Rick Richert

BTW:  This was reported earlier based on a merged copy of 0.9.7i and
0.9.7d+os400 mods.  Since then, I have performed the same test with
clean copy of 0.9.7i and got the same error.  I also tried the same test
with a clean copy of 0.9.8a and got the same error.


I am compiling openssl-0.9.7i on Solaris 5.8 using the 64 bit compiler
options (gcc 3.4.2).  Everything compiles fine, but the Big Number tests
fails for the test_sqr.  By this I mean we don't get the right answers
for specific values.  It is either a problem with BN_mul or BN_div.


This either a bug or some problem with the configuration.  Any ideas?



Rick


Configuration
=============
The following entry was added to Configure for Solaris 5.8.

"solaris64-sparcv8-gcc","gcc:-m64 -mv8 -O3 -fomit-frame-pointer -Wall -
DB_ENDIAN -DBN_DIV2W::-D_REENTRANT::-lsocket -lnsl -ldl:BN_LLONG
RC4_CHAR RC4_CHUNK DES_UNROLL
BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-fPIC:-shared -
m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",

The steps taken were:
$  /bin/sh ./Configure -no-asm solaris64-sparcv8-gcc
$  make
$  make test


bntest Errors
=============
test BN_sqr
print "test BN_sqr\n"
-C0C0C0C0C0 * -C0C0C0C0C0 - 9121B242D241B1209000
2000000000000 * 2000000000000 - 4000000000000000000000000
-B0000FFFFFFFFFF * -B0000FFFFFFFFFF - 7900160000FFFFE9FFFE0000000001
-2CFFFFFF777715FFFF * -2CFFFFFF777715FFFF -
7E8FFFFCFFFDDBC4877C1D976F511D40001
Square test failed!


I did try omiting the -no-asm option and setting the asm file in
Makefile.org, but the compilation breaks with the Solaris assembler
(/usr/ccs/as).  

/usr/ccs/bin/as: "/var/tmp//ccxI3OvD.s", line 147: error: detect global
register use not covered .register pseudo-op




Rick







______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [hidden email]
Automated List Manager                           [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: Big Number Test Failure for 0.9.7i

Rick Richert

Well, it was a configuration issue.  Since we are running Solaris 5.9
and 5.8 on Ultra 60 boxes, and 5.9 works, I used the options from
solaris64-sparcv9-gcc for solaris64-sparcv8-gcc.  Except for the asm
reference (which we don't use) they are the same.  Why the old values
worked with 0.9.7d, is a mystery.

I did learn one lesson from this.  Be sure to test out a clean openssl
on your platform before you put any openssl updates into your project.
Do this for each platform you plan to use.  Configure values that worked
before don't necessarily work with the later upgrades.


Rick



On Thu, 2006-02-09 at 16:13 -0800, Rick Richert wrote:

> BTW:  This was reported earlier based on a merged copy of 0.9.7i and
> 0.9.7d+os400 mods.  Since then, I have performed the same test with
> clean copy of 0.9.7i and got the same error.  I also tried the same test
> with a clean copy of 0.9.8a and got the same error.
>
>
> I am compiling openssl-0.9.7i on Solaris 5.8 using the 64 bit compiler
> options (gcc 3.4.2).  Everything compiles fine, but the Big Number tests
> fails for the test_sqr.  By this I mean we don't get the right answers
> for specific values.  It is either a problem with BN_mul or BN_div.
>
>
> This either a bug or some problem with the configuration.  Any ideas?
>
>
>
> Rick
>
>
> Configuration
> =============
> The following entry was added to Configure for Solaris 5.8.
>
> "solaris64-sparcv8-gcc","gcc:-m64 -mv8 -O3 -fomit-frame-pointer -Wall -
> DB_ENDIAN -DBN_DIV2W::-D_REENTRANT::-lsocket -lnsl -ldl:BN_LLONG
> RC4_CHAR RC4_CHUNK DES_UNROLL
> BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-fPIC:-shared -
> m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
>
> The steps taken were:
> $  /bin/sh ./Configure -no-asm solaris64-sparcv8-gcc
> $  make
> $  make test
>
>
> bntest Errors
> =============
> test BN_sqr
> print "test BN_sqr\n"
> -C0C0C0C0C0 * -C0C0C0C0C0 - 9121B242D241B1209000
> 2000000000000 * 2000000000000 - 4000000000000000000000000
> -B0000FFFFFFFFFF * -B0000FFFFFFFFFF - 7900160000FFFFE9FFFE0000000001
> -2CFFFFFF777715FFFF * -2CFFFFFF777715FFFF -
> 7E8FFFFCFFFDDBC4877C1D976F511D40001
> Square test failed!
>
>
> I did try omiting the -no-asm option and setting the asm file in
> Makefile.org, but the compilation breaks with the Solaris assembler
> (/usr/ccs/as).  
>
> /usr/ccs/bin/as: "/var/tmp//ccxI3OvD.s", line 147: error: detect global
> register use not covered .register pseudo-op
>
>
>
>
> Rick
>
>
>
>
>
>
>
> ______________________________________________________________________
> OpenSSL Project                                 http://www.openssl.org
> User Support Mailing List                    [hidden email]
> Automated List Manager                           [hidden email]

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [hidden email]
Automated List Manager                           [hidden email]
Reply | Threaded
Open this post in threaded view
|

RE: Big Number Test Failure for 0.9.7i

Ted Mittelstaedt
In reply to this post by Rick Richert

You might try installing the GNU binutils and gas instead of the
solaris assembler and linker and see if that helps.  People have
had problems before using gcc and feeding the result to the
solaris linker, and in fact there's a patch for gcc mentioned in
the openssl readme or faq or some such.  (I don't know if it's
appliable to you)

Ted

>-----Original Message-----
>From: [hidden email]
>[mailto:[hidden email]]On Behalf Of Rick Richert
>Sent: Thursday, February 09, 2006 4:14 PM
>To: [hidden email]
>Subject: Big Number Test Failure for 0.9.7i
>
>
>
>BTW:  This was reported earlier based on a merged copy of 0.9.7i and
>0.9.7d+os400 mods.  Since then, I have performed the same test with
>clean copy of 0.9.7i and got the same error.  I also tried the same test
>with a clean copy of 0.9.8a and got the same error.
>
>
>I am compiling openssl-0.9.7i on Solaris 5.8 using the 64 bit compiler
>options (gcc 3.4.2).  Everything compiles fine, but the Big Number tests
>fails for the test_sqr.  By this I mean we don't get the right answers
>for specific values.  It is either a problem with BN_mul or BN_div.
>
>
>This either a bug or some problem with the configuration.  Any ideas?
>
>
>
>Rick
>
>
>Configuration
>=============
>The following entry was added to Configure for Solaris 5.8.
>
>"solaris64-sparcv8-gcc","gcc:-m64 -mv8 -O3 -fomit-frame-pointer -Wall -
>DB_ENDIAN -DBN_DIV2W::-D_REENTRANT::-lsocket -lnsl -ldl:BN_LLONG
>RC4_CHAR RC4_CHUNK DES_UNROLL
>BF_PTR:asm/sparcv8.o:::::::::dlfcn:solaris-shared:-fPIC:-shared -
>m64:.so.\$(SHLIB_MAJOR).\$(SHLIB_MINOR)",
>
>The steps taken were:
>$  /bin/sh ./Configure -no-asm solaris64-sparcv8-gcc
>$  make
>$  make test
>
>
>bntest Errors
>=============
>test BN_sqr
>print "test BN_sqr\n"
>-C0C0C0C0C0 * -C0C0C0C0C0 - 9121B242D241B1209000
>2000000000000 * 2000000000000 - 4000000000000000000000000
>-B0000FFFFFFFFFF * -B0000FFFFFFFFFF - 7900160000FFFFE9FFFE0000000001
>-2CFFFFFF777715FFFF * -2CFFFFFF777715FFFF -
>7E8FFFFCFFFDDBC4877C1D976F511D40001
>Square test failed!
>
>
>I did try omiting the -no-asm option and setting the asm file in
>Makefile.org, but the compilation breaks with the Solaris assembler
>(/usr/ccs/as).
>
>/usr/ccs/bin/as: "/var/tmp//ccxI3OvD.s", line 147: error: detect global
>register use not covered .register pseudo-op
>
>
>
>
>Rick
>
>
>
>
>
>
>
>______________________________________________________________________
>OpenSSL Project                                 http://www.openssl.org
>User Support Mailing List                    [hidden email]
>Automated List Manager                           [hidden email]
>
>--
>No virus found in this incoming message.
>Checked by AVG Free Edition.
>Version: 7.1.375 / Virus Database: 267.15.3/254 - Release Date: 2/8/2006
>

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [hidden email]
Automated List Manager                           [hidden email]