[Beignet] [PATCH 0/6] Add the serialization and deserialization logic to beignet
junyan.he at inbox.com
junyan.he at inbox.com
Thu Aug 22 01:18:26 PDT 2013
From: Junyan He <junyan.he at linux.intel.com>
This serialization and deserialization logic just for gen bin file format.
We do not follow the LLVM or other standard binary standard here now.
So this logic just can be used internal. The pre-defined kernel such as
buffer copy can benefit from this.
The problem still to be fix:
1. The gbe::Kernel will use setConstBufSize to re-allocate a constant buffer
offset when the kernel argument is GBE_ARG_CONSTANT_PTR type. Because we
do not dump the context content to the binary file, the kernel deserialized
from binary will not have context. So this will fail.
2. The version and the endian of the binary for guarantee the conformance.
Signed-off-by: Junyan He <junyan.he at linux.intel.com>
---
backend/src/CMakeLists.txt | 4 +
backend/src/backend/gen_program.cpp | 31 +++
backend/src/backend/gen_program.hpp | 8 +
backend/src/backend/program.cpp | 470 +++++++++++++++++++++++++++++++++++
backend/src/backend/program.h | 4 +
backend/src/backend/program.hpp | 65 ++++-
backend/src/gbe_bin_generater.cpp | 309 +++++++++++++++++++++++
backend/src/ir/constant.hpp | 6 +
backend/src/ir/image.hpp | 3 +
backend/src/ir/sampler.hpp | 3 +
backend/src/sys/platform.hpp | 22 ++
include/CL/cl_intel.h | 8 +
src/cl_api.c | 13 +
src/cl_program.c | 39 +++
src/cl_program.h | 8 +
utests/CMakeLists.txt | 1 +
utests/load_program_from_bin.cpp | 64 +++++
17 files changed, 1055 insertions(+), 3 deletions(-)
More information about the Beignet
mailing list