http://bugs.winehq.org/show_bug.cgi?id=11674
--- Comment #313 from Stefan Dösinger stefan@codeweavers.com 2013-09-04 13:55:50 CDT --- (In reply to comment #312)
It'd be nice to get the updated buffer strategy change upstream under an optional switch/regkey that NVIDIA users can enable, as it's going to hit optimizations in the driver code that other paths cannot in conjunction with NVIDIA's own threading model.
I'd be very unhappy with a registry key to control this. There seems to be no agreement among driver vendors which buffer update mechanism is preferred. You say glBufferSubData, Intel says glMapBufferRange. If the ARB makes a statement about which path is preferred, I'm happy to follow their recommendation. Otherwise this is means burdening users with a driver implementation difference they really shouldn't have to bother about and that shouldn't even exist in the first place.
In CrossOver I have a hack that detects the presence of the Nvidia driver and __GL_NV_THREADED_OPTIMIZATIONS flag. That would work a bit better, because at least the users don't have to worry about it.
In my command stream I'm using glBufferSubData for buffer updates. That's not due to my CS design, but because right now we cannot draw from mapped buffers. GL_ARB_buffer_storage addresses this problem, so the long term idea is to use it if available and fall back to glMapBufferRange otherwise.