Bitcoin Forum
November 13, 2024, 04:20:34 AM *
News: Check out the artwork 1Dq created to commemorate this forum's 15th anniversary
 
   Home   Help Search Login Register More  
Pages: [1] 2 »  All
  Print  
Author Topic: [Removed Bounty] PrimeCoin CUDA miner  (Read 8687 times)
Vorksholk (OP)
Legendary
*
Offline Offline

Activity: 1713
Merit: 1029



View Profile WWW
July 17, 2013, 12:21:06 AM
Last edit: April 04, 2014, 09:43:27 PM by Vorksholk
 #1

As a result of extensive development of OpenCL miners for Primecoin with impressive performance, this bounty is now removed. GPU mining of Primecoin is going to soon be saturated. If you were currently developing something for this bounty (unlikely as all development seems to be Opencl and it has been months) PM me.


Note: mtrlt is making a OpenCL-miner. That doesn't qualify for this bounty.

New rule: CUDA miner has to somewhat-significantly outperform mtrlt miner on equivalently-priced hardware (aka CUDA miner that gets 800 coins/day on a $400 NVidia GPU on testnet will get this bounty if mtrlt's miner will get 500 coins/day on a $400 AMD GPU).

The first person who makes a CUDA miner that outperforms a CPU of equivalent value by more than 2x ($330 NVidia GPU, like a 670, should give more than 2x the blocks of an i7-3770 on testnet over the same period of time) will get 6 Bitcoins! If anyone else wants to add to the bounty, just post a message with your 'pledge'.  

Requirements: compiled windows binary, source code provided.
Optional: compiled linux binaries.

Current bounty chip-ins:
Vorksholk: 6BTC

Alternately, if someone wants to dig through the primecoin code and give me a nice concise summary of exactly how the mining process works (purpose that the sieve serves, relation of block hash to potential primes, process of getting data from primecoind, process of submitting data to primecoind) I will either write my own, or attempt to hire someone with the USD equivalent.

If you provide a great explanation of all of the following (and are the first to do so), I will give you one BTC:
-What purpose the sieve serves
-What relation the block hash has to the potential block-solving primes
-Process of obtaining all mining data from primecoind
-process of submitting prime chain to mining data

Also, at heart, I love NVidia, I'm a NVidia fanboy. Smiley

VeriBlock: Securing The World's Blockchains Using Bitcoin
https://veriblock.org
Eli0t
Sr. Member
****
Offline Offline

Activity: 252
Merit: 250


View Profile
July 17, 2013, 12:23:19 AM
 #2

-What purpose the sieve serves

In mathematics, the sieve of Eratosthenes, one of a number of prime number sieves, is a simple, ancient algorithm for finding all prime numbers up to any given limit. It does so by iteratively marking as composite (i.e. not prime) the multiples of each prime, starting with the multiples of 2.

The multiples of a given prime are generated starting from that prime, as a sequence of numbers with the same difference, equal to that prime, between consecutive numbers. This is the sieve's key distinction from using trial division to sequentially test each candidate number for divisibility by each prime.

The sieve of Eratosthenes is one of the most efficient ways to find all of the smaller primes (below 10 million or so)

awesome bounty btw i hope someone gets it

LTC:  LKpJf3uk7KsHU73kxq8iFJrP1AAKN7Yni7  DGC:  DKXGvEbj3Rwgrm2QQbRyNPDDZDYoq4Y44d  XPM:  AWV5AKfLFyoBaMjg9C77rGUBhuFxz5DGGL
Vorksholk (OP)
Legendary
*
Offline Offline

Activity: 1713
Merit: 1029



View Profile WWW
July 17, 2013, 12:27:21 AM
 #3

-What purpose the sieve serves

In mathematics, the sieve of Eratosthenes, one of a number of prime number sieves, is a simple, ancient algorithm for finding all prime numbers up to any given limit. It does so by iteratively marking as composite (i.e. not prime) the multiples of each prime, starting with the multiples of 2.

The multiples of a given prime are generated starting from that prime, as a sequence of numbers with the same difference, equal to that prime, between consecutive numbers. This is the sieve's key distinction from using trial division to sequentially test each candidate number for divisibility by each prime.

The sieve of Eratosthenes is one of the most efficient ways to find all of the smaller primes (below 10 million or so)

awesome bounty btw i hope someone gets it

Yeah, during my short digging I did find the sieve of Eratosthenes, though your explanation was better than what I found. My main question with the sieve is, since we are finding very huge primes, what purpose this 'table of primes' serves the finding of large prime chains?

VeriBlock: Securing The World's Blockchains Using Bitcoin
https://veriblock.org
logicsol
Newbie
*
Offline Offline

Activity: 35
Merit: 0



View Profile
July 17, 2013, 12:37:14 AM
 #4

Why not Opencl?
Palmdetroit
Legendary
*
Offline Offline

Activity: 910
Merit: 1000


PHS 50% PoS - Stop mining start minting


View Profile
July 17, 2013, 12:39:19 AM
 #5

Why not Opencl?

Imagine if we finally had a Nvidia coin, or at least one worthwhile to mine on nvidia..... would bring tons new people into the cyrptoworld.. good for all IMO


logicsol
Newbie
*
Offline Offline

Activity: 35
Merit: 0



View Profile
July 17, 2013, 12:42:05 AM
 #6

Very true, I had figured something like that was the reasoning. It just struck me that most in this field(mining clients) would be more familiar with Opencl than CUDA.
Eli0t
Sr. Member
****
Offline Offline

Activity: 252
Merit: 250


View Profile
July 17, 2013, 12:49:16 AM
 #7

-What purpose the sieve serves

In mathematics, the sieve of Eratosthenes, one of a number of prime number sieves, is a simple, ancient algorithm for finding all prime numbers up to any given limit. It does so by iteratively marking as composite (i.e. not prime) the multiples of each prime, starting with the multiples of 2.

The multiples of a given prime are generated starting from that prime, as a sequence of numbers with the same difference, equal to that prime, between consecutive numbers. This is the sieve's key distinction from using trial division to sequentially test each candidate number for divisibility by each prime.

The sieve of Eratosthenes is one of the most efficient ways to find all of the smaller primes (below 10 million or so)

awesome bounty btw i hope someone gets it

Yeah, during my short digging I did find the sieve of Eratosthenes, though your explanation was better than what I found. My main question with the sieve is, since we are finding very huge primes, what purpose this 'table of primes' serves the finding of large prime chains?
the sieve works by getting increasing more likely 'primes' by altering a value to be more likely prime, and the table is used as seeds for that 'winnowing' process.
You want to have a big table because the more you have, the more likely one of them will work for a given block.

LTC:  LKpJf3uk7KsHU73kxq8iFJrP1AAKN7Yni7  DGC:  DKXGvEbj3Rwgrm2QQbRyNPDDZDYoq4Y44d  XPM:  AWV5AKfLFyoBaMjg9C77rGUBhuFxz5DGGL
FiiNALiZE
Hero Member
*****
Offline Offline

Activity: 868
Merit: 500

CryptoTalk.Org - Get Paid for every Post!


View Profile
July 17, 2013, 12:51:22 AM
 #8

Not sure if this answers your 2nd question, but:

"Block hash, the value that is embedded in the child block, is derived from hashing the
header together with the proof-of-work certificate. This not only prevents the proof-of-work certificate from being tampered with, but also defeats attempt at generating a single
proof-of-work certificate usable on multiple blocks on the block chain, since the block
header hash of a descendant block then depends on the certificate itself. Note that, if an
attacker generates a different proof-of-work certificate for an existing block, the block
would then have a different block hash even though the block content remains the same
other than the certificate, and would be accepted to the block chain as a sibling block to
the existing block."

Taken from the design paper.



 
                                . ██████████.
                              .████████████████.
                           .██████████████████████.
                        -█████████████████████████████
                     .██████████████████████████████████.
                  -█████████████████████████████████████████
               -███████████████████████████████████████████████
           .-█████████████████████████████████████████████████████.
        .████████████████████████████████████████████████████████████
       .██████████████████████████████████████████████████████████████.
       .██████████████████████████████████████████████████████████████.
       ..████████████████████████████████████████████████████████████..
       .   .██████████████████████████████████████████████████████.
       .      .████████████████████████████████████████████████.

       .       .██████████████████████████████████████████████
       .    ██████████████████████████████████████████████████████
       .█████████████████████████████████████████████████████████████.
        .███████████████████████████████████████████████████████████
           .█████████████████████████████████████████████████████
              .████████████████████████████████████████████████
                   ████████████████████████████████████████
                      ██████████████████████████████████
                          ██████████████████████████
                             ████████████████████
                               ████████████████
                                   █████████
.CryptoTalk.org.|.MAKE POSTS AND EARN BTC!.🏆
razorfishsl
Sr. Member
****
Offline Offline

Activity: 399
Merit: 250


View Profile WWW
July 17, 2013, 01:01:45 AM
 #9

Or you could just go onto the research site and pull down the data for and including the first 17 million  digit primes....

Then use that as a 'feeder' mechanism....

High Quality USB Hubs for Bitcoin miners
https://bitcointalk.org/index.php?topic=560003
AgentME
Member
**
Offline Offline

Activity: 84
Merit: 10


View Profile
July 17, 2013, 01:05:39 AM
 #10

I thought AMD cards were better for Bitcoin mining because they were better at integer operations, and Nvidia was mainly good at floating point. Primecoin mining doesn't involve many floating point operations as far as I know, so targeting Nvidia specifically could be a waste of time.
gateway
Hero Member
*****
Offline Offline

Activity: 552
Merit: 500


View Profile
July 17, 2013, 01:11:11 AM
 #11

Prob everyone has already looked around and found these but just encase

http://www.macs-site.net/CudaPrimes.htm CUDA Primes
https://github.com/MNorthwind/OpenCL-Prime-Numbers-Generator OpenCL

Of course this is just some basic stuff, prob lots of stuff needs to be done, mapping to the memory, dealing with how cores work
on the work, esp since blocks are completed so fast right now.. etc..

rethaw
Sr. Member
****
Offline Offline

Activity: 378
Merit: 255



View Profile
July 17, 2013, 01:15:32 AM
 #12

I'm confused, why wouldn't you write it as OpenCL? This provides at least some level of portability.

EDIT: That being said, it's a generous offer!

Vorksholk (OP)
Legendary
*
Offline Offline

Activity: 1713
Merit: 1029



View Profile WWW
July 17, 2013, 01:20:40 AM
 #13

Why not Opencl?

From what I understand, CUDA is more apt to this type of work. As well, I think variety is a cool thing, and getting both groups of major video card fanboys in on cryptocoins couldn't hurt. Tongue

While I would love OCL (I have 10 7950s and 3 7970s), I think NVidia would be a nice change.

VeriBlock: Securing The World's Blockchains Using Bitcoin
https://veriblock.org
rethaw
Sr. Member
****
Offline Offline

Activity: 378
Merit: 255



View Profile
July 17, 2013, 01:22:53 AM
 #14


If you provide a great explanation of all of the following (and are the first to do so), I will give you one BTC:
-What purpose the sieve serves
-What relation the block hash has to the potential block-solving primes
-Process of obtaining all mining data from primecoind
-process of submitting prime chain to mining data

1) I think you got the purpose of the sieve.

2) None.

3) primecoind getblocktemplate

4) primecoind submitblock

Vorksholk (OP)
Legendary
*
Offline Offline

Activity: 1713
Merit: 1029



View Profile WWW
July 17, 2013, 01:32:19 AM
 #15

-What purpose the sieve serves

In mathematics, the sieve of Eratosthenes, one of a number of prime number sieves, is a simple, ancient algorithm for finding all prime numbers up to any given limit. It does so by iteratively marking as composite (i.e. not prime) the multiples of each prime, starting with the multiples of 2.

The multiples of a given prime are generated starting from that prime, as a sequence of numbers with the same difference, equal to that prime, between consecutive numbers. This is the sieve's key distinction from using trial division to sequentially test each candidate number for divisibility by each prime.

The sieve of Eratosthenes is one of the most efficient ways to find all of the smaller primes (below 10 million or so)

awesome bounty btw i hope someone gets it

Yeah, during my short digging I did find the sieve of Eratosthenes, though your explanation was better than what I found. My main question with the sieve is, since we are finding very huge primes, what purpose this 'table of primes' serves the finding of large prime chains?
the sieve works by getting increasing more likely 'primes' by altering a value to be more likely prime, and the table is used as seeds for that 'winnowing' process.
You want to have a big table because the more you have, the more likely one of them will work for a given block.

This is really interesting! Mathematically, how does the sieve table work? Is one of the primes multiplied by a certain value and then changed in order to obtain a true prime? Also, what address do you want your 0.25 BTC to? Smiley

VeriBlock: Securing The World's Blockchains Using Bitcoin
https://veriblock.org
rabit
Member
**
Offline Offline

Activity: 62
Merit: 10


View Profile
July 17, 2013, 01:33:04 AM
 #16

-What purpose the sieve serves

In mathematics, the sieve of Eratosthenes, one of a number of prime number sieves, is a simple, ancient algorithm for finding all prime numbers up to any given limit. It does so by iteratively marking as composite (i.e. not prime) the multiples of each prime, starting with the multiples of 2.

The multiples of a given prime are generated starting from that prime, as a sequence of numbers with the same difference, equal to that prime, between consecutive numbers. This is the sieve's key distinction from using trial division to sequentially test each candidate number for divisibility by each prime.

The sieve of Eratosthenes is one of the most efficient ways to find all of the smaller primes (below 10 million or so)

awesome bounty btw i hope someone gets it

Yeah, during my short digging I did find the sieve of Eratosthenes, though your explanation was better than what I found. My main question with the sieve is, since we are finding very huge primes, what purpose this 'table of primes' serves the finding of large prime chains?
the sieve works by getting increasing more likely 'primes' by altering a value to be more likely prime, and the table is used as seeds for that 'winnowing' process.
You want to have a big table because the more you have, the more likely one of them will work for a given block.

Could you explain this a little bit deeper?
So the sieve produces the set P:={p prime | p <= sieve size} and i have the block hash h. Now i need to find an integer k such that h*k is the origin of a chain of length difficulty. So how is P explicitly used to find a candidate for such an integer k?
Vorksholk (OP)
Legendary
*
Offline Offline

Activity: 1713
Merit: 1029



View Profile WWW
July 17, 2013, 01:33:10 AM
 #17

I'm confused, why wouldn't you write it as OpenCL? This provides at least some level of portability.

EDIT: That being said, it's a generous offer!

Mainly because from what I understand CUDA is more fit to this purpose, as well as it serving as a nice way to get the NVidia players into cryptos as well. Cheesy

VeriBlock: Securing The World's Blockchains Using Bitcoin
https://veriblock.org
Vorksholk (OP)
Legendary
*
Offline Offline

Activity: 1713
Merit: 1029



View Profile WWW
July 17, 2013, 01:39:21 AM
 #18


If you provide a great explanation of all of the following (and are the first to do so), I will give you one BTC:
-What purpose the sieve serves
-What relation the block hash has to the potential block-solving primes
-Process of obtaining all mining data from primecoind
-process of submitting prime chain to mining data

1) I think you got the purpose of the sieve.

2) None.

3) primecoind getblocktemplate

4) primecoind submitblock

Looks like you know what's up, so I'm gonna grill you for some more information, and if you can provide it you'll be the new owner of a shiny Bitcoin. Smiley

2.) I thought that the block hash was used as some factor of either start of chain +1 or start of chain -1 (or in a bi-twin chain, the average between the two first values?). Was this something else that served the purpose of not allowing the same prime chain to be used multiple times?

3.) "getblocktemplate" provides this, which parts are relevant, and how are they relevant, to mining?
{
    "version" : 2,
    "previousblockhash" : "7072f0272b3e38536e072c94e340b7c7824a71989f6e9f3112ce30d6be5ae525",
    "transactions" : [
    ],
    "coinbaseaux" : {
        "flags" : "062f503253482f"
    },
    "coinbasevalue" : 1249000000,
    "target" : "0000000000000000000000000000000000000000000000007118620000000000",
    "mintime" : 1374023934,
    "mutable" : [
        "time",
        "transactions",
        "prevblock"
    ],
    "noncerange" : "00000000ffffffff",
    "sigoplimit" : 20000,
    "sizelimit" : 1000000,
    "curtime" : 1374024884,
    "bits" : "08f11862",
    "height" : 55422
}

VeriBlock: Securing The World's Blockchains Using Bitcoin
https://veriblock.org
Eli0t
Sr. Member
****
Offline Offline

Activity: 252
Merit: 250


View Profile
July 17, 2013, 02:10:59 AM
 #19

-What purpose the sieve serves

In mathematics, the sieve of Eratosthenes, one of a number of prime number sieves, is a simple, ancient algorithm for finding all prime numbers up to any given limit. It does so by iteratively marking as composite (i.e. not prime) the multiples of each prime, starting with the multiples of 2.

The multiples of a given prime are generated starting from that prime, as a sequence of numbers with the same difference, equal to that prime, between consecutive numbers. This is the sieve's key distinction from using trial division to sequentially test each candidate number for divisibility by each prime.

The sieve of Eratosthenes is one of the most efficient ways to find all of the smaller primes (below 10 million or so)

awesome bounty btw i hope someone gets it

Yeah, during my short digging I did find the sieve of Eratosthenes, though your explanation was better than what I found. My main question with the sieve is, since we are finding very huge primes, what purpose this 'table of primes' serves the finding of large prime chains?
the sieve works by getting increasing more likely 'primes' by altering a value to be more likely prime, and the table is used as seeds for that 'winnowing' process.
You want to have a big table because the more you have, the more likely one of them will work for a given block.

This is really interesting! Mathematically, how does the sieve table work? Is one of the primes multiplied by a certain value and then changed in order to obtain a true prime? Also, what address do you want your 0.25 BTC to? Smiley
the prime chain is linked to the block header hash by requiring that its origin be divisible by the block header hash.
pk/r is used to measure the difficulty of the chain. r is the Fermat test remainder of the next number in chain pk
d = k + (pk- r)/pk  

k is the prime chain length. d = difficulty if pk passes probable primality tests then it should be considered as a chain of higher integral length.

my BTC addy is 13YGmE2CCAxWpAhqQSm5NVz9pU7Q4B22jm
thanks Smiley

LTC:  LKpJf3uk7KsHU73kxq8iFJrP1AAKN7Yni7  DGC:  DKXGvEbj3Rwgrm2QQbRyNPDDZDYoq4Y44d  XPM:  AWV5AKfLFyoBaMjg9C77rGUBhuFxz5DGGL
Vorksholk (OP)
Legendary
*
Offline Offline

Activity: 1713
Merit: 1029



View Profile WWW
July 17, 2013, 03:00:50 AM
 #20

-What purpose the sieve serves

In mathematics, the sieve of Eratosthenes, one of a number of prime number sieves, is a simple, ancient algorithm for finding all prime numbers up to any given limit. It does so by iteratively marking as composite (i.e. not prime) the multiples of each prime, starting with the multiples of 2.

The multiples of a given prime are generated starting from that prime, as a sequence of numbers with the same difference, equal to that prime, between consecutive numbers. This is the sieve's key distinction from using trial division to sequentially test each candidate number for divisibility by each prime.

The sieve of Eratosthenes is one of the most efficient ways to find all of the smaller primes (below 10 million or so)

awesome bounty btw i hope someone gets it

Yeah, during my short digging I did find the sieve of Eratosthenes, though your explanation was better than what I found. My main question with the sieve is, since we are finding very huge primes, what purpose this 'table of primes' serves the finding of large prime chains?
the sieve works by getting increasing more likely 'primes' by altering a value to be more likely prime, and the table is used as seeds for that 'winnowing' process.
You want to have a big table because the more you have, the more likely one of them will work for a given block.

This is really interesting! Mathematically, how does the sieve table work? Is one of the primes multiplied by a certain value and then changed in order to obtain a true prime? Also, what address do you want your 0.25 BTC to? Smiley
the prime chain is linked to the block header hash by requiring that its origin be divisible by the block header hash.
pk/r is used to measure the difficulty of the chain. r is the Fermat test remainder of the next number in chain pk
d = k + (pk- r)/pk  

k is the prime chain length. d = difficulty if pk passes probable primality tests then it should be considered as a chain of higher integral length.

my BTC addy is 13YGmE2CCAxWpAhqQSm5NVz9pU7Q4B22jm
thanks Smiley

Stellar, sent your 0.25 BTC Smiley Cheers!!

VeriBlock: Securing The World's Blockchains Using Bitcoin
https://veriblock.org
Pages: [1] 2 »  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!