Re: [PATCH 0/7] Phase one of sparc crypto opcode support.

2012-09-21 Thread Andy Polyakov
>> You mentioned Montgomery BN. > > Here are how the instructions work. > > The basic model is that there is a range of sizes supported by the > instruction, and all of the data is loaded into a combination of > the floating point registers and all of the register windows of > the cpu. Ouch! >

Re: [PATCH 4/7] sparc: Add assembler macros for loading OPENSSL_sparcv9cap_P into a register.

2012-09-21 Thread Andy Polyakov
> Provide these so that the assembler users can be oblivious about > whether this is PIC or non-PIC, 64-bit or 32-bit, etc. > > It is important to use a real call and return to implement the > obtaining of the %pc as part of the PIC sequence. Sequences > such as: > > call. + 8 >

Re: [openssl.org #2836] [PATCH] Staple the correct OCSP Response when multiple certs are configured

2012-09-21 Thread Rob Stradling via RT
Attached are patches for 1.0.0 and 0.9.8. -- Rob Stradling Senior Research & Development Scientist COMODO - Creating Trust Online Office Tel: +44.(0)1274.730505 Office Fax: +44.(0)1274.730909 www.comodo.com COMODO CA Limited, Registered in England No. 04058690 Registered Office: 3rd Floor, 26

[openssl.org #2836] [PATCH] Staple the correct OCSP Response when multiple certs are configured

2012-09-21 Thread Stephen Henson via RT
> [rob.stradl...@comodo.com - Fri Sep 21 15:02:54 2012]: > > Attached are patches for 1.0.0 and 0.9.8. > > Note, I updated the original change to retain compatibility with existing behaviour as far as possible. See: http://cvs.openssl.org/chngview?cn=22808 Steve. -- Dr Stephen N. Henson. Ope

Re: [openssl.org #2836] [PATCH] Staple the correct OCSP Response when multiple certs are configured

2012-09-21 Thread Rob Stradling via RT
Hi Steve. I saw your update (to 1.0.2 and HEAD), and I did start looking at backporting it into my 1.0.1/1.0.0/0.9.8 patches. ssl_get_server_send_pkey() is not available in 1.0.1 and earlier, so the t1_lib.c patch would have to be something like... + X509 *x; + x =

[openssl.org #2836] [PATCH] Staple the correct OCSP Response when multiple certs are configured

2012-09-21 Thread Stephen Henson via RT
> [rob.stradl...@comodo.com - Fri Sep 21 15:55:39 2012]: > > Hi Steve. > > I saw your update (to 1.0.2 and HEAD), and I did start looking at > backporting it into my 1.0.1/1.0.0/0.9.8 patches. > > ssl_get_server_send_pkey() is not available in 1.0.1 and earlier, so the > t1_lib.c patch would h

Re: [openssl.org #2836] [PATCH] Staple the correct OCSP Response when multiple certs are configured

2012-09-21 Thread Rob Stradling via RT
On 21/09/12 15:04, Stephen Henson via RT wrote: >> [rob.stradl...@comodo.com - Fri Sep 21 15:55:39 2012]: >> >> Hi Steve. >> >> I saw your update (to 1.0.2 and HEAD), and I did start looking at >> backporting it into my 1.0.1/1.0.0/0.9.8 patches. >> >> ssl_get_server_send_pkey() is not available in

Re: [openssl.org #2836] [PATCH] Staple the correct OCSP Response when multiple certs are configured

2012-09-21 Thread Rob Stradling via RT
On 21/09/12 15:12, Rob Stradling via RT wrote: > On 21/09/12 15:04, Stephen Henson via RT wrote: >> Easiest solution is to also backport ssl_get_server_send_pkey see: >> >> http://cvs.openssl.org/chngview?cn=22840 > > I didn't think of that. Thanks! > > I'll prepare patches to backport 22840 to 1

Re: [PATCH 0/7] Phase one of sparc crypto opcode support.

2012-09-21 Thread David Miller
From: Andy Polyakov Date: Fri, 21 Sep 2012 11:36:16 +0200 > No, before thinking about 32-bit mode, I quickly ask what's with save-s > without arguments? Sorry, I just wrote that code as pseudo-code off the top of my head without attending to all of the necessary details. We would indeed need to

Re: [PATCH 4/7] sparc: Add assembler macros for loading OPENSSL_sparcv9cap_P into a register.

2012-09-21 Thread David Miller
From: Andy Polyakov Date: Fri, 21 Sep 2012 12:21:25 +0200 > I'll handle this, but differently. Specifically I won't go through GOT, > but directly to variable, something like this: I would like to politely request that you don't go down this road. > .Lretl: > retl > nop > ... >

Re: [PATCH 4/7] sparc: Add assembler macros for loading OPENSSL_sparcv9cap_P into a register.

2012-09-21 Thread David Miller
Here is a more detailed reply specifically about generating correct and optimal Sparc PIC sequences. Let's get the non-PIC static case out of the way, we should always use: set symbol, %reg! 32-bit setxsymbol, %tmp_reg, %reg ! 64-bit Using calls to PIC stubs

[PATCH 0/2] Sparc AES crypto opcode support.

2012-09-21 Thread David Miller
This builds on top of the 7 patch series I sent the other day which laid the foundation for sparc crypto opcode support. The first patch plugs in optimized versions of key expansion and AES_{decrypt,encrypt}() The second patch is modelled on the AESNI support and explicitly optimizes ECB, CBC, C

[PATCH 1/2] sparc: Add initial support for AES opcodes.

2012-09-21 Thread David Miller
Currently AES_encrypt, AES_decrypt, and the key expansion are optimized. Direct support for CBC, ECB, CTR, etc. will come in subsequent changes. The following measurements were taken on a SPARC-T4. Baseline (OPENSSL_sparcv9cap=0): type 16 bytes 64 bytes256 bytes 1024 byte

[PATCH 2/2] sparc: Expand AES crypto opcodes support to various modes.

2012-09-21 Thread David Miller
On a SPARC-T4, with AES opcodes disabled (OPENSSL_sparcv9cap=0): type 16 bytes 64 bytes256 bytes 1024 bytes 8192 bytes aes-128 cbc 75200.21k83425.11k86767.67k87853.06k88279.72k aes-192 cbc 64906.68k71059.56k73902.42k74532.52k74855.

[PATCH] sparc: Add support for CAMELLIA opcodes.

2012-09-21 Thread David Miller
On a SPARC T4-2, with CAMELLIA opcodes disabled: type 16 bytes 64 bytes256 bytes 1024 bytes 8192 bytes camellia-128 cbc63737.35k66054.61k66780.50k66775.35k 67062.44k camellia-192 cbc51126.33k53836.78k54761.73k54964.91k 55017.47k came