oota-llvm.git
12 years agoEdge to itself is backedge as well.
Jakub Staszak [Wed, 27 Jul 2011 15:42:09 +0000 (15:42 +0000)]
Edge to itself is backedge as well.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136219 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoTrim includes.
Frits van Bommel [Wed, 27 Jul 2011 15:20:06 +0000 (15:20 +0000)]
Trim includes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136218 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUpdate CMake build for new gtest file.
Frits van Bommel [Wed, 27 Jul 2011 10:19:32 +0000 (10:19 +0000)]
Update CMake build for new gtest file.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136215 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove some code that is no longer needed now that googletest knows how
Jay Foad [Wed, 27 Jul 2011 09:26:13 +0000 (09:26 +0000)]
Remove some code that is no longer needed now that googletest knows how
to print STL containers.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136213 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMerge gtest-1.6.0.
Jay Foad [Wed, 27 Jul 2011 09:25:14 +0000 (09:25 +0000)]
Merge gtest-1.6.0.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136212 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoExplicitly cast narrowing conversions inside {}s that will become errors in
Jeffrey Yasskin [Wed, 27 Jul 2011 06:22:51 +0000 (06:22 +0000)]
Explicitly cast narrowing conversions inside {}s that will become errors in
C++0x.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136211 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRevert r136156, which broke several buildbots.
Dan Gohman [Wed, 27 Jul 2011 01:10:27 +0000 (01:10 +0000)]
Revert r136156, which broke several buildbots.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136206 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMisc mid-level changes for new 'fence' instruction.
Eli Friedman [Wed, 27 Jul 2011 01:08:30 +0000 (01:08 +0000)]
Misc mid-level changes for new 'fence' instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136205 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMinor simplification.
Eli Friedman [Wed, 27 Jul 2011 01:02:25 +0000 (01:02 +0000)]
Minor simplification.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136202 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMove some code around to open opportunity for more shuffle matching
Bruno Cardoso Lopes [Wed, 27 Jul 2011 00:56:37 +0000 (00:56 +0000)]
Move some code around to open opportunity for more shuffle matching

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136201 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoThe vpermilps and vpermilpd have different behaviour regarding the
Bruno Cardoso Lopes [Wed, 27 Jul 2011 00:56:34 +0000 (00:56 +0000)]
The vpermilps and vpermilpd have different behaviour regarding the
usage of the shuffle bitmask. Both work in 128-bit lanes without
crossing, but in the former the mask of the high part is the same
used by the low part while in the later both lanes have independent
masks. Handle this properly and and add support for vpermilpd.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136200 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove more dead code!
Bruno Cardoso Lopes [Wed, 27 Jul 2011 00:56:27 +0000 (00:56 +0000)]
Remove more dead code!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136199 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix AliasSetTracker so that it doesn't make any assumptions about instructions it...
Eli Friedman [Wed, 27 Jul 2011 00:46:46 +0000 (00:46 +0000)]
Fix AliasSetTracker so that it doesn't make any assumptions about instructions it doesn't know about (like the atomic instructions I'm adding).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136198 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoSupport .code32 and .code64 in X86 assembler.
Evan Cheng [Wed, 27 Jul 2011 00:38:12 +0000 (00:38 +0000)]
Support .code32 and .code64 in X86 assembler.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136197 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoIt is quiet possible that inlined function body is split into multiple chunks of...
Devang Patel [Wed, 27 Jul 2011 00:34:13 +0000 (00:34 +0000)]
It is quiet possible that inlined function body is split into multiple chunks of consequtive instructions. But, there is not any way to describe this in .debug_inline accelerator table used by gdb. However, describe non contiguous ranges of inlined function body appropriately using AT_range of DW_TAG_inlined_subroutine debug info entry.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136196 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove these two directories. The tests can be ported to dragonegg if
Eric Christopher [Wed, 27 Jul 2011 00:07:56 +0000 (00:07 +0000)]
Remove these two directories. The tests can be ported to dragonegg if
they're still wanted.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136193 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove test/FrontendC, almost all of the tests have been migrated
Eric Christopher [Tue, 26 Jul 2011 23:49:39 +0000 (23:49 +0000)]
Remove test/FrontendC, almost all of the tests have been migrated
to clang now, the rest are in process (6) or have been deleted.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136191 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd support for multi-way live range splitting.
Jakob Stoklund Olesen [Tue, 26 Jul 2011 23:41:46 +0000 (23:41 +0000)]
Add support for multi-way live range splitting.

When splitting global live ranges, it is now possible to split for
multiple destination intervals at once. Previously, we only had the main
and stack intervals.

Each edge bundle is assigned to a split candidate, and splitAroundRegion
will insert copies between the candidate intervals and the stack
interval as needed.

The multi-way splitting is used to split around compact regions when
enabled with -compact-regions. The best candidate register still gets
all the bundles it wants, but everything outside the main interval is
first split around compact regions before we create single-block
intervals.

Compact region splitting still causes some regressions, so it is not
enabled by default.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136186 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoPrint out the MBB live-in registers.
Jakob Stoklund Olesen [Tue, 26 Jul 2011 23:12:08 +0000 (23:12 +0000)]
Print out the MBB live-in registers.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136178 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoEliminate copies of undefined values during coalescing.
Jakob Stoklund Olesen [Tue, 26 Jul 2011 23:00:24 +0000 (23:00 +0000)]
Eliminate copies of undefined values during coalescing.

These copies would coalesce easily, but the resulting value would be
defined by a deleted instruction. Now we also remove the undefined value
number from the destination register.

This fixes PR10503.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136174 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUpdate test.
Benjamin Kramer [Tue, 26 Jul 2011 22:45:39 +0000 (22:45 +0000)]
Update test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136170 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd a neat little two's complement hack for x86.
Benjamin Kramer [Tue, 26 Jul 2011 22:42:13 +0000 (22:42 +0000)]
Add a neat little two's complement hack for x86.

On x86 we can't encode an immediate LHS of a sub directly. If the RHS comes from a XOR with a constant we can
fold the negation into the xor and add one to the immediate of the sub. Then we can turn the sub into an add,
which can be commuted and encoded efficiently.

This code is generated for __builtin_clz and friends.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136167 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRecognize unpckh* masks and match 256-bit versions. The new versions are
Bruno Cardoso Lopes [Tue, 26 Jul 2011 22:03:40 +0000 (22:03 +0000)]
Recognize unpckh* masks and match 256-bit versions. The new versions are
different from the previous 128-bit because they work in lanes.
Update a few comments and add testcases

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136157 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoDelete unnecessarily cautious LastCALLSEQ code.
Dan Gohman [Tue, 26 Jul 2011 22:00:59 +0000 (22:00 +0000)]
Delete unnecessarily cautious LastCALLSEQ code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136156 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM rot_imm printing adjustment.
Jim Grosbach [Tue, 26 Jul 2011 21:44:37 +0000 (21:44 +0000)]
ARM rot_imm printing adjustment.

Allow the rot_imm operand to be optional. This sets the stage for refactoring
away the "rr" versions from the multiclasses and replacing them with Pat<>s.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136154 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM cleanup of rot_imm encoding.
Jim Grosbach [Tue, 26 Jul 2011 21:28:43 +0000 (21:28 +0000)]
ARM cleanup of rot_imm encoding.

Start of cleaning this up a bit. First step is to remove the encoder hook by
storing the operand as the bits it'll actually encode to so it can just be
directly used. Map it to the assembly source values 8/16/24 when we print it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136152 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoPrevent x86-specific DAGCombine from creating nodes with illegal type (which could...
Eli Friedman [Tue, 26 Jul 2011 21:02:58 +0000 (21:02 +0000)]
Prevent x86-specific DAGCombine from creating nodes with illegal type (which could not be selected).  Fixes a minor isel issue that was breaking the testcase from r136130.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136148 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove one last reference to Target in MC library.
Evan Cheng [Tue, 26 Jul 2011 20:57:44 +0000 (20:57 +0000)]
Remove one last reference to Target in MC library.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136145 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoSplit am2offset into register addend and immediate addend forms, necessary for allowi...
Owen Anderson [Tue, 26 Jul 2011 20:54:26 +0000 (20:54 +0000)]
Split am2offset into register addend and immediate addend forms, necessary for allowing the fixed-length disassembler to distinguish between SBFX and STR_PRE.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136141 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUpdate generated code to use new API of GetElementPtrInst::Create.
Nicolas Geoffray [Tue, 26 Jul 2011 20:52:25 +0000 (20:52 +0000)]
Update generated code to use new API of GetElementPtrInst::Create.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136138 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFileCheck'ize test.
Jim Grosbach [Tue, 26 Jul 2011 20:49:44 +0000 (20:49 +0000)]
FileCheck'ize test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136135 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix a typo.
Bill Wendling [Tue, 26 Jul 2011 20:42:28 +0000 (20:42 +0000)]
Fix a typo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136133 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix over-zealous rename from r136095.
Jim Grosbach [Tue, 26 Jul 2011 20:41:24 +0000 (20:41 +0000)]
Fix over-zealous rename from r136095.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136132 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoXFAIL this test while I investigate it; it's failing for an unexpected reason.
Eli Friedman [Tue, 26 Jul 2011 20:41:03 +0000 (20:41 +0000)]
XFAIL this test while I investigate it; it's failing for an unexpected reason.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136131 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd obvious missing case to switch. PR10497.
Eli Friedman [Tue, 26 Jul 2011 20:38:49 +0000 (20:38 +0000)]
Add obvious missing case to switch.  PR10497.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136130 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix a couple minor mistakes pointed out by Bill in adding 'fence' instruction.
Eli Friedman [Tue, 26 Jul 2011 20:24:06 +0000 (20:24 +0000)]
Fix a couple minor mistakes pointed out by Bill in adding 'fence' instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136124 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix llvm-mc target detection code to match llc.
Evan Cheng [Tue, 26 Jul 2011 19:02:16 +0000 (19:02 +0000)]
Fix llvm-mc target detection code to match llc.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136115 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUpdating stale documentation on regalloc modes.
Andrew Trick [Tue, 26 Jul 2011 18:31:49 +0000 (18:31 +0000)]
Updating stale documentation on regalloc modes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136112 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUse the correct for for the version. It's little endian and my brain is
Bill Wendling [Tue, 26 Jul 2011 18:31:41 +0000 (18:31 +0000)]
Use the correct for for the version. It's little endian and my brain is
obviously big endian. :-)
PR10502

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136111 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM diagnostics for ldrexd/stredx out of order paired register operands.
Jim Grosbach [Tue, 26 Jul 2011 18:25:39 +0000 (18:25 +0000)]
ARM diagnostics for ldrexd/stredx out of order paired register operands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136110 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove now unused patterns. 0 insertions(+), 98 deletions(-)
Bruno Cardoso Lopes [Tue, 26 Jul 2011 18:22:39 +0000 (18:22 +0000)]
Remove now unused patterns. 0 insertions(+), 98 deletions(-)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136109 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCleanup old matching for PUNPCK* variants
Bruno Cardoso Lopes [Tue, 26 Jul 2011 18:22:27 +0000 (18:22 +0000)]
Cleanup old matching for PUNPCK* variants

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136108 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoWhile extracting lexical scopes from machine instruction stream, work on one machine...
Devang Patel [Tue, 26 Jul 2011 18:09:53 +0000 (18:09 +0000)]
While extracting lexical scopes from machine instruction stream, work on one machine basic block at a time.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136106 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM parsing and encoding tests for load/store exclusive instructions.
Jim Grosbach [Tue, 26 Jul 2011 18:07:21 +0000 (18:07 +0000)]
ARM parsing and encoding tests for load/store exclusive instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136105 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM fix for LDREX source register encoding.
Jim Grosbach [Tue, 26 Jul 2011 17:44:46 +0000 (17:44 +0000)]
ARM fix for LDREX source register encoding.

rdar://9842203

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136102 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoSCEV: Added a data structure for storing not-taken info per loop
Andrew Trick [Tue, 26 Jul 2011 17:19:55 +0000 (17:19 +0000)]
SCEV: Added a data structure for storing not-taken info per loop
exit. Added an interfaces for querying either the loop's exact/max
backedge taken count or a specific loop exit's not-taken count.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136100 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoStrip trailing whitespace.
Duncan Sands [Tue, 26 Jul 2011 17:19:30 +0000 (17:19 +0000)]
Strip trailing whitespace.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136099 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM assembly parsing and encoding for SWP[B] instructions.
Jim Grosbach [Tue, 26 Jul 2011 17:15:11 +0000 (17:15 +0000)]
ARM assembly parsing and encoding for SWP[B] instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136098 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM SWP instructions store, too, not just load.
Jim Grosbach [Tue, 26 Jul 2011 17:11:05 +0000 (17:11 +0000)]
ARM SWP instructions store, too, not just load.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136096 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoClean up the ARM asm parser a bit.
Jim Grosbach [Tue, 26 Jul 2011 17:10:22 +0000 (17:10 +0000)]
Clean up the ARM asm parser a bit.

No intendeded functional change. Just cleaning up a bit to make things more
self-consistent in layout and style.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136095 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM fix asm parsing range check for [0,31] immediates.
Jim Grosbach [Tue, 26 Jul 2011 16:44:05 +0000 (16:44 +0000)]
ARM fix asm parsing range check for [0,31] immediates.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136091 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM parsing and encoding for SVC instruction.
Jim Grosbach [Tue, 26 Jul 2011 16:24:27 +0000 (16:24 +0000)]
ARM parsing and encoding for SVC instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136090 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM assembly parsing and encoding tests for SUB instruction.
Jim Grosbach [Tue, 26 Jul 2011 15:44:05 +0000 (15:44 +0000)]
ARM assembly parsing and encoding tests for SUB instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136089 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoUpdate ARM STM tests. Fix check: prefix for diagnostic tests.
Jim Grosbach [Tue, 26 Jul 2011 15:41:22 +0000 (15:41 +0000)]
Update ARM STM tests. Fix check: prefix for diagnostic tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136088 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoTeach the Triple class about kfreebsd (FreeBSD kernel with
Duncan Sands [Tue, 26 Jul 2011 15:30:04 +0000 (15:30 +0000)]
Teach the Triple class about kfreebsd (FreeBSD kernel with
a GNU userspace).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136085 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd LLVMAddAlwaysInlinerPass to the C API.
Rafael Espindola [Tue, 26 Jul 2011 15:23:23 +0000 (15:23 +0000)]
Add LLVMAddAlwaysInlinerPass to the C API.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136083 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoLLVM 3.0 is here, remove old do nothing method.
Rafael Espindola [Tue, 26 Jul 2011 15:17:32 +0000 (15:17 +0000)]
LLVM 3.0 is here, remove old do nothing method.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136082 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoSrcDef is only written and never read. Remove it.
Duncan Sands [Tue, 26 Jul 2011 15:05:06 +0000 (15:05 +0000)]
SrcDef is only written and never read.  Remove it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136080 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd helper function for getting true/false constants in a uniform
Duncan Sands [Tue, 26 Jul 2011 15:03:53 +0000 (15:03 +0000)]
Add helper function for getting true/false constants in a uniform
way for i1 and vector of i1 types.  Use these to make some code
more self-documenting.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136079 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoClean up the HTML here a bit.
Bill Wendling [Tue, 26 Jul 2011 10:41:15 +0000 (10:41 +0000)]
Clean up the HTML here a bit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136074 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix typo in comment.
Jay Foad [Tue, 26 Jul 2011 09:36:52 +0000 (09:36 +0000)]
Fix typo in comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136068 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoDon't try to dereference syms[0] on an empty vector. Reported by Todd Jackson
Nick Lewycky [Tue, 26 Jul 2011 08:40:36 +0000 (08:40 +0000)]
Don't try to dereference syms[0] on an empty vector. Reported by Todd Jackson
and Jeffrey Bosboom!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136066 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoThe compact unwinding offsets are divided by 8 on 64-bit machines.
Bill Wendling [Tue, 26 Jul 2011 08:03:49 +0000 (08:03 +0000)]
The compact unwinding offsets are divided by 8 on 64-bit machines.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136065 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoDescribe the reasoning for compact unwind in better terms. Thanks to Nick Kledzik...
Bill Wendling [Tue, 26 Jul 2011 07:58:09 +0000 (07:58 +0000)]
Describe the reasoning for compact unwind in better terms. Thanks to Nick Kledzik for the description.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136064 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd 256-bit isel for movsldup/movshdup
Bruno Cardoso Lopes [Tue, 26 Jul 2011 02:39:32 +0000 (02:39 +0000)]
Add 256-bit isel for movsldup/movshdup

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136051 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMore movsldup/movshdup cleanup. Rewrite the mask matching function and add
Bruno Cardoso Lopes [Tue, 26 Jul 2011 02:39:28 +0000 (02:39 +0000)]
More movsldup/movshdup cleanup. Rewrite the mask matching function and add
support for 256-bit versions (but no instruction selection yet, coming next).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136050 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMore cleanup, subtarget info isn't used here.
Bruno Cardoso Lopes [Tue, 26 Jul 2011 02:39:25 +0000 (02:39 +0000)]
More cleanup, subtarget info isn't used here.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136049 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd 128-bit AVX versions of movshdup/mosldup
Bruno Cardoso Lopes [Tue, 26 Jul 2011 02:39:23 +0000 (02:39 +0000)]
Add 128-bit AVX versions of movshdup/mosldup

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136048 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCleanup movsldup/movshdup matching.
Bruno Cardoso Lopes [Tue, 26 Jul 2011 02:39:13 +0000 (02:39 +0000)]
Cleanup movsldup/movshdup matching.
27 insertions(+), 62 deletions(-)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136047 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRevert to RA_Assign when a virtreg separates into components.
Jakob Stoklund Olesen [Tue, 26 Jul 2011 00:54:56 +0000 (00:54 +0000)]
Revert to RA_Assign when a virtreg separates into components.

When dead code elimination deletes a PHI value, the virtual register may
split into multiple connected components. In that case, revert each
component to the RS_Assign stage.

The new components are guaranteed to be smaller (the original value
numbers are distributed among the components), so this will always be
making progress. The components are now allowed to evict other live
ranges or be split again.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136034 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRename createCodeEmitter to createMCCodeEmitter; createObjectStreamer to createMCObje...
Evan Cheng [Tue, 26 Jul 2011 00:42:34 +0000 (00:42 +0000)]
Rename createCodeEmitter to createMCCodeEmitter; createObjectStreamer to createMCObjectStreamer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136031 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRemove a file from CMakeLists.txt that Evan removed in r136027.
Chandler Carruth [Tue, 26 Jul 2011 00:30:33 +0000 (00:30 +0000)]
Remove a file from CMakeLists.txt that Evan removed in r136027.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136030 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRename TargetAsmParser to MCTargetAsmParser and TargetAsmLexer to MCTargetAsmLexer...
Evan Cheng [Tue, 26 Jul 2011 00:24:13 +0000 (00:24 +0000)]
Rename TargetAsmParser to MCTargetAsmParser and TargetAsmLexer to MCTargetAsmLexer; rename createAsmLexer to createMCAsmLexer and createAsmParser to createMCAsmParser.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136027 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoStill more library dependency updates. This reflects the ever decreasing
Chandler Carruth [Tue, 26 Jul 2011 00:09:11 +0000 (00:09 +0000)]
Still more library dependency updates. This reflects the ever decreasing
dependence on CodeGen layers and backends from the MC layers.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136024 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoClean up a pile of hacks in our CMake build relating to TableGen.
Chandler Carruth [Tue, 26 Jul 2011 00:09:08 +0000 (00:09 +0000)]
Clean up a pile of hacks in our CMake build relating to TableGen.

The first problem to fix is to stop creating synthetic *Table_gen
targets next to all of the LLVM libraries. These had no real effect as
CMake specifies that add_custom_command(OUTPUT ...) directives (what the
'tablegen(...)' stuff expands to) are implicitly added as dependencies
to all the rules in that CMakeLists.txt.

These synthetic rules started to cause problems as we started more and
more heavily using tablegen files from *subdirectories* of the one where
they were generated. Within those directories, the set of tablegen
outputs was still available and so these synthetic rules added them as
dependencies of those subdirectories. However, they were no longer
properly associated with the custom command to generate them. Most of
the time this "just worked" because something would get to the parent
directory first, and run tablegen there. Once run, the files existed and
the build proceeded happily. However, as more and more subdirectories
have started using this, the probability of this failing to happen has
increased. Recently with the MC refactorings, it became quite common for
me when touching a large enough number of targets.

To add insult to injury, several of the backends *tried* to fix this by
adding explicit dependencies back to the parent directory's tablegen
rules, but those dependencies didn't work as expected -- they weren't
forming a linear chain, they were adding another thread in the race.

This patch removes these synthetic rules completely, and adds a much
simpler function to declare explicitly that a collection of tablegen'ed
files are referenced by other libraries. From that, we can add explicit
dependencies from the smaller libraries (such as every architectures
Desc library) on this and correctly form a linear sequence. All of the
backends are updated to use it, sometimes replacing the existing attempt
at adding a dependency, sometimes adding a previously missing dependency
edge.

Please let me know if this causes any problems, but it fixes a rather
persistent and problematic source of build flakiness on our end.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136023 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM assembly parsing and encoding for SSAX, SSUB16 and SSUB8.
Jim Grosbach [Mon, 25 Jul 2011 23:32:14 +0000 (23:32 +0000)]
ARM assembly parsing and encoding for SSAX, SSUB16 and SSUB8.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136013 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoTargetAsmBackend has been renamed to MCAsmBackend.
Evan Cheng [Mon, 25 Jul 2011 23:28:36 +0000 (23:28 +0000)]
TargetAsmBackend has been renamed to MCAsmBackend.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136012 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRename TargetAsmBackend to MCAsmBackend; rename createAsmBackend to createMCAsmBackend.
Evan Cheng [Mon, 25 Jul 2011 23:24:55 +0000 (23:24 +0000)]
Rename TargetAsmBackend to MCAsmBackend; rename createAsmBackend to createMCAsmBackend.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136010 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoInitial implementation of 'fence' instruction, the new C++0x-style replacement for...
Eli Friedman [Mon, 25 Jul 2011 23:16:38 +0000 (23:16 +0000)]
Initial implementation of 'fence' instruction, the new C++0x-style 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

12 years agoFinish adding support for lifetime intrinsics to SROA. Fixes PR10121!
Nick Lewycky [Mon, 25 Jul 2011 23:14:22 +0000 (23:14 +0000)]
Finish adding support for lifetime intrinsics to SROA. Fixes PR10121!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136008 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoI will save before I commit.
Benjamin Kramer [Mon, 25 Jul 2011 23:10:23 +0000 (23:10 +0000)]
I will save before I commit.
I will save before I commit.
I will save before I commit.
I will save before I commit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136007 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM assembly parsing and encoding for SSAT16 instruction.
Jim Grosbach [Mon, 25 Jul 2011 23:09:14 +0000 (23:09 +0000)]
ARM assembly parsing and encoding for SSAT16 instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136006 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoCodegen allonesvector better while using AVX: vpcmpeqd + vinsertf128
Bruno Cardoso Lopes [Mon, 25 Jul 2011 23:05:32 +0000 (23:05 +0000)]
Codegen allonesvector better while using AVX: vpcmpeqd + vinsertf128
This also fixes PR10452

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136004 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd remaining 256-bit vector bitcasts. This also fixes PR10451
Bruno Cardoso Lopes [Mon, 25 Jul 2011 23:05:28 +0000 (23:05 +0000)]
Add remaining 256-bit vector bitcasts. This also fixes PR10451

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136003 91177308-0d34-0410-b5e6-96231b3b80d8

12 years ago- Handle special scalar_to_vector case: splats. Using a native 128-bit
Bruno Cardoso Lopes [Mon, 25 Jul 2011 23:05:25 +0000 (23:05 +0000)]
- Handle special scalar_to_vector case: splats. Using a native 128-bit
shuffle before inserting on a 256-bit vector.
- Add AVX versions of movd/movq instructions
- Introduce a few COPY patterns to match insert_subvector instructions.
This turns a trivial insert_subvector instruction into a register copy,
coalescing the xmm into a ymm and avoid emiting on more instruction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136002 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoReintroduce r135730, this is indeed the right approach, there is no
Bruno Cardoso Lopes [Mon, 25 Jul 2011 23:05:16 +0000 (23:05 +0000)]
Reintroduce r135730, this is indeed the right approach, there is no
native 256-bit vector instruction to do scalar_to_vector.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136001 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agollvm-objdump: Ignore unreachable blocks when printing the CFG.
Benjamin Kramer [Mon, 25 Jul 2011 23:04:36 +0000 (23:04 +0000)]
llvm-objdump: Ignore unreachable blocks when printing the CFG.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136000 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix include guards.
Evan Cheng [Mon, 25 Jul 2011 22:52:04 +0000 (22:52 +0000)]
Fix include guards.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135998 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd a note about efficient codegen for binary log.
Benjamin Kramer [Mon, 25 Jul 2011 22:30:00 +0000 (22:30 +0000)]
Add a note about efficient codegen for binary log.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135996 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAttempt to fix test failure reported on llvm-commits.
Eli Friedman [Mon, 25 Jul 2011 22:28:51 +0000 (22:28 +0000)]
Attempt to fix test failure reported on llvm-commits.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135995 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoBranchProbability::print returns void now.
Jakub Staszak [Mon, 25 Jul 2011 22:27:42 +0000 (22:27 +0000)]
BranchProbability::print returns void now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135994 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMake sure this DAGCombine actually returns an UNDEF of the correct type; PR10476.
Eli Friedman [Mon, 25 Jul 2011 22:25:42 +0000 (22:25 +0000)]
Make sure this DAGCombine actually returns an UNDEF of the correct type; PR10476.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135993 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd BlockFrequency class.
Jakub Staszak [Mon, 25 Jul 2011 22:24:51 +0000 (22:24 +0000)]
Add BlockFrequency class.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135992 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoARM assembly parsing and encoding for SSAT instruction.
Jim Grosbach [Mon, 25 Jul 2011 22:20:28 +0000 (22:20 +0000)]
ARM assembly parsing and encoding for SSAT instruction.

Fix the Rn register encoding for both SSAT and USAT. Update the parsing of the
shift operand to correctly handle the allowed shift types and immediate ranges
and issue meaningful diagnostics when an illegal value or shift type is
specified. Add aliases to parse an ommitted shift operand (default value of
'lsl #0').

Add tests for diagnostics and proper encoding.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135990 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoAdd clarifying comments for the new arguments to UnrollLoop.
Andrew Trick [Mon, 25 Jul 2011 22:17:47 +0000 (22:17 +0000)]
Add clarifying comments for the new arguments to UnrollLoop.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135988 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoRefactoring fail.
Evan Cheng [Mon, 25 Jul 2011 22:16:37 +0000 (22:16 +0000)]
Refactoring fail.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135986 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMove CBackend and CppBackend MC initialization to TargetInfo.
Evan Cheng [Mon, 25 Jul 2011 21:44:12 +0000 (21:44 +0000)]
Move CBackend and CppBackend MC initialization to TargetInfo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135982 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoGet rid of an incorrect optimization for shuffles with PALIGNR and simplify isPALIGNR...
Eli Friedman [Mon, 25 Jul 2011 21:36:45 +0000 (21:36 +0000)]
Get rid of an incorrect optimization for shuffles with PALIGNR and simplify isPALIGNRMask.

Addresses PR10466, although the crash from that PR only triggers in cases where DAGCombine misses optimizing a shuffle.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135980 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoFix more MC layering violations.
Evan Cheng [Mon, 25 Jul 2011 21:32:49 +0000 (21:32 +0000)]
Fix more MC layering violations.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135979 91177308-0d34-0410-b5e6-96231b3b80d8

12 years agoMore MC layering violations.
Evan Cheng [Mon, 25 Jul 2011 21:29:26 +0000 (21:29 +0000)]
More MC layering violations.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135978 91177308-0d34-0410-b5e6-96231b3b80d8