Page MenuHomePhabricator

Specialized double-SHA256 with 64 byte inputs with SSE4.1 and AVX2
ClosedPublic

Authored by deadalnix on Sep 30 2018, 16:20.

Details

Summary
  • Benchmark Merkle root computation
  • Refactor SHA256 code
  • Specialized double sha256 for 64 byte inputs
  • Use SHA256D64 in Merkle root computation
  • 4-way SSE4.1 implementation for double SHA256 on 64-byte inputs
  • 8-way AVX2 implementation for double SHA256 on 64-byte inputs
  • [MOVEONLY] Move unused Merkle branch code to tests
  • Enable double-SHA256-for-64-byte code on 32-bit x86
  • For AVX2 code, also check for AVX, XSAVE, and OS support

This is a backport of Core PR13191, PR13393 and PR13471

Depends on D1844 and D1845

Test Plan
make check

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

deadalnix created this revision.Sep 30 2018, 16:20
Herald added a reviewer: Restricted Project. · View Herald TranscriptSep 30 2018, 16:20
deadalnix edited the summary of this revision. (Show Details)Sep 30 2018, 16:39
deadalnix updated this revision to Diff 5189.Sep 30 2018, 16:41

Backport bug fixes in the logic used to select the SHA256 implementation

deadalnix updated this revision to Diff 5200.Sep 30 2018, 20:11

Fix build

deadalnix updated this revision to Diff 5201.Sep 30 2018, 20:13

Add release notes

deadalnix updated this revision to Diff 5207.Oct 1 2018, 12:22

Reformat a comment

schancel accepted this revision.Oct 8 2018, 23:06
This revision is now accepted and ready to land.Oct 8 2018, 23:06
This revision was automatically updated to reflect the committed changes.