summaryrefslogtreecommitdiffstats
path: root/src/compiler/nir/glsl_to_nir.cpp
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2016-05-13 16:41:13 -0700
committerKenneth Graunke <[email protected]>2016-05-14 00:18:37 -0700
commit59156b2e96315910f1e929c14c5b25ce88f75911 (patch)
treea69391012a086db66ffc5d77b9d6008a57ab72d5 /src/compiler/nir/glsl_to_nir.cpp
parent9f8867d8779c7f402b9614ec334924aafc58cd64 (diff)
i965: Fix undefined df bits in brw_reg comparisons.
Commit 5310bca024f77da40ea6f4c275455f9cb0528f9e added a new "double df" field to the brw_reg struct, adding an extra 4 bytes of data that isn't usually initialized (or may contain irrelevant garbage if the struct is mutated). This means that it's no longer safe to memcmp(). Instead, add a brw_regs_equal() function which ignores the extra df bits unless they matter. To keep the implementation cheap, we wrap the first set of fields in a union/struct so that we can use a single DWord comparison. v2: Drop unnecessary casts (caught by Francisco Jerez). Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Francisco Jerez <[email protected]> Reviewed-by: Samuel Iglesias Gonsálvez <[email protected]>
Diffstat (limited to 'src/compiler/nir/glsl_to_nir.cpp')
0 files changed, 0 insertions, 0 deletions