summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/Constants.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* For PR950:Reid Spencer2006-12-311-75/+36
| | | | | | Change signed integer type names to unsigned equivalents. llvm-svn: 32780
* Fix some comments.Reid Spencer2006-12-241-2/+2
| | | | llvm-svn: 32758
* For PR950:Reid Spencer2006-12-231-40/+25
| | | | | | | | 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
* Make ConstantInt not care about sign any more. To ensure the AsmParser canReid Spencer2006-12-191-14/+19
| | | | | | | still check the validity of signed values an overload to isValueValidForType was added to allow passing in an int64_t to check. llvm-svn: 32663
* Remove the two-argument (inferred cast) form of ConstantExpr::getCast nowReid Spencer2006-12-181-7/+0
| | | | | | that its last uses have been removed. llvm-svn: 32653
* Partial unbreak of VC++ (stream stuff has no easy fix).Jeff Cohen2006-12-151-0/+1
| | | | llvm-svn: 32614
* Replace inferred getCast(V,Ty) calls with more strict variants.Reid Spencer2006-12-121-6/+6
| | | | | | | Rename getZeroExtend and getSignExtend to getZExt and getSExt to match the the casting mnemonics in the rest of LLVM. llvm-svn: 32514
* Don't create usless casts for same-bith-width floating point casts.Reid Spencer2006-12-121-2/+3
| | | | llvm-svn: 32475
* Implement getIntegerCast and getFPCast for ConstantExpr. These are similarReid Spencer2006-12-121-0/+23
| | | | | | to the createIntegerCast and createFPCast for CastInst instructions. llvm-svn: 32457
* Packed StructuresAndrew Lenharth2006-12-081-3/+2
| | | | llvm-svn: 32361
* Provide a getOpcode() method on CmpInst to ensure the opcode is returnedReid Spencer2006-12-071-2/+1
| | | | | | as the right type. Use this to shorten some code. llvm-svn: 32300
* For PR950:Reid Spencer2006-12-061-47/+0
| | | | | | | | | Remove the getMaxValue and getMinValue functions from ConstantIntegral. They don't make sense for a signless type. Also, for isMaxValue and isMinValue, have the caller provided the signedness rather than obtaining it from the constant's type. llvm-svn: 32287
* Bail on the getInferredCast idea. Remove the function and convertReid Spencer2006-12-051-8/+8
| | | | | | remaining uses to more specific casts. llvm-svn: 32231
* Implement getPointerCast.Reid Spencer2006-12-051-0/+10
| | | | llvm-svn: 32211
* Separate getCompare from get and getCompareTy from getTy.Reid Spencer2006-12-041-16/+17
| | | | llvm-svn: 32200
* Implement new cast creation functions for both instructions and constantReid Spencer2006-12-041-2/+20
| | | | | | | expressions. These will get used to reduce clutter as we replace various calls to createInferredCast and getCast. llvm-svn: 32191
* Reduce the size of the ExprMapKeyType class.Reid Spencer2006-12-041-3/+3
| | | | llvm-svn: 32186
* For PR950: Fix constant expressions to properly support ICmp and FCmp type ↵Reid Spencer2006-12-041-59/+127
| | | | | | expressions. llvm-svn: 32170
* Take a baby step towards getting rid of inferred casts. Provide methods onReid Spencer2006-12-041-6/+7
| | | | | | | | CastInst and ConstantExpr that allow the signedness to be explicitly passed in and reliance on signedness removed from getCastOpcode. These are temporary measures useful during the conversion of inferred casts. llvm-svn: 32164
* Implement creation of ICmp and FCmp constant expressions.Reid Spencer2006-12-031-26/+57
| | | | llvm-svn: 32147
* add a new ConstantIntegral::get method. Simplify the implementation ofChris Lattner2006-12-011-3/+6
| | | | | | ConstantInt::get llvm-svn: 32080
* For PR950:Reid Spencer2006-11-271-35/+180
| | | | | | | | | | 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
* Removed iostream #includes. Replaced std::cerr with DOUT.Bill Wendling2006-11-171-6/+6
| | | | llvm-svn: 31814
* For PR950:Reid Spencer2006-11-081-20/+17
| | | | | | | | This patch converts the old SHR instruction into two instructions, AShr (Arithmetic) and LShr (Logical). The Shr instructions now are not dependent on the sign of their operands. llvm-svn: 31542
* For PR950:Reid Spencer2006-11-021-9/+29
| | | | | | Replace the REM instruction with UREM, SREM and FREM. llvm-svn: 31369
* Speed up isCString()Evan Cheng2006-10-261-4/+14
| | | | llvm-svn: 31206
* Add isCString() - returns true if a ConstantArray is a CString.Evan Cheng2006-10-261-0/+13
| | | | llvm-svn: 31201
* For PR950:Reid Spencer2006-10-261-4/+26
| | | | | | | | Make necessary changes to support DIV -> [SUF]Div. This changes llvm to have three division instructions: signed, unsigned, floating point. The bytecode and assembler are bacwards compatible, however. llvm-svn: 31195
* For PR950:Reid Spencer2006-10-201-79/+43
| | | | | | | | This patch implements the first increment for the Signless Types feature. All changes pertain to removing the ConstantSInt and ConstantUInt classes in favor of just using ConstantInt. llvm-svn: 31063
* add a method to determine whether evaluation of a constant can trap.Chris Lattner2006-10-201-0/+27
| | | | llvm-svn: 31059
* Eliminate ConstantBool::True and ConstantBool::False. Instead, provideChris Lattner2006-09-281-8/+18
| | | | | | ConstantBool::getTrue() and ConstantBool::getFalse(). llvm-svn: 30666
* remove reference to dead methodChris Lattner2006-09-281-1/+0
| | | | llvm-svn: 30641
* Use the new ManagedStatic class to explicitly manage static variables, ↵Chris Lattner2006-09-281-71/+47
| | | | | | eliminating static ctors/dtors llvm-svn: 30639
* Add new SetCondInst::isRelational/isEquality methods. RenameChris Lattner2006-09-171-2/+2
| | | | | | Instruction::isRelational to Instruction::isComparison. llvm-svn: 30444
* s|llvm/Support/Visibility.h|llvm/Support/Compiler.h|Chris Lattner2006-08-271-1/+1
| | | | llvm-svn: 29911
* Reduce the size of Constants.o by 25% by generalizing specific instantiations ofJim Laskey2006-07-171-30/+31
| | | | | | std::map. llvm-svn: 29163
* Add a new helper, simplify ConstantExpr::getWithOperandReplaced at Gabor'sChris Lattner2006-07-141-22/+57
| | | | | | request :) llvm-svn: 29148
* Add a new method for bugpoint to useChris Lattner2006-07-141-0/+51
| | | | llvm-svn: 29143
* Use hidden visibility to reduce the sizes of some .o files. This chops 60K ↵Chris Lattner2006-06-281-10/+25
| | | | | | off a release llvm-dis. llvm-svn: 28969
* Add a missing assertion that would have helped out ReidChris Lattner2006-06-101-0/+2
| | | | llvm-svn: 28746
* Provide a simpler interface for getting a ConstantArray from a characterReid Spencer2006-05-301-8/+4
| | | | | | | | string. Instead of specifying the length, just specify whether the user wants a terminating null or not. The default is "true" to retain the same behavior as previously provided by this function. llvm-svn: 28562
* Adjust the interface to ConstantArray::get. The previousReid Spencer2006-05-301-8/+15
| | | | | | | | | implementation always added a null byte to the end of the string. It turns out that this is not always wanted. By adding a length parameter we preserve this behavior when length==0 (default value) but also allow other lengths (not null terminated) to be created. llvm-svn: 28552
* Patches to make the LLVM sources more -pedantic clean. Patch providedChris Lattner2006-05-241-1/+1
| | | | | | by Anton Korobeynikov! This is a step towards closing PR786. llvm-svn: 28447
* Add constant replacement for insertelement/vectorshuffle constant exprsChris Lattner2006-04-081-0/+16
| | | | llvm-svn: 27532
* Add shufflevector support, todo, implement better constant folding.Chris Lattner2006-04-081-1/+39
| | | | llvm-svn: 27510
* Doh!Evan Cheng2006-03-111-2/+2
| | | | llvm-svn: 26705
* Added a parameter to control whether Constant::getStringValue() would chopEvan Cheng2006-03-101-4/+8
| | | | | | off the result string at the first null terminator. llvm-svn: 26704
* Get rid of the multiple copies of getStringValue. Now a Constant:: method.Jim Laskey2006-03-081-0/+40
| | | | llvm-svn: 26616
* VMCore support for the insertelement operation.Robert Bocchino2006-01-171-3/+46
| | | | llvm-svn: 25408
* Added constant folding support for the extractelement operation.Robert Bocchino2006-01-101-0/+2
| | | | llvm-svn: 25187
OpenPOWER on IntegriCloud