Share BuildKernelInfo struct definition (#1453)

Move the main `BuildKernelInfo` definition into `common.h` to reduce
code duplication.

Some tests (e.g. `i_unary_double.cpp`) use a different struct; rename
those structs to `BuildKernelInfo2` for now to avoid ambiguity.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
This commit is contained in:
Sven van Haastregt
2022-07-29 18:22:18 +01:00
committed by GitHub
parent 0a5a8f90c9
commit b06ccc6cd9
27 changed files with 68 additions and 178 deletions

View File

@@ -28,4 +28,14 @@ using KernelMatrix = std::array<std::vector<cl_kernel>, VECTOR_SIZE_COUNT>;
// Array of programs for each vector size.
using Programs = std::array<clProgramWrapper, VECTOR_SIZE_COUNT>;
struct BuildKernelInfo
{
cl_uint offset; // the first vector size to build
cl_uint kernel_count;
KernelMatrix &kernels;
Programs &programs;
const char *nameInCode;
bool relaxedMode; // Whether to build with -cl-fast-relaxed-math.
};
#endif /* COMMON_H */