[Beignet] [[OpenCL-1.2]] GBE: Enable some implemented Opencl 1.2 functions in icd table.
He Junyan
junyan.he at inbox.com
Mon Jun 9 23:20:51 PDT 2014
OK,
if it is mandatory, I agree.
LGTM.
On Tue, 2014-06-10 at 14:07 +0800, Zhigang Gong wrote:
> Just as we discussed, for the mandatory APIs, we 'd better to just keep it
> as NULL if we haven't implemented it.
>
> And if we want to set some stub function, we should not set the stub
> function here. We should implement a dummy
> function in the cl_api.c and just put a NOT_SUPPORT there. And then remove
> the CL_1_2_NOTYET here. In one word,
> we don't need to add a fake stub function here.
>
> Any further comments?
>
> > -----Original Message-----
> > From: Beignet [mailto:beignet-bounces at lists.freedesktop.org] On Behalf Of
> He
> > Junyan
> > Sent: Tuesday, June 10, 2014 12:33 PM
> > To: Zhigang Gong
> > Cc: beignet at lists.freedesktop.org
> > Subject: Re: [Beignet] [[OpenCL-1.2]] GBE: Enable some implemented Opencl
> > 1.2 functions in icd table.
> >
> > hi,
> >
> > I want to add a fake stub function here, printf the warning of not
> implement,
> > and return CL_SOME_ERRORXX, the null function always cause the program
> > crash.
> >
> > On Tue, 2014-06-10 at 09:01 +0800, Zhigang Gong wrote:
> > > Signed-off-by: Zhigang Gong <zhigang.gong at intel.com>
> > > ---
> > > src/cl_khr_icd.c | 14 +++++++-------
> > > 1 file changed, 7 insertions(+), 7 deletions(-)
> > >
> > > diff --git a/src/cl_khr_icd.c b/src/cl_khr_icd.c index
> > > d601134..3a7dec2 100644
> > > --- a/src/cl_khr_icd.c
> > > +++ b/src/cl_khr_icd.c
> > > @@ -142,19 +142,19 @@ struct _cl_icd_dispatch const
> > > cl_khr_icd_dispatch = { #ifdef CL_VERSION_1_2
> > > (void *) NULL,
> > > CL_1_2_NOTYET(clCreateSubDevices),
> > > - CL_1_2_NOTYET(clRetainDevice),
> > > - CL_1_2_NOTYET(clReleaseDevice),
> > > - CL_1_2_NOTYET(clCreateImage),
> > > - CL_1_2_NOTYET(clCreateProgramWithBuiltInKernels),
> > > + clRetainDevice,
> > > + clReleaseDevice,
> > > + clCreateImage,
> > > + clCreateProgramWithBuiltInKernels,
> > > CL_1_2_NOTYET(clCompileProgram),
> > > CL_1_2_NOTYET(clLinkProgram),
> > > CL_1_2_NOTYET(clUnloadPlatformCompiler),
> > > CL_1_2_NOTYET(clGetKernelArgInfo),
> > > - CL_1_2_NOTYET(clEnqueueFillBuffer),
> > > + clEnqueueFillBuffer,
> > > CL_1_2_NOTYET(clEnqueueFillImage),
> > > CL_1_2_NOTYET(clEnqueueMigrateMemObjects),
> > > - CL_1_2_NOTYET(clEnqueueMarkerWithWaitList),
> > > - CL_1_2_NOTYET(clEnqueueBarrierWithWaitList),
> > > + clEnqueueMarkerWithWaitList,
> > > + clEnqueueBarrierWithWaitList,
> > > CL_1_2_NOTYET(clGetExtensionFunctionAddressForPlatform),
> > > CL_GL_INTEROP(clCreateFromGLTexture),
> > > (void *) NULL,
> >
> >
> >
> > _______________________________________________
> > Beignet mailing list
> > Beignet at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/beignet
>
More information about the Beignet
mailing list