i965/fs: Add a negate() function.

Reviewed-by: Jason Ekstrand <jason.ekstrand@intel.com>
This commit is contained in:
Matt Turner 2014-12-04 13:35:25 -08:00
parent 15f6118b77
commit 66cc8de042

View file

@ -118,6 +118,14 @@ public:
uint8_t stride;
};
static inline fs_reg
negate(fs_reg reg)
{
assert(reg.file != HW_REG && reg.file != IMM);
reg.negate = !reg.negate;
return reg;
}
static inline fs_reg
retype(fs_reg reg, enum brw_reg_type type)
{