Tim Hudson via RT wrote:
>> I kicked off some builds last night as I was curious as to the answer to
>> the question - 0.9.8d fails in make test, 0.9.8k passes in make test.
No comment on this one.
> The 1.0.0 beta 3 fails with the SHA1 asm code and in the AES asm code.
> I haven't had a chance to look into this in any detail - just noting that the
> out-of-the-box build isn't working. ./config -no-asm works so the issues are
> all
> in the asm code.
>
> tjh:~/work/openssl-1.0.0-beta3/test> gdb sha1test
> GNU gdb 6.4
> Copyright 2005 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you are
> welcome to change it and/or distribute copies of it under certain conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB. Type "show warranty" for details.
> This GDB was configured as "s390x-suse-linux"...ruUsing host libthread_db
> library "/lib64/libthread_db.so.1".
>
> (gdb) run
> Starting program: /home/tjh/work/openssl-1.0.0-beta3/test/sha1test
>
> Program received signal SIGILL, Illegal instruction.
> sha1_block_data_order () at sha1-s390x.s:13
> 13 lg %r0,16(%r15)
> Current language: auto; currently asm
> (gdb)
>
> tjh:~/work/openssl-1.0.0-beta3> cat /proc/cpuinfo
> vendor_id : IBM/S390
> # processors : 1
> bogomips per cpu: 888.01
> processor 0: version = FF, identification = 0117C9, machine = 2064
To summarize. It's zSeries machine, a.k.a. s390x platform, i.e. 64-bit
one. 2064 or z900 was first one in line. It doesn't seem to be able to
handle lg instruction, which loads a 64-bit value from memory to register...
Now, all s390x assembler programming is based on "z/Architecture
Principals of Operation" document from IBM. Among other things this
document specifies which instructions are optional and available as
installable facility. lg instruction is "base" instruction, i.e. is
believed to be available in all z implementations. Actually all
assembler modules in question are implemented with "base"
instructions(*). If the assumption that all z implementations are
capable of executing "base" instructions does not hold true, then the
only appropriate thing to do would be to a) figure out which z machines
can't handle all of the base instuctions in "Principal of Operation"; b)
how identify such machines in ./config; c) disable assembler on such
machines. Because it would too much hassle to classify "base"
instructions as "really-base" and "not-so-base" and sanitize assembler
(unless of course it's sponsored).
On related note I wonder what instruction would compiler emit to load
64-bit value? Could you generated assembler listing for long foo(long
*p) { return *p; } and sent it? Use gcc -S -O options.
(*) The intention is to guard usage of non-"base" instructions with
run-time check to determine if it can be executed and fall down to
"base"-only code.
______________________________________________________________________
OpenSSL Project http://www.openssl.org
Development Mailing List [email protected]
Automated List Manager [email protected]