Capturing GPU frame: "no gpu workload detected"?

I am trying to debug my Metal app on OSX, and when I press the camera icon to grab a GPU frame, it crashes with a SIGABRT and this error message up top in XCode. What does that mean? This is the first time in a while that I'm working with this app -- I never had a problem capturing GPU frame before.


The console has a lot of output, but this is the start of it:


2018-02-10 18:11:57.794592-0600 XX[72261:9637722] -[_MTLLibrary newExternFunctionWithName:]: unrecognized selector sent to instance 0x60600030a9a0

2018-02-10 18:11:57.797645-0600 XX[72261:9637722] [General] An uncaught exception was raised

2018-02-10 18:11:57.797685-0600 XX[72261:9637722] [General] -[_MTLLibrary newExternFunctionWithName:]: unrecognized selector sent to instance 0x60600030a9a0

2018-02-10 18:11:57.797888-0600 XX[72261:9637722] [General] (

0 CoreFoundation 0x00007fff875ca57b __exceptionPreprocess + 171

1 libobjc.A.dylib 0x00007fff9c9a91da objc_exception_throw + 48

2 CoreFoundation 0x00007fff8764af14 -[NSObject(NSObject) doesNotRecognizeSelector:] + 132

3 CoreFoundation 0x00007fff8753dc93 ___forwarding___ + 1059

4 CoreFoundation 0x00007fff8753d7e8 _CF_forwarding_prep_0 + 120

5 libMTLInterpose.dylib 0x0000000101b63b61 ___ZL19MTLHarvestResourcesP26MTLHarvesterRuntimeStreamsPU21objcproto10MTLLibrary11objc_objectRKNSt3__13setIU8__strongPU22objcproto11MTLFunction11objc_objectNS3_4lessIS7_EENS3_9allocatorIS7_EEEEj_block_invoke + 459

6 MetalTools 0x000000010292ae83 -[MTLToolsPointerArray enumeratePointersUsingBlock:] + 272

7 libMTLInterpose.dylib 0x0000000101b528de

Replies

This certainly shouldn't be happening. Can you file a bug & attach your app so that we can investigate? Any idea what changed in your app or your system config since you last captured successfully?


Cheers,

Seth.

OK I filed a bug (37579251), but after I posted this, I noticed that there are like 4 other posts on this forum saying that they get crashes when capturing a GPU frame on Sierra too -- so hopefully someone there is already aware of this? Sounds like a bug was introduced in a recent Sierra update maybe?

Why is my reply from FIVE DAYS ago still being moderated? What has happened to you Apple.


OK I filed a bug, but after I posted this, I noticed that there are like 4 other posts on this forum saying that they get crashes when capturing a GPU frame on Sierra too -- so hopefully someone there is already aware of this? Sounds like a bug was introduced in a recent Sierra update maybe?


I hope this gets fixed sooner than later -- it severely hampers the ability to debug Metal apps if you don't have a GPU frame capture. And thanks to the decision to kill off Final Cut Pro 7 some of us won't be updating to High Sierra anytime soon....

Tip: don't add links to your posts. These will be moderated and it takes ages.


I haven't been able to go a reliable GPU capture with Xcode 9. It kinda worked with Xcode 8 but now it's a crapshoot.

Ok but my post doesn't have a link. I listed the number for the bug I filed. Don't do that either boys and girls. That moderation thing is a joke, man. I have to moderate one of my sites and I never let something go more than a couple of hours.


Great -- Apple's response to my bug report was "Update to High Sierra, the newest XCode beta". The whole point of my bug report was that I can't update to High Sierra, and that this was something that was working fine in Sierra until they broke it in the last update! Sheesh.

Sigh -- got a response on my bug report. Apple says they have no intention of fixing the bug for Sierra, after they broke it when it was working fine. No wonder these forums are a ghost town if this is how you guys treat your developers now.