Identifying and Solving Performance Issues

OpenGL Driver Monitor is not the primary tool for analyzing performance issues in an OpenGL application. It’s the backup tool that experts use when Instruments and OpenGL Profiler don’t reveal the cause of a performance problem. This chapter assumes that you have already used Apple’s other tools to analyze your OpenGL application.

The strategies described here can help you identify the most common problems that occur in OpenGL applications. Keep in mind that analyzing difficult performance problems is more of an art than a science. Although you’ll want to start with these basic strategies, you’ll need to devise additional ones tailored to the type of problem you see, and to whether you are trying to solve a driver issue or an application one.

Checking for Best Practices

Before you begin to use OpenGL Driver Monitor as an analysis tool, it’s a good idea to check your code to see if you are following the most recent best practices for using OpenGL. See:

Checking Data Transfer Rates

To check data transfer rates, monitor the following:

Checking for Suboptimal Surface and Texture Paging

You need to make sure that your application is not paging texture and surface data unnecessarily. When it does page, you should use the accelerated graphics port (AGP pathway, which is also known as DMA transfer). Non-AGP transfers slow performance. You can check for less optimal paging by looking at these parameters:

Non-AGP transfer is acceptable only if you must reorder data or align it. If possible, use this type of data transfer at initialization time and not during a rendering loop.

If your application has a lot of paging activity, whether it’s AGP or non-AGP, consider using framebuffer objects.