From: Gordan Bobic <gordan at redsleeve.org> To: Conversations around CentOS on ARM hardware <arm-dev at centos.org> Sent: Sunday, 1 January 2017, 11:57 Subject: [Arm-dev] Golang Performance I'm not much of a Go user at the best of times, but I am noticing that there seems to be a huge ( > 10x clock-for-clock) performance discrepancy between x86-64 and aarch64 binaries. Specific example I am looking at is rclone, uploading encryoted backups to Amazon Cloud Drive. When I run it on a Westmere class Xeon (3.6GHz), it is comsuming about 2% CPU to saturate a 20Mbit uplink. When I run it on an X-Gene (2.0GHz), it is consuming about 50% CPU. Even adjusting for differences in clock speeds, this seems to be a huge difference. Is the Go complier known to produce very poor results on aarch64, or is something else in play? I know that x86-64 has a much more powerful SIMD unit, but I am not convinced that this is the explanation, and rclone doesn't use AES AFAIK, so hardware implementation of that doesn't seem to explain it either. At general purpose pointer chasing such as compiling, the X-Gene seems to produce similar performance clock-for-clock as the Westmere Xeon, so the large discrepancy with rclone seems odd. Has anyone got any insights? Both machines are running CentOS 7. Gordan Hi Gordan; I can't offer a detailed diagnosis, just some observations from a project level: Performance of Go on AArch64 is considered important from the discussions I've had with colleagues (I work for ARM, posting today with my own views) and other AArch64 users. With the release of Go 1.7, the compiler back end switched to a 'single static-assignment' back end. This is a significant change in the internals of the go compiler, and judged to be a valuable enhancement. So, versions of Go compiler pre-1.7 and post-1.7 are significantly different, and so optimizations for AArch64 (or any other architecture) are either targetting the pre- or post-1.7 code base. Given this choice, what I observe is the master branch, post-1.7 is the first priority for optimiziations and bug fixing for AArch64. For example, Cherry Zhang https://go-review.googlesource.com/#/q/owner:%22Cherry+Zhang%22 I would expect work from other AArch64 developers (including AES, CRC, etc hardware optimizations) to also target post-1.7 master branch first. It looks to me like golang version picked from the CentOS extra repository would give you version 1.6.3. It might be difficult to predict when this version will receive the attention of the development community for optimization. Have you considered moving to the golang Master branch? best regards,Richard _______________________________________________ Arm-dev mailing list Arm-dev at centos.org https://lists.centos.org/mailman/listinfo/arm-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.centos.org/pipermail/arm-dev/attachments/20170102/fc61a89e/attachment-0006.html>