Where can I find what C++ API correspond to what llvm commands? [closed]












0














What is a general way to look at LLVM and find the corresponding calls in the C++ API?
For example, I have the logical and instruction which corresponds to the Language reference here.
How can I find a corresponding C++ API reference? My general approach would be to put "llvm add instruction C++ API" into a search engine, but this isn't consistently useful.










share|improve this question













closed as off-topic by Ken White, eyllanesc, sideshowbarker, Vega, Pearly Spencer Nov 23 at 10:54


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it." – Ken White, eyllanesc, sideshowbarker, Vega, Pearly Spencer

If this question can be reworded to fit the rules in the help center, please edit the question.













  • Absolutely, but really, my question is about how to navigate development around LLVM. No, I do not expect a perfect mate, but I would like to know how I go about finding something that maps one to the other.
    – vc669
    Nov 23 at 7:44










  • @Swordfish can you please give an example of such instruction?
    – arrowd
    Nov 26 at 12:00
















0














What is a general way to look at LLVM and find the corresponding calls in the C++ API?
For example, I have the logical and instruction which corresponds to the Language reference here.
How can I find a corresponding C++ API reference? My general approach would be to put "llvm add instruction C++ API" into a search engine, but this isn't consistently useful.










share|improve this question













closed as off-topic by Ken White, eyllanesc, sideshowbarker, Vega, Pearly Spencer Nov 23 at 10:54


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it." – Ken White, eyllanesc, sideshowbarker, Vega, Pearly Spencer

If this question can be reworded to fit the rules in the help center, please edit the question.













  • Absolutely, but really, my question is about how to navigate development around LLVM. No, I do not expect a perfect mate, but I would like to know how I go about finding something that maps one to the other.
    – vc669
    Nov 23 at 7:44










  • @Swordfish can you please give an example of such instruction?
    – arrowd
    Nov 26 at 12:00














0












0








0







What is a general way to look at LLVM and find the corresponding calls in the C++ API?
For example, I have the logical and instruction which corresponds to the Language reference here.
How can I find a corresponding C++ API reference? My general approach would be to put "llvm add instruction C++ API" into a search engine, but this isn't consistently useful.










share|improve this question













What is a general way to look at LLVM and find the corresponding calls in the C++ API?
For example, I have the logical and instruction which corresponds to the Language reference here.
How can I find a corresponding C++ API reference? My general approach would be to put "llvm add instruction C++ API" into a search engine, but this isn't consistently useful.







c++ llvm llvm-c++-api






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 23 at 3:53









vc669

31628




31628




closed as off-topic by Ken White, eyllanesc, sideshowbarker, Vega, Pearly Spencer Nov 23 at 10:54


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it." – Ken White, eyllanesc, sideshowbarker, Vega, Pearly Spencer

If this question can be reworded to fit the rules in the help center, please edit the question.




closed as off-topic by Ken White, eyllanesc, sideshowbarker, Vega, Pearly Spencer Nov 23 at 10:54


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it." – Ken White, eyllanesc, sideshowbarker, Vega, Pearly Spencer

If this question can be reworded to fit the rules in the help center, please edit the question.












  • Absolutely, but really, my question is about how to navigate development around LLVM. No, I do not expect a perfect mate, but I would like to know how I go about finding something that maps one to the other.
    – vc669
    Nov 23 at 7:44










  • @Swordfish can you please give an example of such instruction?
    – arrowd
    Nov 26 at 12:00


















  • Absolutely, but really, my question is about how to navigate development around LLVM. No, I do not expect a perfect mate, but I would like to know how I go about finding something that maps one to the other.
    – vc669
    Nov 23 at 7:44










  • @Swordfish can you please give an example of such instruction?
    – arrowd
    Nov 26 at 12:00
















Absolutely, but really, my question is about how to navigate development around LLVM. No, I do not expect a perfect mate, but I would like to know how I go about finding something that maps one to the other.
– vc669
Nov 23 at 7:44




Absolutely, but really, my question is about how to navigate development around LLVM. No, I do not expect a perfect mate, but I would like to know how I go about finding something that maps one to the other.
– vc669
Nov 23 at 7:44












@Swordfish can you please give an example of such instruction?
– arrowd
Nov 26 at 12:00




@Swordfish can you please give an example of such instruction?
– arrowd
Nov 26 at 12:00












1 Answer
1






active

oldest

votes


















3














Usually for an someinst instruction there is a SomeInstInst class. For instance, alloca is implemented by AllocaInst.



But not for add, that's what confused you. Binary arithmetic and logical instructions are implemented using single class called BinaryOperator.



Another exception is a phi instruction - it is implemented in the PHINode class. Other than that, figuring what class you need should be pretty straightforward.






share|improve this answer





















  • As a follow-up, given a function call, say CreateNUW, is there some textual documentation for me to find out what a function does without reading the function definition's source code?
    – vc669
    Nov 23 at 7:57






  • 1




    If there is no documentation in Doxygen, then no, I think. But such functions are mostly self-explanatory.
    – arrowd
    Nov 23 at 9:13


















1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









3














Usually for an someinst instruction there is a SomeInstInst class. For instance, alloca is implemented by AllocaInst.



But not for add, that's what confused you. Binary arithmetic and logical instructions are implemented using single class called BinaryOperator.



Another exception is a phi instruction - it is implemented in the PHINode class. Other than that, figuring what class you need should be pretty straightforward.






share|improve this answer





















  • As a follow-up, given a function call, say CreateNUW, is there some textual documentation for me to find out what a function does without reading the function definition's source code?
    – vc669
    Nov 23 at 7:57






  • 1




    If there is no documentation in Doxygen, then no, I think. But such functions are mostly self-explanatory.
    – arrowd
    Nov 23 at 9:13
















3














Usually for an someinst instruction there is a SomeInstInst class. For instance, alloca is implemented by AllocaInst.



But not for add, that's what confused you. Binary arithmetic and logical instructions are implemented using single class called BinaryOperator.



Another exception is a phi instruction - it is implemented in the PHINode class. Other than that, figuring what class you need should be pretty straightforward.






share|improve this answer





















  • As a follow-up, given a function call, say CreateNUW, is there some textual documentation for me to find out what a function does without reading the function definition's source code?
    – vc669
    Nov 23 at 7:57






  • 1




    If there is no documentation in Doxygen, then no, I think. But such functions are mostly self-explanatory.
    – arrowd
    Nov 23 at 9:13














3












3








3






Usually for an someinst instruction there is a SomeInstInst class. For instance, alloca is implemented by AllocaInst.



But not for add, that's what confused you. Binary arithmetic and logical instructions are implemented using single class called BinaryOperator.



Another exception is a phi instruction - it is implemented in the PHINode class. Other than that, figuring what class you need should be pretty straightforward.






share|improve this answer












Usually for an someinst instruction there is a SomeInstInst class. For instance, alloca is implemented by AllocaInst.



But not for add, that's what confused you. Binary arithmetic and logical instructions are implemented using single class called BinaryOperator.



Another exception is a phi instruction - it is implemented in the PHINode class. Other than that, figuring what class you need should be pretty straightforward.







share|improve this answer












share|improve this answer



share|improve this answer










answered Nov 23 at 5:16









arrowd

21.8k44881




21.8k44881












  • As a follow-up, given a function call, say CreateNUW, is there some textual documentation for me to find out what a function does without reading the function definition's source code?
    – vc669
    Nov 23 at 7:57






  • 1




    If there is no documentation in Doxygen, then no, I think. But such functions are mostly self-explanatory.
    – arrowd
    Nov 23 at 9:13


















  • As a follow-up, given a function call, say CreateNUW, is there some textual documentation for me to find out what a function does without reading the function definition's source code?
    – vc669
    Nov 23 at 7:57






  • 1




    If there is no documentation in Doxygen, then no, I think. But such functions are mostly self-explanatory.
    – arrowd
    Nov 23 at 9:13
















As a follow-up, given a function call, say CreateNUW, is there some textual documentation for me to find out what a function does without reading the function definition's source code?
– vc669
Nov 23 at 7:57




As a follow-up, given a function call, say CreateNUW, is there some textual documentation for me to find out what a function does without reading the function definition's source code?
– vc669
Nov 23 at 7:57




1




1




If there is no documentation in Doxygen, then no, I think. But such functions are mostly self-explanatory.
– arrowd
Nov 23 at 9:13




If there is no documentation in Doxygen, then no, I think. But such functions are mostly self-explanatory.
– arrowd
Nov 23 at 9:13



Popular posts from this blog

A CLEAN and SIMPLE way to add appendices to Table of Contents and bookmarks

Calculate evaluation metrics using cross_val_predict sklearn

Insert data from modal to MySQL (multiple modal on website)