Bitcoin Forum
December 03, 2016, 12:24:29 AM *
News: To be able to use the next phase of the beta forum software, please ensure that your email address is correct/functional.
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: [PATCH] modularize BitcoinMiner a bit (code movement)  (Read 1353 times)
jgarzik
Legendary
*
qt
Offline Offline

Activity: 1470


View Profile
November 21, 2010, 09:21:12 AM
 #1

URL: http://yyz.us/bitcoin/patch.bitcoin-modularize_miner

This patch is similar to patches sometimes seen in the Linux kernel.  Analogous to an algebraic reduction, or a step in a mathematic proof, this patch intentionally makes zero functional code changes.  It moves two chunks of code -- hash meter and check-solution -- from the BitcoinMiner() function into separate functions.

This change makes it easier to integrate remote mining.

Jeff Garzik, bitcoin core dev team and BitPay engineer; opinions are my own, not my employer.
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
1480724669
Hero Member
*
Offline Offline

Posts: 1480724669

View Profile Personal Message (Offline)

Ignore
1480724669
Reply with quote  #2

1480724669
Report to moderator
1480724669
Hero Member
*
Offline Offline

Posts: 1480724669

View Profile Personal Message (Offline)

Ignore
1480724669
Reply with quote  #2

1480724669
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1480724669
Hero Member
*
Offline Offline

Posts: 1480724669

View Profile Personal Message (Offline)

Ignore
1480724669
Reply with quote  #2

1480724669
Report to moderator
Cdecker
Hero Member
*****
Offline Offline

Activity: 487



View Profile WWW
November 21, 2010, 04:36:07 PM
 #2

Seems to be ok: +1

Want to see what developers are chatting about? http://bitcoinstats.com/irc/bitcoin-dev/logs/
Bitcoin-OTC Rating
jgarzik
Legendary
*
qt
Offline Offline

Activity: 1470


View Profile
November 21, 2010, 09:43:21 PM
 #3

Patch updated to move prepare-work and prepare-hash-buffer code into separate functions.

Again, no code changes, just code movement.

The patch now looks similar to m0mchil's getwork patch, and makes integrating remote mining much easier.

Jeff Garzik, bitcoin core dev team and BitPay engineer; opinions are my own, not my employer.
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
jgarzik
Legendary
*
qt
Offline Offline

Activity: 1470


View Profile
November 22, 2010, 09:13:53 AM
 #4

Patch updated to fix silly parameter passing bug in one of the new functions.  Code now generates correct blocks on testnet, as expected.

Jeff Garzik, bitcoin core dev team and BitPay engineer; opinions are my own, not my employer.
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
jgarzik
Legendary
*
qt
Offline Offline

Activity: 1470


View Profile
November 23, 2010, 12:04:40 AM
 #5

Updated to SVN r188 (accounts).

Jeff Garzik, bitcoin core dev team and BitPay engineer; opinions are my own, not my employer.
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
jgarzik
Legendary
*
qt
Offline Offline

Activity: 1470


View Profile
November 23, 2010, 10:46:32 PM
 #6

This patch is entirely superceded by SVN r189, satoshi's version of getwork.

Jeff Garzik, bitcoin core dev team and BitPay engineer; opinions are my own, not my employer.
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!