Resource sharing implementation conflicts with aux-state tracking
The following discussion from !7038 (closed) should be addressed:
-
@anholt commented in a discussion: resources are associated with screens, not contexts. so if resources are going to have flags for needing some flush to happen to them (which are modified by contexts on different threads), then you need some sort of protection on those flags to avoid data races between threads. Or you need the flag to be context-local, but then you can't do anything at resource deletion time since that is not associated with a context.