https://bugs.freedesktop.org/show_bug.cgi?id=106302
Bug ID: 106302 Summary: [radeonsi] Garbage content when accessing a texture in multiple shared EGL contexts Product: Mesa Version: 17.2 Hardware: x86-64 (AMD64) OS: Linux (All) Status: NEW Severity: normal Priority: medium Component: Drivers/Gallium/radeonsi Assignee: dri-devel@lists.freedesktop.org Reporter: seb@vestigecounty.com QA Contact: dri-devel@lists.freedesktop.org
Created attachment 139204 --> https://bugs.freedesktop.org/attachment.cgi?id=139204&action=edit Isolated test case
Summary: ======== On radeonsi, when performing an "asynchronous texture upload" (that is, a texture upload on a secondary thread and secondary shared EGL context) the produced texture is not usable on the main thread (contains garbage).
Steps to reproduce: =================== 1. Create an EGL context (with its own pbuffer surface) and make it current on Thread 1. 2. Create another EGL context (with its own pbuffer surface) and make it current on Thread 2. 3. Generate and upload a texture on Thread 2. 4. When Thread 2 is finished, pass the texture name to Thread 1. 5. Draw a textured quad on Thread 1 using the texture passed from Thread 2.
Expected behavior: ================== Valid texture content in pbuffer surface of Thread 1.
Actual behavior: ================ Garbage is observed.
Behavior is observed in stock mesa in Ubuntu 17.10. Bug is not repro with software renderer or the i915 driver. Please use the attached cpp file to reproduce.