nine: potential optimization ideas
Looking at CSMT CPU usage, there's a couple things that would significantly improve performance:
- defer all destructors (textures+buffers) using CSMT
- this would mean that all the refcount subtraction occurs in CSMT, meaning that a huge amount of refcounting could be eliminated; in Left 4 Dead 2, these account for about 25% of all CPU usage by CSMT
- (potentially) rework userbuf constant upload to use the threaded context uploader, which would reduce memory usage
- not sure if viable given that this is copying regions into the buffer, so they'd have to be flattened ahead of time