summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore
Commit message (Collapse)AuthorAgeFilesLines
* Use StringRef.Devang Patel2009-10-211-4/+5
| | | | llvm-svn: 84786
* Do not use SmallVector to store MDNode elements.Devang Patel2009-10-212-16/+18
| | | | llvm-svn: 84784
* Incorporate various suggestions Chris gave during metadata review.Devang Patel2009-10-211-30/+16
| | | | | | | | | | - i < getNumElements() instead of getNumElements() > i - Make setParent() private - Fix use of resizeOperands - Reset HasMetadata bit after removing all metadata attached to an instruction - Efficient use of iterators llvm-svn: 84765
* Cosmetic changes.Devang Patel2009-10-201-9/+9
| | | | | | | | s/validName/isValidName/g s/with an Instruction/to an Instruction/g s/RegisterMDKind/registerMDKind/g llvm-svn: 84689
* Banish ConstantsLock. It's serving no purpose other than slowing things downOwen Anderson2009-10-193-60/+22
| | | | | | at the moment. llvm-svn: 84529
* various cleanups.Chris Lattner2009-10-191-30/+31
| | | | llvm-svn: 84471
* Fix test/Bindings/Ocaml/vmcore.ml. When IRBuilder::CreateMalloc was removed,Nick Lewycky2009-10-172-15/+18
| | | | | | | LLVMBuildMalloc was reimplemented but with the bug that it didn't insert the resulting instruction. llvm-svn: 84374
* Teach vm core to more aggressively fold 'trunc' constantexprs,Chris Lattner2009-10-171-9/+160
| | | | | | | | | allowing it to simplify the crazy constantexprs in the testcases down to something sensible. This allows -std-compile-opts to completely "devirtualize" the pointers to member functions in the testcase from PR5176. llvm-svn: 84368
* Emit newlines at the end of instructions too.Nick Lewycky2009-10-171-2/+2
| | | | llvm-svn: 84348
* Remove unnecessary include.Daniel Dunbar2009-10-171-1/+0
| | | | llvm-svn: 84336
* Remove MallocInst from LLVM Instructions.Victor Hernandez2009-10-172-15/+1
| | | | llvm-svn: 84299
* Autoupgrade malloc insts to malloc calls.Victor Hernandez2009-10-172-17/+31
| | | | | | | | Update testcases that rely on malloc insts being present. Also prematurely remove MallocInst handling from IndMemRemoval and RaiseAllocations to help pass tests in this incremental step. llvm-svn: 84292
* Add copyMD to copy metadata from one instruction to another instruction.Devang Patel2009-10-141-0/+15
| | | | llvm-svn: 84113
* I don't see any point in having both eh.selector.i32 and eh.selector.i64,Duncan Sands2009-10-141-0/+46
| | | | | | | | | | | | | so get rid of eh.selector.i64 and rename eh.selector.i32 to eh.selector. Likewise for eh.typeid.for. This aligns us with gcc, which always uses a 32 bit value for the selector on all platforms. My understanding is that the register allocator used to assert if the selector intrinsic size didn't match the pointer size, and this was the reason for introducing the two variants. However my testing shows that this is no longer the case (I fixed some bugs in selector lowering yesterday, and some more today in the fastisel path; these might have caused the original problems). llvm-svn: 84106
* Add an "msasm" flag to inline asm as suggested in PR 5125.Dale Johannesen2009-10-133-6/+11
| | | | | | | A little ugliness is accepted to keep the binary file format compatible. No functional change yet. llvm-svn: 84020
* Copy metadata when value is RAUW'd. It is debatable whether this is the ↵Devang Patel2009-10-132-0/+16
| | | | | | right approach for custom metadata data in general. However, right now the only custom data user, "dbg", expects this behavior while FE is constructing llvm IR with debug info. llvm-svn: 83977
* Force memory use markers to have a ConstantInt for the size argument.Nick Lewycky2009-10-131-0/+11
| | | | llvm-svn: 83960
* Fix http://llvm.org/PR5160, to let CallbackVHs modify other ValueHandles on theJeffrey Yasskin2009-10-121-23/+46
| | | | | | same Value without breaking things. llvm-svn: 83861
* add some more hooks to the C bindings, patch by Kenneth Uildriks!Chris Lattner2009-10-121-1/+59
| | | | llvm-svn: 83821
* Add a form of addPreserved which takes a string argument, to allow passesDan Gohman2009-10-081-0/+14
| | | | | | | | to declare that they preserve other passes without needing to pull in additional header file or library dependencies. Convert MachineFunctionPass and CodeGenLICM to make use of this. llvm-svn: 83555
* Do not assume that the module is set.Devang Patel2009-10-071-15/+18
| | | | llvm-svn: 83462
* Make getPointerTo return a const PointerType* rather thanDuncan Sands2009-10-071-1/+1
| | | | | | an unqualified PointerType* because it seems more correct. llvm-svn: 83454
* Introduce and use convenience methods for getting pointer typesDuncan Sands2009-10-063-2/+42
| | | | | | | where the element is of a basic builtin type. For example, to get an i8* use getInt8PtrTy. llvm-svn: 83379
* strength reduce a ton of type equality tests to check the typeid (ThroughChris Lattner2009-10-053-23/+23
| | | | | | | | the new predicates I added) instead of going through a context and doing a pointer comparison. Besides being cheaper, this allows a smart compiler to turn the if sequence into a switch. llvm-svn: 83297
* Requires element types in a constant initializer to match the element types ofNick Lewycky2009-10-031-11/+3
| | | | | | of the constant. This reverts r6544 and r7428. llvm-svn: 83270
* Check for null MDNode element while printing comment.Devang Patel2009-09-301-1/+1
| | | | llvm-svn: 83172
* Assert that ConstantArrays are created with correctly-typed elements.Jeffrey Yasskin2009-09-301-1/+4
| | | | llvm-svn: 83168
* Print tag name for MDNodes that are used to encode debug info. Devang Patel2009-09-301-1/+29
| | | | llvm-svn: 83160
* Lookup handler name only when assertions are enabled.Devang Patel2009-09-291-2/+2
| | | | llvm-svn: 83114
* Add removeMD().Devang Patel2009-09-291-15/+33
| | | | llvm-svn: 83107
* Only one custom meadata of each kind can be attached with an instruction.Devang Patel2009-09-291-9/+19
| | | | llvm-svn: 83105
* Use assertion instead of early exit to catch malformed custom metadata store.Devang Patel2009-09-291-5/+3
| | | | llvm-svn: 83102
* Parse custom metadata attached with an instruction.Devang Patel2009-09-292-1/+24
| | | | llvm-svn: 83033
* Add C API calls for building FNeg operations. Patch by KS Sreeram!Dan Gohman2009-09-281-0/+4
| | | | llvm-svn: 83021
* s/class Metadata/class MetadataContext/gDevang Patel2009-09-284-17/+17
| | | | llvm-svn: 83019
* Do not use global typedef for MDKindID.Devang Patel2009-09-281-5/+5
| | | | llvm-svn: 83016
* Do not hardcode metadata names.Devang Patel2009-09-281-4/+18
| | | | llvm-svn: 83010
* Remove dead code.Devang Patel2009-09-281-5/+1
| | | | llvm-svn: 82999
* Remove temporary debugging hack.Dan Gohman2009-09-281-1/+1
| | | | llvm-svn: 82953
* Move the dominator verification code out of special code embedded withinDan Gohman2009-09-282-54/+39
| | | | | | | | | | | | the PassManager code into a regular verifyAnalysis method. Also, reorganize loop verification. Make the LoopPass infrastructure call verifyLoop as needed instead of having LoopInfo::verifyAnalysis check every loop in the function after each looop pass. Add a new command-line argument, -verify-loop-info, to enable the expensive full checking. llvm-svn: 82952
* Extend the StartPassTimer and StopPassTimer functions so that theDan Gohman2009-09-281-26/+20
| | | | | | | | code that stops the timer doesn't have to search to find the timer object before it stops the timer. This avoids a lock acquisition and a few other things done with the timer running. llvm-svn: 82949
* Extract the code for releasing a pass into a separate function, andDan Gohman2009-09-271-24/+25
| | | | | | tidy it up a little. llvm-svn: 82944
* Remove the "metadata*" type and simplify the code it complicated. This was onlyNick Lewycky2009-09-272-91/+18
| | | | | | | used to support GlobalVariables storing MDNodes, back when they were derived from Constant before the introduction of NamedMDNode, but never removed. llvm-svn: 82943
* Round out the API for the new optimization flags.Nick Lewycky2009-09-271-0/+16
| | | | llvm-svn: 82930
* Micro-optimize DerivedType::dropAllTypeUses.Dan Gohman2009-09-271-1/+2
| | | | llvm-svn: 82900
* Remove dead code from this function and optimize. Update its correspondingNick Lewycky2009-09-271-19/+5
| | | | | | LangRef entry too. llvm-svn: 82890
* Instruction::clone does not need to take an LLVMContext&. Remove that andNick Lewycky2009-09-271-44/+42
| | | | | | update all the callers. llvm-svn: 82889
* For the NSWSub support in the builder to actually be useable,Duncan Sands2009-09-261-0/+5
| | | | | | | there need to be corresponding changes to the constant folders, done in this patch. llvm-svn: 82862
* Rename ConstantFP's getInf to getInfinity.Dan Gohman2009-09-251-1/+1
| | | | llvm-svn: 82823
* Add a ConstantFP::getInf utility function for creating infinity ConstantFPs.Dan Gohman2009-09-251-0/+6
| | | | llvm-svn: 82818
OpenPOWER on IntegriCloud