Questions tagged [midstate]
4 questions
10
votes
1 answer
Did Satoshi intend to allow midstate computation to speed up hashing?
The design of Bitcoin allows computers to compute a hash with 2 iterations of the SHA256 compression function instead of 3 on all but 1 out of every 2^32 attempts.
When Satoshi chose SHA256d for Bitcoin, did he intend to allow this?
Nick ODell
- 29,184
- 11
- 69
- 129
5
votes
2 answers
What is a midstate? How does using a midstate speed up hashing?
This defines "midstate" as the "precomputed hash state after hashing the first half of the data."
I've heard "midstate" used in the context of speeding up hashing. How does using a midstate speed up hashing?
Geremia
- 4,469
- 4
- 37
- 75
2
votes
2 answers
What is the duration of a ban?
I read somewhere that a node is banned for 24 hours.
However I found the Misbehaving() function which makes state->fShouldBan = true;. But I could not find any other function that makes state->fShouldBan = false;. It seems that banning is…
Önder Gürcan
- 337
- 1
- 8
0
votes
2 answers
How do i create/implement a midstate function (One that can accurately calculate the midstate of already mined blocks)
I'm creating an AI controlled bitcoin miner but I'm having trouble manually & locally creating a midstate function to be used for optimizing the mining process. Basically I've created independent functions that handle the steps involved in mining…
AncientTides
- 75
- 9