diff options
author | Kenneth Graunke <[email protected]> | 2016-05-13 16:41:13 -0700 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2016-05-14 00:18:37 -0700 |
commit | 59156b2e96315910f1e929c14c5b25ce88f75911 (patch) | |
tree | a69391012a086db66ffc5d77b9d6008a57ab72d5 /src/compiler | |
parent | 9f8867d8779c7f402b9614ec334924aafc58cd64 (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')
0 files changed, 0 insertions, 0 deletions