I've checked the beta3 code against the code we use (successfully).

In aes, the only differences are entry point changes caused by IBM
namespacing our variant of OpenSSL.
In sha1 there's an additional .align 16 directive here in Beta3

.globl      sha1_block_data_order
.type sha1_block_data_order,\...@function
sha1_block_data_order:
___
$code.=<<___ if ($kimdfunc);
      lghi  %r0,0
      la    %r1,16($sp)
      .long 0xb93e0002  # kimd %r0,%r2
      lg    %r0,16($sp)
      tmhh  %r0,`0x8000>>$kimdfunc`
      jz    .Lsoftware
      lghi  %r0,$kimdfunc
      lgr   %r1,$ctx
      lgr   %r2,$inp
      sllg  %r3,$len,6
      .long 0xb93e0002  # kimd %r0,%r2
      brc   1,.-4       # pay attention to "partial completion"
      br    %r14
.align      16                                 <<<<<<<<<<<<<<<<<<<<<<<<<<<<
.Lsoftware:

None of those differences should cause compile failures. I can't get at the
build machine at present to check the gcc and binutils versions, email me
if you need that information at some point.

Note that this code does only compile for a 64 bit target. It doesn't work
with 32 bit code.

Peter




                                                                                
                                                       
  From:       Peter Waltenberg/Australia/i...@ibmau                             
                                                        
                                                                                
                                                       
  To:         openssl-dev@openssl.org                                           
                                                       
                                                                                
                                                       
  Date:       09/17/2009 07:27 PM                                               
                                                       
                                                                                
                                                       
  Subject:    Re: [openssl.org #2046] OpenSSL 1.0.0 beta 3 ASM fails on z/Linux 
64-bit                                                 
                                                                                
                                                       
  Sent by:    owner-openssl-...@openssl.org                                     
                                                       
                                                                                
                                                       





Doesn't help much, but we do use that code, and at least slightly older
versions do compile and run on 64 bit Z.

(I had to backport it from a later OpenSSL to 0.9.8, so I can't be sure I'm
using exactly the same asm at this point).

I'll double check tomorrow and see if there are differences between the
beta 3 asm and the version we use here.

Peter





  From:       "Tim Hudson via RT" <r...@openssl.org>


  To:


  Cc:         openssl-dev@openssl.org


  Date:       09/17/2009 06:08 PM


  Subject:    [openssl.org #2046] OpenSSL 1.0.0 beta 3 ASM fails on z/Linux
64-bit

  Sent by:    owner-openssl-...@openssl.org







> 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.

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.

0.9.8k passes make test, 0.9.8d fails make test in BN code.

./config
make
make test

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)


Linux somewhere 2.6.16.21-0.8-default #1 SMP Mon Jul 3 18:25:39 UTC 2006
s390x
s390x s390x GNU/Linux

tjh:~/work/openssl-1.0.0-beta3> gcc -v
Using built-in specs.
Target: s390x-suse-linux
Configured with: ../configure --enable-threads=posix --prefix=/usr
--with-local-prefix=/usr/local --infodir=/usr/share/info
--mandir=/usr/share/man
--libdir=/usr/lib64 --libexecdir=/usr/lib64
--enable-languages=c,c++,objc,fortran,java --enable-checking=release
--with-gxx-include-dir=/usr/include/c++/4.1.0 --enable-ssp --disable-libssp

--enable-java-awt=gtk --enable-gtk-cairo --disable-libjava-multilib
--with-slibdir=/lib64 --with-system-zlib --enable-shared
--enable-__cxa_atexit
--enable-libstdcxx-allocator=new --without-system-libunwind
--with-tune=z9-109
--with-arch=z900 --with-long-double-128 --host=s390x-suse-linux
Thread model: posix
gcc version 4.1.0 (SUSE Linux)

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


[attachment "PGP.sig" deleted by Peter Waltenberg/Australia/IBM]

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       openssl-dev@openssl.org
Automated List Manager                           majord...@openssl.org


______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       openssl-dev@openssl.org
Automated List Manager                           majord...@openssl.org

Reply via email to