[Beignet] [PATCH] GBE: remove some useless code.

Song, Ruiling ruiling.song at intel.com
Mon May 5 00:45:44 PDT 2014


LGTM

-----Original Message-----
From: Beignet [mailto:beignet-bounces at lists.freedesktop.org] On Behalf Of Zhigang Gong
Sent: Sunday, May 04, 2014 9:17 AM
To: beignet at lists.freedesktop.org
Cc: Gong, Zhigang
Subject: [Beignet] [PATCH] GBE: remove some useless code.

Signed-off-by: Zhigang Gong <zhigang.gong at intel.com>
---
 backend/src/backend/gen_context.cpp | 21 ---------------------
 1 file changed, 21 deletions(-)

diff --git a/backend/src/backend/gen_context.cpp b/backend/src/backend/gen_context.cpp
index 369c1bf..00cbf1d 100644
--- a/backend/src/backend/gen_context.cpp
+++ b/backend/src/backend/gen_context.cpp
@@ -144,27 +144,6 @@ namespace gbe
     p->pop();
   }
 
-  //Each emit function should only using one flag reg, otherwise, should handle the case both use f0.1
-  GenRegister GenContext::checkFlagRegister(GenRegister flagReg) {
-    uint32_t nr=0, subnr=0;
-    if(flagReg.file == GEN_ARCHITECTURE_REGISTER_FILE) {
-      assert(flagReg.nr >= GEN_ARF_FLAG && flagReg.nr < GEN_ARF_MASK);
-      return flagReg;
-    }
-
-    //flagReg is grf register, use f0.1, so f0.1 shouldn't be in use.
-    //Only check curr in the GenInstructionState stack, it seems enough now.
-    //Should check other GenInstructionState in the stack if needed in future.
-    if(p->curr.predicate == GEN_PREDICATE_NORMAL) {
-      nr = p->curr.flag;
-      subnr = p->curr.subFlag;
-      //TODO: Add mov to save/restore if f0.1 is in use
-      assert(!(nr == 0 && subnr == 2));
-    }
-
-    return GenRegister::flag(0, 1);
-  }
-
   void GenContext::emitStackPointer(void) {
     using namespace ir;
 
-- 
1.8.3.2

_______________________________________________
Beignet mailing list
Beignet at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/beignet


More information about the Beignet mailing list