Hi.
I am developing some application with AMD OpenCL.
But as I compiled certain small CL code, its binary size was too big, so program was down.
When I use NVIDA or Intel OpenCL Compiler, it works well.
While the size of binary of compiled by Intel is 19kB, that of AMD is 2MB.
Can you check?
Here is a simple example
{
short block[12][64];
}MB_information;
__kernel main()
{
MB_information MB;
Saturate(MB.block);
}
{
Block_Ptr = val;
}
Thank you.
I test this modified kernel which works. Hope this is helpful to you. I am using win7, sdk 2.7 and the latest driver on A6
typedef struct
{
short block[12][64];
}MB_information;
__kernel test(__global int* in_out)
{
MB_information MB;
Saturate(MB.block[3]);
}
void Saturate(short* Block_Ptr)
{
Block_Ptr[3] = 5;
}
can u try this again?
typedef struct
{
short block[12][64];
}MB_information;
typedef struct
{
int block_count;
}idct_new_params;
typedef struct
{
}picture_params;
void Saturate(short* Block_Ptr)
{
Block_Ptr[63] ^= 1;
}
__kernel void idct_new(idct_new_params inp, picture_params pp, __global MB_information * MBinfo, __global unsigned char* frf, __global unsigned char* brf, __global unsigned char* crf)
{
//int MBA=inp.MBA;
//int MBA= get_global_id(0);
int block_count=inp.block_count;
//MB_information MB=MBinfo[MBA];
MB_information MB=MBinfo[0];
/* copy or add block data into picture */
for (int comp=0; comp<block_count; comp++)
{
Saturate(MB.block[comp]);
}
return;
}