Skip to content
  • Iago Toral's avatar
    i965: Ensure FS execution in presence of atomic buffers · 9bbdd0ed
    Iago Toral authored and Samuel Iglesias Gonsálvez's avatar Samuel Iglesias Gonsálvez committed
    
    
    On Haswell we need to set the UAV_ONLY WM state bit when there are no colour
    or depth buffer writes and on all hardware we should set the early
    depth/stencil control field to PSEXEC unless early fragment tests are enabled
    to make sure that the fragment shader is executed regardless of whether
    per-fragment tests pass or not as the spec requires.
    
    So far we have been doing this for images only, but we should apply the same
    treatment to all side effectful scenarios. Suggested by Curro.
    
    This is not strictly required for compliance with the original
    ARB_shader_atomic_counters extension, it's only necessary to get the execution
    semantics specified in GL4.2+ right.
    
    v2:
    - Mark active_fs_has_side_effects as constant. (Curro)
    - Mention that this is only only necessary to get the execution semantics
    specified in GL4.2+ right. (Curro)
    
    Reviewed-by: default avatarFrancisco Jerez <currojerez@riseup.net>
    9bbdd0ed