I know. I have been struggling to do just that for well over a week
I definitely get different results:
// with hint (correct result but slow) INFO: > Vendor: Google Inc. (Apple) INFO: > Renderer: ANGLE (Apple, ANGLE Metal Renderer: Apple M2 Max, Version 13.4 (Build 22F2073)) INFO: > Version: OpenGL ES 3.0.0 (ANGLE 2.1.20982 git hash: f3e3810b917c) INFO: > GLSL: OpenGL ES GLSL ES 3.00 (ANGLE 2.1.20982 git hash: f3e3810b917c)
// without hint (wrong result but crazy fast) INFO: > Vendor: Google Inc. (Apple) INFO: > Renderer: ANGLE (Apple, Apple M2 Max, OpenGL 4.1 Metal - 83.1) INFO: > Version: OpenGL ES 3.0.0 (ANGLE 2.1.20982 git hash: f3e3810b917c) INFO: > GLSL: OpenGL ES GLSL ES 3.00 (ANGLE 2.1.20982 git hash: f3e3810b917c)
I also noticed while stepping through the code that without the hint, the glfw internal function
chooseEGLConfig gets only 1 buffer config to choose from. With the hint it gets 10 and picks one…
After more research, it is definitely not a CPU/GPU issue. Using the hint, seems to limit the framerate no matter whether I call
glfwSwapInterval(0) or not. So it is “slower” in the sense that it slowly drifts down to 60fps, but neither CPU nor the GPU are doing much.
I probably now need to investigate the Google Angle code to figure out why is there such a restriction
Is the framerate issues because of V-sync or similar? I don’t know anything about these tools that you use, but if when enabling the Metal backend, it might choose a different image presentation mode than for OpenGL; the issue might simply be that when presenting or acquiring a new swap chain image (or the Metal equivalent), the CPU waits on the GPU, and the GPU is limited in its selected mode to a certain framerate.
glfwSwapInterval(0) disables V-Sync and I did check that Angle makes the proper call into Metal to disable V-Sync which I detailed in this Angle Forum post.