iOS 14 device autorotation blocked by Metal

Dear Apple Engineers,

This is a strange bug of iOS 14 beta 3. The following line added to any UIViewController hangs auto rotation *forever* in XCode debugger.
Code Block
public static let metalDevice:MTLDevice? = MTLCreateSystemDefaultDevice() //Freezes iOS 14 device autorotation forever

Now even if you remove this line, nothing happens. The device will never autorotate when connected to XCode debugger. It however autorotates when not connected to debugger. The only way is to remove the line, compress it in zip file, delete the project and uncompress the zip file and build again.

What is the known workaround? I shall be filing bug report soon.


Answered by Devgeek in 624977022
I found that setting GPU Frame Capture to "Disable" or "Metal" fixes it. The default choice in Scheme option is "Automatically Enabled" which is the culprit.
Accepted Answer
I found that setting GPU Frame Capture to "Disable" or "Metal" fixes it. The default choice in Scheme option is "Automatically Enabled" which is the culprit.
iOS 14 device autorotation blocked by Metal
 
 
Q