mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
intel/compiler: Cast reg types explicitly
Makes coverity happier.
CID: 1416799
Fixes: c1ac1a3d25 (i965: Add a brw_hw_type_to_reg_type() function)
Reviewed-by: Matt Turner <mattst88@gmail.com>
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
This commit is contained in:
parent
c261bc11e6
commit
5dd072380a
1 changed files with 2 additions and 2 deletions
|
|
@ -111,13 +111,13 @@ brw_hw_type_to_reg_type(const struct gen_device_info *devinfo,
|
|||
{
|
||||
if (file == BRW_IMMEDIATE_VALUE) {
|
||||
for (enum brw_reg_type i = 0; i <= BRW_REGISTER_TYPE_LAST; i++) {
|
||||
if (gen4_hw_type[i].imm_type == hw_type) {
|
||||
if (gen4_hw_type[i].imm_type == (enum hw_imm_type)hw_type) {
|
||||
return i;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (enum brw_reg_type i = 0; i <= BRW_REGISTER_TYPE_LAST; i++) {
|
||||
if (gen4_hw_type[i].reg_type == hw_type) {
|
||||
if (gen4_hw_type[i].reg_type == (enum hw_reg_type)hw_type) {
|
||||
return i;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue