[cfe-dev] OpenCL parsing / type support
Arnaud Allard de Grandmaison
Arnaud.AllardDeGrandMaison at dibcom.com
Wed Mar 10 12:03:12 PST 2010
To be more specific, this is about intrinsic prototypes with address spaces, not function prototypes.
--
Arnaud de Grandmaison
________________________________________
From: cfe-dev-bounces at cs.uiuc.edu [cfe-dev-bounces at cs.uiuc.edu] On Behalf Of Arnaud Allard de Grandmaison [Arnaud.AllardDeGrandMaison at dibcom.com]
Sent: Wednesday, March 10, 2010 7:34 PM
To: cfe-dev at cs.uiuc.edu
Subject: Re: [cfe-dev] OpenCL parsing / type support
>> 1. address space qualifiers (eg., __global float*, __constant int,
>> __local char*)
>> 2. function qualifiers (eg, __kernel void foo(...) ),
>> some builtin types (float4, float8, float16, image2d_t, etc.)
>These are not magic parser features, in the opencl implementations I'm
> aware of, these are macros that come from an implicit #include. These are > #defines for various attributes, __global typically turns into
> __attribute__((address_space. __kernel turns into attribute(annotate)
Although not magic parser feature per se, in the case of the address_space attributes this requires modifying clang to accept them nicely in the function prototypes. I have a patch for this for llvm/clang-2.6, and I plan to provided a patch for clang-head soon.
--
Arnaud de Grandmaison
_______________________________________________
cfe-dev mailing list
cfe-dev at cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
_______________________________________________
cfe-dev mailing list
cfe-dev at cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
More information about the cfe-dev
mailing list