Re: GCM performance and Unsafe byte array accesses

2015-09-01 Thread Andrew Haley
On 09/01/2015 04:42 PM, Anthony Scarpino wrote: > Does your alignment changes affect x86 only or should this help all > architectures? It does the best thing it can on every architecture. On those which support unaligned accesses, it uses them; if not, it doesn't. But there is a very cool optim

Re: GCM performance and Unsafe byte array accesses

2015-09-01 Thread Anthony Scarpino
Hi Andrew, Does your alignment changes affect x86 only or should this help all architectures? In general I don't see a disadvantage and that it could be expanded to other places in crypto too. But I have think about the effects on sparc, so that would need to be tested. Right now the sparc in

GCM performance and Unsafe byte array accesses

2015-08-27 Thread Andrew Haley
I've been looking at the performance of AES/GCM. The profile is quite surprising: samples cum. samples %cum. % symbol name 476009 47600936.7033 36.7033 aescrypt_encryptBlock 297239 77324822.9190 59.6224 ghash_processBlocks 195334 96858215.0615 74.6839 i