Can anyone tell me if Spoetnik's CPU miner works in cheat mode? It's giving me pretty good hashrates on my i3 laptop but I'm not sure if any blocks I might find will be accepted. Thanks.
you should be fine when it comes to sending QUALITY work.
there should be NO problem at all finding blocks !
the REAL question though is performance actually better or is it an illusion kind of ? i am not so sure it helps much
let me explain what is happening with cheat mode
if hashing is going to take too long it simply drops the work and gets new work to start hashing on.
so it's not possible to send ANY bad shares or invalid data of any kind.
it will work EXACTLY like the official version of the hashing algo.
how the hashing algo works is by running five different hashing algo's in three rounds..
and what normally happens is in order to build a proper final hash the cycle of what hash algo's get triggered and on what round vary a lot.
here is a sample of what it looks like
gro = 2
_jh = 1
ske = 0
blk = 0
ske = 1
blk = 1
ske = 2
blk = 2
ske = 0
blk = 0
ske = 1
blk = 1
ske = 2
_jh = 2
ske = 1
blk = 1
the quoted info is where i put some logging into the code to watch what was happening while hashing normally..
each three letter code is the different hashing algo's abbreviated to 3 letters.
and each of those numbers are what round the specific hashing algo was triggered.
that is 5 algo's running 3 rounds and there is 2 specific points where it checks to run one algo or the other.
anyway, so what you see logged right away in first line in my quoted sample info is Groestl got triggered on round 3 (the final round)
so that means it had already completed hashing it's way through rounds 1 and 2 and now it hit GRO on round 3.
what i did was change the code so that it asks for new work if the miner detects that Groestl will get run more than once.
because Groestl i think is the hardest hash algo to run and takes the longest to finish.
so the change i shared for testing on my cpu miner topic in my sig simply on some circumstances stops hashing and asks for new work
it does not change the work that gets sent.. does that make any sense ?
I am not sure you really gain anything in terms of speed doing this.
I Did try something more or less similar on the cgminer code some times ago
Actually I was just counting the number of times the groestl was called and if it was about to enter a 2nd time the groestl condition nothing was done (which is kind of stupid, just realized, as I should have asked to leave the loop to avoid computing the other algo for nothing... may-be I should check again... )
However if there is a gain in terms of "raw" speed, the probability to find a corresponding hash also decrease since it throws all hashes with 2 (or more) groestl functions.
If I am not mistaken, there is 1/2 chance to get groestl at each round, so
1/4 3/8 to get groestl twice and 1/8 three time
So the probability to get 2 or more groestl is
3/8 1/2
And the probability to get less than 2 should be
5/8 1/2, which is like saying only 1 over 2 hashes are considered by the new algo.
So technically to be faster than the original algorithm, the speed of the "cheat" algo must be 2 times faster than the original to compensate the loss of certain combination.
If it is the case, your cheat is faster otherwise it is slower.
obviously if your cheat is just 2x faster, it has the exact same speed as the original.
(in my case, if I remember well I was slower, but there was a mistake, since I wasn't leaving the loop fast enough)
In any case my conclusion with the R9 290x was that the best way to optimise its performance (versus my gtx780ti) was to run on an other coin...
edit: few error in prob calculation... (hope I got it right this time... it's late...)
i think you could perceive the result in many ways.. i can anyway.
it's complicated kinda lol
I didn't just do this.. another guy did 1+ year ago on quark and i got his code sample and had spent MONTHS working on it..
so all together i have spent one hella crazy ass mega long time recompiling and checking
as well as having dedicated beta testers helping test the so called cheat mode.. so i have given it a LOT of thought lol
I have been making miners mods for ages and have spent huge amount for time doing in for just under a year.
you can add 1+1 from right to left or you can add 1+1 from left to right and it's still 2
you don't need to be good at math to figure that out either lol
what i did was provide ONE example of about 100's i have done in the last few days alone..
i have re-written the hashing algo to use no rounds or switch statements or or or...
my current version is massively different than what i posted last lol
and faster
edit:
https://github.com/cbuchner1/ccminer/commit/be044f31a1df3baa05857018ba8525700743159fcase ya didn't see that before lol
May 05, 2014
Christian Buchner - cbuchner1 - Speed optimization: do MUCH LESS Groestl in Jackpot, throw away 75% of the hashes. More speed ;-)