[Patch][OpenCL] CL2.0 atomic types

Pekka Jääskeläinen pekka.jaaskelainen at tut.fi
Wed Jan 14 11:13:19 PST 2015


Hi Anastasia,

 > I suggest patching first for the non-extension types and later add support
 > for the #pragma (and hopefully a check that allows customizing the support
 > per target).

How about this? I'm not sure if it'd nice to expose the atomics if they
are not supported by the target or enabled via the pragma.

On 01/13/2015 07:57 PM, Anastasia Stulova wrote:
> I just realized this was lost sometime during holidays. :)
>
> @Pekka, I don't have a fix for the extensions for the moment. Would it still
> be ok if I commit this and we look into other bits later?
>
> -----Original Message-----
> From: Pekka Jääskeläinen [mailto:pekka.jaaskelainen at tut.fi]
> Sent: 15 December 2014 16:42
> To: Anastasia Stulova; cfe-commits at cs.uiuc.edu
> Subject: Re: [Patch][OpenCL] CL2.0 atomic types
>
> Hi,
>
> Looks good otherwise but (u)long and double atomics should be enabled only
> if the cl_khr_int64_extended_atomics and cl_khr_int64_base_atomics are
> enabled via #pragma, if I read the specs correctly. The double atomics
> additionally require that the target supports double.
>
> Similar applies to the pointer (difference) types (for 64b address space,
> they are supported only if the above extensions are supported).
>
> Related to this is the question whether we should ask from the target if the
> optional extensions should be supported or not, and not enable them
> unconditionally.
>
> I suggest patching first for the non-extension types and later add support
> for the #pragma (and hopefully a check that allows customizing the support
> per target).
>
> On 12/15/2014 05:21 PM, Anastasia Stulova wrote:
>> Hello,
>>
>> This patch adds CL2.0 atomic types to Clang.
>>
>> Looking forward to your feedback,
>>
>> Anastasia
>
> --
> Pekka
>
>
>
>


-- 
--PJ




More information about the cfe-commits mailing list