[Beignet] [PATCH 08/10] Android: work around a LLVM 3.5 unrolling bug.

Yang Rong rong.r.yang at intel.com
Thu May 19 08:37:14 UTC 2016


From: Zhigang Gong <zhigang.gong at intel.com>

Signed-off-by: Zhigang Gong <zhigang.gong at intel.com>
---
 backend/src/llvm/llvm_to_gen.cpp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/backend/src/llvm/llvm_to_gen.cpp b/backend/src/llvm/llvm_to_gen.cpp
index 653fc09..41723d1 100644
--- a/backend/src/llvm/llvm_to_gen.cpp
+++ b/backend/src/llvm/llvm_to_gen.cpp
@@ -183,7 +183,9 @@ namespace gbe
     // and it may even make som cl kernel cannot compile because of limited scratch memory for spill.
     // As we observe this under strict math. So we disable CustomLoopUnroll if strict math is enabled.
     if (!strictMath) {
+#if !defined(__ANDROID__)
       MPM.add(createCustomLoopUnrollPass()); //1024, 32, 1024, 512)); //Unroll loops
+#endif
       MPM.add(createLoopUnrollPass()); //1024, 32, 1024, 512)); //Unroll loops
       if(optLevel > 0) {
 #if LLVM_VERSION_MAJOR == 3 && LLVM_VERSION_MINOR >= 8
-- 
2.1.4



More information about the Beignet mailing list