Different values for maxTotalThreadsPerThreadgroup ?

I've just started playing around with Metal. I've written small sample programs to explore it.


One strange thing I've noticed: the call to maxTotalThreadsPerThreadgroup returns different

values in the 2 different apps (both are very simple apps, just to play with the API).

So

NSLog(@"max TotalThreadsPerThreadgroup = %lu", (unsigned long)[m_Kernel maxTotalThreadsPerThreadgroup]);

returns "160" for one app, and "512" for the other, on the exact same device. What could be causing this difference?

160 is not a common value for a threadgroup size !

Are you using a multi-GPU computer ? Perhaps a laptop with integrated GPU + a discrete GPU ?

Is there more than one device (check with MTLCopyAllDevices) ?

And in this case, what is the value returned by lowpower property of each of the device ?


Just a guess, but it is possible that your app activates one or the other device...

The device is an iPhone 6, running iOS 8.3 (12F70).

Different values for maxTotalThreadsPerThreadgroup ?
 
 
Q