With recent work a plugin can now Annotate a VarDecl at the AST level, how can this be used in a Pass at the IR level? What classes are responsible for their manipulation? I assumed it would be part of Value, or something common like it, but I do not see any mentions of Annotation or Attribute. Thank you -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110922/6465c3f9/attachment.html>
Hi Mark, I don't know anything about Clang's annotations or attributes, but from what you describe it sounds like you want to attach metadata to Values? Try searching for "metadata" instead, that should get you more results :) Cheers, James From: llvmdev-bounces at cs.uiuc.edu [mailto:llvmdev-bounces at cs.uiuc.edu] On Behalf Of Mark Brown Sent: 22 September 2011 07:46 To: llvmdev at cs.uiuc.edu Subject: [LLVMdev] new annotations in IR? With recent work a plugin can now Annotate a VarDecl at the AST level, how can this be used in a Pass at the IR level? What classes are responsible for their manipulation? I assumed it would be part of Value, or something common like it, but I do not see any mentions of Annotation or Attribute. Thank you -- IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110922/e7658e48/attachment.html>
Close, metadata has already been attached to Clang's VarDecls. I do not know what this would be in LLVM, my first guess just just Value(since its kind of a goto object for everything I need). On Thu, Sep 22, 2011 at 2:55 AM, James Molloy <James.Molloy at arm.com> wrote:> Hi Mark,**** > > ** ** > > I don’t know anything about Clang’s annotations or attributes, but from > what you describe it sounds like you want to attach metadata to Values?*** > * > > ** ** > > Try searching for “metadata” instead, that should get you more results J** > ** > > ** ** > > Cheers,**** > > ** ** > > James**** > > ** ** > > *From:* llvmdev-bounces at cs.uiuc.edu [mailto:llvmdev-bounces at cs.uiuc.edu] *On > Behalf Of *Mark Brown > *Sent:* 22 September 2011 07:46 > *To:* llvmdev at cs.uiuc.edu > *Subject:* [LLVMdev] new annotations in IR?**** > > ** ** > > With recent work a plugin can now Annotate a VarDecl at the AST level, how > can this be used in a Pass at the IR level? What classes are responsible for > their manipulation? I assumed it would be part of Value, or something common > like it, but I do not see any mentions of Annotation or Attribute. > > Thank you**** > > -- IMPORTANT NOTICE: The contents of this email and any attachments are > confidential and may also be privileged. If you are not the intended > recipient, please notify the sender immediately and do not disclose the > contents to any other person, use it for any purpose, or store or copy the > information in any medium. Thank you. >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110922/8ee2a64b/attachment.html>
On Thu, Sep 22, 2011 at 02:46:05AM -0400, Mark Brown wrote:> With recent work a plugin can now Annotate a VarDecl at the AST level, how > can this be used in a Pass at the IR level? What classes are responsible for > their manipulation? I assumed it would be part of Value, or something common > like it, but I do not see any mentions of Annotation or Attribute. > > Thank youAFAIK, there is no specific code to manipulate annotations. You could write an analysis pass to process & use them though, that shouldn't require a lot of work. -- Julien Lerouge PGP Key Id: 0xB1964A62 PGP Fingerprint: 392D 4BAD DB8B CE7F 4E5F FA3C 62DB 4AA7 B196 4A62 PGP Public Key from: keyserver.pgp.com
How can they processed? I cant seem to find any solid information about how they exist in IR form from a Passes perspective. I see things like @llvm.var.annotation in dumps but no relevant sounding methods to get at these. Thank you On Thu, Sep 22, 2011 at 1:20 PM, Julien Lerouge <jlerouge at apple.com> wrote:> On Thu, Sep 22, 2011 at 02:46:05AM -0400, Mark Brown wrote: > > With recent work a plugin can now Annotate a VarDecl at the AST level, > how > > can this be used in a Pass at the IR level? What classes are responsible > for > > their manipulation? I assumed it would be part of Value, or something > common > > like it, but I do not see any mentions of Annotation or Attribute. > > > > Thank you > > AFAIK, there is no specific code to manipulate annotations. You could > write an analysis pass to process & use them though, that shouldn't > require a lot of work. > > -- > Julien Lerouge > PGP Key Id: 0xB1964A62 > PGP Fingerprint: 392D 4BAD DB8B CE7F 4E5F FA3C 62DB 4AA7 B196 4A62 > PGP Public Key from: keyserver.pgp.com >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110922/3d84ba00/attachment.html>
Maybe Matching Threads
- [LLVMdev] new annotations in IR?
- [LLVMdev] AnalysisUsage & Call Graph SCC Pass Manager
- [LLVMdev] Pre pr4572 lvm-gcc building/working revision needed
- [LLVMdev] Problem in External/SPEC/CFP2000/177.mesa/Makefile ?
- [LLVMdev] LLVM-GCC & GV zeroinitializers, 2.5 vs 2.6.