Bruno Cardoso Lopes [Mon, 1 Aug 2011 21:54:09 +0000 (21:54 +0000)]
Add v4f64 -> v2f32 fp_round support. Also add a testcase to exercise
the legalizer. This commit together with the two previous ones fixes
PR10495.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136654
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Mon, 1 Aug 2011 21:54:05 +0000 (21:54 +0000)]
Teach PreprocessISelDAG to be aware of vector types and to not process them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136653
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Mon, 1 Aug 2011 21:54:02 +0000 (21:54 +0000)]
Lower CONCAT_VECTORS to use two VINSERTF128 instructions instead of
using a stack store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136652
91177308-0d34-0410-b5e6-
96231b3b80d8
Roman Divacky [Mon, 1 Aug 2011 20:38:27 +0000 (20:38 +0000)]
Fix a typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136646
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Mon, 1 Aug 2011 20:06:49 +0000 (20:06 +0000)]
The FixedLenDecoder needs to gracefully handle failing per-instruction decoder hooks in addition to per-operand decoder hooks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136645
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Mon, 1 Aug 2011 19:55:11 +0000 (19:55 +0000)]
Actually finish switching to the new system for Target sublibrary
TableGen deps introduced in r136023. This completes the fixing that
dgregor started in r136621. Sorry for missing these the first time
around.
This should fix some of the random race-condition failures people are
still seeing with CMake.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136643
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Mon, 1 Aug 2011 19:51:53 +0000 (19:51 +0000)]
Since vectors with all ones can't be created with a 256-bit instruction,
avoid returning early for v8i32 types, which would only be valid for
vector with all zeros. Also split the handling of zeros and ones into separate
checking logic since they are handled differently. This fixes PR10547
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136642
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 1 Aug 2011 19:43:05 +0000 (19:43 +0000)]
Set endianess and pointer size for PPC Linux. Bug noticed by Roman Divacky.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136639
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Mon, 1 Aug 2011 19:16:26 +0000 (19:16 +0000)]
Change SmallVector to SmallPtrSet in BranchProbabilityInfo. Handle cases where
one than one successor goes to the same block.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136638
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Mon, 1 Aug 2011 18:44:37 +0000 (18:44 +0000)]
Enhance the fixed length disassembler to better handle operand decoding failures.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136635
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Mon, 1 Aug 2011 18:43:18 +0000 (18:43 +0000)]
Add a clear() operation to MCInst, to drop all of its operands. Useful for the disassembler, where we may realize fairly late into decoding that something is wrong and need to reset.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136634
91177308-0d34-0410-b5e6-
96231b3b80d8
Richard Osborne [Mon, 1 Aug 2011 16:45:59 +0000 (16:45 +0000)]
Fix crash with varargs function with no named parameters.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136623
91177308-0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Mon, 1 Aug 2011 16:29:27 +0000 (16:29 +0000)]
Update CMake target names for tablegen-generated data in the X86 and ARM targets. This should fix the CMake build with MSVC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136621
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Mon, 1 Aug 2011 15:22:10 +0000 (15:22 +0000)]
Add BlockFrequency::getEntryFrequency()
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136618
91177308-0d34-0410-b5e6-
96231b3b80d8
Jay Foad [Mon, 1 Aug 2011 12:48:54 +0000 (12:48 +0000)]
Add braces.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136612
91177308-0d34-0410-b5e6-
96231b3b80d8
Jay Foad [Mon, 1 Aug 2011 12:29:14 +0000 (12:29 +0000)]
Simplify printAlias.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136611
91177308-0d34-0410-b5e6-
96231b3b80d8
Jay Foad [Mon, 1 Aug 2011 12:28:01 +0000 (12:28 +0000)]
Micro-optimisation in getAliasedGlobal.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136610
91177308-0d34-0410-b5e6-
96231b3b80d8
Jay Foad [Mon, 1 Aug 2011 12:27:15 +0000 (12:27 +0000)]
Remove an unnecessary cast.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136609
91177308-0d34-0410-b5e6-
96231b3b80d8
Jay Foad [Mon, 1 Aug 2011 12:20:36 +0000 (12:20 +0000)]
The operands of a GlobalAlias are always Constants. Simplify things
accordingly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136608
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Sun, 31 Jul 2011 22:00:40 +0000 (22:00 +0000)]
I mis-interpreted the MCDisassembler's intended dependencies. Now to fix
them properly. Specifically, the disassembler clearly attempts to
initialiaze all TargetInfo, MCTargeDesc, AsmParser, and Disassembler
sublibraries of registered targets. This makes the CMakeLists accurately
reflect this intent in the code.
This should fix the last of the link errors that I have gotten reports
of on OS X, but if anyone continues to see link errors, continue to
pester me and I'll look into it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136603
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Sun, 31 Jul 2011 06:47:33 +0000 (06:47 +0000)]
Fix some validation errors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136591
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Sun, 31 Jul 2011 06:45:03 +0000 (06:45 +0000)]
Fix some validation errors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136590
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Sun, 31 Jul 2011 06:30:59 +0000 (06:30 +0000)]
Add the 'resume' instruction for the new EH rewrite.
This adds the 'resume' instruction class, IR parsing, and bitcode reading and
writing. The 'resume' instruction resumes propagation of an existing (in-flight)
exception whose unwinding was interrupted with a 'landingpad' instruction (to be
added later).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136589
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Sun, 31 Jul 2011 05:54:04 +0000 (05:54 +0000)]
Do not handle cases with >= and <= predicates.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136588
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Sun, 31 Jul 2011 04:51:14 +0000 (04:51 +0000)]
Remove untrue comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136587
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Sun, 31 Jul 2011 04:47:20 +0000 (04:47 +0000)]
Do not handle case where LHS is equal to zero, because InstCombiner always moves
it to RHS anyway.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136586
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sun, 31 Jul 2011 04:43:41 +0000 (04:43 +0000)]
Add a small gep optimization I noticed was missing while reading some IL.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136585
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sun, 31 Jul 2011 03:53:42 +0000 (03:53 +0000)]
Time the emission of debug values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136584
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Sun, 31 Jul 2011 03:27:24 +0000 (03:27 +0000)]
Add Zero Heurestics to BranchProbabilityInfo. If we compare value to zero we
decide whether condition is likely to be true this way:
x == 0 -> false
x < 0 -> false
x <= 0 -> false
x != 0 -> true
x > 0 -> true
x >= 0 -> true
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136583
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Sun, 31 Jul 2011 01:12:39 +0000 (01:12 +0000)]
Remove InvalidateStructLayoutInfo from the ocaml bindings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136582
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sat, 30 Jul 2011 17:19:14 +0000 (17:19 +0000)]
Revert r136528 "Enable compact region splitting by default."
While this generally helped x86-64, there was some large regressions
for i386.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136571
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Sat, 30 Jul 2011 10:10:23 +0000 (10:10 +0000)]
Switch another of the old dependencies on implicitly produced synthetic
rules to the new explicitly listed TableGen rules. Somehow I missed this
in my original sweep.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136567
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Sat, 30 Jul 2011 08:47:05 +0000 (08:47 +0000)]
Remove yet another buried and hidden implicit dependency: every single
sub-library for the targets depended on the core target CodeGen library.
This completely undermined the careful work to separate the those
libraries, especially the MC-layer ones. This surfaced as circular
dependencies when the libraries were built as shared libraries where
CMake doesn't allow cycles.
This should fix PR10537. I'll watch the bots to see if there is fallout
on other platforms.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136565
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Sat, 30 Jul 2011 05:42:50 +0000 (05:42 +0000)]
Revert r136253, r136263, r136269, r136313, r136325, r136326, r136329, r136338,
r136339, r136341, r136369, r136387, r136392, r136396, r136429, r136430, r136444,
r136445, r136446, r136253 pending review.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136556
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Callanan [Sat, 30 Jul 2011 01:29:54 +0000 (01:29 +0000)]
Added several architecture names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136552
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sat, 30 Jul 2011 00:57:25 +0000 (00:57 +0000)]
Revert "Don't check liveness of unallocatable registers."
The ARM target depends on CPSR liveness being tracked after register
allocation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136548
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Fri, 29 Jul 2011 23:52:01 +0000 (23:52 +0000)]
Make my attempt to build up global deps variables actually utilize
globally scoped constructs. Also, round-trip these dependencies through
the LLVMConfig.cmake.in file thata is used by CMake-based clients of
"installed" (or built) LLVM trees.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136543
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 29 Jul 2011 23:36:21 +0000 (23:36 +0000)]
Don't check liveness of unallocatable registers.
This includes registers like EFLAGS and ST0-ST7. We don't check for
liveness issues in the verifier and scavenger because registers will
never be allocated from these classes.
While in SSA form, we do care about the liveness of unallocatable
unreserved registers. Liveness of EFLAGS and ST0 neds to be correct for
MachineDCE and MachineSinking.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136541
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 29 Jul 2011 23:02:48 +0000 (23:02 +0000)]
Check for multiple defs in the machine code verifier.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136535
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Fri, 29 Jul 2011 23:01:18 +0000 (23:01 +0000)]
Correctly handle scattered operands where the bits of the operand are contiguous, but out of order.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136534
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 29 Jul 2011 22:51:22 +0000 (22:51 +0000)]
Add an isSSA() flag to MachineRegisterInfo.
This flag is true from isel to register allocation when the machine
function is required to be in SSA form. The TwoAddressInstructionPass
and PHIElimination passes clear the flag.
The SSA flag wil be used by the machine code verifier to check for SSA
form, and eventually an assertion can enforce it in +Asserts builds.
This will catch the common target error of creating machine code with
multiple defs of a virtual register.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136532
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 22:43:06 +0000 (22:43 +0000)]
Unconstify Inits
Remove const qualifiers from Init references, per Chris' request.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136531
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Fri, 29 Jul 2011 22:25:21 +0000 (22:25 +0000)]
Do not lose branch weights when lowering SwitchInst.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136529
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 29 Jul 2011 22:10:27 +0000 (22:10 +0000)]
Enable compact region splitting by default.
This helps generate better code in functions with high register
pressure.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136528
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 29 Jul 2011 21:18:58 +0000 (21:18 +0000)]
Add support for the 'Q' constraint.
Fixes rdar://
9866494
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136523
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 20:50:18 +0000 (20:50 +0000)]
Remove a blank line from the top.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136511
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 29 Jul 2011 20:32:28 +0000 (20:32 +0000)]
have the verifier catch gep's into opaque struct types. PR10473
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136510
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 29 Jul 2011 20:26:09 +0000 (20:26 +0000)]
ARM SRS instruction parsing, diassembly and encoding support.
Fix the instruction encoding for operands. Refactor mode to use explicit
instruction definitions per FIXME to be more consistent with loads/stores.
Fix disassembler accordingly. Add tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136509
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Fri, 29 Jul 2011 20:23:34 +0000 (20:23 +0000)]
On mac, it seems the MC disassembler is actually using the targetinfo
for targets that don't have an MC-ized disassembler. I'm suspicious that
this shouldn't actually be happening, but hoping to fix the CMake build
on macs first, and investigate why second.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136508
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Fri, 29 Jul 2011 20:05:36 +0000 (20:05 +0000)]
Remove unneeded const_cast.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136506
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 29 Jul 2011 20:02:39 +0000 (20:02 +0000)]
ARM CPS mode immediate is 5 bits, not 4.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136505
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Fri, 29 Jul 2011 19:49:58 +0000 (19:49 +0000)]
Clear DbgValues in the end.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136503
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Fri, 29 Jul 2011 19:30:00 +0000 (19:30 +0000)]
Add more constantness in BranchProbabilityInfo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136502
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:26 +0000 (19:07 +0000)]
[AVX] Make DagInits Unique
Make sure DagInits are unique and created only once.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136501
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:24 +0000 (19:07 +0000)]
[AVX] Make FieldInit Unique
Make sure FieldInits are unique and created only once.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136500
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:23 +0000 (19:07 +0000)]
[AVX] Make VarListElementInit Unique
Make sure VarListElementInits are unique and created only once.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136499
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:22 +0000 (19:07 +0000)]
[AVX] Make VarBitInit Unique
Make sure VarBitInits are unique and created only once.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136498
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:21 +0000 (19:07 +0000)]
[AVX] Make VarInit Unique
Make sure VarInits are unique and created only once.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136497
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:20 +0000 (19:07 +0000)]
[AVX] Make TernOpInit Unique
Make sure TernOpInits are unique and created only once. This will be
important for AVX/SIMD as many operators will be used to generate
patterns and other relevant data.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136496
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:19 +0000 (19:07 +0000)]
[AVX] Make BinOpInit Unique
Make sure BinOpInits are unique and created only once. This will be
important for AVX/SIMD as many operators will be used to generate
patterns and other relevant data.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136495
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:18 +0000 (19:07 +0000)]
[AVX] Make UnOpInit Unique
Make sure UnOpInits are unique and created only once. This will be
important for AVX/SIMD as many operators will be used to generate
patterns and other relevant data.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136494
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:16 +0000 (19:07 +0000)]
[AVX] Make ListInits Unique
Ensure ListInits are unique and only created once. This will be
important for AVX as lists will be used extensively to pass generic
patterns, prefix information and other things to lower-level
pattern-generation classes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136493
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:15 +0000 (19:07 +0000)]
[AVX] Make CodeInit Unique
Use a StringMap to ensure CodeInits are unique and created only
once.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136492
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:14 +0000 (19:07 +0000)]
[AVX] Make StringInit Unique
Use a StringMap to ensure the StringInits are unique. This is
especially important for AVX where we will have many smallish
strings representing instruction prefixes, suffixes and the like.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136491
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:12 +0000 (19:07 +0000)]
[AVX] Make IntInit Unique
Use a DenseMap to make sure only one IntInit of any value exists.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136490
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:11 +0000 (19:07 +0000)]
[AVX] Make BitsInit Unique
Make BitsInit a FoldingSetNode so we can unique it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136489
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:10 +0000 (19:07 +0000)]
[AVX] Unique BitInit
Keep only two copies of BitInit: one for true and one for false.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136488
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:09 +0000 (19:07 +0000)]
[AVX] Unique UnsetInit
Keep only one UnsetInit around.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136487
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:07 +0000 (19:07 +0000)]
[AVX] Create Inits Via Factory Method
Replace uses of new *Init with *Init::get. This hides the allocation
implementation so that we can unique Inits in various ways.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136486
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:05 +0000 (19:07 +0000)]
[AVX] Constify Inits
Make references to Inits const everywhere. This is the final step
before making them unique.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136485
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:02 +0000 (19:07 +0000)]
[AVX] Remove non-const Iterators
Remove all non-const iterators from Init classes. This is another
step toward constifying Inits and ultimately turning them into
FoldingSetNodes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136484
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:07:00 +0000 (19:07 +0000)]
[AVX] Remove Mutating Members from Inits
Get rid of all Init members that modify internal state. This is in
preparation for making references to Inits const.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136483
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:06:59 +0000 (19:06 +0000)]
Add ListInit::getValues
Add a getValues ListInit method to return the sequence of values in
the list.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136482
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 29 Jul 2011 19:06:58 +0000 (19:06 +0000)]
Add a std::string Wrapper for TableGen
Create a std::string wrapper for use as a DenseMap key. DenseMap is
not safe in generate with strings, so this wrapper indicates that only
strings guaranteed not to have certain values should be used in the
DenseMap.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136481
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Fri, 29 Jul 2011 19:00:35 +0000 (19:00 +0000)]
Clean up debug info after reassociation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136480
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 29 Jul 2011 18:47:24 +0000 (18:47 +0000)]
ARM assembly parsing and encoding for RFE instruction.
Fill in the missing fixed bits and the register operand bits of the instruction
encoding. Refactor the definition to make the mode explicit, which is
consistent with how loads and stores are normally represented and makes
parsing much easier. Add parsing aliases for pseudo-instruction variants.
Update the disassembler for the new representations. Add tests for parsing and
encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136479
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Fri, 29 Jul 2011 18:28:52 +0000 (18:28 +0000)]
Third time's the charm for implementing tied operand decoding properly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136478
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Fri, 29 Jul 2011 18:26:59 +0000 (18:26 +0000)]
Don't look at $PWD in GetCurrentDirectory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136477
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 29 Jul 2011 17:51:39 +0000 (17:51 +0000)]
ARM SRS and RFE instructions are not code-gen only.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136475
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 29 Jul 2011 17:42:17 +0000 (17:42 +0000)]
ARM range checking for mode on CPS instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136473
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 29 Jul 2011 17:39:27 +0000 (17:39 +0000)]
ARM update tests for CPS instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136472
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 29 Jul 2011 17:36:04 +0000 (17:36 +0000)]
Update FIXME.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136470
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 29 Jul 2011 17:33:29 +0000 (17:33 +0000)]
Tweak comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136468
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Fri, 29 Jul 2011 17:32:03 +0000 (17:32 +0000)]
Fix a case where, when trying to track tied operands, we'd accidentally overwrite our mapping.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136467
91177308-0d34-0410-b5e6-
96231b3b80d8
Douglas Gregor [Fri, 29 Jul 2011 15:41:39 +0000 (15:41 +0000)]
Switch the CMake edis build over to add_llvm_library_dependencies
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136463
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Fri, 29 Jul 2011 07:50:02 +0000 (07:50 +0000)]
Avoid undefined behaviour if somehow NUM_GRAPHS equals 2^32 (or
whatever the size of unsigned is), though this can't actually
occur for any integer value of NUM_NODES.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136460
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Fri, 29 Jul 2011 04:42:39 +0000 (04:42 +0000)]
Teach Path::GetCurrentDirectory to use $PWD, to support users who like to do
screwy things by setting PWD != getcwd(). For example, some developers I know
will use this to control the value in gcc's DW_AT_comp_dir value in debug
output. With this patch, that trick will now work on clang too.
The only other effect of this change is that the static analysis will now
respect $PWD when reporting the directory of the files in its HTML output. I
think that's fine.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136459
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Fri, 29 Jul 2011 03:49:23 +0000 (03:49 +0000)]
Fix a lot of typos, improve (but not necessarily fix) grammaros and reflow some
lines. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136458
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Fri, 29 Jul 2011 03:05:32 +0000 (03:05 +0000)]
Misc optimizer+codegen work for 'cmpxchg' and 'atomicrmw'. They appear to be
working on x86 (at least for trivial testcases); other architectures will
need more work so that they actually emit the appropriate instructions for
orderings stricter than 'monotonic'. (As far as I can tell, the ARM, PPC,
Mips, and Alpha backends need such changes.)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136457
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakub Staszak [Fri, 29 Jul 2011 02:36:53 +0000 (02:36 +0000)]
Remove incEdgeWeight and decEdgeWeight. Set edge weight directly to avoid
rounding errors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136456
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Fri, 29 Jul 2011 02:12:59 +0000 (02:12 +0000)]
Fix the MCDisassembler dependencies. These were just absurdly wrong.
First off, only depend on the actual MC-ized disassemblers in the
targets, not all of the libraries those in turn depend on.
Second off, only depend on those MC-ized disassemblers for targets we're
building.
This should fix builds of fewer than all targets.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136455
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Fri, 29 Jul 2011 02:05:28 +0000 (02:05 +0000)]
Fix two tests that I crashed in the previous commits. The mask elts
on the second half must be reindexed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136454
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Fri, 29 Jul 2011 01:31:15 +0000 (01:31 +0000)]
Match VPERMIL masks more strictly and update the target specific mask
generation to always catch the weird cases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136453
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Fri, 29 Jul 2011 01:31:11 +0000 (01:31 +0000)]
Add DecodeShuffle shuffle support for VPERMIPD variantes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136452
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Fri, 29 Jul 2011 01:31:07 +0000 (01:31 +0000)]
Add v8i32 and v4i64 vpermil patterns
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136451
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Fri, 29 Jul 2011 01:31:04 +0000 (01:31 +0000)]
Fix a bug while generating target specific VPERMIL masks: skip
undef mask elements. This fixes PR10529.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136450
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Fri, 29 Jul 2011 01:31:02 +0000 (01:31 +0000)]
Enable usage of SSE4 extracts and inserts in their 128-bit AVX forms.
Also tidy up code a bit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136449
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Fri, 29 Jul 2011 01:30:59 +0000 (01:30 +0000)]
Cleanup PALIGNR handling and remove the old palign pattern fragment.
Also make PALIGNR masks to don't match 256-bits, which isn't supported
It's also a step to solve PR10489
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136448
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 29 Jul 2011 01:15:29 +0000 (01:15 +0000)]
Use the pointer type size.
With this, we can now compile a simple EH program.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136446
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 29 Jul 2011 01:11:33 +0000 (01:11 +0000)]
And now something that compiles...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136445
91177308-0d34-0410-b5e6-
96231b3b80d8