Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
openssl linux-aarch64 vs linux-generic64
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on ARM
View previous topic :: View next topic  
Author Message
erm67
l33t
l33t


Joined: 01 Nov 2005
Posts: 653
Location: EU

PostPosted: Thu Jul 06, 2017 10:26 am    Post subject: openssl linux-aarch64 vs linux-generic64 Reply with quote

The gentoo openssl ebuild configures openssl on arm64 as generic64, but there's are now some assembly code available for aarch64, the results are not terrific and apparently the aes asm routines are just as fast as the code produced by gcc6+graphite+lto on my system.

Code:

openssl.aarch64  ghash           263012.50k   624123.97k  1074193.32k  1295074.99k  1398237.87k
openssl.generic   ghash            57252.45k    63059.84k    65039.96k    65772.65k    65708.03k
openssl.aarch64  sha1             21034.93k    75709.44k   225295.79k   443869.87k   628282.56k
openssl.generic   sha1              14776.03k    43234.37k    98299.48k   143431.68k   166511.30k
openssl.aarch64   sha256           54790.81k   162208.43k   365465.86k   526146.56k   613447.00k
openssl.generic    sha256           13715.07k    29898.60k    50701.99k    61735.94k    65899.18k
openssl.aarch64   sha512           13278.58k    53303.55k    86171.65k   124076.71k   142630.91k
openssl.generic    sha512            9564.81k    38016.49k    58622.29k    82489.00k    93678.25k



Nevertheless ghash and sha routines are a lot faster using openssl's aarch64 profile, I will file a bug to bugzilla with this patch as soon as I recover my password :-)

If someone wants to try it on their arm64 this is the patch, just ebuild digest and make sure the lib is reloaded.
Code:
--- openssl.orig/files/gentoo.config-1.0.2   2017-07-06 12:10:23.890921185 +0200
+++ openssl/files/gentoo.config-1.0.2   2017-07-06 09:51:50.361392922 +0200
@@ -81,8 +81,8 @@
 case ${system} in
 linux)
    case ${chost_machine}:${ABI} in
-      aarch64*be*)  machine="generic64 -DB_ENDIAN";;
-      aarch64*)     machine="generic64 -DL_ENDIAN";;
+      aarch64*be*)  machine="aarch64 -DB_ENDIAN";;
+      aarch64*)     machine="aarch64 -DL_ENDIAN";;
       alphaev56*|\
       alphaev[678]*)machine=alpha+bwx-${compiler};;
       alpha*)       machine=alpha-${compiler};;

_________________
Ok boomer
True ignorance is not the absence of knowledge, but the refusal to acquire it.
Ab esse ad posse valet, a posse ad esse non valet consequentia

My fediverse account: @erm67@erm67.dynu.net
Back to top
View user's profile Send private message
ConiKost
Developer
Developer


Joined: 11 Jan 2005
Posts: 1365

PostPosted: Sat Jul 07, 2018 9:04 pm    Post subject: Reply with quote

This got merged into portage :-)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on ARM All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum