summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore
Commit message (Collapse)AuthorAgeFilesLines
* Fix ICmpInst::makeConstantRange to use ConstantRange's API properlyDan Gohman2010-01-261-2/+30
| | | | | | in the case of empty and full ranges. llvm-svn: 94548
* Add MDNode::getIfExists(), an efficient way to determine if a value is used ↵Victor Hernandez2010-01-261-28/+40
| | | | | | by metadata (since metadata does not appear in a value's use list) llvm-svn: 94492
* Change Value::getUnderlyingObject to have the MaxLookup value specified as aBob Wilson2010-01-251-4/+3
| | | | | | | | | | | | parameter with a default value, instead of just hardcoding it in the implementation. The limit of MaxLookup = 6 was introduced in r69151 to fix a performance problem with O(n^2) behavior in instcombine, but the scalarrepl pass is relying on getUnderlyingObject to go all the way back to an AllocaInst. Making the limit part of the method signature makes it clear that by default the result is limited and should help avoid similar problems in the future. This fixes pr6126. llvm-svn: 94433
* mark some libraries that currently require RTTI.Chris Lattner2010-01-241-1/+1
| | | | llvm-svn: 94377
* simplify code a bit.Chris Lattner2010-01-231-5/+5
| | | | llvm-svn: 94281
* InstCombine should not fold sext/zext of a vector and a bitcast to a scalar ↵Mon P Wang2010-01-231-2/+3
| | | | | | to a sext/zext llvm-svn: 94280
* Remove MetadataBase class because it is not adding significant value.Devang Patel2010-01-221-2/+2
| | | | llvm-svn: 94243
* Fix/strengthen verification of llvm.dbg.declareVictor Hernandez2010-01-221-5/+10
| | | | llvm-svn: 94195
* Stop building RTTI information for *most* llvm libraries. NotableChris Lattner2010-01-221-0/+1
| | | | | | | | | | | missing ones are libsupport, libsystem and libvmcore. libvmcore is currently blocked on bugpoint, which uses EH. Once it stops using EH, we can switch it off. This #if 0's out 3 unit tests, because gtest requires RTTI information. Suggestions welcome on how to fix this. llvm-svn: 94164
* give PassNameParser a home.Chris Lattner2010-01-221-0/+3
| | | | llvm-svn: 94162
* add an out-of-line virtual method to CmpInst to give it a home.Chris Lattner2010-01-221-0/+2
| | | | llvm-svn: 94161
* elimiante the dynamic_cast's from opt.Chris Lattner2010-01-221-3/+4
| | | | llvm-svn: 94160
* eliminate a bunch more unneeded dynamic_cast's.Chris Lattner2010-01-221-13/+14
| | | | llvm-svn: 94156
* eliminate a bunch of dynamic_cast's.Chris Lattner2010-01-221-7/+20
| | | | llvm-svn: 94155
* eliminate a bunch of dynamic_cast's.Chris Lattner2010-01-221-9/+6
| | | | llvm-svn: 94154
* tidy upChris Lattner2010-01-211-9/+16
| | | | llvm-svn: 94100
* Fix a crasher trying to fold each element in a comparison between two vectorsNick Lewycky2010-01-212-9/+16
| | | | | | | | | | if one of the vectors didn't have elements (such as undef). Fixes PR 6096. Fix an issue in the constant folder where fcmp (<2 x %ty>, <2 x %ty>) would have <2 x i1> type if constant folding was successful and i1 type if it wasn't. This exposed a related issue in the bitcode reader. llvm-svn: 94069
* Backout r93990Victor Hernandez2010-01-201-9/+4
| | | | llvm-svn: 93995
* Fix/strengthen verification of llvm.dbg.declareVictor Hernandez2010-01-201-4/+9
| | | | llvm-svn: 93990
* Fix if/else brackets; getFunctionForValue() is to be called for non-metadata ↵Victor Hernandez2010-01-201-1/+3
| | | | | | values llvm-svn: 93984
* Fix the conditions to unambiguously show the logic they represent. This is theChandler Carruth2010-01-201-3/+3
| | | | | | | logic enforced in the test case as well, so hopefully it is correct. Please review Victor. llvm-svn: 93980
* Refactor common parts of MDNode::getFunction() and assertLocalFunction() ↵Victor Hernandez2010-01-202-34/+24
| | | | | | into getFunctionForValue() llvm-svn: 93977
* Add comment that MDNode::getFunction() is not to be used by ↵Victor Hernandez2010-01-181-1/+2
| | | | | | performance-critical code (currently only used by AsmWriter) llvm-svn: 93802
* Simplify MDNode::getFunction() and assertLocalFunction() by avoiding extra ↵Victor Hernandez2010-01-181-46/+39
| | | | | | Function* variable and smallptrset since function-local metadata cannot be cyclic llvm-svn: 93762
* reject some invalid IR. We already assert and reject this from theChris Lattner2010-01-181-0/+2
| | | | | | .ll parser, but PR6070 wants it in the verifier too. llvm-svn: 93756
* Make printing of metadata more robust when function is not found (which is ↵Victor Hernandez2010-01-181-1/+1
| | | | | | the normal situation for non function-local metadata) llvm-svn: 93748
* Update CMake files for Mangler move.Benjamin Kramer2010-01-161-1/+0
| | | | llvm-svn: 93665
* move the mangler into libtarget from vmcore.Chris Lattner2010-01-161-104/+0
| | | | llvm-svn: 93664
* reapply the mangler gutting patch.Chris Lattner2010-01-161-183/+4
| | | | llvm-svn: 93656
* Revert 93648.Rafael Espindola2010-01-161-4/+183
| | | | | | | | Mangler::getMangledName is used from lto Mangler::setUseQuotes is used in the AsmPrinter Mangler::setSymbolsCanStartWithDigit is used in the AsmPrinter llvm-svn: 93652
* Mangler::getMangledName is now dead, remove it and all the other stuff in ↵Chris Lattner2010-01-161-183/+4
| | | | | | Mangler that is now transitively dead. woo. llvm-svn: 93648
* add an inefficient version of getNameWithPrefix that returns an std::string.Chris Lattner2010-01-161-0/+10
| | | | llvm-svn: 93641
* Remove the InlineHint attribute. There are no current or plannedEric Christopher2010-01-151-2/+0
| | | | | | users. llvm-svn: 93558
* Improve llvm.dbg.declare intrinsic by referring directly to the storage in ↵Victor Hernandez2010-01-153-4/+16
| | | | | | | | | its first argument, via function-local metadata (instead of via a bitcast). This patch also cleans up code that expects there to be a bitcast in the first argument and testcases that call llvm.dbg.declare. It also strips old llvm.dbg.declare intrinsics that did not pass metadata as the first argument. llvm-svn: 93531
* Revert r93504 because older uses of llvm.dbg.declare intrinsics need to be ↵Victor Hernandez2010-01-151-4/+3
| | | | | | auto-upgraded llvm-svn: 93515
* Improve llvm.dbg.declare intrinsic by referring directly to the storage in ↵Victor Hernandez2010-01-151-3/+4
| | | | | | | | its first argument, via function-local metadata (instead of via a bitcast). This patch also cleans up code that expects there to be a bitcast in the first argument and testcases that call llvm.dbg.declare. llvm-svn: 93504
* In debug builds, assert that function-local metadata has only 1 parent functionVictor Hernandez2010-01-141-1/+30
| | | | llvm-svn: 93449
* Fix printing of function-local metadata in AsmWriterVictor Hernandez2010-01-141-2/+3
| | | | llvm-svn: 93402
* Add MDNode::getFunction(), which figures out the metadata's function, if it ↵Victor Hernandez2010-01-141-0/+34
| | | | | | has function that it is local to. llvm-svn: 93400
* Introduce Twine::toStringRef, a variant of toVector which avoids the copy if theBenjamin Kramer2010-01-133-23/+9
| | | | | | | twine can be represented as a single StringRef. Use the new methode to simplify some twine users. llvm-svn: 93317
* don't add the \1 to the name.Chris Lattner2010-01-131-1/+1
| | | | llvm-svn: 93304
* add new isSingleStringRef()/getSingleStringRef() methods to twine, Chris Lattner2010-01-131-2/+7
| | | | | | | | and use them to avoid a copy of a string in getNameWithPrefix in the common case. It seems like Value::setName and other places should use this as well? llvm-svn: 93301
* ugh, my last patch just sped up a method and changed all the clientsChris Lattner2010-01-131-19/+51
| | | | | | | | that I want to completely eliminate. Add fixme's so I remember this in the future, and add the missing helper that they should be upgraded to use instead. llvm-svn: 93300
* change Mangler::makeNameProper to return its result in a SmallVectorChris Lattner2010-01-131-53/+66
| | | | | | | | | | | | instead of returning it in an std::string. Based on this change: 1. Change TargetLoweringObjectFileCOFF::getCOFFSection to take a StringRef 2. Change a bunch of targets to call makeNameProper with a smallstring, making several of them *much* more efficient. 3. Rewrite Mangler::makeNameProper to not build names and then prepend prefixes, not use temporary std::strings, and to avoid other crimes. llvm-svn: 93298
* my mistake, Mangler::makeNameProper wants to take a twine, not a stringref!Chris Lattner2010-01-131-2/+5
| | | | llvm-svn: 93296
* change makeNameProper to take a stringref instead of std::string.Chris Lattner2010-01-131-8/+8
| | | | llvm-svn: 93295
* Further progration of metadata operands. TheDale Johannesen2010-01-131-0/+5
| | | | | | | dumper doesn't really do what I want yet, but at least it doesn't crash now. llvm-svn: 93272
* Use Twine, instead of StringRef, for consistency.Devang Patel2010-01-121-5/+18
| | | | llvm-svn: 93249
* Use ilist_tratis to autoinsert and remove NamedMDNode from MDSymbolTable.Devang Patel2010-01-122-12/+25
| | | | llvm-svn: 93247
* Reimplement getToken and SplitString as "StringRef helper functions"Benjamin Kramer2010-01-111-7/+10
| | | | | | | | | - getToken is modeled after StringRef::split but it can split on multiple separator chars and skips leading seperators. - SplitString is a StringRef::split variant for more than 2 elements with the same behaviour as getToken. llvm-svn: 93161
OpenPOWER on IntegriCloud