summaryrefslogtreecommitdiff
path: root/test/Assembler
Commit message (Collapse)AuthorAge
* add newlines at the end of files.Chris Lattner2010-04-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100705 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
* Function-local metadata whose operands had been optimized to no longer refer ↵Victor Hernandez2010-02-06
| | | | | | to function-local IR were not getting written by BitcodeWriter; solution is for these metadata to be enumerated just like global metadata. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95467 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix (and test) function-local metadata that occurs before the instruction ↵Victor Hernandez2010-02-04
| | | | | | that it refers to; fix is to not enumerate operands of function-local metadata until after all instructions have been enumerated git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95269 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve llvm.dbg.declare intrinsic by referring directly to the storage in ↵Victor Hernandez2010-01-15
| | | | | | | | | | | 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. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93531 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r93504 because older uses of llvm.dbg.declare intrinsics need to be ↵Victor Hernandez2010-01-15
| | | | | | auto-upgraded git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93515 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve llvm.dbg.declare intrinsic by referring directly to the storage in ↵Victor Hernandez2010-01-15
| | | | | | | | | | 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. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93504 91177308-0d34-0410-b5e6-96231b3b80d8
* Extend testcase to also test llvm.dbg.value intrinsicVictor Hernandez2010-01-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93408 91177308-0d34-0410-b5e6-96231b3b80d8
* Now that LLParser, AsmWriter, BitcodeReader, and BitcodeWriter all correctly ↵Victor Hernandez2010-01-14
| | | | | | support function-local metadata, test it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93406 91177308-0d34-0410-b5e6-96231b3b80d8
* Re-add parsing of function-local metadata; this time with testcase.Victor Hernandez2010-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92793 91177308-0d34-0410-b5e6-96231b3b80d8
* Delete useless trailing semicolons.Dan Gohman2010-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92740 91177308-0d34-0410-b5e6-96231b3b80d8
* add some basic named MD tests.Chris Lattner2009-12-31
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92336 91177308-0d34-0410-b5e6-96231b3b80d8
* reimplement insertvalue/extractvalue metadata handling to not blindly Chris Lattner2009-12-30
| | | | | | | accept invalid input. Actually add a testcase. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92297 91177308-0d34-0410-b5e6-96231b3b80d8
* fix parsing of mdstring values.Chris Lattner2009-12-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92290 91177308-0d34-0410-b5e6-96231b3b80d8
* Each instruction is allowed to have *multiple* different Chris Lattner2009-12-29
| | | | | | | | metadata objects on them. Though the entire compiler supports this, the asmparser didn't. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92270 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not crash when .ll printing metadata that smells like debug info, but isn't.Chris Lattner2009-12-29
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92268 91177308-0d34-0410-b5e6-96231b3b80d8
* Adjust testcases for msasm -> alignstack.Dale Johannesen2009-10-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84796 91177308-0d34-0410-b5e6-96231b3b80d8
* Add an "msasm" flag to inline asm as suggested in PR 5125.Dale Johannesen2009-10-13
| | | | | | | | | A little ugliness is accepted to keep the binary file format compatible. No functional change yet. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84020 91177308-0d34-0410-b5e6-96231b3b80d8
* Clean up the usage of evaluateICmpRelation's return value.Nick Lewycky2009-09-20
| | | | | | | | Add another line to the ConstantExprFold test to demonstrate the GEPs may not wrap around in either the signed or unsigned senses. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82361 91177308-0d34-0410-b5e6-96231b3b80d8
* fix PR4963: folding insertvalue would sometimes turn a packed struct intoChris Lattner2009-09-15
| | | | | | | an unpacked one. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81845 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix this test to test what it was originally intended to test.Dan Gohman2009-09-11
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81539 91177308-0d34-0410-b5e6-96231b3b80d8
* Change tests from "opt %s" to "opt < %s" so that opt doesn't see theDan Gohman2009-09-11
| | | | | | | | | input filename so that opt doesn't print the input filename in the output so that grep lines in the tests don't unintentionally match strings in the input filename. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81537 91177308-0d34-0410-b5e6-96231b3b80d8
* fix test to not get a moduleid that matches 'br'Chris Lattner2009-09-11
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81526 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach lib/VMCore/ConstantFold.cpp how to set the inbounds keyword andDan Gohman2009-09-11
| | | | | | | | | | | | | | how to fold notionally-out-of-bounds array getelementptr indices instead of just doing these in lib/Analysis/ConstantFolding.cpp, because it can be done in a fairly general way without TargetData, and because not all constants are visited by lib/Analysis/ConstantFolding.cpp. This enables more constant folding. Also, set the "inbounds" flag when the getelementptr indices are one-past-the-end. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81483 91177308-0d34-0410-b5e6-96231b3b80d8
* Use opt -S instead of piping bitcode output through llvm-dis.Dan Gohman2009-09-08
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81257 91177308-0d34-0410-b5e6-96231b3b80d8
* Change these tests to feed the assembly files to opt directly, insteadDan Gohman2009-09-08
| | | | | | | of using llvm-as, now that opt supports this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81226 91177308-0d34-0410-b5e6-96231b3b80d8
* Reappy r80998, now that the GlobalOpt bug that it exposed on MiniSAT is fixed.Dan Gohman2009-09-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81172 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "Include optional subclass flags, such as inbounds, nsw, etc., ...", thisDaniel Dunbar2009-09-06
| | | | | | breaks MiniSAT on x86_64. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81098 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix spacing.Daniel Dunbar2009-09-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81097 91177308-0d34-0410-b5e6-96231b3b80d8
* Include optional subclass flags, such as inbounds, nsw, etc., in theDan Gohman2009-09-04
| | | | | | | | | | | | | | | | | | Constant uniquing tables. This allows distinct ConstantExpr objects with the same operation and different flags. Even though a ConstantExpr "a + b" is either always overflowing or never overflowing (due to being a ConstantExpr), it's still necessary to be able to represent it both with and without overflow flags at the same time within the IR, because the safety of the flag may depend on the context of the use. If the constant really does overflow, it wouldn't ever be safe to use with the flag set, however the use may be in code that is never actually executed. This also makes it possible to merge all the flags tests into a single test. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80998 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove obsolete -f flags.Dan Gohman2009-08-25
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79992 91177308-0d34-0410-b5e6-96231b3b80d8
* Various AsmWriter output cleanups. Use WriteAsOperand instead ofDan Gohman2009-08-13
| | | | | | | PrintUnmangledNameSafely. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78878 91177308-0d34-0410-b5e6-96231b3b80d8
* Extend the AsmWriter to print unnamed numbered types as "%0 = type ..."Dan Gohman2009-08-12
| | | | | | | | and unnamed numbered global variables as "@0 = global ...". Extend the AsmParser to recognize these forms. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78859 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a new keyword 'inbounds' for use with getelementptr. See theDan Gohman2009-07-27
| | | | | | | LangRef.html changes for details. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77259 91177308-0d34-0410-b5e6-96231b3b80d8
* Change the assembly syntax for nsw, nuw, and exact, putting themDan Gohman2009-07-27
| | | | | | | | after their associated opcodes rather than before. This makes them a little easier to read. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77194 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix assert assembling zero-argument constant GEP.Eli Friedman2009-07-24
| | | | | | | | | There's still a strict-aliasing violation here, but I don't feel like dealing with that right now... git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77005 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename the new unsigned and signed keywords to nuw and nsw,Dan Gohman2009-07-22
| | | | | | | which stand for no-unsigned-wrap and no-signed-wrap. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76810 91177308-0d34-0410-b5e6-96231b3b80d8
* Assembly and Bitcode support for unsigned/signed overflow flags andDan Gohman2009-07-20
| | | | | | | exact sdiv flags. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76475 91177308-0d34-0410-b5e6-96231b3b80d8
* Apparently Darwin doesn't have /dev/full :-(.Dan Gohman2009-07-15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75809 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a testcase for raw_ostream error checking.Dan Gohman2009-07-15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75795 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the vicmp and vfcmp instructions. Because we never had a release withNick Lewycky2009-07-08
| | | | | | | | these instructions, no autoupgrade or backwards compatibility support is provided. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74991 91177308-0d34-0410-b5e6-96231b3b80d8
* Split the Add, Sub, and Mul instruction opcodes into separateDan Gohman2009-06-04
| | | | | | | | | | | | | | | | integer and floating-point opcodes, introducing FAdd, FSub, and FMul. For now, the AsmParser, BitcodeReader, and IRBuilder all preserve backwards compatability, and the Core LLVM APIs preserve backwards compatibility for IR producers. Most front-ends won't need to change immediately. This implements the first step of the plan outlined here: http://nondot.org/sabre/LLVMNotes/IntegerOverflow.txt git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72897 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert this. There's no way to verifiy indirect calls, and an optimizer can turnTorok Edwin2009-05-22
| | | | | | | | indirect call into direct call, thus the verifier would reject something it previously accepted. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72249 91177308-0d34-0410-b5e6-96231b3b80d8
* Verify that calling conventions match function prototype.Torok Edwin2009-05-22
| | | | | | | | | | This only rejects mismatches between target specific calling convention and C/LLVM specific calling convention. There are too many fastcc/C, coldcc/cc42 mismatches in the testsuite, these are not reject by the verifier. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72248 91177308-0d34-0410-b5e6-96231b3b80d8
* Make this test slightly more strict.Dan Gohman2009-04-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70180 91177308-0d34-0410-b5e6-96231b3b80d8
* Any size of integral indices are allowed in gep for indexing into sequential ↵Sanjiv Gupta2009-04-26
| | | | | | types. Also adding a test case to check the indices type allowed into struct. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70134 91177308-0d34-0410-b5e6-96231b3b80d8
* add testcase for strange types of gep indicesChris Lattner2009-04-25
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70085 91177308-0d34-0410-b5e6-96231b3b80d8
* testcase and asmparser fix for PR4066Chris Lattner2009-04-25
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70080 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix g++-4.4.0 warning, it was causing llvm-nm to fail on wrapped BC files:Torok Edwin2009-04-25
| | | | | | | | | | | | | | Path.cpp:59: warning: case label value exceeds maximum value for type magic[0] is a (signed) char, but some case values are unsigned (e.g. 0xde). When magic[0] was 0xde, the switch has taken the default branch instead of case 0xde branch. Apparently this was the behaviour with older versions of gcc too, but not with g++. Now g++-4.4 behaves as gcc, and ignores unsigned case values out of range signed range. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70038 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug in our autoupgrade support: in an argument list to a functionChris Lattner2009-03-25
| | | | | | | | | | | | | | call, we should treat "i64 zext" as the start of a constant expr, but "i64 0 zext" as an argument with an obsolete attribute on it (this form is already tested by test/Assembler/2007-07-30-AutoUpgradeZextSext.ll). Make the autoupgrade logic more discerning to avoid treating "i64 zext" as an old-style attribute, causing us to reject a valid constant expr. This fixes PR3876. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67682 91177308-0d34-0410-b5e6-96231b3b80d8