[Mesa-dev] [PATCH 03/23] i965/vec4: Add constructor of src_reg from a fixed hardware reg.
Francisco Jerez
currojerez at riseup.net
Mon Dec 2 11:31:08 PST 2013
---
src/mesa/drivers/dri/i965/brw_vec4.cpp | 8 ++++++++
src/mesa/drivers/dri/i965/brw_vec4.h | 1 +
2 files changed, 9 insertions(+)
diff --git a/src/mesa/drivers/dri/i965/brw_vec4.cpp b/src/mesa/drivers/dri/i965/brw_vec4.cpp
index 73f91a0..4458e76 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4.cpp
@@ -112,6 +112,14 @@ src_reg::src_reg(int32_t i)
this->imm.i = i;
}
+src_reg::src_reg(struct brw_reg reg)
+{
+ init();
+
+ this->file = HW_REG;
+ this->fixed_hw_reg = reg;
+}
+
src_reg::src_reg(dst_reg reg)
{
init();
diff --git a/src/mesa/drivers/dri/i965/brw_vec4.h b/src/mesa/drivers/dri/i965/brw_vec4.h
index 5cec9f9..4b1e86a 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4.h
+++ b/src/mesa/drivers/dri/i965/brw_vec4.h
@@ -125,6 +125,7 @@ public:
src_reg(float f);
src_reg(uint32_t u);
src_reg(int32_t i);
+ src_reg(struct brw_reg reg);
bool equals(src_reg *r);
bool is_zero() const;
--
1.8.3.4
More information about the mesa-dev
mailing list