Altera_Forum
Honored Contributor
8 years agowindrvr6.sys lead to blue Screen
I am implementing Support Vector Machine(SVM) predict function on de5net_a7 but I have some problem that the program will lead blue screen on win10 and win7 system,
The OpenCL program working properly on GPU,and the sdk can generate .aocx file,my SDK version is 16.1,how can i solve this problem. Thank you very much. This is my kernel code:#define GSIZE 64
__attribute__((num_simd_work_items(4)))
__attribute__((reqd_work_group_size(1,1,64)))
__kernel void classification(__global uchar * restrict textures, __global uchar * restrict SVS, __global float * restrict alphas,
float gamma,__global float * restrict result)
{
uint gidx = get_global_id(0); //img_w
uint gidy = get_global_id(1); //img_h
uint gidz = get_global_id(2); //sv_num
int img_w = get_global_size(0);
uint lid = get_local_id(2); //64
uint group_size_z = get_num_groups(2);
uint group_id_z = get_group_id(2);
__local uchar texture;
__local float alpha_local;
__local float res;
__local float gamma_local;
if(lid==0){
gamma_local = gamma;
# pragma unroll
for(int i=0;i<90;i++){
texture = textures;
if(i<GSIZE){
alpha_local = alphas;
}
}
}
barrier(CLK_LOCAL_MEM_FENCE);
int temp = 0;
int i=0;
# pragma unroll
for(i=0;i<86;i+=4){
int t0 = SVS-texture;
int t1 = SVS-texture;
temp += t0*t0+t1*t1;
t0 = SVS-texture;
t1 = SVS-texture;
temp += t0*t0+t1*t1;
}
# pragma unroll
for(;i<90;i++){
int t0 = SVS-texture;
temp += t0*t0;
}
res = alpha_local*exp(-1*gamma_local*(float)temp);
barrier(CLK_LOCAL_MEM_FENCE);
if(lid==0){
float sum=0;
# pragma unroll
for(int i=0;i<GSIZE-3;i+=4){
sum += res;
sum += res;
sum += res;
sum += res;
}
result = sum;
}
}
https://alteraforum.com/forum/attachment.php?attachmentid=14263&stc=1