summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/ConstantFolding.h
Commit message (Collapse)AuthorAgeFilesLines
* ConstantFolding.cpp/h -> ConstantFold.cpp/h to avoid confusion withChris Lattner2007-02-271-53/+0
| | | | | | lib/Analysis/ConstantFolding. llvm-svn: 34653
* Revise APIs for creating constantexpr GEPs to not require the use of vectors.Chris Lattner2007-01-311-3/+1
| | | | | | This allows us to eliminate many temporary vectors, and theirassociated malloc/free pairs. llvm-svn: 33692
* Cleanup ConstantFoldCompareInstruction:Reid Spencer2006-12-241-1/+2
| | | | | | | | | | 1. Make the arguments const like the other ConstantFold* functions. 2. Clean up evaluateFCmpRelation so it makes sense for floating point. 3. Implement the use of evaluateFCmpRelation to fold floating point CEs 4. Shorten a variable name so more things fit on one line. 5. Fix various comments. llvm-svn: 32759
* For PR950:Reid Spencer2006-12-231-2/+2
| | | | | | | | This patch removes the SetCC instructions and replaces them with the ICmp and FCmp instructions. The SetCondInst instruction has been removed and been replaced with ICmpInst and FCmpInst. llvm-svn: 32751
* For PR950: Implement a stub for folding ICmp and FCmp instructionsReid Spencer2006-12-041-0/+2
| | | | llvm-svn: 32169
* For PR950:Reid Spencer2006-11-271-1/+5
| | | | | | | | | | The long awaited CAST patch. This introduces 12 new instructions into LLVM to replace the cast instruction. Corresponding changes throughout LLVM are provided. This passes llvm-test, llvm/test, and SPEC CPUINT2000 with the exception of 175.vpr which fails only on a slight floating point output difference. llvm-svn: 31931
* Add shufflevector support, todo, implement better constant folding.Chris Lattner2006-04-081-0/+3
| | | | llvm-svn: 27510
* VMCore support for the insertelement operation.Robert Bocchino2006-01-171-0/+3
| | | | llvm-svn: 25408
* Added constant folding support for the extractelement operation.Robert Bocchino2006-01-101-0/+2
| | | | llvm-svn: 25187
* Remove trailing whitespaceMisha Brukman2005-04-211-3/+3
| | | | llvm-svn: 21427
* Convert 'struct' to 'class' in various places to adhere to the coding standardsChris Lattner2004-10-271-1/+1
| | | | | | and work better with VC++. Patch contributed by Morten Ofstad! llvm-svn: 17281
* Allow creation of GEP constantexprs with a vector of value* operands asChris Lattner2004-10-111-1/+2
| | | | | | | well as a vector of constant*'s. It turns out that this is more efficient and all of the clients want to do that, so we should cater to them. llvm-svn: 16923
* Fix a link error using VS8.0Chris Lattner2004-06-081-1/+1
| | | | llvm-svn: 14071
* Add new functionChris Lattner2004-03-121-0/+3
| | | | llvm-svn: 12322
* Rename ConstantHandling.* -> ConstantFolding.*Chris Lattner2004-01-121-62/+16
| | | | | | | | | | | | | | | | | | | | | | | | Move a bunch of (now) private stuff from ConstantFolding.h into ConstantFolding.cpp. This _finally_ gets us to a place where we have a sane constant folder. The rules are: 1. LLVM clients now use ConstantExpr::get* methods to fold constants. If they cannot be folded, a constantexpr is created, so these methods always return valid Constant*'s. 2. The implementation of ConstantExpr::get* uses the functions exposed by ConstantFolding.h to try to fold constants. If they cannot be folded, they should return a null pointer. 3. The implementation of ConstantFolding can do whatever it wants, and only has one client (Constants.cpp) This cuts down on the wierd dependencies, and eliminates the two interfaces. The old constanthandling interface was especially bad for clients to use because almost none of them took the failure condition into consideration, thus leading to obscure problems. llvm-svn: 10807
* Remove a whole bunch more ugliness. This is actually getting to the point ofChris Lattner2004-01-121-40/+20
| | | | | | | this whole refactoring: allow constant folding methods to return something other than predefined classes, allow them to return generic Constant*'s. llvm-svn: 10806
* Move ConstantHandling.h into lib/VMCore and out of include/llvmChris Lattner2004-01-121-2/+2
| | | | llvm-svn: 10805
* Move this file to lib/VMCoreChris Lattner2004-01-121-0/+102
llvm-svn: 10804
OpenPOWER on IntegriCloud