summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/Constants.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Added support for the extractelement operation.Robert Bocchino2006-01-101-0/+38
| | | | llvm-svn: 25181
* Fix an assertion to allow constant folding of packed valuesChris Lattner2006-01-041-3/+4
| | | | llvm-svn: 25071
* Revert previous patch. Additional tests fail.Reid Spencer2005-12-221-3/+0
| | | | llvm-svn: 24968
* Fix PR409:Reid Spencer2005-12-221-0/+3
| | | | | | | | Implement the suggested check to ensure that out-of-range float constants don't get accepted by LLVM accidentally. Adjust the supporting test cases as well. llvm-svn: 24963
* add a hack to work around broken VC++ scoping rules. Thx to JeffC for pointingChris Lattner2005-10-071-13/+13
| | | | | | this out to me llvm-svn: 23655
* refactor a bit of code.Chris Lattner2005-10-041-29/+35
| | | | | | | | When moving constant entries in 'Map' if the entry is the representative constant for the abstractypemap, make sure to update it as well. This fixes the bcreader failures from last night on several C++ apps. llvm-svn: 23628
* Minor speedup to avoid array searches given a Use*. This speeds up bc readingChris Lattner2005-10-041-23/+39
| | | | | | of the python test from 1:00 to 54s. llvm-svn: 23627
* Change the signature of replaceUsesOfWithOnConstant. The bool was alwaysChris Lattner2005-10-041-32/+12
| | | | | | | true dynamically. Finally, pass the Use* that replaceAllUsesWith has into the method for future use. llvm-svn: 23626
* For large constants (e.g. arrays and structs with many elements) justChris Lattner2005-10-041-23/+56
| | | | | | | | | | | creating the keys and doing comparisons to index into 'Map' takes a lot of time. For these large constants, keep an inverse map so that 'remove' and move operations are much faster. This speeds up a release build of the bc reader on Eric's nasty python bytecode file from 1:39 to 1:00s. llvm-svn: 23624
* minor cleanup/fastpath for the bcreader. This speeds up the bcreaderChris Lattner2005-10-041-2/+23
| | | | | | from 1:41 -> 1:39 on the large python .bc file in a release build. llvm-svn: 23623
* implement the struct version of the array speedup, speeding up theChris Lattner2005-10-041-9/+49
| | | | | | testcase a bit more from 1:48 -> 1.40. llvm-svn: 23619
* Change ConstantArray::replaceUsesOfWithOnConstant to attempt to updateChris Lattner2005-10-031-8/+58
| | | | | | | | | | | | | constant arrays in place instead of reallocating them and replaceAllUsesOf'ing the result. This speeds up a release build of the bcreader from: 136.987u 120.866s 4:24.38 to 49.790u 49.890s 1:40.14 ... a 2.6x speedup parsing a large python bc file. llvm-svn: 23614
* move some methods, no other changesChris Lattner2005-10-031-130/+132
| | | | llvm-svn: 23613
* minor microoptimizationsChris Lattner2005-10-031-14/+21
| | | | llvm-svn: 23612
* Split SimpleConstantVal up into its components, so each Constant subclass ↵Chris Lattner2005-09-271-10/+14
| | | | | | | | | | getsa different enum value. This allows 'classof' for these to be really simple,not needing to call getType() anymore. This speeds up isa/dyncast/etc for constants, and also makes them smaller. For example, the text section of a release build of InstCombine.cpp shrinks from 230037 bytes to 216363 bytes, a 6% reduction. llvm-svn: 23467
* Move code dependency for MathExtras.h out of Constants.h.Jim Laskey2005-08-171-0/+9
| | | | llvm-svn: 22840
* Culling out use of unions for converting FP to bits and vice versa.Jim Laskey2005-08-171-24/+5
| | | | llvm-svn: 22838
* Remove trailing whitespaceMisha Brukman2005-04-211-31/+31
| | | | llvm-svn: 21427
* Add new function getPtrPtrFromArrayPtr().Alkis Evlogimenos2005-03-191-0/+7
| | | | llvm-svn: 20684
* Fix a typo in an assertion comment.Reid Spencer2005-03-091-1/+1
| | | | | | Patch contributed by Vladimir Merzliakov. llvm-svn: 20529
* remove all of the various setName implementations, consolidating them intoChris Lattner2005-03-051-4/+0
| | | | | | Value::setName, which is no longer virtual. llvm-svn: 20464
* Constants never get names.Chris Lattner2005-03-051-5/+2
| | | | llvm-svn: 20459
* Adjust to changes in User class. Aggregate constants now must explicitlyChris Lattner2005-01-291-46/+81
| | | | | | manage their operands. llvm-svn: 19890
* Fix grammarMisha Brukman2005-01-271-1/+1
| | | | llvm-svn: 19854
* Allow getZeroExtend and getSignExtend to work with boolean inputs.Chris Lattner2005-01-011-5/+13
| | | | llvm-svn: 19210
* Change this method to return ulong, not uint, for 64-bit targets.Chris Lattner2004-12-131-5/+4
| | | | llvm-svn: 18906
* Revert the recent patches to "fix" ConstantFP::isValueValidForType. NoneReid Spencer2004-12-071-5/+1
| | | | | | of them seem to work everywhere. llvm-svn: 18598
* Provide a missing header file.Reid Spencer2004-12-071-0/+1
| | | | llvm-svn: 18597
* Fix some comments.Reid Spencer2004-12-071-1/+2
| | | | llvm-svn: 18596
* Fix check for valid floats. Also use and HUGE_VALF insteadAlkis Evlogimenos2004-12-071-10/+1
| | | | | | of std::numeric_limits, because they work in more platforms. llvm-svn: 18593
* For PR409: \Reid Spencer2004-12-061-0/+11
| | | | | | | Test the range of float constants to ensure we are not attempting to create a \ float constant using a double value that is out of range for a float llvm-svn: 18585
* Add hooks to free all memory allocated by the singleton factories in theseChris Lattner2004-11-191-0/+36
| | | | | | files. Patch contributed by Morten Ofstad! llvm-svn: 17995
* Gep indices must be of int, uint, long or ulong type.Alkis Evlogimenos2004-10-281-1/+1
| | | | llvm-svn: 17313
* Make this actually work.Alkis Evlogimenos2004-10-241-2/+2
| | | | llvm-svn: 17199
* Add ConstantExpr::getSizeOf(Type*).Alkis Evlogimenos2004-10-241-0/+9
| | | | llvm-svn: 17196
* Implement UndefValue classChris Lattner2004-10-161-0/+45
| | | | llvm-svn: 17040
* Allow creation of GEP constantexprs with a vector of value* operands asChris Lattner2004-10-111-10/+19
| | | | | | | 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
* When creating constant arrays check that the initializer vector is theAlkis Evlogimenos2004-09-151-0/+2
| | | | | | same size as the one in the array type. llvm-svn: 16354
* Add assertion descriptiosn on type mismatches when creatingAlkis Evlogimenos2004-09-101-6/+8
| | | | | | ConstantArray and ConstantPacked objects. llvm-svn: 16261
* Changes For Bug 352Reid Spencer2004-09-011-1/+1
| | | | | | | | Move include/Config and include/Support into include/llvm/Config, include/llvm/ADT and include/llvm/Support. From here on out, all LLVM public header files must be under include/llvm/. llvm-svn: 16137
* Packed types, brought to you by Brad JonesBrian Gaeke2004-08-201-0/+92
| | | | llvm-svn: 15938
* Check constant expression validity more strictlyChris Lattner2004-08-171-0/+31
| | | | llvm-svn: 15883
* Add a hack to work around a problem my changes exposedChris Lattner2004-08-041-0/+7
| | | | llvm-svn: 15509
* Fix a latent bug exposed by my recent changesChris Lattner2004-08-041-1/+9
| | | | llvm-svn: 15498
* Stop using getValues().Alkis Evlogimenos2004-08-041-6/+6
| | | | llvm-svn: 15482
* Implement a FIXME, by not searching linearly through a map to remove anChris Lattner2004-08-041-8/+34
| | | | | | element. This speeds up the bytecode reader from 12.86s to 8.72s on 252.eon. llvm-svn: 15463
* Fix #includes of i*.h => Instructions.h as per PR403.Misha Brukman2004-07-291-1/+1
| | | | llvm-svn: 15334
* classof implementations are now inlinedChris Lattner2004-07-191-42/+5
| | | | llvm-svn: 14987
* bug 122:Reid Spencer2004-07-171-57/+5
| | | | | | | | | - Replace ConstantPointerRef usage with GlobalValue usage - Minimize redundant isa<GlobalValue> usage - Correct isa<Constant> for GlobalValue subclass - Delete ConstantPointerRef member function implementations llvm-svn: 14928
* implement new helper methodChris Lattner2004-07-121-0/+8
| | | | llvm-svn: 14776
OpenPOWER on IntegriCloud