summaryrefslogtreecommitdiff
path: root/lib/AsmParser
Commit message (Collapse)AuthorAge
* Pacify a noisy compiler, and sink this variable declaration closer to its uses.Nick Lewycky2010-09-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115206 91177308-0d34-0410-b5e6-96231b3b80d8
* Silence compiler warning.Nick Lewycky2010-09-29
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115107 91177308-0d34-0410-b5e6-96231b3b80d8
* Push twines deeper into SourceMgr's error handling methods.Benjamin Kramer2010-09-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114847 91177308-0d34-0410-b5e6-96231b3b80d8
* Add ret instruction to PTX backendChe-Liang Chiou2010-09-25
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114788 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally."Michael J. Spencer2010-09-13
| | | | | | | | | | 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
* CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally.Michael J. Spencer2010-09-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113632 91177308-0d34-0410-b5e6-96231b3b80d8
* Add X86 MMX type to bitcode and Type.Dale Johannesen2010-09-10
| | | | | | | | | (The Ada bindings probably need it too, but all the obvious places to change say "do not edit this file".) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113618 91177308-0d34-0410-b5e6-96231b3b80d8
* remove unions from LLVM IR. They are severely buggy and notChris Lattner2010-08-28
| | | | | | | being actively maintained, improved, or extended. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112356 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a comment explaining why this code doesn't just callDan Gohman2010-08-24
| | | | | | | ParseMetadataValue. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111914 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a comment explaining why this code is more complex than itDan Gohman2010-08-24
| | | | | | | initially seems it should require. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111913 91177308-0d34-0410-b5e6-96231b3b80d8
* Extend function-local metadata to be usable as attachments.Dan Gohman2010-08-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111895 91177308-0d34-0410-b5e6-96231b3b80d8
* Give ParseInstructionMetadata access to the PerFunctionState object.Dan Gohman2010-08-24
| | | | | | | | This is in preparation for generalizing its parsing of function-local values. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111893 91177308-0d34-0410-b5e6-96231b3b80d8
* Create the new linker type "linker_private_weak_def_auto".Bill Wendling2010-08-20
| | | | | | | | | | | | | It's similar to "linker_private_weak", but it's known that the address of the object is not taken. For instance, functions that had an inline definition, but the compiler decided not to inline it. Note, unlike linker_private and linker_private_weak, linker_private_weak_def_auto may have only default visibility. The symbols are removed by the linker from the final linked image (executable or dynamic library). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111684 91177308-0d34-0410-b5e6-96231b3b80d8
* Introduce a new temporary MDNode concept. Temporary MDNodes areDan Gohman2010-08-20
| | | | | | | | | not part of the IR, are not uniqued, and may be safely RAUW'd. This replaces a variety of alternate mechanisms for achieving the same effect. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@111681 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't print the filename twice in file-not-found errors.Dan Gohman2010-08-04
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110179 91177308-0d34-0410-b5e6-96231b3b80d8
* Move MaximumAlignment to be a member of the Value class.Dan Gohman2010-07-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109891 91177308-0d34-0410-b5e6-96231b3b80d8
* Define a maximum supported alignment value for load, store, andDan Gohman2010-07-28
| | | | | | | | | | alloca instructions (constrained by their internal encoding), and add error checking for it. Fix an instcombine bug which generated huge alignment values (null is infinitely aligned). This fixes undefined behavior noticed by John Regehr. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109643 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r109361; it's impossible to write a call with an argument with anEli Friedman2010-07-24
| | | | | | | | invalid type. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109365 91177308-0d34-0410-b5e6-96231b3b80d8
* Minor simplification.Eli Friedman2010-07-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109362 91177308-0d34-0410-b5e6-96231b3b80d8
* Make the ll parser check that arguments have valid types.Eli Friedman2010-07-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109361 91177308-0d34-0410-b5e6-96231b3b80d8
* Make NamedMDNode not be a subclass of Value, and simplify the interfaceDan Gohman2010-07-21
| | | | | | | for creating and populating NamedMDNodes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109061 91177308-0d34-0410-b5e6-96231b3b80d8
* Disallow null as a named metadata operand.Dan Gohman2010-07-21
| | | | | | | | | | | | Make MDNode::destroy private. Fix the one thing that used MDNode::destroy, outside of MDNode itself. One should never delete or destroy an MDNode explicitly. MDNodes implicitly go away when there are no references to them (implementation details aside). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109028 91177308-0d34-0410-b5e6-96231b3b80d8
* Factor out metadata parsing into a separate function.Dan Gohman2010-07-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108343 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for empty named metadata too. This isn't particularlyDan Gohman2010-07-13
| | | | | | | useful, but it is nice for consistency. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108262 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for empty metadata nodes: !{}.Dan Gohman2010-07-13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108259 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement the "linker_private_weak" linkage type. This will be used forBill Wendling2010-07-01
| | | | | | | | | | | | | | | | | | | | | | | | Objective-C metadata types which should be marked as "weak", but which the linker will remove upon final linkage. However, this linkage isn't specific to Objective-C. For example, the "objc_msgSend_fixup_alloc" symbol is defined like this: .globl l_objc_msgSend_fixup_alloc .weak_definition l_objc_msgSend_fixup_alloc .section __DATA, __objc_msgrefs, coalesced .align 3 l_objc_msgSend_fixup_alloc: .quad _objc_msgSend_fixup .quad L_OBJC_METH_VAR_NAME_1 This is different from the "linker_private" linkage type, because it can't have the metadata defined with ".weak_definition". Currently only supported on Darwin platforms. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107433 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r107205 and r107207.Bill Wendling2010-06-29
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107215 91177308-0d34-0410-b5e6-96231b3b80d8
* Introducing the "linker_weak" linkage type. This will be used for Objective-CBill Wendling2010-06-29
| | | | | | | | | | | | | | | | | | | | metadata types which should be marked as "weak", but which the linker will remove upon final linkage. For example, the "objc_msgSend_fixup_alloc" symbol is defined like this: .globl l_objc_msgSend_fixup_alloc .weak_definition l_objc_msgSend_fixup_alloc .section __DATA, __objc_msgrefs, coalesced .align 3 l_objc_msgSend_fixup_alloc: .quad _objc_msgSend_fixup .quad L_OBJC_METH_VAR_NAME_1 This is different from the "linker_private" linkage type, because it can't have the metadata defined with ".weak_definition". git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107205 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate the restriction that the array size in an alloca must be i32.Dan Gohman2010-05-28
| | | | | | | This will help reduce the amount of casting required on 64-bit targets. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104911 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for thiscall calling convention.Anton Korobeynikov2010-05-16
| | | | | | Patch by Charles Davis and Steven Watanabe! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@103902 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the API compatibility layer which converted add, sub, and mulDan Gohman2010-05-03
| | | | | | | | | to fadd, fsub, and fmul, when used with a floating-point type. LLVM has supported the new instructions since 2.6, so it's time to get on board. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102971 91177308-0d34-0410-b5e6-96231b3b80d8
* reject invalid comma stuff with a message. We reject the case inChris Lattner2010-04-23
| | | | | | | | | | | | | | | | | PR6888 with: $ llvm-as t.ll llvm-as: t.ll:2:29: error: expected metadata or 'align' store <3 x i32> %x, i32 1, i32 1>, <3 x i32>* %p ^ instead of: $ llvm-as t.ll llvm-as: git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102154 91177308-0d34-0410-b5e6-96231b3b80d8
* reapply 'reject forward references to functions whose type don't match'Chris Lattner2010-04-20
| | | | | | | now that the testsuite has been updated. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101866 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "reject forward references to functions whose type don't match", ↵Daniel Dunbar2010-04-17
| | | | | | because DJG told me to! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101675 91177308-0d34-0410-b5e6-96231b3b80d8
* reject forward references to functions whose type don't matchChris Lattner2010-04-17
| | | | | | | up with the definition (and fix a broken testcase). PR6491. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101670 91177308-0d34-0410-b5e6-96231b3b80d8
* turn an assert into a proper check, fixing crash on invalid here:Chris Lattner2010-04-10
| | | | | | | | | | | | $ llvm-as t.ll llvm-as: t.ll:1:6: error: expected 'type' after '=' %0 = = type { i32, float, float, double } ^ PR6810. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100934 91177308-0d34-0410-b5e6-96231b3b80d8
* fix a crash on invalid metadata, e.g.: call i32 @foo(), XXXXChris Lattner2010-04-07
| | | | | | | | | | We would return the error without inserting the new instruction into the program, so it wouldn't get deallocated, and an abort would trigger when the module was deleted. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100602 91177308-0d34-0410-b5e6-96231b3b80d8
* enhance SMDiagnostic to also maintain a pointer to the SourceMgr.Chris Lattner2010-04-06
| | | | | | | | Add a simplified constructor for clients that don't have locations like "file not found" errors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100538 91177308-0d34-0410-b5e6-96231b3b80d8
* Give llvm::SourceMgr the ability to have a client-specifiedChris Lattner2010-04-06
| | | | | | | diagnostic handler. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100503 91177308-0d34-0410-b5e6-96231b3b80d8
* stringref-ize the MemoryBuffer::get apis. This requiresChris Lattner2010-04-05
| | | | | | | a co-committed clang patch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100485 91177308-0d34-0410-b5e6-96231b3b80d8
* include header.Chris Lattner2010-04-01
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100087 91177308-0d34-0410-b5e6-96231b3b80d8
* rewrite handling of forward ref'd instruction metadata Chris Lattner2010-04-01
| | | | | | | | | to used deferred resolution instead of creating a temporary node + rauw. There is no reason to create the temporary mdnode, then do rauw, then destroy it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100086 91177308-0d34-0410-b5e6-96231b3b80d8
* no really, we don't need to copy strings around in the accessor.Chris Lattner2010-04-01
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100083 91177308-0d34-0410-b5e6-96231b3b80d8
* eliminate a temporary smallvectorChris Lattner2010-04-01
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100082 91177308-0d34-0410-b5e6-96231b3b80d8
* Introduce isOpaqueTy and use it rather than isa<OpaqueType>. Also, move someDuncan Sands2010-02-16
| | | | | | | methods to try to have the type predicates be more logically positioned. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96349 91177308-0d34-0410-b5e6-96231b3b80d8
* There are two ways of checking for a given type, for example isa<PointerType>(T)Duncan Sands2010-02-16
| | | | | | | | and T->isPointerTy(). Convert most instances of the first form to the second form. Requested by Chris. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96344 91177308-0d34-0410-b5e6-96231b3b80d8
* Uniformize the names of type predicates: rather than having isFloatTy andDuncan Sands2010-02-15
| | | | | | | isInteger, we now have isFloatTy and isIntegerTy. Requested by Chris! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96223 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for a union type in LLVM IR. Patch by Talin!Chris Lattner2010-02-12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96011 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a new function attribute, 'alignstack'. It will indicate (when the backendsCharles Davis2010-02-12
| | | | | | | | implement support for it) that the stack should be forcibly realigned in the prologue (and the process reversed in the epilogue). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95945 91177308-0d34-0410-b5e6-96231b3b80d8
* Reintroduce the InlineHint function attribute.Jakob Stoklund Olesen2010-02-06
| | | | | | | | | | | | This time it's for real! I am going to hook this up in the frontends as well. The inliner has some experimental heuristics for dealing with the inline hint. When given a -respect-inlinehint option, functions marked with the inline keyword are given a threshold just above the default for -O3. We need some experiments to determine if that is the right thing to do. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95466 91177308-0d34-0410-b5e6-96231b3b80d8