Sunday, September 12, 2010

Multithreaded Resource Preparation

I gave myself three weeks to write our chapter on multithreaded resource preparation. I manged to come in right on time even with Labor Day weekend in the mix. I am exhausted.

This is not an introduction to multithreading but rather how to apply multithreading to improve the performance and responsiveness of a 3D engine by moving I/O, CPU intensive algorithms (think triangulation, vertex cache optimization, etc), and renderer resource creation to worker threads.

The chapter highlights include:
  • Brief review of hardware parallelism
    • CPU: Pipelining, superscalar, SIMD, multithreading, Hyper-Threading, multi-core.
    • GPU: Pipelining, shaders, CPU/GPU parallelism.
  • Architectures for multithreaded resource preparation
    • Using message queues to communicate between threads [code contributed by Kevin Ring].
    • Coarse grain threads [code].
    • Pipeline of fine grain threads.
  • Multithreading with OpenGL
    • One GL thread, multiple worker threads.
    • Multiple threads, one context.
    • Multiple threads, multiple contexts.
      • Shared contexts.
      • CPU vs GL synchronization. Fences [code].
Also, here's a list of resources on OpenGL multithreading that I found useful:

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.