Commit Graph

208285 Commits

Author SHA1 Message Date
Yaron Keren
24b64a9405 Add REQUIRES: x86-registered-target to test since it's required.
llvm-svn: 245462
2015-08-19 17:18:32 +00:00
Eric Fiselier
2838c169a5 [libcxxabi] Add "install-libcxxabi" target.
Summary:
Currently you can't install libc++abi from within the LLVM tree without installing all of LLVM. This patch adds an install rule for libc++abi.


Reviewers: danalbert, compnerd, rengolin, beanz

Subscribers: martell, beanz, jroelofs, cfe-commits

Differential Revision: http://reviews.llvm.org/D11682

llvm-svn: 245461
2015-08-19 17:17:21 +00:00
Chaoren Lin
d904371271 XTIMEOUT TestExitDuringStep for Darwin.
llvm-svn: 245460
2015-08-19 17:13:02 +00:00
Yaron Keren
7890a01263 According to i686 ABI, long double size on x86 is 12 bytes not 16 bytes.
See
 https://gcc.gnu.org/onlinedocs/gcc-3.2/gcc/i386-and-x86-64-Options.html

llvm-svn: 245459
2015-08-19 17:02:32 +00:00
Alexander Kornienko
e1292f8e4e [clang-tidy] Fix LoopConvertCheck bug.
Fix LoopConvertCheck bug: StringRef to temporaries.

Also add LLVM_ATTRIBUTE_UNUSED to ModernizeModuleAnchorDestination.

http://reviews.llvm.org/D12157

Patch by Angel Garcia!

llvm-svn: 245458
2015-08-19 16:54:51 +00:00
Renato Golin
eb552e83e0 Revert "[AArch64] Simplify/refactor code to ease code review. NFC."
This reverts commit r245443, as it broke AArch64 test-suite tramp3d
with an assert "Reg && "Null register has no regunits".

llvm-svn: 245455
2015-08-19 16:29:53 +00:00
Derek Schuff
55817ee604 x32. Fixes a bug in x32 exception handling.
This patch updates the X86 lowering so that the Exception Pointer and Selector
are 64-bit wide only if Subtarget.isTarget64BitLP64.

Patch by João Porto

Reviewers: dschuff, rnk
Differential Revision: http://reviews.llvm.org/D12111

llvm-svn: 245454
2015-08-19 16:28:21 +00:00
Filipe Cabecinhas
3e96367e60 [cmake darwin] Use a STATUS message type. Explain where the arches came from.
llvm-svn: 245453
2015-08-19 16:23:19 +00:00
JF Bastien
5ab87edbb4 x32. Fixes jmp %reg in x32
x32 has 32-bit pointers; x86-64 can't jmp %r32. This patch addresses this issue by explicitly zero-extending brind's target to 64-bits.

Author: jpp

Reviewers: jfb, dschuff, pavel.v.chupin

Subscribers: llvm-commits

Differential revision: http://reviews.llvm.org/D12112

llvm-svn: 245452
2015-08-19 16:17:08 +00:00
Tobias Grosser
b0da42fb55 Generate alias metadata even in OpenMP mode
To make alias scope metadata generation work in OpenMP mode we now provide
the ScopAnnotator with information about the base pointer rewrite that happens
when passing arrays into the OpenMP subfunction.

llvm-svn: 245451
2015-08-19 16:04:35 +00:00
James Y Knight
3b0fd753c4 [Sparc] Rename LoadASR and StoreASR from r245360 to *ASI, as was intended.
llvm-svn: 245450
2015-08-19 15:59:49 +00:00
Renato Golin
4b79ebceb4 [AArch64] Quick fix for cxa demangler
This makes all libcxxabi tests pass on AArch64. Further changes and
new tests to come.

Patch by Keith Walker.

llvm-svn: 245449
2015-08-19 15:24:03 +00:00
Pavel Labath
4b48595adf Increase timeout in TestCallThatRestarts
the test was failing on android because processing 30 signals involved a lot of round-trips,
which was not possible in the 0.5s default timeout. After the increase the test seems to pass
reliably.

llvm-svn: 245448
2015-08-19 15:24:02 +00:00
James Y Knight
5bdf7ab0cf Properly pass through the PIC mode to the integrated assembler when
doing assembly-only, and unify the Driver's PIC argument parsing.

On a few architectures, parsing of assembly files annoyingly depends
on whether PIC is enabled or not. This was handled for external 'as'
already (passing -KPIC), but was missed for calls to the standalone
internal assembler.

The integrated-as.s test needed to be modified to not expect
-fsanitize=address to be unused, as now fsanitize *IS* used for
assembly, since -fsanitize=memory can sometimes imply -fPIE, which the
assembler needs to know (gack!!).

Differential Revision: http://reviews.llvm.org/D11845

llvm-svn: 245447
2015-08-19 15:12:02 +00:00
Bruno Cardoso Lopes
61009142b8 Revert "[PeepholeOptimizer] Look through PHIs to find additional register sources"
Revert r245442 while investigating a fix. An assertion hit in
http://lab.llvm.org:8080/green/job/clang-stage1-configure-RA_build/11380

llvm-svn: 245446
2015-08-19 15:10:32 +00:00
Vladimir Sukharev
457d34193e [ARM] Proper generic cpus handling
"generic" cpu was wrongly handled as exact real CPU name of ARMv8.1A architecture.

This has been fixed, now it is abstract name, suitable for any arch.

Reviewers: rengolin

Subscribers: cfe-commits

Differential Revision: http://reviews.llvm.org/D11640

llvm-svn: 245445
2015-08-19 14:50:18 +00:00
James Y Knight
d966fb6fef [SPARC] Fix BooleanContents, so that select of a trunc doesn't
eliminate the trunc.

Differential Revision: http://reviews.llvm.org/D10442

llvm-svn: 245444
2015-08-19 14:47:04 +00:00
Chad Rosier
494abf1ad8 [AArch64] Simplify/refactor code to ease code review. NFC.
llvm-svn: 245443
2015-08-19 14:34:54 +00:00
Bruno Cardoso Lopes
0a1c126684 [PeepholeOptimizer] Look through PHIs to find additional register sources
Reapply r243486.

- Teaches the ValueTracker in the PeepholeOptimizer to look through PHI
instructions.
- Add findNextSourceAndRewritePHI method to lookup into multiple sources
returnted by the ValueTracker and rewrite PHIs with new sources.

With these changes we can find more register sources and rewrite more
copies to allow coaslescing of bitcast instructions. Hence, we eliminate
unnecessary VR64 <-> GR64 copies in x86, but it could be extended to
other archs by marking "isBitcast" on target specific instructions. The
x86 example follows:

A:
  psllq %mm1, %mm0
  movd  %mm0, %r9
  jmp C

B:
  por %mm1, %mm0
  movd  %mm0, %r9
  jmp C

C:
  movd  %r9, %mm0
  pshufw  $238, %mm0, %mm0

Becomes:

A:
  psllq %mm1, %mm0
  jmp C

B:
  por %mm1, %mm0
  jmp C

C:
  pshufw  $238, %mm0, %mm0

Differential Revision: http://reviews.llvm.org/D11197
rdar://problem/20404526

llvm-svn: 245442
2015-08-19 14:34:41 +00:00
Tobias Grosser
d8e3c8c665 Fix typo
llvm-svn: 245441
2015-08-19 14:22:48 +00:00
Pavel Labath
14e21925a5 Add TestCrashDuringStep
this tests that a crash that happens during instruction step is reported correctly.

llvm-svn: 245440
2015-08-19 14:15:45 +00:00
Silviu Baranga
ad1b19fcb7 [ARM] Add instruction selection patterns for vmin/vmax
Summary:
The mid-end was generating vector smin/smax/umin/umax nodes, but
we were using vbsl to generatate the code. This adds the vmin/vmax
patterns and a test to check that we are now generating vmin/vmax
instructions.

Reviewers: rengolin, jmolloy

Subscribers: aemerson, rengolin, llvm-commits

Differential Revision: http://reviews.llvm.org/D12105

llvm-svn: 245439
2015-08-19 14:11:27 +00:00
Kuba Brecka
746da5fe2a Fix typo in lib/safestack/CMakeLists.txt that prevents safestack static library from being built on OS X.
llvm-svn: 245438
2015-08-19 14:03:51 +00:00
Joerg Sonnenberger
7d180c59bb Map %fprs to %asr6 in the Sparc assembler parser.
llvm-svn: 245437
2015-08-19 13:55:14 +00:00
Pavel Labath
78856474fb On Linux, clear the signal mask of the launched inferior
Summary:
Due to fork()/execve(), the launched inferior inherits the signal mask of its parent (lldb-server). But because lldb-server modifies its signal mask (It blocks SIGCHLD, for example), the inferior starts with some signals being initially blocked.

One consequence is that TestCallThatRestarts.ExprCommandThatRestartsTestCase (test/expression_command/call-restarts) fails because sigchld_handler() in lotta-signals.c is not called, due to the SIGCHLD signal being blocked.

To prevent the signal masking done by lldb-server from affecting the created inferior, the signal mask of the inferior is now cleared before the execve().

Patch by: Yacine Belkadi

Reviewers: ovyalov, labath

Subscribers: lldb-commits

Differential Revision: http://reviews.llvm.org/D12138

llvm-svn: 245436
2015-08-19 13:47:57 +00:00
NAKAMURA Takumi
bc224b8049 clang-tools-extra/test/clang-tidy/readability-identifier-naming.cpp: Appease targeting msvc.
llvm-svn: 245435
2015-08-19 13:22:58 +00:00
Alexander Kornienko
bd725b4537 [clang-tidy] Add use-nullptr check to clang-tidy.
Move UseNullptr from clang-modernize to modernize module in clang-tidy.

http://reviews.llvm.org/D12081

Patch by Angel Garcia!

llvm-svn: 245434
2015-08-19 13:13:12 +00:00
Daniel Sanders
1e97a0b324 Emit <regmask R1 R2 R3 ...> instead of just <regmask> in IR dumps.
Reviewers: qcolombet

Subscribers: kparzysz, qcolombet, llvm-commits

Differential Revision: http://reviews.llvm.org/D11644

llvm-svn: 245433
2015-08-19 12:03:04 +00:00
Tobias Grosser
85508e804b Revert "[X86] Widen the 'AND' mask if doing so shrinks the encoding size"
This reverts commit 245169 which miscompiles MultiSource/Applications/siod
from LNT.

llvm-svn: 245432
2015-08-19 11:35:10 +00:00
Michael Kuperstein
9fe42604aa [X86] Do not lower scalar sdiv/udiv to a shifts + mul sequence when optimizing for minsize
There are some cases where the mul sequence is smaller, but for the most part,
using a div is preferable. This does not apply to vectors, since x86 doesn't
have vector idiv, and a vector mul/shifts sequence ought to be smaller than a
scalarized division.

Differential Revision: http://reviews.llvm.org/D12082

llvm-svn: 245431
2015-08-19 11:21:43 +00:00
Michael Kuperstein
dcdab4cd3a [TLI] Refactor "is integer division cheap" queries.
This removes the isPow2SDivCheap() query, as it is not currently used in
any meaningful way. isIntDivCheap() no longer relies on a state variable
(as all in-tree target set it to false), but the interface allows querying
based on the type optimization level.

NFC.

Differential Revision: http://reviews.llvm.org/D12082

llvm-svn: 245430
2015-08-19 11:17:59 +00:00
Alexander Kornienko
76c288062a [clang-tidy] Add new IdentifierNaming check
This check will try to enforce coding guidelines on the identifiers naming.
It supports lower_case, UPPER_CASE, camelBack and CamelCase casing and
tries to convert from one to another if a mismatch is detected.

It also supports a fixed prefix and suffix that will be prepended or appended
to the identifiers, regardless of the casing.

Many configuration options are available, in order to be able to create
different rules for different kind of identifier. In general, the
rules are falling back to a more generic rule if the specific case is not
configured.

http://reviews.llvm.org/D10933

Patch by Beren Minor!

llvm-svn: 245429
2015-08-19 11:15:36 +00:00
Omair Javaid
dee4a867be Fix lldb-server arm-linux-g++ build
llvm-svn: 245428
2015-08-19 10:44:16 +00:00
Alexander Kornienko
0497084b69 [clang-tidy] Add loop-convert check to clang-tidy.
Move LoopConvert from clang-modernize to modernize module in clang-tidy.

http://reviews.llvm.org/D12076

Patch by Angel Garcia!

llvm-svn: 245427
2015-08-19 09:11:46 +00:00
Alexander Kornienko
c90b526e38 Remove an empty directory left after r245318.
llvm-svn: 245426
2015-08-19 09:00:21 +00:00
Tobias Grosser
07c1c2fcc9 Make prevectorization width configurable
Polly uses 'prevectorization' to enable outer loop vectorization. When
vectorizing an outer loop, we strip-mine <number-of-prevec-dims> loop
iterations which are than interchanged to the innermost level such that LLVM's
inner loop vectorizer (or Polly's simple vectorizer) can easily vectorize this
loop. The number of loop iterations to strip-mine is now configurable with the
option -polly-prevect-width=<number-of-prevec-dims>.

This is mostly a debugging option. We should probably add a heuristic that
derives the number of prevectorization dimensions from the target data and
the data types used.

llvm-svn: 245424
2015-08-19 08:46:11 +00:00
Tobias Grosser
161c9081e5 Do not use negative option name
Instead of -polly-no-tiling, we use -polly-tiling=false to disable tiling.

llvm-svn: 245423
2015-08-19 08:22:06 +00:00
Tobias Grosser
f10f4636ff Simplify tiling code a bit
We only need to allocate the tile size vector if we actually want to perform
a tiling.

llvm-svn: 245422
2015-08-19 08:03:37 +00:00
Dimitry Andric
251c629117 Fix warnings about pessimizing return moves for C++11 and higher
Summary:
Throughout the libc++ headers, there are a few instances where
_VSTD::move() is used to return a local variable.  Howard commented in
r189039 that these were there "for non-obvious reasons such as to help
things limp along in C++03 language mode".

However, when compiling these headers with warnings on, and in C++11 or
higher mode (like we do in FreeBSD), they cause the following complaints
about pessimizing moves:

    In file included from tests.cpp:26:
    In file included from tests.hpp:29:
    /usr/include/c++/v1/map:1368:12: error: moving a local object in a return statement prevents copy elision [-Werror,-Wpessimizing-move]
        return _VSTD::move(__h);  // explicitly moved for C++03
               ^
    /usr/include/c++/v1/__config:368:15: note: expanded from macro '_VSTD'
    #define _VSTD std::_LIBCPP_NAMESPACE
                  ^

Attempt to fix this by adding a _LIBCPP_EXPLICIT_MOVE() macro to
__config, which gets defined to _VSTD::move for pre-C++11, and to
nothing for C++11 and later.

I am not completely satisfied with the macro name (I also considered
_LIBCPP_COMPAT_MOVE and some other variants), so suggestions are
welcome. :)

Reviewers: mclow.lists, howard.hinnant, EricWF

Subscribers: arthur.j.odwyer, cfe-commits

Differential Revision: http://reviews.llvm.org/D11394

llvm-svn: 245421
2015-08-19 06:43:33 +00:00
Nick Lewycky
1098e496e1 More clean up, still NFC. Remove dead variables now that the casts are gone.
llvm-svn: 245420
2015-08-19 06:25:30 +00:00
Nick Lewycky
2c852543a3 Clean up this file a little. Remove dead casts, casting Values to Values. Adjust some comments for typos and whitespace. NFC.
llvm-svn: 245419
2015-08-19 06:22:33 +00:00
Chaoren Lin
9a379c19a9 XFAIL TestCppScope for Darwin.
llvm-svn: 245418
2015-08-19 06:21:09 +00:00
Daniel Jasper
a2a463a787 Remove forkpty test with -Wl,-as-needed. This currently breaks in
various places. Let me know if you need more details about a
reproduction.

llvm-svn: 245417
2015-08-19 06:10:57 +00:00
Ashutosh Nema
c5b7b55589 Exposed findDefsUsedOutsideOfLoop as a loop utility function
Exposed findDefsUsedOutsideOfLoop as a loop utility function by moving 
it from LoopDistribute to LoopUtils.

Reviewed By: anemet

llvm-svn: 245416
2015-08-19 05:40:42 +00:00
Eric Fiselier
9c039962ca Use TestAtomic instead of std::atomic so the test can run in C++03
llvm-svn: 245415
2015-08-19 05:00:36 +00:00
Alexey Bataev
c7e8435bef [OPENMP] Link libomp.lib on Windows
Adds libomp.lib for -fopenmp=libomp and libiomp5md.lib for -fopenmp=libiomp5 on Windows
Differential Revision: http://reviews.llvm.org/D11932

llvm-svn: 245414
2015-08-19 04:49:01 +00:00
Eric Fiselier
1df02ee1f9 Mark std::packaged_task tests as unsupported in C++03.
std::packaged_task requires variadic templates and is #ifdef out in C++03.
This patch silences the tests in C++03. This patch also rewrites the .fail.cpp tests so that they use clang verify.

llvm-svn: 245413
2015-08-19 04:10:15 +00:00
Chaoren Lin
464be90e6d Fix TestCppNsImport and TestCppScope for remote tests.
llvm-svn: 245412
2015-08-19 04:08:56 +00:00
Eric Fiselier
21851d2b45 Remove commented out TODOs. They defined unneeded methods.
llvm-svn: 245411
2015-08-19 03:48:08 +00:00
Eric Fiselier
9a5e62bf75 Fix use of static_assert macro with nested commas
llvm-svn: 245410
2015-08-19 03:38:41 +00:00