Bitcoin Forum
April 20, 2024, 04:05:46 AM *
News: Latest Bitcoin Core release: 26.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 [15] 16 17 18 19 20 21 22 23 24 25 26 »
  Print  
Author Topic: New demonstration CPU miner available  (Read 386159 times)
lfm
Full Member
***
Offline Offline

Activity: 196
Merit: 104



View Profile
March 25, 2011, 09:49:27 PM
 #281

I'm having trouble getting decent speeds out of Jgarzik's miner on Ubuntu 10.10 (Phenom II X4 920). I'm only getting 125 kh/s per thread (4 threads), which drops to 50 kh/s with 4way enabled.

The same computer does 10+ mh/s using ufasoft's Win SSE2 miner.
Can someone please enlighten me as to how I can get the same performance under Linux.

try "-a 4way" command line switch
Each block is stacked on top of the previous one. Adding another block to the top makes all lower blocks more difficult to remove: there is more "weight" above each block. A transaction in a block 6 blocks deep (6 confirmations) will be very difficult to remove.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
chromicant
Newbie
*
Offline Offline

Activity: 40
Merit: 0


View Profile
March 25, 2011, 10:22:38 PM
 #282

I'm having trouble getting decent speeds out of Jgarzik's miner on Ubuntu 10.10 (Phenom II X4 920). I'm only getting 125 kh/s per thread (4 threads), which drops to 50 kh/s with 4way enabled.

The same computer does 10+ mh/s using ufasoft's Win SSE2 miner.
Can someone please enlighten me as to how I can get the same performance under Linux.

If you do a ./minerd --help, is sse2_64 listed as a valid algorithm to use? If not, you need a copy of yasm 1.1 from Debian and use that. That'll compile the SSE2 code. You also need to be running a 64-bit version of Ubuntu.

The SSE2 code is not well-tuned for some AMD architectures, it seems.
SawEfDir
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile
March 27, 2011, 12:36:45 PM
 #283

I'm having troubles getting the new sse2_amd64 algo compiled on my amd64 debian unstable system. I'm using the source from the git repo, commit 69529c38594f7bd56b50b9effed5a45125ccba3e
Though .configure seems to find yasm, make doesn't seem to compile it properly like shown in other forum posts. Trying minerd --algo sse_amd64 fails with minerd displaying the help page. Other algos seem to work ok. Debian unstable uses gcc-4.5 by default.

Unfortunately, the forum won't let me attach any files because the upload folder is full, and I don't want to clutter the post with long log file outputs.

Is there any extra option must set for ./configure in order to get the sse2_amd64 compiled in?
chromicant
Newbie
*
Offline Offline

Activity: 40
Merit: 0


View Profile
March 27, 2011, 12:45:03 PM
 #284

You can use a pastebin for the logs. Need them to help you out.
SawEfDir
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile
March 27, 2011, 02:31:04 PM
 #285

Oh indeed, thanks for the hint:

config.log: http://pastebin.com/stxRvch7
configure stdout: http://pastebin.com/dbLQsjzF
make stdout: http://pastebin.com/dTV252An
chromicant
Newbie
*
Offline Offline

Activity: 40
Merit: 0


View Profile
March 27, 2011, 04:03:30 PM
 #286

Ok. Took a look at the logs. Seems like configure is not doing the yasm test correctly. Can you run yasm --version and open an issue on my Github page for cpuminer?

https://github.com/chromicant/cpuminer/issues
hazzey
Newbie
*
Offline Offline

Activity: 9
Merit: 0


View Profile
March 27, 2011, 07:17:43 PM
 #287

I just went through the installation of minerd on Ubuntu 10.10.  I have one request for the maintainers.
Could you put in the README or INSTALL a list of the packages that will be required for the "configure" to complete.  I was able to get most of the required packages right away, but the libcurl one threw me for a while.  I had installed libcurl, but the configure script was not happy.  I finally had to install the libcurl-dev package.  This wasn't apparent from the error message that the configure script gave.  The error just says that libcurl needs to be of a certain version, not that you needed to install the dev package.

The packages that I remember installing were: yasm, libcurl-dev, automake, and gcc.

This might help future users wanting to install a cpu miner on linux.

Thanks,

hazzey
jgarzik (OP)
Legendary
*
Offline Offline

Activity: 1596
Merit: 1091


View Profile
March 27, 2011, 07:34:04 PM
 #288

I just went through the installation of minerd on Ubuntu 10.10.  I have one request for the maintainers.
Could you put in the README or INSTALL a list of the packages that will be required for the "configure" to complete.  I was able to get most of the required packages right away, but the libcurl one threw me for a while.  I had installed libcurl, but the configure script was not happy.  I finally had to install the libcurl-dev package.  This wasn't apparent from the error message that the configure script gave.  The error just says that libcurl needs to be of a certain version, not that you needed to install the dev package.

The dependencies are listed in README.

The need for a "-dev" package is just required general knowledge:  to build any source code, not just minerd, you must install each -dev package required by that source code.




Jeff Garzik, Bloq CEO, former bitcoin core dev team; opinions are my own.
Visit bloq.com / metronome.io
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
hazzey
Newbie
*
Offline Offline

Activity: 9
Merit: 0


View Profile
March 28, 2011, 12:11:04 AM
 #289


The dependencies are listed in README.

The need for a "-dev" package is just required general knowledge:  to build any source code, not just minerd, you must install each -dev package required by that source code.


That does make sense, but like I said, it isn't immediately obvious, especially to someone who isn't used to compiling programs.

Now this might not be that big of a deal since most people who go through the trouble of download/compiling are well versed in it, but there may also be others like me who could benefit from a little more verbose documentation.

Well, even if nothing changes, someone might be helped just from my post.

Thanks,

hazzey
chromicant
Newbie
*
Offline Offline

Activity: 40
Merit: 0


View Profile
March 28, 2011, 02:25:04 AM
Last edit: March 28, 2011, 02:43:09 AM by chromicant
 #290

Ok. Took a look at the logs. Seems like configure is not doing the yasm test correctly. Can you run yasm --version and open an issue on my Github page for cpuminer?

https://github.com/chromicant/cpuminer/issues

And to talk to myself...I think I found the problem. Let me see if I can quickly fix it.

Edit

Fixed pushed to http://github.com/chromicant/cpuminer on the sse2 branch. Can people can pull from it and test to make sure it builds on other machines? It works on mine Ubuntu 10.10 x86_64 box with YASM 1.1.0.2352.

It also contains a minor update to the assembly code to remove the few pipeline stalls. I was playing with a profiler, and looking at some data people posted here, and made some minor fixes. Don't really see any noticeable speedup, but it should be there in theory. And we know how well theory is in practice.
eideteker
Newbie
*
Offline Offline

Activity: 13
Merit: 0


View Profile
March 28, 2011, 05:40:51 AM
 #291

I just noticed this - the date reads a month in the past in the CPU miner.  Is this a problem on my end?  My computer's date/time are set correct.
SawEfDir
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile
March 30, 2011, 05:02:33 PM
 #292

Ok. Took a look at the logs. Seems like configure is not doing the yasm test correctly. Can you run yasm --version and open an issue on my Github page for cpuminer?

https://github.com/chromicant/cpuminer/issues
It seems the yasm version installed on my system was to old. I've thought I've installed version 1.1.0, but it actually was 0.8.0.
Debian unstable does only provide yasm 0.8.0. One can install 1.1.0 using the debian-multimedia.org repositories, though.

Thanks for you help.
Tolkien
Newbie
*
Offline Offline

Activity: 16
Merit: 0



View Profile
March 30, 2011, 05:45:10 PM
 #293

I was looking at the cpu-miner's code (cpu-miner.c) and found in
static void *miner_thread(void *userdata) a few lines that look like this:
Quote
rc = (rc4 == -1) ? false : true;
and rc isn't initialized at declaration..
I'm a C++ (among other languages) programmer, not C, but I know a WTF when I see one..
I'd love to hear the reason as to why this wasn't simply
Quote
bool rc = false;
(some code) ...
if (rc4 != -1) {
  rc = true;
}

I'd say that's 10,000x more readable and it's one less uninitialized variable, and less code.

I don't mean to sound grumpy, it's just.. so.... obvious...

Also, what's with the aversion to C++ and Boost everyone seems to have? Macro abuse should be a thing of the past with template metaprogramming. I'm not saying don't use assembly (especially), macros or C-specific things at all, I'm just saying you can get rid of a tonne of macro abuse by combining template metaprogramming with Boost's Preprocessor library correctly to hide compilation details behind a layer that abstracts away algorithmic details from general program flow with no impact on generated output.

This wasn't initially meant as a rant or anything with a harsh sounding tone btw, I'm just hungry and looking forward to pressing submit before I go eat. :S
LMGTFY
Hero Member
*****
Offline Offline

Activity: 644
Merit: 502



View Profile
March 30, 2011, 05:48:40 PM
 #294

I'd love to hear the reason as to why this wasn't simply
Quote
bool rc = false;
(some code) ...
if (rc4 != -1) {
  rc = true;
}
I'm not a C/C++ programmer, but wouldn't...
Code:
rc = (rc4 != -1);
...be even more readable?

This space intentionally left blank.
Tolkien
Newbie
*
Offline Offline

Activity: 16
Merit: 0



View Profile
March 30, 2011, 05:56:48 PM
 #295

I'd love to hear the reason as to why this wasn't simply
Quote
bool rc = false;
(some code) ...
if (rc4 != -1) {
  rc = true;
}
I'm not a C/C++ programmer, but wouldn't...
Code:
rc = (rc4 != -1);
...be even more readable?

It would be if it were correct but it's not, the program flow would change regardless of whether or not rc were initialized.
jgarzik (OP)
Legendary
*
Offline Offline

Activity: 1596
Merit: 1091


View Profile
March 30, 2011, 06:00:51 PM
 #296

I'm not a C/C++ programmer, but wouldn't...
Code:
rc = (rc4 != -1);
...be even more readable?

It would be if it were correct but it's not, the program flow would change regardless of whether or not rc were initialized.

LMGTFY's code is correct, and you are mistaken (about not only this, but macro abuse etc. also)




Jeff Garzik, Bloq CEO, former bitcoin core dev team; opinions are my own.
Visit bloq.com / metronome.io
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
LMGTFY
Hero Member
*****
Offline Offline

Activity: 644
Merit: 502



View Profile
March 30, 2011, 06:04:45 PM
 #297

I'd love to hear the reason as to why this wasn't simply
Quote
bool rc = false;
(some code) ...
if (rc4 != -1) {
  rc = true;
}
I'm not a C/C++ programmer, but wouldn't...
Code:
rc = (rc4 != -1);
...be even more readable?

It would be if it were correct but it's not, the program flow would change regardless of whether or not rc were initialized.
Sorry, I wasn't suggesting replace all your code, obviously the initialisation and the (some code) block would be retained. It's just the if {} block I meant.

This space intentionally left blank.
Tolkien
Newbie
*
Offline Offline

Activity: 16
Merit: 0



View Profile
March 30, 2011, 06:07:54 PM
 #298

I'm not a C/C++ programmer, but wouldn't...
Code:
rc = (rc4 != -1);
...be even more readable?

It would be if it were correct but it's not, the program flow would change regardless of whether or not rc were initialized.

LMGTFY's code is correct, and you are mistaken (about not only this, but macro abuse etc. also)

Really? Double checking myself. 0.o I'd disagree about the macro abuse though. The unrelated code I'm working on has quite a bit of macro usage removed with the help of template metaprogramming.

Edit: After double checking I can safely and easily say I was wrong indeed
Quote
rc = (rc4 != -1);
is right. My mind must be playing tricks on me sorry. :S Now to go eat!
Tolkien
Newbie
*
Offline Offline

Activity: 16
Merit: 0



View Profile
March 30, 2011, 06:13:40 PM
 #299

I'd love to hear the reason as to why this wasn't simply
Quote
bool rc = false;
(some code) ...
if (rc4 != -1) {
  rc = true;
}
I'm not a C/C++ programmer, but wouldn't...
Code:
rc = (rc4 != -1);
...be even more readable?

It would be if it were correct but it's not, the program flow would change regardless of whether or not rc were initialized.
Sorry, I wasn't suggesting replace all your code, obviously the initialisation and the (some code) block would be retained. It's just the if {} block I meant.

That was taken for granted, yeah. Wink
jkminkov
Hero Member
*****
Offline Offline

Activity: 698
Merit: 500


View Profile
March 30, 2011, 08:02:52 PM
 #300

moving from http://bitcointalk.org/index.php?topic=3889.msg75264#msg75264 till end of page #24


http://bayimg.com/KaEgHaADl

win xp sp3 32bit

Q9550 @ 2,83Ghz

tuned all threads affinity with task manager to one core

.:31211457:. 100 dollars in one place talking - Dudes, hooray, Bitcoin against us just one, but we are growing in numbers!
Pages: « 1 2 3 4 5 6 7 8 9 10 11 12 13 14 [15] 16 17 18 19 20 21 22 23 24 25 26 »
  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!