summaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
* Add NEON VLD1-dup instructions (load 1 element to all lanes).Bob Wilson2010-11-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120194 91177308-0d34-0410-b5e6-96231b3b80d8
* macho-dump: Fix typo.Daniel Dunbar2010-11-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120185 91177308-0d34-0410-b5e6-96231b3b80d8
* test/site.exp.in: Add "emitir", for now, fixing up r120156. CMake depends on ↵NAKAMURA Takumi2010-11-26
| | | | | | site.exp.in, though, "emitir" might be unused. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120174 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove explicit uses of -emit-llvm, the test infrastructure adds itDuncan Sands2010-11-25
| | | | | | | | | automatically. Use -S with llvm-gcc rather than -c, so tests can work when llvm-gcc is really dragonegg (which can output IR with -S but not -c). Yes, dragonegg supports objective-c++ (poorly though). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120164 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove explicit uses of -emit-llvm, the test infrastructure adds itDuncan Sands2010-11-25
| | | | | | | | | automatically. Use -S with llvm-gcc rather than -c, so tests can work when llvm-gcc is really dragonegg (which can output IR with -S but not -c). Yes, dragonegg supports objective-c (poorly though). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120163 91177308-0d34-0410-b5e6-96231b3b80d8
* Use -S rather than -c for the benefit of dragonegg.Duncan Sands2010-11-25
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120161 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove explicit uses of -emit-llvm, the test infrastructure adds itDuncan Sands2010-11-25
| | | | | | | | | automatically. Use -S with llvm-gcc rather than -c, so tests can work when llvm-gcc is really dragonegg (which can output IR with -S but not -c). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120160 91177308-0d34-0410-b5e6-96231b3b80d8
* Judging from the comment, the system assembler is supposed to assembleDuncan Sands2010-11-25
| | | | | | | | | the output of this test. Since it was producing bitcode, that clearly wasn't happening! Have it produce target assembler and assemble that instead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120159 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove explicit uses of -emit-llvm, the test infrastructure adds itDuncan Sands2010-11-25
| | | | | | | | | automatically. Use -S with llvm-gcc rather than -c, so tests can work when llvm-gcc is really dragonegg (which can output IR with -S but not -c). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120158 91177308-0d34-0410-b5e6-96231b3b80d8
* Dragonegg cannot output bitcode, only human readable IR, so use -S ratherDuncan Sands2010-11-25
| | | | | | | than -c. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120157 91177308-0d34-0410-b5e6-96231b3b80d8
* Use LLVMCC_EMITIR_FLAG rather than hard-coding "-emit-llvm".Duncan Sands2010-11-25
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120156 91177308-0d34-0410-b5e6-96231b3b80d8
* Use multiple 0x66 prefixes so that all nops up to 15 bytes are a single ↵Rafael Espindola2010-11-25
| | | | | | instruction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120147 91177308-0d34-0410-b5e6-96231b3b80d8
* Factor some code to parseSectionFlags and fix the default type of a section.Rafael Espindola2010-11-25
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120145 91177308-0d34-0410-b5e6-96231b3b80d8
* Treat a call of function pointer like a load of the pointer when consideringNick Lewycky2010-11-24
| | | | | | | | whether the pointer can be replaced with the global variable it is a copy of. Fixes PR8680. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120126 91177308-0d34-0410-b5e6-96231b3b80d8
* Behave a bit more like gnu as and use the symbol (instead of the section)Rafael Espindola2010-11-24
| | | | | | for any relocation to a symbol defined in a tls section. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120121 91177308-0d34-0410-b5e6-96231b3b80d8
* Relocate with the symbol if the relocation is of kind NTPOFF.Rafael Espindola2010-11-24
| | | | | | Patch by David Meyer, I added the test. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120104 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix and add tests for all cases in x86 and x86_64 where gnu as implicitlyRafael Espindola2010-11-24
| | | | | | sets the type of a symbol to STT_TLS. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120100 91177308-0d34-0410-b5e6-96231b3b80d8
* Testcase for r120017.Rafael Espindola2010-11-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120099 91177308-0d34-0410-b5e6-96231b3b80d8
* Allow for 'fcmp ogt' in SPU.Kalle Raiskila2010-11-24
| | | | | | | Fix by Visa Putkinen! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120090 91177308-0d34-0410-b5e6-96231b3b80d8
* If a symbol is used as tls, mark it as tls even if not declare as so. ProbablyRafael Espindola2010-11-24
| | | | | | fixes PR8659. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120076 91177308-0d34-0410-b5e6-96231b3b80d8
* The srem -> urem transform is not safe for any divisor that's not a power of ↵Benjamin Kramer2010-11-23
| | | | | | | | | | | two. E.g. -5 % 5 is 0 with srem and 1 with urem. Also addresses Frits van Bommel's comments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120049 91177308-0d34-0410-b5e6-96231b3b80d8
* Recognize sign/zero-extended constant BUILD_VECTORs for VMULL operations.Bob Wilson2010-11-23
| | | | | | | We need to check if the individual vector elements are sign/zero-extended values. For now this only handles constants values. Radar 8687140. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120034 91177308-0d34-0410-b5e6-96231b3b80d8
* InstCombine: Reduce "X shift (A srem B)" to "X shift (A urem B)" iff B is ↵Benjamin Kramer2010-11-23
| | | | | | | | | positive. This allows to transform the rem in "1 << ((int)x % 8);" to an and. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120028 91177308-0d34-0410-b5e6-96231b3b80d8
* Exploit distributive laws (eg: And distributes over Or, Mul over Add, etc) in aDuncan Sands2010-11-23
| | | | | | | | | | | | | fairly systematic way in instcombine. Some of these cases were already dealt with, in which case I removed the existing code. The case of Add has a bunch of funky logic which covers some of this plus a few variants (considers shifts to be a form of multiplication), which I didn't touch. The simplification performed is: A*B+A*C -> A*(B+C). The improvement is to do this in cases that were not already handled [such as A*B-A*C -> A*(B-C), which was reported on the mailing list], and also to do it more often by not checking for "only one use" if "B+C" simplifies. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120024 91177308-0d34-0410-b5e6-96231b3b80d8
* Division by pow-of-2 is not cheap on SPU, do it with Kalle Raiskila2010-11-23
| | | | | | | shifts. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120022 91177308-0d34-0410-b5e6-96231b3b80d8
* Produce a relocation for pcrel absolute values. Based on a patch by David Meyer.Rafael Espindola2010-11-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120006 91177308-0d34-0410-b5e6-96231b3b80d8
* duncan's spider sense was right, I completely reversed the conditionChris Lattner2010-11-23
| | | | | | | on this instcombine xform. This fixes a miscompilation of 403.gcc. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119988 91177308-0d34-0410-b5e6-96231b3b80d8
* filecheckizeChris Lattner2010-11-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119987 91177308-0d34-0410-b5e6-96231b3b80d8
* InstCombine: Implement X - A*-B -> X + A*B.Benjamin Kramer2010-11-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119984 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix epilogue codegen to avoid leaving the stack pointer in an invalidEvan Cheng2010-11-22
| | | | | | | | | | | | | | | | | | state. Previously Thumb2 would restore sp from fp like this: mov sp, r7 sub, sp, #4 If an interrupt is taken after the 'mov' but before the 'sub', callee-saved registers might be clobbered by the interrupt handler. Instead, try restoring directly from sp: add sp, #4 Or, if necessary (with VLA, etc.) use a scratch register to compute sp and then restore it: sub.w r4, r7, #8 mov sp, r7 rdar://8465407 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119977 91177308-0d34-0410-b5e6-96231b3b80d8
* If a GEP index simply advances by multiples of a type of zero size,Duncan Sands2010-11-22
| | | | | | | then replace the index with zero. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119974 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug with extractelement on SPU.Kalle Raiskila2010-11-22
| | | | | | | | In the attached testcase, the element was never extracted (missing rotate). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119973 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement the "if (X == 6 || X == 4)" -> "if ((X|2) == 6)" optimization.Benjamin Kramer2010-11-22
| | | | | | | | This currently only catches the most basic case, a two-case switch, but can be extended later. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119964 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement branch analysis in the MBlaze backend.Wesley Peck2010-11-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119951 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a rather pointless InstructionSimplify transform, inspired by recent ↵Duncan Sands2010-11-21
| | | | | | | | | | | constant folding improvements: if P points to a type of size zero, turn "gep P, N" into "P". More generally, if a gep index type has size zero, instcombine could replace the index with zero, but that is not done here. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119942 91177308-0d34-0410-b5e6-96231b3b80d8
* Add encoding for ARM "trap" instruction.Bill Wendling2010-11-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119938 91177308-0d34-0410-b5e6-96231b3b80d8
* implement PR8524, apparently mainline gas accepts movq as an alias for movdChris Lattner2010-11-21
| | | | | | | when transfering between i64 gprs and mmx regs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119931 91177308-0d34-0410-b5e6-96231b3b80d8
* implement PR8576, deleting dead stores with intervening may-alias stores.Chris Lattner2010-11-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119927 91177308-0d34-0410-b5e6-96231b3b80d8
* file checkizeChris Lattner2010-11-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119926 91177308-0d34-0410-b5e6-96231b3b80d8
* optimize:Chris Lattner2010-11-21
| | | | | | | | | | | void a(int x) { if (((1<<x)&8)==0) b(); } into "x != 3", which occurs over 100 times in 403.gcc but in no other program in llvm-test. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119922 91177308-0d34-0410-b5e6-96231b3b80d8
* Handle PCRel relocations with absolute values. Fixes PR8656.Rafael Espindola2010-11-21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119917 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement PR8644: forwarding a memcpy value to a byval,Chris Lattner2010-11-21
| | | | | | | | | | | | | allowing the memcpy to be eliminated. Unfortunately, the requirements on byval's without explicit alignment are really weak and impossible to predict in the mid-level optimizer, so this doesn't kick in much with current frontends. The fix is to change clang to set alignment on all byval arguments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119916 91177308-0d34-0410-b5e6-96231b3b80d8
* Removing the useless test that I added recently. It was meant as an example, ↵Andrew Trick2010-11-20
| | | | | | but not complicated enough to merit another test. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119898 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a test for CodeGenPrepare's ability to look through PHI nodes when ↵Owen Anderson2010-11-19
| | | | | | | | | performing addressing mode folding, introduced in r119853. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119857 91177308-0d34-0410-b5e6-96231b3b80d8
* Prefetch has a MemOperand now. FileCheckize a test.Dale Johannesen2010-11-19
| | | | | | | | This finishes up 8460971. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119848 91177308-0d34-0410-b5e6-96231b3b80d8
* Make isScalarToVector to return false if the node is a scalar. This will preventMon P Wang2010-11-19
| | | | | | | | DAGCombine from making an illegal transformation of bitcast of a scalar to a vector into a scalar_to_vector. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119819 91177308-0d34-0410-b5e6-96231b3b80d8
* Added support for the Mach-O .symbol_resolver directive. rdar://8673046Kevin Enderby2010-11-19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119816 91177308-0d34-0410-b5e6-96231b3b80d8
* Add MC encodings for some Thumb instructions. Test for a few of them. The "bxBill Wendling2010-11-19
| | | | | | | | lr" instruction cannot be tested just yet. It requires matching a "condition code", but adding one of those makes things go south quickly... git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119774 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for parsing the writeback ("!") token.Bill Wendling2010-11-18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119761 91177308-0d34-0410-b5e6-96231b3b80d8
* More tests.Owen Anderson2010-11-18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119756 91177308-0d34-0410-b5e6-96231b3b80d8