Benchmarking

This section describes how to measure the performance of Chromium's network layer, command packer/unpacker and rendering.

Network Performance

Network performance can be measured with the npclient and npserver programs. Here's a simple example:

The npclient and npserver programs mimic Chromium's client/application and server/network nodes but are stripped down to just test networking functions.

The npserver program simply receives messages sent to it by the npclient program.

The npclient program takes a variety of command line options to specify the number and size of buffers to send to the servers. You can test one-to-many network communication by starting several npserver instances and specifying the host names to npclient.

For example, here's how one might test network performance to two rendering nodes in a cluster:

Both npclient and npserver take a few simple command line options. To see them, specify the -h option to either program.

Packing/unpacking Performance

The packperf program measures the rate at which glVertex commands can be processed by the packer.

XXX additional measurements with packertest framework???

Rendering Performance

The spheres program is a handy program for measuring triangle throughput in Chromium. It can be used in sort-first, sort-last, or other configurations.

Basically, spheres draws a user-specified number of spheres (arranged in a circle), each with a user-specified number of triangles. The spheres may be rendered as immediate-mode vertex arrays, display lists or as vertex arrays in vertex buffer objects (with GL_ARB_vertex_buffer_object).

Here's an example of running the spheres demo in a sort-last configuration:

Here's an example of running spheres in a tilesort configuration:

The spheres program accept several command-line parameters:

   -size N     specifies number of parallel instances
   -rank I     specifies instance's rank in [0..N-1]
   -swap       do SwapBuffers
   -clear      do glClear
   -s N        specifies number of spheres per frame
   -t N        specifies approximate number of triangles per sphere
   -f N        specifies number of frames to render before exiting
   -v          render with vertex buffer objects
   -d          render with display lists
   -h          print help