From: Pan Xiuli <[email protected]>

When we need some subnr bigger than one reg size, we can get that offset
in selection instruction output.

Signed-off-by: Pan Xiuli <[email protected]>
---
 backend/src/backend/gen_insn_selection_output.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/backend/src/backend/gen_insn_selection_output.cpp 
b/backend/src/backend/gen_insn_selection_output.cpp
index ed26650..4e420f6 100644
--- a/backend/src/backend/gen_insn_selection_output.cpp
+++ b/backend/src/backend/gen_insn_selection_output.cpp
@@ -45,7 +45,7 @@ namespace gbe
           cout << "(abs)";
         cout << "%" << reg.value.reg;
         if (reg.subphysical)
-          cout << "." << reg.subnr;
+          cout << "." << reg.subnr + reg.nr * GEN_REG_SIZE;
 
         if (dst)
           cout << "<" << GenRegister::hstride_size(reg) << ">";
-- 
2.7.4

_______________________________________________
Beignet mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/beignet

Reply via email to