Bug #85819 | Optimize AARCH64 CRC32c implementation | ||
---|---|---|---|
Submitted: | 6 Apr 2017 3:04 | Modified: | 7 Apr 2017 8:22 |
Reporter: | Yuqi Gu (OCA) | Email Updates: | |
Status: | Verified | Impact on me: | |
Category: | MySQL Server: InnoDB Plugin storage engine | Severity: | S5 (Performance) |
Version: | 5.7 | OS: | Linux |
Assigned to: | CPU Architecture: | ARM | |
Tags: | Contribution |
[6 Apr 2017 3:04]
Yuqi Gu
[6 Apr 2017 5:41]
Yuqi Gu
Contribution submitted via Github - Bug #85819 Add AArch64 optimized crc32c implementation #136n (*) I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.
Contribution: bug85819-5.7.txt (text/plain), 5.40 KiB.
[6 Apr 2017 5:59]
Yuqi Gu
ARMv8 defines a set of optional CRC32/CRC32C instructions. The CRC32 function for AArch64 that uses these instructions will optimize the performance rather than that uses table-based lookup.
[6 Apr 2017 6:13]
Alexey Kopytov
Duplicate of bug #79144 ?
[7 Apr 2017 5:22]
Yuqi Gu
ARMv8 defines PMULL crypto instruction. The new patch optimizes crc32c calculate with the instruction when available rather than (*) I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.
Contribution: bug85819-02-5.7.txt (text/plain), 8.38 KiB.
[7 Apr 2017 5:22]
Yuqi Gu
I updated the crc32 optimization code. ARMv8 defines PMULL crypto instruction. The new patch optimizes crc32c calculate with the PMULLinstruction when available rather than original linear crc32 instructions. The result of benchmark: Platform \ Case (millisecond) | Software CRC | AArch64 CRC Intrinsics | AArch64 Crypto instruction AMD seattle (Softiron) |1101.783 |200.535 |114.509 Cavium ThunderX |1504.497 |479.690 |286.274 Hisilicon Taishan( Huawei) |1035.202 |232.984 |115.580 It shows that the performance for CRC32 of innodb on AArch64 is better than linear crc32 instruction.
[7 Apr 2017 5:31]
Yuqi Gu
GH PR: https://github.com/mysql/mysql-server/pull/136
[7 Apr 2017 5:34]
Yuqi Gu
ARMv8 defines PMULL crypto instruction.This patch optimizes crc32c calculate with the instruction.
[7 Apr 2017 8:22]
MySQL Verification Team
Hello Yuqi Gu, Thank you for the report and contribution. Thanks, Umesh
[28 Apr 2017 16:10]
OCA Admin
Contribution submitted via Github - Bug #85819 Add AArch64 optimized crc32c implementation (*) Contribution by Yuqi Gu (Github guyuqi, mysql-server/pull/136#issuecomment-292444031): I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.
Contribution: git_patch_114523745.txt (text/plain), 11.05 KiB.