frameretrace branch

Mark Janes edited this page Jul 30, 2018 · 15 revisions

The frameretrace branch of Apitrace is an effort to create a frame-analysis UI based on Apitrace. Limiting retrace to a single frame or group of frames allows the user to repeatedly and rapidly play the frame's calls without retracing the whole trace file.

The existing qapitrace tool provides access to many aspects of a trace file. Unfortunately, the command-line interface to the retrace tool limits the usability of qapitrace. Accessing details for a frame or api call results in a full playback of the trace, which can be time consuming. The process of debugging or optimizing a trace often requires exploration of the trace file, which is hampered by the slow retrace.

The frameretrace UI works with a server process, which exposes a socket to the UI. This process is either created by the frametrace UI (local operation) or can be spawned manually by the user. The server process accepts retrace commands over the socket, and provides the results back to the UI. When the server process is instructed over the socket, it opens the trace file and retraces all commands up to the specified frame. As the communication is socket based, the frameretrace UI can be on a different machine to the server process, which is useful for work with embedded systems or when working with many systems on a network.

The UI commands the server process to retrace from the beginning of the frame to a specified draw call and provide results (framebuffer images, bound state, etc) back to the UI. This is generally safe to do because of the repeatable nature of GL commands within a frame boundary.

The workflow for frameretrace is intended to be similar to GPA Frame Analyzer for DirectX, a widely used frame debug/optimization tool. Some descriptions of Frame Analyzer features can be seen here:

http://gpa.helpmax.net/en/intel-graphics-performance-analyzers-help/intel-gpa-frame-analyzer/introduction-to-the-intel-gpa-frame-analyzer/

I've made an effort to list out the main use cases for a fully-featured frame analysis tool. The core workflow is:

  • Explore renders, shaders, state, and textures in a frame. Use GPU metrics to identify which renders consume the most time.

  • Alter shaders, state, uniforms, and texture settings for renders, and see the result in updated metrics and framebuffer images.

  • Analyze a single frame on both windows and linux, to identify and root cause performance deltas between platforms.

The feature backlog for FrameRetrace is tracked here: https://www.pivotaltracker.com/n/projects/1471332

building frameretrace

troubleshooting

frameretrace use cases

screen shots

high level design

You can’t perform that action at this time.
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.
Press h to open a hovercard with more details.