Bitcoin Forum

Other => Beginners & Help => Topic started by: Balthazar2012 on July 31, 2013, 10:12:22 PM



Title: SHA256 Implementation Gate Equivalent
Post by: Balthazar2012 on July 31, 2013, 10:12:22 PM
Hi Guys,
I needed help in understanding how to calculate the GE for a SHA256 implementation. I need to calculate the GE of individual functions in the SHA256 hashing algorithm.

Could anyone please direct me to an appropriate paper/book that explains this in detail?

Thanks in advance!

P.S: Correct me if I sound dumb in what I've asked. It is quite apparent that I am a newbie in this domain.


Title: Re: SHA256 Implementation Gate Equivalent
Post by: cp1 on August 01, 2013, 01:36:16 AM
There's an open source fpga, maybe that will have the info.


Title: Re: SHA256 Implementation Gate Equivalent
Post by: J35st3r on August 01, 2013, 08:12:46 AM
It depends on how far you unroll the SHA256 algorithm. The open source code https://bitcointalk.org/index.php?topic=9047.0 fits two fully unrolled SHA256 engines (for the two stages of SHA256D) into a 115kLE cyclone IV (I think the utilization is around  90kLE). However if you just want the minimum then a single fully rolled engine comes in at around 1kLE (and runs 128 times slower). As for the conversion between Logic Elements (CLBs) and gates, I've seen estimates of around 12 gates per LE. Anyway have a look through the thread I linked above, lots of info there and the linked github has the verilog code.