Commit Graph

98602 Commits

Author SHA1 Message Date
Hao Liu
a339740cb8 [AArch64]Add missing pair intrinsics such as:
int32_t vminv_s32(int32x2_t a)
which should be compiled into SMINP Vd.2S,Vn.2S,Vm.2S


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196749 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-09 03:51:42 +00:00
Hao Liu
2f3f02f6f5 [AArch64]Pattern match failures for truncate store and extend load
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196748 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-09 03:34:08 +00:00
Venkatraman Govindaraju
e0dc442801 [SparcV9]: Expand MULHU/MULHS:i64 and UMUL_LOHI/SMUL_LOHI:i64 on sparcv9.
This fixes PR18150.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196735 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 22:06:07 +00:00
Manman Ren
8186046028 Revert 196544 due to internal bot failures.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196732 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 20:28:33 +00:00
Reed Kotler
9bdfe3644f Make sure we mark these registers as defined. Previously was done
in the td file.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196731 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 19:21:47 +00:00
Reed Kotler
c9ea75ee5b Cleaning up of prologue/epilogue code for Mips16. First step
here is to make save/restore into variable number of argument instructions.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196726 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 16:51:52 +00:00
Tim Northover
7c4342e90b ARM: fix folding of stack-adjustment (yet again).
When trying to eliminate an "sub sp, sp, #N" instruction by folding
it into an existing push/pop using dummy registers, we need to account
for the fact that this might affect precisely how "fp" gets set in the
prologue.

We were attempting this, but assuming that *whenever* we performed a
fold it would make a difference. This is false, for example, in:
    push {r4, r7, lr}
    add fp, sp, #4
    vpush {d8}
    sub sp, sp, #8

we can fold the "sub" into the "vpush", forming "vpush {d7, d8}".
However, in that case the "add fp" instruction mustn't change, which
we were getting wrong before.

Should fix PR18160.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196725 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 15:56:50 +00:00
Michael Kuperstein
d34102e551 Fixed CRLF
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196719 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 12:16:20 +00:00
Michael Kuperstein
7dba1260ea Ensure bitcode encoding of visibility styles stays stable. Patch by Boaz Ouriel.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196718 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 11:35:09 +00:00
Duncan P. N. Exon Smith
3f8ce09441 Fix comments for PassDebuggingString
No functionality change.  Changing comments to match code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196713 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 01:28:17 +00:00
Mark Seaborn
34005c92bb Fix inlining to not lose the "cleanup" clause from landingpads
This fixes PR17872.  This bug can lead to C++ destructors not being
called when they should be, when an exception is thrown.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196711 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 00:51:21 +00:00
Mark Seaborn
615f9b7162 Fix inlining to not produce duplicate landingpad clauses
Before this change, inlining one "invoke" into an outer "invoke" call
site can lead to the outer landingpad's catch/filter clauses being
copied multiple times into the resulting landingpad.  This happens:

 * when the inlined function contains multiple "resume" instructions,
   because forwardResume() copies the clauses but is called multiple
   times;

 * when the inlined function contains a "resume" and a "call", because
   HandleCallsInBlockInlinedThroughInvoke() copies the clauses but is
   redundant with forwardResume().

Fix this by deduplicating the code.

This problem doesn't lead to any incorrect execution; it's only
untidy.

This change will make fixing PR17872 a little easier.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196710 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-08 00:50:58 +00:00
Renato Golin
1de8133402 force vector width via cpu on vectorizer metadata enable
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196669 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 21:46:08 +00:00
Jakub Staszak
7ae72bfd94 Don't #include heavy Dominators.h file in LoopInfo.h. This change reduces
overall time of LLVM compilation by ~1%.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196667 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 21:20:17 +00:00
Rafael Espindola
f7f74c22b1 Remove the notion of primitive types.
They were out of place since the introduction of arbitrary precision integer
types.

This also synchronizes the documentation to Types.h, so it refers to first class
types and single value types.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196661 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 19:34:20 +00:00
NAKAMURA Takumi
dfe327f749 Whitespace cleanups.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196654 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 11:21:42 +00:00
NAKAMURA Takumi
2665f321ad Remove empty MCJIT/load-object-a.ll since r196641.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196645 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 06:17:10 +00:00
Andrew Trick
dcddd7146d Factor out the SchedRemainder/SchedBoundary from GenericScheduler strategy.
These helper classes take care of the book-keeping the drives the
GenericScheduler heuristics. It is likely that developers writing
target-specific schedulers that work similarly to GenericScheduler
will want to use these helpers too. The immediate goal is to develop a
GenericPostScheduler that can run in place of the old PostRAScheduler,
but will use the new machine model.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196643 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 05:59:44 +00:00
Lang Hames
a49701db7d Revert r196639 while I investigate a bot failure.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196641 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 04:25:19 +00:00
Lang Hames
d4ef813fd5 Correct think-o in foldPatchpoint. Thanks to Andy Trick for pointing it out.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196640 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 03:30:59 +00:00
Lang Hames
e7777cdc64 Add support for archives and object file caching under MCJIT.
Patch by Andy Kaylor, with minor edits to resolve merge conflicts.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196639 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 03:05:51 +00:00
Matt Arsenault
eb2934e782 Fix assert with copy from global through addrspacecast
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196638 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 02:58:45 +00:00
Matt Arsenault
47172e86cc Add getBitCastOrAddrSpaceCast
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196637 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 02:58:41 +00:00
Akira Hatanaka
ca37060166 [mips] Fix test case.
Indent the command lines to indicate they continue from previous lines. Also,
fix incorrect uses of CHECK-DAG and CHECK-NOT.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196636 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 02:48:29 +00:00
Rafael Espindola
954b6b844b Remove unused value.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196635 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 02:27:52 +00:00
Vincent Lejeune
d254d3111e Add a RequireStructuredCFG Field to TargetMachine.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196634 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 01:49:19 +00:00
Vincent Lejeune
7c8fbdac72 R600: Remove orphaned declarations
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196633 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 01:49:10 +00:00
Yuchen Wu
1b871ba44c llvm-cov: Added test.h header to tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196632 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 01:28:11 +00:00
Kaelyn Uhrain
b95d0907fc Fix the segfault reported in PR 11990.
The sefault occurs due to an infinite loop when the verifier tries to
determine the size of a type of the form "%rt = type { %rt }" while
checking an alloca of the type.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196626 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-07 00:13:34 +00:00
Kaelyn Uhrain
46af5e8efa Fix a narrowing warning due to a type mismatch (size_t vs uint64).
lib/Transforms/Instrumentation/AddressSanitizer.cpp:1405:36: error: non-constant-expression cannot be narrowed from type 'uint64_t' (aka 'unsigned long long') to 'size_t' (aka 'unsigned int') in initializer list [-Wc++11-narrowing]
    getAllocaSizeInBytes(AI),
    ^~~~~~~~~~~~~~~~~~~~~~~~

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196623 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 23:09:24 +00:00
David Peixotto
7db4f8d9d8 Cache AllowAtInIdentifier as class variable in AsmLexer
This commit caches the value of the AllowAtInIdentifier variable as
a class variable in AsmLexer. We do this to avoid repeated MAI
queries and string comparisons each time we lex an identifier.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196622 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 23:05:33 +00:00
Justin Bogner
74999cfe0c Support: Fix handling of args that begin with @ but aren't files
Command line arguments that begin with @ but aren't a path to an
existing file currently cause later @file arguments to be ignored.

Correctly skip over these arguments instead of trying to read a
non-existent file 20 times and giving up.

Since the problem manifests in the clang driver, the test is in that
repository.

Fixes rdar://problem/15590906

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196620 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 22:56:19 +00:00
Ana Pazos
a2bfea9743 Added support for mcpu krait
- krait processor currently modeled with the same features as A9.
- Krait processor additionally has VFP4 (fused multiply add/sub)
and hardware division features enabled.
- krait has currently the same Schedule model as A9
- krait cpu flag is not recognized by the GNU assembler yet,
it is replaced with march=armv7-a to avoid a lower march
from being used.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196619 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 22:48:17 +00:00
David Blaikie
b0ec1be634 DebugInfo: Move unit begin/end labels into the unit
This removes another case of spooky action at a distance (building the
same label names in multiple places creating an implicit dependency
between those places) and helps pave the way for type units.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196617 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 22:33:05 +00:00
David Blaikie
b5a244bd54 DebugInfo: Include the section and start-of-section label in the unit
This is a precursor to moving type units into the correct (debug_types)
section with comdat groups and full type unit headers.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196615 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 22:14:48 +00:00
Duncan P. N. Exon Smith
42883d0ac4 Don't use isNullValue to evaluate ConstantExpr
ConstantExpr can evaluate to false even when isNullValue gives false.

Fixes PR18143.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196611 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 21:48:36 +00:00
Yuchen Wu
92b10e5f85 llvm-cov: Regenerated gcov files with r195513 changes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196609 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 21:33:50 +00:00
David Peixotto
d05b93515d Integrated assembler incorrectly lexes ARM-style comments
The integrated assembler fails to properly lex arm comments when
they are adjacent to an identifier in the input stream. The reason
is that the arm comment symbol '@' is also used as symbol variant in
other assembly languages so when lexing an identifier it allows the
'@' symbol as part of the identifier.

Example:
  $ cat comment.s
  foo:
    add r0, r0@got to parse this as a comment

  $ llvm-mc -triple armv7 comment.s
  comment.s:4:18: error: unexpected token in argument list
    add r0, r0@got to parse this as a comment
                   ^
This should be parsed as correctly as `add r0, r0`.

This commit modifes the assembly lexer to not include the '@' symbol
in identifiers when lexing for targets that use '@' for comments.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196607 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 20:35:58 +00:00
Rafael Espindola
3221b5bd23 micro optimization: isSizedDerivedType is only called with arrays, vectors and structs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196604 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 20:12:19 +00:00
David Blaikie
08e03ce70f DwarfDebug: Walk skeletons during fission pubtypes/pubnames emission
This more accurately represents the actual walk - pubnames/pubtypes are
emitted into the .o, not the .dwo, and reference the skeletons not the
full units.

Use the newly established ID->index invariant to lookup the underlying
full unit to retrieve its public names and types.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196601 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 19:38:49 +00:00
David Blaikie
5877a5b8a2 DebugInfo: Ensure unit IDs (for non-skeletal units) match thein index in the list
This simplifies reasoning about the code and enables simple navigation
from a skeleton to its full unit. (currently there are no type unit
skeletons, so the skeleton list doesn't have the same ID == index
property)

Eventually we should get rid of this ID and just store the labels we
need as the IDs are allowing this code to create difficult to
manage/understand associations (loops over non-skeletal units are
implicitly referencing their skeletal units during pub* emission, for
example). It may be necessary to have some kind of skeleton->full unit
association and a more direct pointer or similar device would be
preferable than an index.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196600 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 19:38:46 +00:00
Weiming Zhao
1c6611db44 Bug 18149: [AArch32] VSel instructions has no ARMCC field
The current peephole optimizing for compare inst assumes an instr that
uses CPSR has an MO for ARM Cond code.However, for VSEL instructions
(vseqeq, vselgt, vselgt, vselvs), there is no such operand nor do
they support the modification of Cond Code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196588 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 17:56:48 +00:00
Andrew Trick
c008152a39 comment grammar
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196585 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 17:19:20 +00:00
Cameron McInally
febc28b529 Update AVX512 vector blend intrinsic names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196581 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 13:35:35 +00:00
Richard Sandiford
9f9758935a [SystemZ] Use LOAD AND TEST for comparisons with -0
...since it os equivalent to comparison with +0.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196580 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 09:59:12 +00:00
Richard Sandiford
8bf51dc72b [SystemZ] Extend the use of C(L)GFR
instcombine prefers to put extended operands first, so this patch
handles that case for C(L)GFR.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196579 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 09:56:50 +00:00
Richard Sandiford
e3a804ba21 [SystemZ] Optimize selects between 0 and -1
Since z has no setcc instruction as such, the choice of setBooleanContents
is a bit arbitrary.  Currently it's set to ZeroOrOneBooleanContent,
so we produced a branch-free form when selecting between 0 and 1,
but not when selecting between 0 and -1.  This patch handles the latter
case too.

At some point I'd like to measure whether it's better to use conditional
moves for constant selects on z196, but that's future work.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196578 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 09:53:09 +00:00
Kostya Serebryany
5aafde2d5a [asan] fix ndebug build with strict warnings (-Wunused-variable)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196574 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 09:26:09 +00:00
Kostya Serebryany
daa1bf3b74 [asan] rewrite asan's stack frame layout
Summary:
Rewrite asan's stack frame layout.
First, most of the stack layout logic is moved into a separte file
to make it more testable and (potentially) useful for other projects.
Second, make the frames more compact by using adaptive redzones
(smaller for small objects, larger for large objects).
Third, try to minimized gaps due to large alignments (this is hypothetical since
today we don't see many stack vars aligned by more than 32).

The frames indeed become more compact, but I'll still need to run more benchmarks
before committing, but I am sking for review now to get early feedback.

This change will be accompanied by a trivial change in compiler-rt tests
to match the new frame sizes.

Reviewers: samsonov, dvyukov

Reviewed By: samsonov

CC: llvm-commits

Differential Revision: http://llvm-reviews.chandlerc.com/D2324

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196568 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 09:00:17 +00:00
Daniel Jasper
21c34931e8 Fix bug introduced in r196517.
Not only does it trigger -Wparentheses, I think the assert actually
relies on incorrect operator precedence.

Also, the grammar as questionable, but I might not know enough about the
problem at hand.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196567 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-06 08:58:22 +00:00