[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wine-devel
Subject:    Re: [PATCH 2/2] opencl: Basic OpenCL 1.0 implementation.  (try 2)
From:       Alexandre Julliard <julliard () winehq ! org>
Date:       2010-11-30 10:15:46
Message-ID: 877hfv9kx9.fsf () wine ! dyndns ! org
[Download RAW message or body]

Peter Urbanec <winehq.org@urbanec.net> writes:

> +static BOOL load_funcs(void *handle)
> +{
> +#define LOAD_FUNCPTR(f) if((p##f = (void*)wine_dlsym(handle, #f, NULL, 0)) == NULL) \
> +    { ERR("Can not find " #f "\n"); return FALSE; } else { TRACE("Loaded function " #f "\n"); };
> +
> +    /* Platform API */
> +    LOAD_FUNCPTR(clGetPlatformIDs)
> +    LOAD_FUNCPTR(clGetPlatformInfo)
> +
> +    /* Device APIs */
> +    LOAD_FUNCPTR(clGetDeviceIDs)
> +    LOAD_FUNCPTR(clGetDeviceInfo)

Why are you loading everything dynamically instead of simply linking to it?

-- 
Alexandre Julliard
julliard@winehq.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic