+ /* The hardware seems to have issues with having a two different format
+ * views of the same texture in the sampler cache at the same time. It's
+ * unclear exactly what the issue is but it hurts glCopyImageSubData
+ * particularly badly because it does a lot of format reinterprets. We
+ * badly need better understanding of the issue and a better fix but this
+ * works for now and fixes CTS tests.
+ *
+ * TODO: Remove this hack!
+ */
+ brw_emit_pipe_control_flush(brw, PIPE_CONTROL_CS_STALL |
+ PIPE_CONTROL_TEXTURE_CACHE_INVALIDATE);
+