Commit Graph

83846 Commits

Author SHA1 Message Date
Benjamin Kramer
b26e2916c9 Replace some explicit compare loops with std::equal.
No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160501 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 10:46:05 +00:00
Jush Lu
ee649839a2 [arm-fast-isel] Add support for vararg function calls.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160500 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 09:49:00 +00:00
Alexey Samsonov
71d94f8055 DebugInfo library: add support for fetching absolute paths to source files
(instead of basenames) from DWARF. Use this behavior in llvm-dwarfdump tool.

Reviewed by Benjamin Kramer.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160496 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 07:03:58 +00:00
Galina Kistanova
72ea0c9ffa Fixed few warnings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160493 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 04:50:12 +00:00
Bill Wendling
0818e71e8f Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160483 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:25:04 +00:00
Bill Wendling
df6c55155c Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160482 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:23:13 +00:00
Bill Wendling
f59083cc02 Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160480 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:17:40 +00:00
Bill Wendling
2127c9b93a Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160479 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:15:11 +00:00
Chad Rosier
7a43e30a9b Tweak prose.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160478 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:11:45 +00:00
Bill Wendling
56cb229866 Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160477 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:11:40 +00:00
Bill Wendling
79223c3654 Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160476 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:06:06 +00:00
Bill Wendling
96cb112852 Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160475 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:04:14 +00:00
Bill Wendling
8c51e3995d Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160473 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:01:33 +00:00
Bill Wendling
17689b13be Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160472 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-19 00:01:00 +00:00
Bill Wendling
aa7507d68d Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160471 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 23:58:37 +00:00
Richard Trieu
76f63aef56 Move around some enum elements so that lastMRM corrects gets assigned 56, which
is one more that MRM_DF which is 55.  Previously, it held value 45, the same
as MRM_D0.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160465 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 23:04:22 +00:00
Jim Grosbach
b8d17643a5 TblGen: Tweak to pretty-print DAGISel.inc a bit better.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160463 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 22:41:03 +00:00
Jordan Rose
6ef4996b09 Allow PointerIntPairs to be created from const void *.
For a measure of safety, this conversion is only permitted if the
stored pointer type can also be created from a const void *.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160456 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 21:58:49 +00:00
Manman Ren
62a89f5808 X86: remove redundant cmp against zero.
Updated OptimizeCompare in peephole to remove redundant cmp against zero.
We only remove Compare if CF and OF are not used.

rdar://11855129


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160454 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 21:40:01 +00:00
Preston Gurd
d4d961615c This patch fixes 8 out of 20 unexpected failures in "make check"
when run on an Intel Atom processor. The failures have arisen due
to changes elsewhere in the trunk over the past 8 weeks or so.

These failures were not detected by the Atom buildbot because the
CPU on the Atom buildbot was not being detected as an Atom CPU.
The fix for this problem is in Host.cpp and X86Subtarget.cpp, but
shall remain commented out until the current set of Atom test failures
are fixed.

Patch by Andy Zhang and Tyler Nowicki!



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160451 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 20:49:17 +00:00
Victor Oliveira
1ef3b6c90d Adding some debug information to PassManager
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160446 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 19:59:29 +00:00
Chad Rosier
df9495390a Whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160445 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 19:35:16 +00:00
Chandler Carruth
32d75bec4b Fix a somewhat nasty crasher in PR13378. This crashes inside of
LiveIntervals due to the two-addr pass generating bogus MI code.

The crux of the issue was a loop nesting problem. The intent of the code
which attempts to transform instructions before converting them to
two-addr form is to defer and reprocess any transformed instructions as
the second processing is likely to have more opportunities to coalesce
copies, etc. Unfortunately, there was one section of processing that was
not deferred -- the INSERT_SUBREG rewriting. Due to quirks of how this
rewriting proceeded, not only did it occur early, it removed the bits of
information needed for the deferred processing to correctly generate the
necessary two address form (specifically inserting a copy), but didn't
trigger any immediate assertions and produced what appeared to be
already valid two-address from code. Thus, the assertion only fired much
later in the pipeline.

The fix is to hoist the transformation logic up layer to where it can
more firmly defer all further processing, and to teach the normal
processing to handle an edge case previously handled as part of the
transformation logic. This edge case (already matched tied register
operands) needs to *not* defer any steps.

As has been brought up repeatedly in the process: wow does this code
need refactoring. I *may* squeeze in some time to at least bring sanity
to this loop... but wow... =]

Thanks to Jakob for helpful hints on the way here, and the review.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160443 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 18:58:22 +00:00
Andrew Trick
8d8d961de4 Fix ARMTargetLowering::isLegalAddImmediate to consider thumb encodings.
Based on Evan's suggestion without a commitable test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160441 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 18:34:27 +00:00
Andrew Trick
49b446fa0a whitespace
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160440 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 18:34:24 +00:00
Andrew Trick
2f3c326786 Added unit test for PR13361: LSR + SCEV "hangs" on reasonably sized test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160439 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 18:07:52 +00:00
Victor Oliveira
26ad67adcd test commit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160438 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 17:53:05 +00:00
Simon Atanasyan
6aef977e85 Add some missed ELF constants definitions:
- section types
- dynamic table entries tags
- state flags for DT_FLAGS_1 entry

The patch reviewed by Rafael Espindola.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160433 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 14:12:32 +00:00
NAKAMURA Takumi
2e14d27cc4 Update config.h.cmake corresponding to config.h.in.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160431 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 09:17:02 +00:00
Nadav Rotem
fd34c110cf The vbroadcast family of instructions has 'fallback patterns' in case where the
load source operand is used by multiple nodes. The v2i64 broadcast was emulated
by shuffling the two lower i32 elements to the upper two.
We had a bug in the immediate used for the broadcast.
Replacing 0 to 0x44.
0x44 means [01|00|01|00] which corresponds to the correct lane.

Patch by Michael Kuperstein.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160430 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 08:14:48 +00:00
Jack Carter
a0f14afee1 Mips specific inline asm operand modifier 'M':
Print the high order register of a double word register operand.

In 32 bit mode, a 64 bit double word integer will be represented
by 2 32 bit registers. This modifier causes the high order register
to be used in the asm expression. It is useful if you are using 
doubles in assembler and continue to control register to variable
relationships.

This patch also fixes a related bug in a previous patch:

    case 'D': // Second part of a double word register operand
    case 'L': // Low order register of a double word register operand
    case 'M': // High order register of a double word register operand

I got 'D' and 'M' confused. The second part of a double word operand
will only match 'M' for one of the endianesses. I had 'L' and 'D'
be the opposite twins when 'L' and 'M' are.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160429 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 06:41:36 +00:00
Andrew Trick
18a1b616ea SCEVTraversal: Add a visited set.
Expression trees may be DAGs. Make sure traversal has linear complexity.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160426 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 05:14:03 +00:00
Craig Topper
76bd9386f1 Remove tab characters.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160425 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 04:59:16 +00:00
Craig Topper
833d7f8588 Fix typo in error message and remove some tab characters.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160423 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 04:36:35 +00:00
Andrew Trick
7f496a628e indvars: drive by heuristics fix.
Minor oversight noticed by inspection. Sorry no unit test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160422 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 04:35:13 +00:00
Andrew Trick
4781d8ee1c indvars: Linear function test replace should avoid reusing undef.
Fixes PR13371: indvars pass incorrectly substitutes 'undef' values.

I do not like this fix. It's needed until/unless the meaning of undef
changes. It attempts to be complete according to the IR spec, but I
don't have much confidence in the implementation given the difficulty
testing undefined behavior. Worse, this invalidates some of my
hard-fought work on indvars and LSR to optimize pointer induction
variables. It results benchmark regressions, which I'll track
internally. On x86_64 no LTO I see:

-3% huffbench
-3% 400.perlbench
-8% fhourstones

My only suggestion for recovering is to change the meaning of
undef. If we could trust an arbitrary instruction to produce a some
real value that can be manipulated (e.g. incremented) according to
non-undef rules, then this case could be easily handled with SCEV.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160421 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 04:35:10 +00:00
Craig Topper
75dc33a60b Make x86 asm parser to check for xmm vs ymm for index register in gather instructions. Also fix Intel syntax for gather instructions to use 'DWORD PTR' or 'QWORD PTR' to match gas.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160420 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 04:11:12 +00:00
Galina Kistanova
d3a32b952b Fixed few warnings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160419 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 04:06:49 +00:00
Nuno Lopes
4532bf6ecf ignore 'invoke @llvm.donothing', but still keep the edge to the continuation BB
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160411 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 00:07:17 +00:00
Joel Jones
7c82e6a32a More replacing of target-dependent intrinsics with target-indepdent
intrinsics.  The second instruction(s) to be handled are the vector versions 
of count set bits (ctpop).

The changes here are to clang so that it generates a target independent 
vector ctpop when it sees an ARM dependent vector bits set count.  The changes 
in llvm are to match the target independent vector ctpop and in 
VMCore/AutoUpgrade.cpp to update any existing bc files containing ARM 
dependent vector pop counts with target-independent ctpops.  There are also 
changes to an existing test case in llvm for ARM vector count instructions and 
to a test for the bitcode upgrade.

<rdar://problem/11892519>

There is deliberately no test for the change to clang, as so far as I know, no
consensus has been reached regarding how to test neon instructions in clang;
q.v. <rdar://problem/8762292>


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160410 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-18 00:02:16 +00:00
Nuno Lopes
0b5f1aca32 Apparently it's possible to do an 'invoke asm'.
Update the language reference to reflect that.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160408 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 23:51:33 +00:00
Akira Hatanaka
e882accb7a Clean up Mips16InstrFormats.td and Mips16InstrInfo.td.
Patch by Reed Kotler.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160403 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 22:55:34 +00:00
Evan Cheng
afb24cecff Add test case for r160387
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160389 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 19:40:05 +00:00
Evan Cheng
a9e13ba3c8 Back out r160101 and instead implement a dag combine to recover from instcombine transformation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160387 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 18:54:11 +00:00
Jim Grosbach
d3e31218ef TableGen: Pattern<> references to null_frag are a nop.
A standalone pattern defined in a multiclass expansion should handle
null_frag references just like patterns on instructions. Follow-up to
r160333.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160384 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 18:39:36 +00:00
Jakob Stoklund Olesen
1cacae0f29 Fix broken ipo_ext_iterator constructors.
These functions have obviously never been used before.
They should be identical to the idf_ext_iterator counterparts.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160381 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 17:57:25 +00:00
Jakob Stoklund Olesen
a532bcec2f Add some trace output to TwoAddressInstructionPass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160380 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 17:57:23 +00:00
Benjamin Kramer
de39671ebb Remove unused variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160372 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 17:00:11 +00:00
Nuno Lopes
5d2fada44c simplify getSetSize() per Duncan's comments
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160368 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 15:43:59 +00:00
NAKAMURA Takumi
f30135c519 llvm/test/Transforms/LoopRotate/PhiRename-1.ll: FileCheck-ize. It fixes PR13301.
It began choking since Chandler's r159547, possibly due to improper expression on grep from TclParser to ShParser.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160367 91177308-0d34-0410-b5e6-96231b3b80d8
2012-07-17 15:43:17 +00:00