Mark Lacey
2010-Aug-17 02:24 UTC
[LLVMdev] Where can I find an explanation of $src1, $src2, $in, $ptr, etc.?
I have read through the TableGen Fundamentals documentation and been browsing various .td files. One thing that is not clear to me is where things like $src1 (as in GR32:$src1) are defined, and what they mean. The TableGen Fundamentals page seems silent on this, and I have not found other documentation that explains it. Browsing through the .td files has not helped, either (although that has been quite useful to clarify things that are not spelled out in detail on the TableGen Fundamentals page). Thanks, Mark -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20100816/fd7f0584/attachment.html>
Bob Wilson
2010-Aug-17 02:42 UTC
[LLVMdev] Where can I find an explanation of $src1, $src2, $in, $ptr, etc.?
On Aug 16, 2010, at 7:24 PM, Mark Lacey wrote:> I have read through the TableGen Fundamentals documentation and been browsing various .td files. One thing that is not clear to me is where things like $src1 (as in GR32:$src1) are defined, and what they mean. The TableGen Fundamentals page seems silent on this, and I have not found other documentation that explains it. Browsing through the .td files has not helped, either (although that has been quite useful to clarify things that are not spelled out in detail on the TableGen Fundamentals page).It's not entirely clear what you're referring to, but in general, those are just arbitrary operand names. They are defined and used within the instruction patterns. If that doesn't help, perhaps you could post a specific example that you're having trouble with.
John Myers
2010-Aug-17 05:42 UTC
[LLVMdev] Where can I find an explanation of $src1, $src2, $in, $ptr, etc.?
I've also been curious about this and couldn't find any documentation. By looking at the other TD files I can tell basically what it does but, It would be nice to have documentation saying that *$var* is a variable and what can and can not be done with it. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20100816/0fd4a78b/attachment.html>
Mark Lacey
2010-Aug-17 05:43 UTC
[LLVMdev] Where can I find an explanation of $src1, $src2, $in, $ptr, etc.?
On Mon, Aug 16, 2010 at 7:42 PM, Bob Wilson <bob.wilson at apple.com> wrote:> > On Aug 16, 2010, at 7:24 PM, Mark Lacey wrote: > > > I have read through the TableGen Fundamentals documentation and been > browsing various .td files. One thing that is not clear to me is where > things like $src1 (as in GR32:$src1) are defined, and what they mean. The > TableGen Fundamentals page seems silent on this, and I have not found other > documentation that explains it. Browsing through the .td files has not > helped, either (although that has been quite useful to clarify things that > are not spelled out in detail on the TableGen Fundamentals page). > > It's not entirely clear what you're referring to, but in general, those are > just arbitrary operand names. They are defined and used within the > instruction patterns. If that doesn't help, perhaps you could post a > specific example that you're having trouble with.I think I might have answered my own question with a little more browsing and your mention of "arbitrary operand names". It appears that the syntax here is recordkind:$name where 'recordkind' has been previously defined, and 'name' is just a descriptive name attached to a particular dag node input, which may (or may not) be referred to later in the definition of the current record. Is that correct? Mark -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20100816/ad15b0ef/attachment.html>
Reasonably Related Threads
- [LLVMdev] Where can I find an explanation of $src1, $src2, $in, $ptr, etc.?
- [LLVMdev] Where can I find an explanation of $src1, $src2, $in, $ptr, etc.?
- how to add a instruction
- [LLVMdev] Simpler types in TableGen isel patterns
- [LLVMdev] Strange spill behaviour