[Mesa-dev] [PATCH 10/19] i965/fs: Drop redundant zero assignments in fs_inst::init().
Matt Turner
mattst88 at gmail.com
Thu Feb 20 13:41:23 PST 2014
Unfortunately the compiler isn't able to recognize that assigning
reg_undef is just zeroing the fs_reg, which was already done by the
above memset.
---
src/mesa/drivers/dri/i965/brw_fs.cpp | 6 ------
1 file changed, 6 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp
index ae1237e..e51cdbd 100644
--- a/src/mesa/drivers/dri/i965/brw_fs.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs.cpp
@@ -56,12 +56,6 @@ fs_inst::init()
{
memset(this, 0, sizeof(*this));
this->opcode = BRW_OPCODE_NOP;
- this->conditional_mod = BRW_CONDITIONAL_NONE;
-
- this->dst = reg_undef;
- this->src[0] = reg_undef;
- this->src[1] = reg_undef;
- this->src[2] = reg_undef;
/* This will be the case for almost all instructions. */
this->regs_written = 1;
--
1.8.3.2
More information about the mesa-dev
mailing list