compiler: add ACCESS_STREAM_CACHE_POLICY

radeonsi will use this.

Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
This commit is contained in:
Marek Olšák
2019-07-31 21:16:12 -04:00
parent 902dd50cf0
commit 9fb2fd0b43
2 changed files with 6 additions and 0 deletions

View File

@@ -1549,6 +1549,9 @@ static unsigned get_cache_policy(struct ac_nir_context *ctx,
cache_policy |= ac_glc;
}
if (access & ACCESS_STREAM_CACHE_POLICY)
cache_policy |= ac_slc;
return cache_policy;
}

View File

@@ -736,6 +736,9 @@ enum gl_access_qualifier
* a lack of ACCESS_COHERENT and ACCESS_VOLATILE.
*/
ACCESS_CAN_REORDER = (1 << 6),
/** Use as little cache space as possible. */
ACCESS_STREAM_CACHE_POLICY = (1 << 7),
};
/**