Author

Topic: OFFICIAL CGMINER mining software thread for linux/win/osx/mips/arm/r-pi 4.11.0 - page 688. (Read 5805728 times)

hero member
Activity: 742
Merit: 500
excuse me for being lazy but I keep seeing a lot of talk about 5970 , ive been too busy to keep up with the conversation - but if someone could tell me whats going on in respect  the 5970 development I would really appreciate it

my 5970 gets 380 mhash per core in windows 7 with the ccc 11.8

is it possible to do better?

thanks in advance for filling me in!
Same hashrates as you except I am mining on linux. (My U is a little less than expected because I have p2pool as my secondary pool)
Code:
GPU 0:  72.5C 4349RPM | 380.7/379.8Mh/s | A:4693 R:243 HW:0 U: 5.01/m I: 8
GPU 1:  68.5C         | 377.9/377.6Mh/s | A:4644 R:241 HW:0 U: 4.95/m I: 8
hero member
Activity: 896
Merit: 1000
Buy this account on March-2019. New Owner here!!
excuse me for being lazy but I keep seeing a lot of talk about 5970 , ive been too busy to keep up with the conversation - but if someone could tell me whats going on in respect  the 5970 development I would really appreciate it

my 5970 gets 380 mhash per core in windows 7 with the ccc 11.8

is it possible to do better?

thanks in advance for filling me in!
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
On further inspection this code won't work...

Back to the drawing board.  Tongue
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
I haven't pushed it to the git tree. I have no idea if it works at all... since I don't even have a GPU that can mine at the moment still  Roll Eyes
Ok I've added a git branch called "reorder". If you git pull and then "git checkout reorder" you can try it.
legendary
Activity: 1666
Merit: 1000
CK - worth a git pull to test on linux machines as well?

None of mine are dual 5970 currently but that will soon change  Grin
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
Theoretically it should even fix card ordering of any sort, not just dual GPUs that are split up:


Here it is completely untested... so please test it  Wink
http://ck.kolivas.org/apps/cgminer/temp/cgminer.exe


EDIT: tested, doesn't work. Hold on...

Just use as per normal.
donator
Activity: 1218
Merit: 1079
Gerald Davis
Yes I understood that. I just didn't expect it was possible, but this extra debugging has shown me it is. I just need to actually code it up now.

That would be awesome and would certainly warrant a donation from any miner who uses multiple dual GPU cards.  Well certainly from the non-cheapo ones. Smiley
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
Yes I understood that. I just didn't expect it was possible, but this extra debugging has shown me it is. I just need to actually code it up now.
hero member
Activity: 807
Merit: 500
Hmmmm D&T... I was thinking that I can't fix the ordering, as that happens on a bios+mobo+os+driver+/- crossfire basis  Undecided

There is a way though... hmm but it would require running through all the ADL code first and then renumbering everything... hmmmmmm
* ckolivas hmms some more...

I think I have a way.
* ckolivas ponders.

BBIAW...
I think D&T's concern was that you assumed it was always A+C,B+D,E+F more than what order they displayed in.  Based on your acknowledgements RE: bios+mobo+os+driver+/-crossfire that isn't the case and you may be able to identify them appropriately regardless.  However, if you can and want to make them display in a logical order, more power to you.  Wink
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
I was trying to identify linked GPUs with this latest code to prevent frying a GPU by disabling the one that had the fan control while the one without the fan control was still burning.

Hmmmm D&T... I was thinking that I can't fix the ordering, as that happens on a bios+mobo+os+driver+/- crossfire basis  Undecided

There is a way though... hmm but it would require running through all the ADL code first and then renumbering everything... hmmmmmm
* ckolivas hmms some more...

I think I have a way.
* ckolivas ponders.

BBIAW...
donator
Activity: 1218
Merit: 1079
Gerald Davis

This is reassuring. Using my existing logic, cgminer should already be grouping A+C, B+D and E+F which corresponds with your layout. This should actually already be working. GPU 0 and GPU 2 should be showing the same fanspeed and so on. Is it not working?

It "does".  Just (at least in my instance) it seems weird it is
A+C
B+D
E+F

instead of
A+D
B+E
C+F

or
A+B
C+D
E+F

but this is the only rig that has a single different card "XFX Black Edition" so I wonder if that is making it "weird".  My other 14 5970s are all ATI branded reference. 

Quote
I'm trying to recall if you watercooled or something, because cgminer also relies on one card having a fancontrol while the other does not. Is there any way you have removed the fancontrol? Ultimately all I'm trying to do with this code is make the fan speed control work from the temps from both GPUs.

It is watercooled so there are no fans connected.  I didn't do anything to the card other than unplug the fan header. It does report fan speed (one per pair of GPUs).  I have GPU-fan set to 0% for all 6 cards in config file.  It reports some low RPM like 400 or something.  Weirdly that XFX bastard reports no fan speed (or temp) for either GPU.

Honestly I wish I had never got this XFX black edition.  The more I think about it the more likely I am to ebay it and grab another ATI branded reference card.

When I use windows remote desktop I lose all temp/fan/clock data so when I get home I will grab a screenshot of what cgminer shows when mining.

I will report w/ screenshot of cgminer mining, the data debug dump and the config file all in one post.  Hopefully if others do the same you can get enough data points.
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
Thanks very much for that D&T

You said:

A iBusNumber 10
B iBusNumber 14
C iBusNumber 9
D iBusNumber 13
E iBusNumber 5
F iBusNumber 6

and:
GPU #0 & GPU #2 = 2nd physical card (2nd expansion slot from CPU)
GPU #1 & GPU #3 = 3rd physical card (3rd expansion slot from CPU)
GPU #5 & GPU #6 = 1st physical card (1st expansion slot from CPU)

This is reassuring. Using my existing logic, cgminer should already be grouping A+C, B+D and E+F which corresponds with your layout. This should actually already be working. GPU 0 and GPU 2 should be showing the same fanspeed and so on. Is it not working?

I'm trying to recall if you watercooled or something, because cgminer also relies on one card having a fancontrol while the other does not. Is there any way you have removed the fancontrol? Ultimately all I'm trying to do with this code is make the fan speed control work from the temps from both GPUs.

If not, I could always remove the test for one having a fancontrol and the other not having and relying entirely on the bus numbers.
donator
Activity: 1218
Merit: 1079
Gerald Davis
For those on windows with 5970 or 6990 that are out of order, please run this like you would run cgminer, but with -T and stop it once it starts mining. Then please post the lines that look like this:

...

And then please describe the layout of where the GPUs of each gpu "twin" appears.

Code:
C:\bitcoin\cgminer-2.1.2>cgdebug -T
[2012-01-27 05:51:04] iAdapterIndex  0 strUDID PCI_VEN_1002&DEV_689C&SUBSYS_20421002&REV_00_8&36D7B016&0&004000100008A iBusNumber 10 iDeviceNumber 0 FunctionNumber 0 iVendorID 1002 strAdapterName  ATI Radeon HD 5900 Series
[2012-01-27 05:51:04] iAdapterIndex  2 strUDID PCI_VEN_1002&DEV_689C&SUBSYS_20421002&REV_00_8&D94A8A1&0&004000180008A iBusNumber 14 iDeviceNumber 0 iFunctionNumber 0 iVendorID 1002 strAdapterName  ATI Radeon HD 5900 Series
[2012-01-27 05:51:05] iAdapterIndex  4 strUDID PCI_VEN_1002&DEV_689C&SUBSYS_25421002&REV_00_8&21A460A4&0&002000100008A iBusNumber 9 iDeviceNumber 0 iFunctionNumber 0 iVendorID 1002 strAdapterName  ATI Radeon HD 5900 Series
[2012-01-27 05:51:05] iAdapterIndex  7 strUDID PCI_VEN_1002&DEV_689C&SUBSYS_25421002&REV_00_8&79EA6D1&0&002000180008A iBusNumber 13 iDeviceNumber 0 iFunctionNumber 0 iVendorID 1002 strAdapterName  ATI Radeon HD 5900 Series
[2012-01-27 05:51:05] iAdapterIndex 10 strUDID PCI_VEN_1002&DEV_689C&SUBSYS_30201682&REV_00_8&2239DA41&0&002000000008A iBusNumber 5 iDeviceNumber 0 iFunctionNumber 0 iVendorID 1002 strAdapterName  ATI Radeon HD 5900 Series
[2012-01-27 05:51:05] iAdapterIndex 13 strUDID PCI_VEN_1002&DEV_689C&SUBSYS_30201682&REV_00_8&376D29B3&0&004000000008A iBusNumber 6 iDeviceNumber 0 iFunctionNumber 0 iVendorID 1002 strAdapterName  ATI Radeon HD 5900 Series


One thing I can help decode is:
SUBSYS_20421002
SUBSYS_25421002
SUBSYS_30201682

The GPU-Z utility indicates the suffix 1002 is ATI and 1682 is XFX

What is interesting is I have 3 5970 and 3 different prefixes (2042, 2542, 3020).  Probably coincidence but one can hope.

Is it possible this is a GPU level serial #?
[2012-01-27 05:51:04] iAdapterIndex  0 strUDID PCI_VEN_1002&DEV_689C&SUBSYS_20421002&REV_00_8&36D7B016&0&004000100008A iBusNumber 10 iDeviceNumber 0 FunctionNumber 0 iVendorID 1002 strAdapterName  ATI Radeon HD 5900 Series

Remember on my Win7 workstation the card order isn't consistent.

In cgminer display:
Code:
GPU #0 & GPU #2 = 2nd physical card (2nd expansion slot from CPU)
GPU #1 & GPU #3 = 3rd physical card (3rd expansion slot from CPU)
GPU #5 & GPU #6 = 1st physical card (1st expansion slot from CPU)

In cgminer.conf:
Code:
"gpu-engine" : "Card2-GPU1,Card2-GPU2,Card3-GPU1,Card3-GPU2,Card1-GPU1,Card1-GPU2",

Hey ckolivas I just thought of something.  On two of my cards the system enumerates the first GPU of each card first and the the second GPU of each card but the third GPU is both GPU in a row.   So C1, C2, C1, C2, C3, C3 right?  Now other people have describe both methods (C1, C1, C2, C2, C3, C3  or C1, C2, C3, C1, C2, C3).

I am wondering if crossfire has something to do with the way Windows orders the card. The 5970 and 6990 have an internal crossfire bridge.  My understanding is the card is simply a PCIe switch which converts one physical PCIe slot into two seperate "virtual" PCIe slots.  The two GPU are then wired to that and have a cross fire bridge hardwired between them.  Logically it is no different than using a 2:1 PCIe expansion adapter and plugging into 2 5870s.   I wonder if I have crossfire accidentally turned on for just one of my cards thus 2 cards are ordered one way and the last card is ordered differently.  I can't check remotely but it the only thing I can think of to explain the strange combination of both GPU ordering patterns.

That might explain how/why people have one of two different ordering patterns (A, B, C, A, B, C) or (A, A, B, B, C, C).  One pattern is used when crossfired, one when not?  Maybe it has to do w/ what the cross fire status was when windows was first installed?  I am rambling now ... Smiley

TL/DR maybe when people post their ordering data they should also check crossfire status in either GPU-Z or CCC.
legendary
Activity: 4634
Merit: 1851
Linux since 1997 RedHat 4
one tiny suggestion, you could make the api socket work a lot faster after a restart by setting SO_REUSEADDR with setsockopt.  I do not know if this might have negative effects on systems other linux, but it works fine here and makes socket always open on first try (no more "API bind to port %d failed - trying again in 15sec", which I was seeing quite a lot).

doubt you actually need the code from me heh.  but in case, at line 889 of api.c, after sock is returned from socket()..

int optval_reuseaddr = 1;
setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, &optval_reuseaddr, sizeof(optval_reuseaddr));

or something like that..  makes life nicer.

Thanks I'll probably put SO_REUSEADDR in next time I'm making changes.
(but I'll try test a few possible issues with it first in case it causes something else)

The current code doesn't need it if you quit from the API, but if you quit directly from cgminer (pressing 'q') the socket is killed and thus doesn't clean up (i.e. doesn't get to call shutdown() )
Though really I should make the socket thread shutdown tidily by calling shutdown() also when you 'q' cgminer, except none of the other threads do, so I thought it sorta pointless to add the extra interrupt code.
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
Thanks.

Here is a cgdebug.exe special build that outputs extra information about each device.

http://ck.kolivas.org/apps/cgminer/temp/cgdebug.exe

For those on windows with 5970 or 6990 that are out of order, please run this like you would run cgminer, but with -T and stop it once it starts mining. Then please post the lines that look like this:

Code:
[2012-01-22 17:31:58] lpAdapterID 20016752 iBusNumber 1 iDeviceNumber 0 iFunctionNumber 0 iVendorID 4098 strAdapterName AMD Radeon HD 6900 Series  strDisplayName :0.0 lpInfo.strUDID  256:26393:4098:12583:5762 

And then please describe the layout of where the GPUs of each gpu "twin" appears.

Thanks!
full member
Activity: 210
Merit: 100
full member
Activity: 210
Merit: 100
...All in all it's a mindfuck of epic proportions.
Never did any GPU programming and now I hope I won't ever have to.
If the lane IDs are getting screwed up that's likely due to some insane PCIE line multiplexing and redriving being done by some board designs...

There, Conman, a little something has just been sent your way.
-ck
legendary
Activity: 4088
Merit: 1631
Ruu \o/
Does his mean you don't need another Linux/6990 box?
Correct, thanks for the offer though. I just happened to bug someone online and get the access I needed. Linux is working mostly ok now with these dual card GPUs. Windows on the other hand... as you can see.
donator
Activity: 1218
Merit: 1079
Gerald Davis
Does AMD API exposed a card serial # or any other unique identifying information?
Nope nope, as I've said numerous times before this is the most unsatisfying part of it.
The opencl information is useless for determining which card is which. Furthermore if you have 2 monitors connected to a single GPU, it will come up as 2 unique opencl devices.
Then motherboards decide to order cards backwards sometimes with the pci bus id order being the opposite of the device order we end up getting.
Some motherboards do not order their PCIE lanes in numerical order as well, with lanes going 1,3,2 or other randomness.
Then the ATI Display Library gives unique adapter ID information that has absolutely nothing in common with the opencl devices.
There are also unique "thermal devices" in the ADL which had the opportunity to designate GPU 0 and GPU 1 in shared devices (like 6990) but instead they simply come up as unique devices.
Shared GPUs in single cards also do not have a single identifying feature whatsoever to say they're on the same card.
Then of course, windows does something different to linux, and osx doesnt even have an ADL.
All I can do is enumerate them in the order they appear and *hope* they align.
Then I use surrogate markers with circumstantial evidence that the GPUs are on the same card.
As far as I'm concerned, getting any of these bastards behaving in concert is somewhat of a miracle.
All in all it's a mindfuck of epic proportions.

I agree.  Sad AMD doesn't provide a serial # via the OpenCL driver.  Then at least one could simply explicitly declare everything via config file

Like I said via trial and error I got it to work and it is only on my Windows workstation so I am not that weird.  It just seems "incomplete" to me that AMD doesn't provide better enumeration tools especially via the heterogeneous nature of OpenCL devices.
Jump to: