summaryrefslogtreecommitdiffstats
path: root/src/intel/compiler/brw_fs.cpp
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2017-08-21 18:42:41 -0700
committerJason Ekstrand <[email protected]>2017-11-07 10:37:52 -0800
commitb299ded02eccfa94aede65086bd1ad254aaa5180 (patch)
treedac5963f2b20449b08cbca5d0c521fd938bac9f4 /src/intel/compiler/brw_fs.cpp
parent103081c9a9912a11b47077b8e25efdbbb3d65e10 (diff)
intel/fs: use pull constant locations to check for first compile of a shader
Before, we bailing in assign_constant_locations based on the minimum dispatch size. The more direct thing to do is simply to check for whether or not we have constant locations and bail if we do. For nir_setup_uniforms, it's completely safe to do it multiple times because we just copy a value from the NIR shader. Reviewed-by: Iago Toral Quiroga <[email protected]>
Diffstat (limited to 'src/intel/compiler/brw_fs.cpp')
-rw-r--r--src/intel/compiler/brw_fs.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/intel/compiler/brw_fs.cpp b/src/intel/compiler/brw_fs.cpp
index c2907bf40b0..71fd8bf2f06 100644
--- a/src/intel/compiler/brw_fs.cpp
+++ b/src/intel/compiler/brw_fs.cpp
@@ -1956,8 +1956,10 @@ void
fs_visitor::assign_constant_locations()
{
/* Only the first compile gets to decide on locations. */
- if (dispatch_width != min_dispatch_width)
+ if (push_constant_loc) {
+ assert(pull_constant_loc);
return;
+ }
bool is_live[uniforms];
memset(is_live, 0, sizeof(is_live));