aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Bitcode/Reader
Commit message (Collapse)AuthorAgeFilesLines
...
| * Merge the contents from exception-handling-rewrite to the mainline.Bill Wendling2011-07-271-0/+39
| | | | | | | | | | | | | | This adds the new instructions 'landingpad' and 'resume'. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136253 91177308-0d34-0410-b5e6-96231b3b80d8
| * Initial implementation of 'fence' instruction, the new C++0x-style ↵Eli Friedman2011-07-251-0/+33
| | | | | | | | | | | | | | | | | | | | replacement for llvm.memory.barrier. This is just a LangRef entry and reading/writing/memory representation; optimizer+codegen support coming soon. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136009 91177308-0d34-0410-b5e6-96231b3b80d8
| * Convert GetElementPtrInst to use ArrayRef.Jay Foad2011-07-251-1/+1
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135904 91177308-0d34-0410-b5e6-96231b3b80d8
| * Make better use of ConstantExpr::getGetElementPtr's InBounds parameter.Jay Foad2011-07-211-4/+3
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135676 91177308-0d34-0410-b5e6-96231b3b80d8
| * Convert ConstantExpr::getGetElementPtr andJay Foad2011-07-211-4/+3
| | | | | | | | | | | | | | ConstantExpr::getInBoundsGetElementPtr to use ArrayRef. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135673 91177308-0d34-0410-b5e6-96231b3b80d8
* | Revert "Recover LLVM 2.7 parse bitcode backward-compatible."Stephen Hines2011-08-052-105/+8
| | | | | | | | | | | | | | | | | | | | | | | | This reverts commit c7724cf3957f39d927f430969af25eddc2875df4. BUG=4942491 Conflicts: lib/Bitcode/Reader/BitcodeReader.cpp Change-Id: I6bb6e7c0b846f4b0b78d5d57b934c3d2efb45e44
* | Migrate to LLVM upstream r135568 (Jul 20 2011)Logan Chien2011-07-201-4/+4
| | | | | | | | Change-Id: I24e4ef16d197e4cd8ac2b49c691dde9ded9969c9
* | Merge with LLVM upstream r135568 (Jul 20th 2011)Logan Chien2011-07-202-51/+51
|\ \ | |/ | | | | | | | | | | Conflicts: lib/Bitcode/Reader/BitcodeReader.cpp Change-Id: Iebed76d2f7d281e742947e31d9a0b78174daf2d6
| * Add APInt(numBits, ArrayRef<uint64_t> bigVal) constructor to prevent future ↵Jeffrey Yasskin2011-07-181-4/+4
| | | | | | | | | | | | | | | | | | ambiguity errors like the one corrected by r135261. Migrate all LLVM callers of the old constructor to the new one. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135431 91177308-0d34-0410-b5e6-96231b3b80d8
| * land David Blaikie's patch to de-constify Type, with a few tweaks.Chris Lattner2011-07-182-49/+49
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135375 91177308-0d34-0410-b5e6-96231b3b80d8
* | Merge upstream to r135343 at Sat. 16th July 2011.Nowar Gu2011-07-162-84/+338
|\ \ | |/
| * Convert CallInst and InvokeInst APIs to use ArrayRef.Jay Foad2011-07-151-3/+2
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135265 91177308-0d34-0410-b5e6-96231b3b80d8
| * Convert InsertValueInst and ExtractValueInst APIs to use ArrayRef.Jay Foad2011-07-131-4/+2
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135040 91177308-0d34-0410-b5e6-96231b3b80d8
| * Second attempt at de-constifying LLVM Types in FunctionType::get(),Jay Foad2011-07-121-2/+2
| | | | | | | | | | | | StructType::get() and TargetData::getIntPtrType(). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134982 91177308-0d34-0410-b5e6-96231b3b80d8
| * Revert r134893 and r134888 (and related patches in other trees). It was causingBill Wendling2011-07-121-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | an assert on Darwin llvm-gcc builds. Assertion failed: (castIsValid(op, S, Ty) && "Invalid cast!"), function Create, file /Users/buildslave/zorg/buildbot/smooshlab/slave-0.8/build.llvm-gcc-i386-darwin9-RA/llvm.src/lib/VMCore/Instructions.cpp, li\ ne 2067. etc. http://smooshlab.apple.com:8013/builders/llvm-gcc-i386-darwin9-RA/builds/2354 --- Reverse-merging r134893 into '.': U include/llvm/Target/TargetData.h U include/llvm/DerivedTypes.h U tools/bugpoint/ExtractFunction.cpp U unittests/Support/TypeBuilderTest.cpp U lib/Target/ARM/ARMGlobalMerge.cpp U lib/Target/TargetData.cpp U lib/VMCore/Constants.cpp U lib/VMCore/Type.cpp U lib/VMCore/Core.cpp U lib/Transforms/Utils/CodeExtractor.cpp U lib/Transforms/Instrumentation/ProfilingUtils.cpp U lib/Transforms/IPO/DeadArgumentElimination.cpp U lib/CodeGen/SjLjEHPrepare.cpp --- Reverse-merging r134888 into '.': G include/llvm/DerivedTypes.h U include/llvm/Support/TypeBuilder.h U include/llvm/Intrinsics.h U unittests/Analysis/ScalarEvolutionTest.cpp U unittests/ExecutionEngine/JIT/JITTest.cpp U unittests/ExecutionEngine/JIT/JITMemoryManagerTest.cpp U unittests/VMCore/PassManagerTest.cpp G unittests/Support/TypeBuilderTest.cpp U lib/Target/MBlaze/MBlazeIntrinsicInfo.cpp U lib/Target/Blackfin/BlackfinIntrinsicInfo.cpp U lib/VMCore/IRBuilder.cpp G lib/VMCore/Type.cpp U lib/VMCore/Function.cpp G lib/VMCore/Core.cpp U lib/VMCore/Module.cpp U lib/AsmParser/LLParser.cpp U lib/Transforms/Utils/CloneFunction.cpp G lib/Transforms/Utils/CodeExtractor.cpp U lib/Transforms/Utils/InlineFunction.cpp U lib/Transforms/Instrumentation/GCOVProfiling.cpp U lib/Transforms/Scalar/ObjCARC.cpp U lib/Transforms/Scalar/SimplifyLibCalls.cpp U lib/Transforms/Scalar/MemCpyOptimizer.cpp G lib/Transforms/IPO/DeadArgumentElimination.cpp U lib/Transforms/IPO/ArgumentPromotion.cpp U lib/Transforms/InstCombine/InstCombineCompares.cpp U lib/Transforms/InstCombine/InstCombineAndOrXor.cpp U lib/Transforms/InstCombine/InstCombineCalls.cpp U lib/CodeGen/DwarfEHPrepare.cpp U lib/CodeGen/IntrinsicLowering.cpp U lib/Bitcode/Reader/BitcodeReader.cpp git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134949 91177308-0d34-0410-b5e6-96231b3b80d8
| * De-constify Types in FunctionType::get().Jay Foad2011-07-111-2/+2
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134888 91177308-0d34-0410-b5e6-96231b3b80d8
| * Land the long talked about "type system rewrite" patch. ThisChris Lattner2011-07-092-71/+329
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | patch brings numerous advantages to LLVM. One way to look at it is through diffstat: 109 files changed, 3005 insertions(+), 5906 deletions(-) Removing almost 3K lines of code is a good thing. Other advantages include: 1. Value::getType() is a simple load that can be CSE'd, not a mutating union-find operation. 2. Types a uniqued and never move once created, defining away PATypeHolder. 3. Structs can be "named" now, and their name is part of the identity that uniques them. This means that the compiler doesn't merge them structurally which makes the IR much less confusing. 4. Now that there is no way to get a cycle in a type graph without a named struct type, "upreferences" go away. 5. Type refinement is completely gone, which should make LTO much MUCH faster in some common cases with C++ code. 6. Types are now generally immutable, so we can use "Type *" instead "const Type *" everywhere. Downsides of this patch are that it removes some functions from the C API, so people using those will have to upgrade to (not yet added) new API. "LLVM 3.0" is the right time to do this. There are still some cleanups pending after this, this patch is large enough as-is. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134829 91177308-0d34-0410-b5e6-96231b3b80d8
| * type can be nullChris Lattner2011-07-071-1/+1
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134601 91177308-0d34-0410-b5e6-96231b3b80d8
| * use a more efficient check for 'is metadata'Chris Lattner2011-07-071-5/+4
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134599 91177308-0d34-0410-b5e6-96231b3b80d8
* | Recover LLVM 2.7 parse bitcode backward-compatible.Nowar Gu2011-06-252-8/+105
| | | | | | | | | | | | | | | | | | | | | | | | | | Since LLVM 3.0 modify the bitcode format, it will break old bitcode. I fix the following commit by Chris Lattner. 020a5a449f297ced1f0fed08fb81c5da87fb7c9a 9d61dd9a088be975df4beb4632a39ed009bd0ef5 96a74c57d9e8fe0595ba8308eec1276cf8bcf6b0 4f6bab98c54a93276b8370d3f61f63bf765f7e1f Now LLVM can support *READ* either old or new version bitcode. That won't make trouble on Android legacy code.
* | Merge upstream to r133679 at Thu. 23th Jun 2011.Nowar Gu2011-06-232-153/+24
|\ \ | |/
| * Replace the existing forms of ConstantArray::get() with a single formJay Foad2011-06-221-1/+1
| | | | | | | | | | | | that takes an ArrayRef. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133615 91177308-0d34-0410-b5e6-96231b3b80d8
| * Revamp the "ConstantStruct::get" methods. Previously, these were scatteredChris Lattner2011-06-201-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | all over the place in different styles and variants. Standardize on two preferred entrypoints: one that takes a StructType and ArrayRef, and one that takes StructType and varargs. In cases where there isn't a struct type convenient, we now add a ConstantStruct::getAnon method (whose name will make more sense after a few more patches land). It would be "really really nice" if the ConstantStruct::get and ConstantVector::get methods didn't make temporary std::vectors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133412 91177308-0d34-0410-b5e6-96231b3b80d8
| * Drop the "2" suffix on some enums.Chris Lattner2011-06-171-3/+3
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133274 91177308-0d34-0410-b5e6-96231b3b80d8
| * remove support for a bunch of obsolete instruction encodingsChris Lattner2011-06-171-92/+11
| | | | | | | | | | | | | | and other backward compatibility hacks. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133273 91177308-0d34-0410-b5e6-96231b3b80d8
| * Remove some "2" suffixes from the metadata enums now that "1" is gone.Chris Lattner2011-06-171-7/+7
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133269 91177308-0d34-0410-b5e6-96231b3b80d8
| * remove bitcode reader support for LLVM 2.7 metadata encoding.Chris Lattner2011-06-172-48/+2
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133268 91177308-0d34-0410-b5e6-96231b3b80d8
* | Merge upstream to r133240 at Fri. 17th Jun 2011.Nowar Gu2011-06-201-8/+14
|\ \ | |/ | | | | | | | | Conflicts: lib/CodeGen/AsmPrinter/AsmPrinter.cpp lib/Target/ARM/ARMCodeEmitter.cpp
| * Whitespace and other cleanup. Functionallity unchanged.Chad Rosier2011-06-031-1/+0
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132533 91177308-0d34-0410-b5e6-96231b3b80d8
| * Fix LTO builds with xcode 4.Rafael Espindola2011-05-261-1/+11
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132132 91177308-0d34-0410-b5e6-96231b3b80d8
| * PR9214: Convert Metadata API to use ArrayRef.Jay Foad2011-04-211-4/+2
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129932 91177308-0d34-0410-b5e6-96231b3b80d8
| * PR9214: Convert ConstantExpr::getWithOperands() to use ArrayRef.Jay Foad2011-04-131-2/+1
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129439 91177308-0d34-0410-b5e6-96231b3b80d8
| * Revert r129235 pending a vetting of the EH rewrite.Bill Wendling2011-04-101-7/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --- Reverse-merging r129235 into '.': D test/Feature/bb_attrs.ll U include/llvm/BasicBlock.h U include/llvm/Bitcode/LLVMBitCodes.h U lib/VMCore/AsmWriter.cpp U lib/VMCore/BasicBlock.cpp U lib/AsmParser/LLParser.cpp U lib/AsmParser/LLLexer.cpp U lib/AsmParser/LLToken.h U lib/Bitcode/Reader/BitcodeReader.cpp U lib/Bitcode/Writer/BitcodeWriter.cpp git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129259 91177308-0d34-0410-b5e6-96231b3b80d8
| * Beginning of the Great Exception Handling Rewrite.Bill Wendling2011-04-101-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add a "landing pad" attribute to the BasicBlock. * Modify the bitcode reader and writer to handle said attribute. Later: The verifier will ensure that the landing pad attribute is used in the appropriate manner. I.e., not applied to the entry block, and applied only to basic blocks that are branched to via a `dispatch' instruction. (This is a work-in-progress.) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129235 91177308-0d34-0410-b5e6-96231b3b80d8
* | Merge upstream r129128Jush Lu2011-04-091-2/+1
|\ \ | |/
| * Remove PHINode::reserveOperandSpace(). Instead, add a parameter toJay Foad2011-03-301-2/+1
| | | | | | | | | | | | PHINode::Create() giving the (known or expected) number of operands. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@128537 91177308-0d34-0410-b5e6-96231b3b80d8
* | Merge upstream r127116Jush Lu2011-03-091-10/+29
|\ \ | |/
| * convert ConstantVector::get to use ArrayRef.Chris Lattner2011-02-151-1/+1
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125537 91177308-0d34-0410-b5e6-96231b3b80d8
| * revert my ConstantVector patch, it seems to have made the llvm-gccChris Lattner2011-02-141-1/+1
| | | | | | | | | | | | | | builders unhappy. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125504 91177308-0d34-0410-b5e6-96231b3b80d8
| * Switch ConstantVector::get to use ArrayRef instead of a pointer+sizeChris Lattner2011-02-141-1/+1
| | | | | | | | | | | | | | idiom. Change various clients to simplify their code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125487 91177308-0d34-0410-b5e6-96231b3b80d8
| * implement .ll and .bc support for nsw/nuw on shl and exact on lshr/ashr.Chris Lattner2011-02-071-4/+10
| | | | | | | | | | | | | | Factor some code better. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125006 91177308-0d34-0410-b5e6-96231b3b80d8
| * enhance vmcore to know that udiv's can be exact, and add a trivialChris Lattner2011-02-061-4/+6
| | | | | | | | | | | | | | | | | | | | instcombine xform to exercise this. Nothing forms exact udivs yet though. This is progress on PR8862 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124992 91177308-0d34-0410-b5e6-96231b3b80d8
| * FixedNumOperandTraits and VariadicOperandTraits assumed that, given aJay Foad2011-01-111-1/+2
| | | | | | | | | | | | | | | | | | | | | | "this" pointer for any subclass of User, you could static_cast it to User* and then reinterpret_cast that to Use* to get the end of the operand list. This isn't a safe assumption in general, because the static_cast might adjust the "this" pointer. Fixed by having these OperandTraits classes take an extra template parameter, which is the subclass of User. This is groundwork for PR889. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123235 91177308-0d34-0410-b5e6-96231b3b80d8
| * First step in fixing PR8927:Rafael Espindola2011-01-081-2/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a unnamed_addr bit to global variables and functions. This will be used to indicate that the address is not significant and therefore the constant or function can be merged with others. If an optimization pass can show that an address is not used, it can set this. Examples of things that can have this set by the FE are globals created to hold string literals and C++ constructors. Adding unnamed_addr to a non-const global should have no effect unless an optimization can transform that global into a constant. Aliases are not allowed to have unnamed_addr since I couldn't figure out any use for it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123063 91177308-0d34-0410-b5e6-96231b3b80d8
| * Fix PR8494: when reading invalid bitcode, getTypeByID may returnDuncan Sands2010-10-281-2/+7
| | | | | | | | | | | | | | a null pointer. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@117551 91177308-0d34-0410-b5e6-96231b3b80d8
| * Provide a fast "get me the target triple from the module" API. This canBill Wendling2010-10-062-1/+129
| | | | | | | | | | | | | | | | | | drastically reduce the linking time during LTO. Patch by Shantonu Sen! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115728 91177308-0d34-0410-b5e6-96231b3b80d8
| * Fix spelling.Bill Wendling2010-09-281-1/+1
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114974 91177308-0d34-0410-b5e6-96231b3b80d8
| * Revert "CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally."Michael J. Spencer2010-09-131-2/+0
| | | | | | | | | | | | | | | | | | | | This reverts commit r113632 Conflicts: cmake/modules/AddLLVM.cmake git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113819 91177308-0d34-0410-b5e6-96231b3b80d8
| * Add full auto-upgrade support for LLVM 2.7 bitcode metadata.Dan Gohman2010-09-132-31/+49
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113764 91177308-0d34-0410-b5e6-96231b3b80d8
| * CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally.Michael J. Spencer2010-09-101-0/+2
| | | | | | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113632 91177308-0d34-0410-b5e6-96231b3b80d8