Mesa (master): i965: Add switch cases for ir_unop_noise, which should have been lowered.

Eric Anholt anholt at kemper.freedesktop.org
Fri Sep 10 02:51:11 UTC 2010


Module: Mesa
Branch: master
Commit: 6ef5f212343c0557c4fca272d8236226c1a7c87a
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=6ef5f212343c0557c4fca272d8236226c1a7c87a

Author: Eric Anholt <eric at anholt.net>
Date:   Thu Sep  9 19:49:58 2010 -0700

i965: Add switch cases for ir_unop_noise, which should have been lowered.

Fixes compiler warnings.

---

 src/mesa/drivers/dri/i965/brw_fs.cpp               |    4 ++++
 .../dri/i965/brw_fs_channel_expressions.cpp        |    3 +++
 2 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp
index c23e7ce..cf5c521 100644
--- a/src/mesa/drivers/dri/i965/brw_fs.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs.cpp
@@ -753,6 +753,10 @@ fs_visitor::visit(ir_expression *ir)
       assert(!"not reached: should be handled by brw_channel_expressions");
       break;
 
+   case ir_unop_noise:
+      assert(!"not reached: should be handled by lower_noise");
+      break;
+
    case ir_unop_sqrt:
       emit(fs_inst(FS_OPCODE_SQRT, this->result, op[0]));
       break;
diff --git a/src/mesa/drivers/dri/i965/brw_fs_channel_expressions.cpp b/src/mesa/drivers/dri/i965/brw_fs_channel_expressions.cpp
index d8d58a9..4786140 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_channel_expressions.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_channel_expressions.cpp
@@ -356,6 +356,9 @@ ir_channel_expressions_visitor::visit_leave(ir_assignment *ir)
       assign(ir, 0, last);
       break;
    }
+   case ir_unop_noise:
+      assert(!"noise should have been broken down to function call");
+      break;
    }
 
    ir->remove();




More information about the mesa-commit mailing list