[PATCH] D20979: [OpenCL] Use function attribute/metadata to represent kernel attributes

Anastasia Stulova via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 9 11:27:56 PDT 2016


Anastasia added a comment.

In http://reviews.llvm.org/D20979#452616, @yaxunl wrote:

> In http://reviews.llvm.org/D20979#452463, @Anastasia wrote:
>
> > Looking good generally, I am just not sure about mixing two different representations.
>
>
> If we choose only one form of representation, would you suggest to use function metadata or function attribute?


I am still not sure if this is the intended use of target-dependent attributes to be honest. So I would prefer metadata representation.

Also if we use metadata could we avoid parsing values from strings potentially in contrast to attributes that represent all values as strings?

Related to your earlier comments about inflexibility of metadata, would it be possible to extend MDNode to be able to insert new operands?


http://reviews.llvm.org/D20979





More information about the cfe-commits mailing list