r600/sfn: rename texture coordinate offset for clarity
authorGert Wollny <gert.wollny@collabora.com>
Fri, 10 Feb 2023 16:57:16 +0000 (17:57 +0100)
committerMarge Bot <emma+marge@anholt.net>
Fri, 17 Feb 2023 08:30:17 +0000 (08:30 +0000)
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21357>

src/gallium/drivers/r600/sfn/sfn_instr_tex.cpp
src/gallium/drivers/r600/sfn/sfn_instr_tex.h

index 1a47740..fc4d9a9 100644 (file)
@@ -49,7 +49,7 @@ TexInstr::TexInstr(Opcode op,
     m_inst_mode(0),
     m_resource_id(rid)
 {
-   memset(m_offset, 0, sizeof(m_offset));
+   memset(m_coord_offset, 0, sizeof(m_coord_offset));
    m_src.add_use(this);
 }
 
@@ -69,14 +69,14 @@ void
 TexInstr::set_offset(unsigned index, int32_t val)
 {
    assert(index < 3);
-   m_offset[index] = val;
+   m_coord_offset[index] = val;
 }
 
 int
 TexInstr::get_offset(unsigned index) const
 {
    assert(index < 3);
-   return m_offset[index] << 1;
+   return m_coord_offset[index] << 1;
 }
 
 void
@@ -108,7 +108,7 @@ TexInstr::is_equal_to(const TexInstr& lhs) const
       return false;
 
    for (int i = 0; i < 3; ++i) {
-      if (m_offset[i] != lhs.m_offset[i])
+      if (m_coord_offset[i] != lhs.m_coord_offset[i])
          return false;
    }
    return m_inst_mode == lhs.m_inst_mode && resource_base() == lhs.resource_base() &&
@@ -158,12 +158,12 @@ TexInstr::do_print(std::ostream& os) const
    if (resource_offset())
       os << " SO:" << *resource_offset();
 
-   if (m_offset[0])
-      os << " OX:" << m_offset[0];
-   if (m_offset[1])
-      os << " OY:" << m_offset[1];
-   if (m_offset[2])
-      os << " OZ:" << m_offset[2];
+   if (m_coord_offset[0])
+      os << " OX:" << m_coord_offset[0];
+   if (m_coord_offset[1])
+      os << " OY:" << m_coord_offset[1];
+   if (m_coord_offset[2])
+      os << " OZ:" << m_coord_offset[2];
 
    if (m_inst_mode || is_gather(m_opcode))
       os << " MODE:" << m_inst_mode;
index 06e0275..44dd952 100644 (file)
@@ -191,7 +191,7 @@ private:
 
    RegisterVec4 m_src;
    std::bitset<num_tex_flag> m_tex_flags;
-   int m_offset[3];
+   int m_coord_offset[3];
    int m_inst_mode;
    unsigned m_resource_id;