Module: Mesa
Branch: main
Commit: 46d98a71ef89e53223abb5febfb3dc76325e4c09
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=46d98a71ef89e53223abb5febfb3dc76325e4c09

Author: Rohan Garg <[email protected]>
Date:   Thu Nov 30 19:59:19 2023 +0100

intel/compiler: use the proper enum type to store the op

Signed-off-by: Rohan Garg <[email protected]>
Reviewed-by: Kenneth Graunke <[email protected]>
Reviewed-by: Lionel Landwerlin <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26432>

---

 src/intel/compiler/brw_fs_nir.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/intel/compiler/brw_fs_nir.cpp 
b/src/intel/compiler/brw_fs_nir.cpp
index afb6a499327..13386ec40a1 100644
--- a/src/intel/compiler/brw_fs_nir.cpp
+++ b/src/intel/compiler/brw_fs_nir.cpp
@@ -4446,7 +4446,7 @@ fs_visitor::nir_emit_intrinsic(const fs_builder &bld, 
nir_intrinsic_instr *instr
                   fs_reg(), srcs, SURFACE_LOGICAL_NUM_SRCS);
       } else {
          unsigned num_srcs = info->num_srcs;
-         int op = lsc_aop_for_nir_intrinsic(instr);
+         enum lsc_opcode op = lsc_aop_for_nir_intrinsic(instr);
          if (op == LSC_OP_ATOMIC_INC || op == LSC_OP_ATOMIC_DEC) {
             assert(num_srcs == 4);
             num_srcs = 3;
@@ -6390,7 +6390,7 @@ void
 fs_visitor::nir_emit_global_atomic(const fs_builder &bld,
                                    nir_intrinsic_instr *instr)
 {
-   int op = lsc_aop_for_nir_intrinsic(instr);
+   enum lsc_opcode op = lsc_aop_for_nir_intrinsic(instr);
 
    fs_reg dest = get_nir_def(instr->def);
 

Reply via email to