You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Besides the main frame in the game loop, a game engine can have asynchronous tasks, threads, or GPU-related work during a frame. Currently, puffin categorizes all scopes under the same puffin frame, which is a problem when it comes to those three situations.
GPU work is executed in parallel to the frame.
Asynchronous tasks might take multiple frames to complete.
Threads are not dependent on frames at all.
This results in a problem described in #59 where the frame time of GPU and CPU is added up when in reality it should not be and where the timing of CPU and GPU need to be aligned. In some of Embark's internal code bases, we have large spikes for threads that take a significant amount of time which in turn make the slowest frame summary window dysfunctional because the normal frames are relatively low compared to them.
Potential suggested solutions:
Separate timelines of CPU/GPU with potentially relating both timelines together. Potentially do this by reporting CPU and GPU to different places. Then use two different profilers UIs to visualize them.
Simple effort to go around the frame time calculation is to only measure the main thread.
The text was updated successfully, but these errors were encountered:
TimonPost
changed the title
Tracking: Make puffin integrate with GPU, async, thread profiling data.
Tracking: Make puffin integrate with GPU, async tasks, thread profiling data.
Oct 19, 2022
TimonPost
changed the title
Tracking: Make puffin integrate with GPU, async tasks, thread profiling data.
Tracking: Make puffin integrate with GPU, async tasks, and thread profiling data.
Oct 19, 2022
It's a problem than I encounter in my test with puffin-test-app and is threaded loading simulation.
Would it be possible to differentiate threads at puffin level ?
Some would be marked to frame tick, some would be marked to be frame tick independent.
Then puffin and ui could handle it ... I don't know how ^^
On your project(s), only main thread is sync on frame ? Or few other thread can be synchronized on frames ?
Concerning GPU, compute tasks are unsynchronized to frame, be display tasks are generally synchronized to frame (but with a shitf), no ?
Concerning UI, I have seen some profiler than can display multiple frames continuously in the Flamegraph. It's a possible solution for display management ?
Believe the timeline simply just needs to show continuous time, and where users of puffin can add multiple frame scopes with the "main" frame being what is typically blocking the overall frame time on a main thread, and "GPU" frame time being another common usage. So you can jump between frames and focus on them, and show what are stalls / histogram for them, but you can also scroll freely across time.
Besides the main frame in the game loop, a game engine can have asynchronous tasks, threads, or GPU-related work during a frame. Currently, puffin categorizes all scopes under the same puffin frame, which is a problem when it comes to those three situations.
This results in a problem described in #59 where the frame time of GPU and CPU is added up when in reality it should not be and where the timing of CPU and GPU need to be aligned. In some of Embark's internal code bases, we have large spikes for threads that take a significant amount of time which in turn make the slowest frame summary window dysfunctional because the normal frames are relatively low compared to them.
Potential suggested solutions:
The text was updated successfully, but these errors were encountered: