[Beignet] [Patch V2 1/2] GBE: fix legacy read64 mix pointer bug.

Yang Rong rong.r.yang at intel.com
Mon Jan 9 06:50:46 UTC 2017


Tmp register is start from insn.extra.elem.

Signed-off-by: Yang Rong <rong.r.yang at intel.com>
---
 backend/src/backend/gen_context.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/backend/src/backend/gen_context.cpp b/backend/src/backend/gen_context.cpp
index 0c1f82a..bb104cf 100644
--- a/backend/src/backend/gen_context.cpp
+++ b/backend/src/backend/gen_context.cpp
@@ -2063,8 +2063,8 @@ namespace gbe
     if (bti.file == GEN_IMMEDIATE_VALUE) {
       p->UNTYPED_READ(dst, src, bti, elemNum);
     } else {
-      const GenRegister tmp = ra->genReg(insn.dst(elemNum));
-      const GenRegister btiTmp = ra->genReg(insn.dst(elemNum + 1));
+      const GenRegister tmp = ra->genReg(insn.dst(insn.extra.elem));
+      const GenRegister btiTmp = ra->genReg(insn.dst(insn.extra.elem + 1));
       unsigned desc = p->generateUntypedReadMessageDesc(0, elemNum);
 
       unsigned jip0 = beforeMessage(insn, bti, tmp, btiTmp, desc);
-- 
2.1.4



More information about the Beignet mailing list