[cfe-dev] attributes on function arguments
Marshall Clow
marshall at idio.com
Sat May 30 22:44:01 PDT 2009
At 8:38 PM -0700 5/30/09, Nick Lewycky wrote:
>I tried to implement a novel attribute, "__attribute__((nocapture))"
>which would apply LLVM's "nocapture" attribute to pointer-typed
>parameters or arguments in a function declaration or call. There
>don't seem to be any attributes like this to copy the technique.
>
>The attribute goes onto the ParamVarDecl just fine but those don't
>seem to line up with the CGFunctionInfo's args due to things like
>implicit "this" and such. Also, it doesn't seem like ArgInfo is a
>good place to put an attribute like nocapture.
>
>Does anyone have a suggestion for how this should work in Clang?
>I've attached my attempt at an implementation.
Um, no you didn't. :-(
--
-- Marshall
Marshall Clow Idio Software <mailto:marshall at idio.com>
It is by caffeine alone I set my mind in motion.
It is by the beans of Java that thoughts acquire speed,
the hands acquire shaking, the shaking becomes a warning.
It is by caffeine alone I set my mind in motion.
More information about the cfe-dev
mailing list