Commit Graph

235538 Commits

Author SHA1 Message Date
James Molloy c3b4ed4a70 Revert "[Thumb] Reapply r272251 with a fix for PR28348"
This reverts commit r274510 - it made green dragon unhappy.

llvm-svn: 274512
2016-07-04 17:14:24 +00:00
Benjamin Kramer fdaed4c411 [clang-include-fixer] fix PEP8 warnings
This fixes PEP8 E231, E225, E226, E302 warnings.

Patch by Kirill Bobyrev!

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

llvm-svn: 274511
2016-07-04 16:47:17 +00:00
James Molloy 9f019835ef [Thumb] Reapply r272251 with a fix for PR28348
We were using DAG->getConstant instead of DAG->getTargetConstant. This meant that we could inadvertently increase the use count of a constant if stars aligned, which it did in this testcase. Increasing the use count of the constant could cause ISel to fall over (because DAGToDAG lowering assumed the constant had only one use!)

Original commit message:
  [Thumb] Select a BIC instead of AND if the immediate can be encoded more optimally negated

  If an immediate is only used in an AND node, it is possible that the immediate can be more optimally materialized when negated. If this is the case, we can negate the immediate and use a BIC instead;

    int i(int a) {
      return a & 0xfffffeec;
    }

  Used to produce:
      ldr r1, [CONSTPOOL]
      ands r0, r1
    CONSTPOOL: 0xfffffeec

  And now produces:
      movs    r1, #255
      adds    r1, #20  ; Less costly immediate generation
      bics    r0, r1

llvm-svn: 274510
2016-07-04 16:35:41 +00:00
Anastasia Stulova 7f8d6dc0ef [OpenCL] Make OpenCL Builtins added according to the right version.
Currently we only have OpenCL 2.0 Builtins i.e. pipes or address space conversions.

They have to be added only in the version 2.0 compilation mode to make the identifiers
available for use in the other versions.

Review: http://reviews.llvm.org/D20249
llvm-svn: 274509
2016-07-04 16:07:18 +00:00
George Rimar 5e37aeaf6a Fixed check-lld msan after r274504 "[ELF] - Implemented --fatal-warnings option."
Bot failed:
http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/14361/steps/check-lld%20msan/logs/stdio

Fix:
Initialize Config->FatalWarnings with false. As it might be used once a bit earlier than its
initialization from command line arguments.

llvm-svn: 274507
2016-07-04 14:54:23 +00:00
Simon Pilgrim 02d435d2f4 [X86][AVX512] Autoupgrade the VPERMPD/VPERMQ intrinsics
llvm-svn: 274506
2016-07-04 14:19:05 +00:00
Pavel Labath 97ef14c64b Split TestTemplateIntegerArgs test into two
Summary:
One of the tests there does not work with gcc, so I'm spinning that off into a separate test, so
that we can XFAIL it with more granularity.

I am also renaming the test to reflect the fact that it no longer tests only integer arguments.

Reviewers: clayborg

Subscribers: lldb-commits

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

llvm-svn: 274505
2016-07-04 13:49:46 +00:00
George Rimar 857644cef8 [ELF] - Implemented --fatal-warnings option.
--fatal-warnings: Treat warnings as errors

DIfferential revision: http://reviews.llvm.org/D21969

llvm-svn: 274504
2016-07-04 13:43:12 +00:00
Simon Pilgrim 8b82fce537 [X86][AVX512] Added VPERMPD/VPERMQ intrinsics fast-isel generic IR tests
llvm-svn: 274503
2016-07-04 13:43:10 +00:00
Simon Pilgrim 30db811526 [X86][AVX512] Converted the VPERMPD/VPERMQ intrinsics to generic IR
llvm-svn: 274502
2016-07-04 13:34:44 +00:00
Eric Liu bb11252113 [include-fixer] reduce stack size by changing RegexHeaderMap to use const char * pair.
llvm-svn: 274501
2016-07-04 13:34:11 +00:00
Tamas Berghammer c662533d05 Ignore oatdata and oatexec symbols more widely
These are artifical symbols inside android oat files without any value
for the user while causing a significant perfoamce hit inside the
unwinder. We were already ignoring it inside system@framework@boot.oat
bot they have to be ignored in every oat file. Considering that oat
files are only used on android this have no effect on any other
platfrom.

llvm-svn: 274500
2016-07-04 13:31:57 +00:00
Pavel Labath 140b8d1ecd Remove SIGPIPE handler in LLGS
It is sufficient to set the handeler to SIG_IGN, to get the desired behaviour. Also, the handler
calling a lot of signal-unsafe functions.

llvm-svn: 274499
2016-07-04 13:07:35 +00:00
Simon Pilgrim 9fca300cbe [X86][AVX512] Autoupgrade the VPERMILPD/VPERMILPS intrinsics
llvm-svn: 274498
2016-07-04 12:40:54 +00:00
Eric Liu e617adea12 Fixed warning caused by r274402.
llvm-svn: 274497
2016-07-04 12:10:08 +00:00
Haojian Wu c1926075c3 [clang-tidy] Fix more enum declaration cases in misc-unused-using-decls check.
Summary: Fix PR28350.

Reviewers: alexfh

Subscribers: aaron.ballman, Eugene.Zelenko, cfe-commits

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

llvm-svn: 274496
2016-07-04 12:01:56 +00:00
Eric Liu c97b9bda76 Fix broken build caused by r274494.
llvm-svn: 274495
2016-07-04 11:42:37 +00:00
Eric Liu f33bc95f8f [include-fixer] make HeaderMapCollector maps from regex instead of postfix.
Summary:
this enables us to map a group of headers to one header name,
e.g. headers from one directory can be mapped to the same header.

Reviewers: bkramer

Subscribers: cfe-commits, hokein

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

llvm-svn: 274494
2016-07-04 11:22:35 +00:00
Simon Pilgrim c8cf2ddb6d [X86][AVX512] Added VPERMILPD/VPERMILPS intrinsics fast-isel generic IR tests
Added PSHUFD tests as well

llvm-svn: 274493
2016-07-04 11:07:50 +00:00
Simon Pilgrim 17388f2569 [X86][AVX512] Converted the VPERMILPD/VPERMILPS intrinsics to generic IR
llvm-svn: 274492
2016-07-04 11:06:15 +00:00
Pavel Labath 7cf00d191a Enable test log collection from remote debug servers (take 2)
Summary:
This is a slightly reworked version of D16322, which I had reverted because it did not do what it
advertised. Differences from the previous version are:
- moved the code for cleaning up the remote working dir to a later point as it was removing the
  log file before we could get to it.
- specialised log downloading code for gdb-remote tests is not needed, as this will cover that
  use case as well.

Reviewers: tfiala

Subscribers: lldb-commits

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

llvm-svn: 274491
2016-07-04 09:59:45 +00:00
Pavel Labath abb79683bb Join TestTlsGlobal tests again and use the proper decorator
llvm-svn: 274490
2016-07-04 09:27:53 +00:00
Tamas Berghammer 4721a55e4d Fix the libc++ pretty printers for the android NDK
The libc++ shipped with the android NDK is shipped using a different
internal namespace then the upstream libc++ (__ndk1 vs. __1) to avoid
an ODR violation between the platform and the user application. This
change fixes our pretty printers to be able to work with the types
from the android NDK libc++.

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

llvm-svn: 274489
2016-07-04 09:13:10 +00:00
Tamas Berghammer 40aac2b8ae Fix ClangASTContext after some clang API changes
llvm-svn: 274488
2016-07-04 09:11:08 +00:00
Jacob Baungard Hansen 1bf12828be [Sparc] Allow LEON cpu models to be selected with -mcpu
Summary: This change exposes the recently added LEON CPUs (D19359) in the LLVM Sparc backend to Clang, allowing the cpu's to be selected using the -mcpu flag.

Reviewers: jyknight, lero_chris

Subscribers: jyknight, cfe-commits

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

llvm-svn: 274487
2016-07-04 08:56:08 +00:00
Nicolai Haehnle 84c9f9919a Add writeonly IR attribute
Summary:
This complements the earlier addition of IntrWriteMem and IntrWriteArgMem
LLVM intrinsic properties, see D18291.

Also start using the attribute for memset, memcpy, and memmove intrinsics,
and remove their special-casing in BasicAliasAnalysis.

Reviewers: reames, joker.eph

Subscribers: joker.eph, llvm-commits

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

llvm-svn: 274485
2016-07-04 08:01:29 +00:00
Craig Topper ac1823f6e9 [AVX512] Modify what indices we emit for the zero vector we use for zero extension of the result of a v2i1 or v4i1 masked compare. This way we emit something that the backend easily interprets as a concatenation rather than a true shuffle. This delivers slightly better codegen with the current backend capabilities.
llvm-svn: 274484
2016-07-04 07:09:46 +00:00
Craig Topper d83f818a3e [CodeGen] Make the code that detects a if a shuffle is really a concatenation of the inputs more general purpose.
We can now handle concatenation of each source multiple times. The previous code just checked for each source to appear once in either order.

This also now handles an entire source vector sized piece having undef indices correctly. We now concat with UNDEF instead of using one of the sources. This is responsible for the test case change.

llvm-svn: 274483
2016-07-04 06:19:35 +00:00
Jonas Hahnfeld 170fcc8772 __kmp_partition_places: Update assertion for new parameter update_master_only
If update_master_only is set the place list is not completely traversed
and therefore this assertion failed. Make it only trigger if
update_master_only is false.

(was introduced by D20539)

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

llvm-svn: 274482
2016-07-04 05:58:10 +00:00
NAKAMURA Takumi 4cb46e6747 Reformat blank lines.
llvm-svn: 274481
2016-07-04 01:26:33 +00:00
NAKAMURA Takumi f252951e90 Reformat comment lines.
llvm-svn: 274480
2016-07-04 01:26:27 +00:00
NAKAMURA Takumi 940cd9368d Untabify.
llvm-svn: 274479
2016-07-04 01:26:21 +00:00
NAKAMURA Takumi f4c6441b01 Reformat.
llvm-svn: 274478
2016-07-04 01:26:14 +00:00
David Majnemer 3b568aa4ed [Sema] A flexible array member must not be the only named member
We didn't correctly detect situations where a flexible array member was
the only named member in a record.

This fixes PR28407.

llvm-svn: 274477
2016-07-04 00:24:59 +00:00
Simon Pilgrim c804751a18 [X86] Add shuffle mask rescaling helper function. NFCI.
llvm-svn: 274476
2016-07-03 21:28:17 +00:00
David Majnemer 8b62269391 [AST] Use ArrayRef in more interfaces
ArrayRef is a little better than passing around a pointer/length pair.

No functional change is intended.

llvm-svn: 274475
2016-07-03 21:17:51 +00:00
Simon Pilgrim 8e84fcf118 [X86][AVX2] Merge unary permute matching behind the same V2.isUndef() condition. NFCI.
llvm-svn: 274474
2016-07-03 20:39:42 +00:00
Simon Pilgrim 7f096de0b8 [X86][AVX512] Add support for 512-bit shuffle lowering to VPERMPD/VPERMQ
llvm-svn: 274473
2016-07-03 19:50:06 +00:00
Craig Topper d1eca0f32c [CodeGen] Teach OR combine of shuffles involving zero vectors to better handle undef indices.
Undef indices can now be treated as zeros. Or if its undef ORed with zero, we will keep the undef.

llvm-svn: 274472
2016-07-03 19:37:12 +00:00
Craig Topper 8e826d5abe [X86] Add tests to show that the DAG combine for OR of shuffles with zero vectors doesn't handle undefs as well as it could. Fix coming in another commit.
llvm-svn: 274471
2016-07-03 19:37:10 +00:00
Haicheng Wu b71b2f622a [MBB] add a missing corner case in UpdateTerminator()
After the block placement, if a block ends with a conditional branch, but the
next block is not its successor. The conditional branch should be changed to
unconditional branch.  This patch fixes PR28307, PR28297, PR28402.

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

llvm-svn: 274470
2016-07-03 19:14:17 +00:00
Simon Pilgrim 68ea80649b [X86][AVX512] Add support for VPERMPD/VPERMQ masked shuffle comments
llvm-svn: 274469
2016-07-03 18:40:24 +00:00
Simon Pilgrim a0d73835b2 [X86][AVX512] Add support for 512-bit shuffle decoding of VPERMPD/VPERMQ
llvm-svn: 274468
2016-07-03 18:27:37 +00:00
Simon Pilgrim 5080e7f56c [X86][AVX] Renamed VPERMILPI shuffle comment macros to be more specific
llvm-svn: 274467
2016-07-03 18:02:43 +00:00
Simon Pilgrim dbd6db0dc7 [X86][AVX512] Add support for VPALIGNR/PSHUFD/PSHUFHW/PSHUFLW masked shuffle comments
llvm-svn: 274466
2016-07-03 15:00:51 +00:00
Sanjay Patel cbaac41856 [InstCombine] enable vector select of bools -> logic folds
llvm-svn: 274465
2016-07-03 14:34:39 +00:00
Simon Pilgrim 598bdb6bfe [X86][AVX512] Add support for UNPCK masked shuffle comments
llvm-svn: 274464
2016-07-03 14:26:21 +00:00
Sanjay Patel a1a4e100be fix formatting; NFC
llvm-svn: 274463
2016-07-03 14:08:19 +00:00
Simon Pilgrim 1f59076196 [X86][AVX512] Add support for VPERM/VSHUF masked shuffle comments
llvm-svn: 274462
2016-07-03 13:55:41 +00:00
Simon Pilgrim 68f438a036 [X86][AVX512] Add support for PMOVZX masked shuffle comments
llvm-svn: 274461
2016-07-03 13:33:28 +00:00