Headless returns false for both GPUs

I'm iterating over the list of returned MTLDevices on a 2013 Mac Pro and both GPUs return false for their headless property. Is this accurate? I thought only 1 GPU had access to displays.


The code


let devices: [MTLDevice] = MTLCopyAllDevices()        
//...
          for metalDevice: MTLDevice in devices {
                if metalDevice.headless == true {
                    print("headless")
                    headlessDevice = metalDevice
                }
                else {
                    print("it has a head")
                }
            }



I could just pick the one not returned by MTLCreateSystemDefaultDevice but is there a better way of picking the secondary GPU?

I confirm your result... isHeadless returns false for the two D500 of my MacPro 2013.

I've just post a bugreport.

Corrected in beta 2 !

Good to hear. I'm was just downloading the new Beta to see if it was fixed.

hmm... no... sorry

My mistake... I've bypassed the headless test code in my sample, and forgot to reactivate it...

So it didn't work at all : the "headless" property continue to return NO for all the devices.

Sorry again...My radar is still open.



Anyway the barrier problem was corrected.

Hm. I just ran a test using Xcode 7b2 (7A121l) and both of my D700s report they are not headless.

Just for good measure, I checked after the update to 10.11 (15A204h) that just posted and still no difference. Both claim not to be headless and both claim to not be low power. But at least the name of each device is now "AMD Metal" instead of "Metal", so there was some progress. =]

It is somewhat logical that none of your D700s is a lowPower device... 😉


I missed the name change.

Could there be some sort of SLI/Crossfire thing going on? If they're sharing rendering duties, could that explain why neither are headless?


Wait, "headless" means there's not a monitor attached, right?

The cards do support Crossfire in Windows but not OS X. AFAIK this hasn't changed in 10.11. That would be a pretty cool surprise if so.


The headers define headless as: "On systems that include more that one GPU, this will return YES for any device that does not support any displays. Only available on Mac OS X."

bummer. I finally was able to install beta 2 and you're correct. Neither GPU is listed as headless.

Headless returns false for both GPUs
 
 
Q