summaryrefslogtreecommitdiff
path: root/include/llvm/Support/IRBuilder.h
Commit message (Collapse)AuthorAge
* Add a NullFolder class that doesn't fold constants.Duncan Sands2008-08-12
| | | | | | | | | | | | | This may be used as the second IRBuilder template parameter, the idea being that people learning LLVM may find it helpful (several people asked on IRC if it was possible to turn off constant folding because it made it hard for them to see what was going on). Compiles, but otherwise completely untested. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54698 91177308-0d34-0410-b5e6-96231b3b80d8
* Make it possible to use different constantDuncan Sands2008-08-11
| | | | | | | | | | | folding policies with IRBuilder. The default, provided by ConstantFolder, is to do minimal folding like now: what ConstantExpr provides. An alternative is to use TargetFolder, which uses target information to fold constants more. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54640 91177308-0d34-0410-b5e6-96231b3b80d8
* Unbreak the llvm-gcc build: recent changes toDuncan Sands2008-08-09
| | | | | | | IRBuilder are not expecting null names. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54581 91177308-0d34-0410-b5e6-96231b3b80d8
* Make 'Insert' set the name for Loads, instead of passing the name into theChris Lattner2008-08-09
| | | | | | | LoadInst ctor, which causes std::string thrashing. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54577 91177308-0d34-0410-b5e6-96231b3b80d8
* Have IRBuilder take a template argument on whether or not to preserveEric Christopher2008-08-08
| | | | | | | | names. This can save a lot of allocations if you aren't going to be looking at the output. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54546 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename the version of CreateRet that's a convenience method for creatingDan Gohman2008-07-25
| | | | | | | | multiple-valued return values, so that the name CreateRet is just for creating plain ret statements. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54053 91177308-0d34-0410-b5e6-96231b3b80d8
* Make CreateBinOp/CreateNeg/CreateNot do constant folding.Chris Lattner2008-07-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53950 91177308-0d34-0410-b5e6-96231b3b80d8
* Enable first-class aggregates support.Dan Gohman2008-07-23
| | | | | | | | | | | | | Remove the GetResultInst instruction. It is still accepted in LLVM assembly and bitcode, where it is now auto-upgraded to ExtractValueInst. Also, remove support for return instructions with multiple values. These are auto-upgraded to use InsertValueInst instructions. The IRBuilder still accepts multiple-value returns, and auto-upgrades them to InsertValueInst instructions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53941 91177308-0d34-0410-b5e6-96231b3b80d8
* Add insertvalue and extractvalue folding support in IRBuilder.Dan Gohman2008-07-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53931 91177308-0d34-0410-b5e6-96231b3b80d8
* IRBuilder support for insertvalue and extractvalue.Dan Gohman2008-07-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53926 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a couple more helper functions to deal withEric Christopher2008-07-02
| | | | | | | | creating global constant strings and pointers to global constant strings. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53051 91177308-0d34-0410-b5e6-96231b3b80d8
* Tweak IRBuilder to explicitly call the setName(const char*) method on ValueChris Lattner2008-06-27
| | | | | | | | | | | | instead of passing the name into the instruction ctors. Since most instruction ctors take their name as an std::string, this avoids copying the string to the heap and a malloc and free. Patch by Pratik Solanki! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52832 91177308-0d34-0410-b5e6-96231b3b80d8
* API change for {BinaryOperator|CmpInst|CastInst}::create*() --> Create. ↵Gabor Greif2008-05-16
| | | | | | Legacy interfaces will be in place for some time. (Merge from use-diet branch.) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51200 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support to IR builder for new vicmp, vfcmp routinesNate Begeman2008-05-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51127 91177308-0d34-0410-b5e6-96231b3b80d8
* Add CreateCall3/CreateCall4 at Eric's request.Chris Lattner2008-05-01
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50515 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a spiffy little "CreateCall2" method, which can be used to makeChris Lattner2008-05-01
| | | | | | | a function call that takes two Value*'s as arguments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50514 91177308-0d34-0410-b5e6-96231b3b80d8
* Merge LLVMBuilder and FoldingBuilder, callingDuncan Sands2008-04-13
the result IRBuilder. Patch by Dominic Hamon. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49604 91177308-0d34-0410-b5e6-96231b3b80d8