[Beignet] [PATCH] GBE: remove some useless code for getting printf buffer address.
Ruiling Song
ruiling.song at intel.com
Thu Jul 31 01:48:01 PDT 2014
This is not used anymore.
Also fix an annoying warning.
Signed-off-by: Ruiling Song <ruiling.song at intel.com>
---
backend/src/llvm/llvm_gen_backend.cpp | 8 +-------
backend/src/llvm/llvm_gen_ocl_function.hxx | 2 --
2 files changed, 1 insertion(+), 9 deletions(-)
diff --git a/backend/src/llvm/llvm_gen_backend.cpp b/backend/src/llvm/llvm_gen_backend.cpp
index 81c1769..d2e0c87 100644
--- a/backend/src/llvm/llvm_gen_backend.cpp
+++ b/backend/src/llvm/llvm_gen_backend.cpp
@@ -772,7 +772,7 @@ namespace gbe
return ctx.newImmediate(data);
} else {
vector<P> array;
- for(int i = 0; i < seq->getNumElements(); i++)
+ for(uint32_t i = 0; i < seq->getNumElements(); i++)
array.push_back(GET_EFFECT_DATA(seq, i, tid));
return ctx.newImmediate((T*)&array[0], array.size());
}
@@ -2419,10 +2419,6 @@ namespace gbe
regTranslator.newScalarProxy(ir::ocl::goffset2, dst); break;
case GEN_OCL_GET_WORK_DIM:
regTranslator.newScalarProxy(ir::ocl::workdim, dst); break;
- case GEN_OCL_PRINTF_BUF_ADDR:
- regTranslator.newScalarProxy(ir::ocl::printfbptr, dst); break;
- case GEN_OCL_PRINTF_INDEX_BUF_ADDR:
- regTranslator.newScalarProxy(ir::ocl::printfiptr, dst); break;
case GEN_OCL_FBH:
case GEN_OCL_FBL:
case GEN_OCL_COS:
@@ -3211,8 +3207,6 @@ handle_write_image:
assert(fmt);
break;
}
- case GEN_OCL_PRINTF_BUF_ADDR:
- case GEN_OCL_PRINTF_INDEX_BUF_ADDR:
default: break;
}
}
diff --git a/backend/src/llvm/llvm_gen_ocl_function.hxx b/backend/src/llvm/llvm_gen_ocl_function.hxx
index f3ce096..05639a9 100644
--- a/backend/src/llvm/llvm_gen_ocl_function.hxx
+++ b/backend/src/llvm/llvm_gen_ocl_function.hxx
@@ -192,5 +192,3 @@ DECL_LLVM_GEN_FUNCTION(SIMD_ALL, __gen_ocl_simd_all)
// printf function
DECL_LLVM_GEN_FUNCTION(PRINTF, __gen_ocl_printf)
-DECL_LLVM_GEN_FUNCTION(PRINTF_BUF_ADDR, __gen_ocl_printf_get_buf_addr)
-DECL_LLVM_GEN_FUNCTION(PRINTF_INDEX_BUF_ADDR, __gen_ocl_printf_get_index_buf_addr)
--
1.7.10.4
More information about the Beignet
mailing list