Jakub Kuderski [Wed, 26 Jul 2017 20:26:13 +0000 (20:26 +0000)]
[Dominators] Fix typos. NFC.
llvm-svn: 309170
Eric Beckmann [Wed, 26 Jul 2017 20:22:26 +0000 (20:22 +0000)]
Disable libxml on i686, because it is a 32 bit architecture and
libxml2.so is for 64 bit.
llvm-svn: 309169
Jonathan Peyton [Wed, 26 Jul 2017 20:07:58 +0000 (20:07 +0000)]
Introduce KMP_DEVICE_THREAD_LIMIT
This change drops in KMP_DEVICE_THREAD_LIMIT to replace KMP_MAX_THREADS. It's
possible there will eventually be a OMP_DEVICE_THREAD_LIMIT, and we need
something to distinguish from OMP_THREAD_LIMIT, which is currently implemented
incorrectly (the fix for that will be added soon in a separate patch).
KMP_ALL_THREADS is deprecated here, but we can keep the "all" option on
KMP_DEVICE_THREAD_LIMIT to support that functionality. KMP_DEVICE_THREAD_LIMIT
now has priority over its deprecated rival KMP_ALL_THREADS. I also cleaned up
some comments that incorrectly referred to non-existent kmp_max_threads variable
instead of kmp_max_nth.
I've left the name of where this setting eventually ends up as
__kmp_max_nth, for now.
This change does not change much in the way of functionality. It does NOT change
OMP_THREAD_LIMIT. It's just cleaning up and setting up for that.
Patch by Terry Wilmarth
Differential Revision: https://reviews.llvm.org/D35860
llvm-svn: 309168
Tom Stellard [Wed, 26 Jul 2017 20:00:53 +0000 (20:00 +0000)]
AMDGPU/GlobalISel: Mark 32-bit G_OR as legal
Reviewers: arsenm
Reviewed By: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D35127
llvm-svn: 309165
Michael Kruse [Wed, 26 Jul 2017 19:58:15 +0000 (19:58 +0000)]
[Simplify] Fix invalid removal write for escaping values.
A PHI node's incoming block is the user of its operand, not the PHI's parent.
Assuming the PHINode's parent being the user lead to the removal of a
MemoryAccesses because its use was assumed to be inside of the SCoP.
llvm-svn: 309164
Aditya Nandakumar [Wed, 26 Jul 2017 19:58:03 +0000 (19:58 +0000)]
[GISel]: Avoid zero length array when building Instrs that don't have
uses.
Also splitting the buildSources part allows more overloads such as
adding MachineOperands directly in the arguments for buildInstr.
llvm-svn: 309163
Rafael Espindola [Wed, 26 Jul 2017 19:57:40 +0000 (19:57 +0000)]
Try to fix the windows build.
llvm-svn: 309162
Rafael Espindola [Wed, 26 Jul 2017 19:39:40 +0000 (19:39 +0000)]
Try to fix the windows build.
llvm-svn: 309161
Rafael Espindola [Wed, 26 Jul 2017 19:37:58 +0000 (19:37 +0000)]
Try to fix the windows build.
llvm-svn: 309160
Peter Collingbourne [Wed, 26 Jul 2017 19:15:29 +0000 (19:15 +0000)]
Change CallLoweringInfo::CS to be an ImmutableCallSite instead of a pointer. NFCI.
This was a use-after-free waiting to happen.
llvm-svn: 309159
Adam Nemet [Wed, 26 Jul 2017 19:03:18 +0000 (19:03 +0000)]
Migrate SimplifyLibCalls to new OptimizationRemarkEmitter
Summary:
This changes SimplifyLibCalls to use the new OptimizationRemarkEmitter
API.
In fact, as SimplifyLibCalls is only ever called via InstCombine,
(as far as I can tell) the OptimizationRemarkEmitter is added there,
and then passed through to SimplifyLibCalls later.
I have avoided changing any remark text.
This closes PR33787
Patch by Sam Elliott!
Reviewers: anemet, davide
Reviewed By: anemet
Subscribers: davide, mehdi_amini, eraman, fhahn, llvm-commits
Differential Revision: https://reviews.llvm.org/D35608
llvm-svn: 309158
Andrew V. Tischenko [Wed, 26 Jul 2017 18:55:14 +0000 (18:55 +0000)]
This patch returns proper value to indicate the case when instruction throughput can't be calculated.
Differential revision https://reviews.llvm.org/D35831
llvm-svn: 309156
Alexey Sotkin [Wed, 26 Jul 2017 18:49:54 +0000 (18:49 +0000)]
[OpenCL] Fix access qualifiers metadata for kernel arguments with typedef
Subscribers: cfe-commits, yaxunl, Anastasia
Differential Revision: https://reviews.llvm.org/D35420
llvm-svn: 309155
Adrian Prantl [Wed, 26 Jul 2017 18:48:32 +0000 (18:48 +0000)]
Do a better job at emitting prefrabricated skeleton CUs.
This is a better fix than r308708 for the problem introduced in
r304020. It restores the skeleton CU testcases modified by that commit
to their original form and most importantly ensures that
frontend-generated skeleton CUs (such as used to point to Clang
modules) come after the regular CUs. This broke for DICompileUnit
nodes that don't have any immediate children because they are now
constructed lazily instead of the order in which they are listed in
!llvm.dbg.cu. After this commit we still don't guarantee that order,
but we do guarantee that empty skeletons come last.
Shipping versions of LLDB are very sensitive to the ordering of
CUs. I'll track a fix for LLDB to be more permissive separately.
This fixes a test failure in the LLDB testsuite.
rdar://problem/
33357252
llvm-svn: 309154
Rafael Espindola [Wed, 26 Jul 2017 18:47:49 +0000 (18:47 +0000)]
Simplify. NFC.
llvm-svn: 309153
Rafael Espindola [Wed, 26 Jul 2017 18:42:48 +0000 (18:42 +0000)]
Detemplate SymbolTable.
NFC, just makes it easier to access from non templated code.
llvm-svn: 309152
Eric Beckmann [Wed, 26 Jul 2017 18:33:21 +0000 (18:33 +0000)]
Unlink nodes instead of copying, to avoid memory problems.
llvm-svn: 309151
Jakub Kuderski [Wed, 26 Jul 2017 18:27:39 +0000 (18:27 +0000)]
[Dominators] Change Roots type to SmallVector
Summary: We can use the template parameter `IsPostDom` to pick an appropriate SmallVector size to store DomTree roots for dominators and postdominators. Before, the code would always allocate memory with `std::vector`.
Reviewers: dberlin, davide, sanjoy, grosser
Reviewed By: grosser
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D35636
llvm-svn: 309148
Jonathan Roelofs [Wed, 26 Jul 2017 18:13:57 +0000 (18:13 +0000)]
Partial fix for PR33858
https://reviews.llvm.org/D35848
llvm-svn: 309147
Jakub Kuderski [Wed, 26 Jul 2017 18:07:40 +0000 (18:07 +0000)]
[Dominators] Move root-finding out of DomTreeBase and simplify it
Summary:
This patch moves root-finding logic from DominatorTreeBase to GenericDomTreeConstruction.h.
It makes the behavior simpler and more consistent by always adding a virtual root to PostDominatorTrees.
Reviewers: dberlin, davide, grosser, sanjoy
Reviewed By: dberlin
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D35597
llvm-svn: 309146
Erich Keane [Wed, 26 Jul 2017 18:04:45 +0000 (18:04 +0000)]
Add bitrig removal to release notes
llvm-svn: 309145
Reid Kleckner [Wed, 26 Jul 2017 18:04:18 +0000 (18:04 +0000)]
Un-XFAIL some internal lit tests on Windows, they pass for me locally
llvm-svn: 309144
Eric Beckmann [Wed, 26 Jul 2017 17:47:44 +0000 (17:47 +0000)]
Diffing against a file that is itself used in the test seems to be a bad
idea, because it might get locked down and rendered unopenable.
llvm-svn: 309142
Rafael Espindola [Wed, 26 Jul 2017 17:27:27 +0000 (17:27 +0000)]
Simplify. NFC.
llvm-svn: 309141
George Karpenkov [Wed, 26 Jul 2017 17:19:36 +0000 (17:19 +0000)]
Fix LIT test breakage
Differential Revision: https://reviews.llvm.org/D35867
llvm-svn: 309140
Simon Pilgrim [Wed, 26 Jul 2017 16:47:00 +0000 (16:47 +0000)]
[X86][AVX512] Regenerated and cleaned up extension tests.
llvm-svn: 309139
Simon Pilgrim [Wed, 26 Jul 2017 16:45:57 +0000 (16:45 +0000)]
[X86] Regenerate setcc tests
llvm-svn: 309138
Simon Pilgrim [Wed, 26 Jul 2017 16:41:18 +0000 (16:41 +0000)]
[X86][AVX512] Regenerate shuffle tests with broadcast comments.
llvm-svn: 309137
Simon Pilgrim [Wed, 26 Jul 2017 16:39:07 +0000 (16:39 +0000)]
[X86] Regenerate memset tests
llvm-svn: 309136
Eric Beckmann [Wed, 26 Jul 2017 16:35:44 +0000 (16:35 +0000)]
Correctly enable the llvm-mt tests, now that build flags changed.
llvm-svn: 309134
Reid Kleckner [Wed, 26 Jul 2017 16:25:48 +0000 (16:25 +0000)]
Quote '?' in llvm-rc test
Summary:
Bash interperets the '?' character as matching an arbitrary character.
On systems that have a file or directory with exactly one character in
their root directory, '/?' gets reinterpreted into that pathname, which
fails to match the expected Help text for llvm-rc.
This patch quotes the '/?' to avoid that edge case.
Reviewers: mnbvmar, ecbeckmann, rnk
Reviewed By: rnk
Subscribers: dyung, ruiu, llvm-commits
Differential Revision: https://reviews.llvm.org/D35852
llvm-svn: 309133
Florian Hahn [Wed, 26 Jul 2017 16:07:51 +0000 (16:07 +0000)]
[Hexagon] Mark raise_relocation_error as NORETURN.
Summary:
This silences a couple of implicit fallthrough warnings with GCC 7.1 in
this file.
Reviewers: colinl, kparzysz
Reviewed By: kparzysz
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D35889
llvm-svn: 309129
Dehao Chen [Wed, 26 Jul 2017 15:47:00 +0000 (15:47 +0000)]
Update the assertion to meet with the changes in r309121. (NFC)
llvm-svn: 309125
Simon Pilgrim [Wed, 26 Jul 2017 15:41:57 +0000 (15:41 +0000)]
[X86] Add combineBT test failure because bits have multiple uses.
llvm-svn: 309124
Brian Gesiak [Wed, 26 Jul 2017 15:10:50 +0000 (15:10 +0000)]
[lit] Mark several of lit's tests XFAIL on Windows
Summary:
rL257221 attempted to run lit's own test suite continuously, but that
commit was reverted because lit's test suite does not pass on Windows.
Because lit's tests do not run continuously, they often regress.
In order to un-revert rL257221, mark lit tests that fail as XFAIL for
Windows platforms.
Test Plan:
On a Windows development environment, follow the instructions in
utils/lit/README.txt to run lit's test suite:
```
utils/lit/lit.py \
--path /path/to/your/llvm/build/bin \
utils/lit/tests
```
Verify that the test suite is run and a successful exit code is
returned.
Reviewers: mgorny, rnk, delcypher, beanz
Reviewed By: rnk
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D35879
llvm-svn: 309123
Brian Gesiak [Wed, 26 Jul 2017 15:02:05 +0000 (15:02 +0000)]
[lit] Fix type error for parallelism groups
Summary:
Whereas rL299560 and rL309071 call `parallelism_groups.items()`, under the
assumption that `parallelism_groups` is a `dict` type, the default
parameter for that attribute is a `list`. Change the default to a
`dict` for type correctness.
This regression in the unit tests would have been caught if the
unit tests were being run continously. It also would have been caught
if the lit project used a Python type checker such as `mypy`.
Test Plan:
As per the instructions in `utils/lit/README.txt`, run the lit unit
test suite:
```
utils/lit/lit.py \
--path /path/to/your/llvm/build/bin \
utils/lit/tests
```
Verify that the test `lit :: unit/TestRunner.py` fails before applying this
patch, but passes once this patch is applied.
Reviewers: mgorny, rnk, rafael
Reviewed By: mgorny
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D35878
llvm-svn: 309122
Dehao Chen [Wed, 26 Jul 2017 15:01:20 +0000 (15:01 +0000)]
Make new PM honor -fdebug-info-for-profiling
Summary: The new PM needs to invoke add-discriminator pass when building with -fdebug-info-for-profiling.
Reviewers: chandlerc, davidxl
Reviewed By: chandlerc
Subscribers: sanjoy, llvm-commits
Differential Revision: https://reviews.llvm.org/D35744
llvm-svn: 309121
Brian Gesiak [Wed, 26 Jul 2017 14:59:36 +0000 (14:59 +0000)]
Revert "[lit] Remove dead code not referenced in the LLVM SVN repo."
Summary:
This reverts rL306623, which removed `FileBasedTest`, an abstract base class,
but did not also remove the usages of that class in the lit unit tests.
The revert fixes four test failures in the lit unit test suite.
Test plan:
As per the instructions in `utils/lit/README.txt`, run the lit unit
test suite:
```
utils/lit/lit.py \
--path /path/to/your/llvm/build/bin \
utils/lit/tests
```
Verify that the following tests fail before applying this patch, and
pass once the patch is applied:
```
lit :: test-data.py
lit :: test-output.py
lit :: xunit-output.py
```
In addition, run `check-llvm` to make sure the existing LLVM test suite
executes normally.
Reviewers: george.karpenkov, mgorny, dlj
Reviewed By: mgorny
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D35877
llvm-svn: 309120
Roman Gareev [Wed, 26 Jul 2017 14:59:15 +0000 (14:59 +0000)]
[ScheduleOptimizer] Translate to C++ bindings
Translate the ScheduleOptimizer to use the new isl C++ bindings.
Reviewed-by: Michael Kruse <llvm@meinersbur.de>
Differential Revision: https://reviews.llvm.org/D35845
llvm-svn: 309119
Serge Pavlov [Wed, 26 Jul 2017 14:58:55 +0000 (14:58 +0000)]
Regression test for PR10856
llvm-svn: 309118
Nuno Lopes [Wed, 26 Jul 2017 14:11:23 +0000 (14:11 +0000)]
[docs] change a few code-blocks to llvm from text
llvm-svn: 309117
Alex Lorenz [Wed, 26 Jul 2017 13:58:02 +0000 (13:58 +0000)]
unguarded availability: add a fixit for the "annotate '...'
with an availability attribute to silence" note
rdar://
33539233
Differential Revision: https://reviews.llvm.org/D35726
llvm-svn: 309116
Jonas Hahnfeld [Wed, 26 Jul 2017 13:55:00 +0000 (13:55 +0000)]
[CMake] Disable building libomptarget and add CMake switch
Introduce OPENMP_ENABLE_LIBOMPTARGET which defaults to OFF at the moment.
libomptarget is not yet ready for prime time:
- Offloading to NVIDIA GPUs is not completed yet (compiler, device RTL)
- The generic ELF plugin for offloading to the host (meant for testing)
uses a single instance of the OpenMP runtime (libomp). That is why
omp_is_initial_device() returns 1 which makes the tests fail.
Because of these reasons, we want to disable building (and testing!)
for release 5.0.
See https://bugs.llvm.org/show_bug.cgi?id=33859
Differential Revision: https://reviews.llvm.org/D35719
llvm-svn: 309115
Stefan Pintilie [Wed, 26 Jul 2017 13:44:59 +0000 (13:44 +0000)]
[NFC] test commit.
Added a comment to explain how to add a PPCISD node.
llvm-svn: 309114
Yuka Takahashi [Wed, 26 Jul 2017 13:36:58 +0000 (13:36 +0000)]
[Bash-autocompletion] Show HelpText with possible flags
Summary:
`clang --autocomplete=-std` will show
```
-std: Language standard to compile for
-std= Language standard to compile for
-stdlib= C++ standard library to use
```
after this change.
However, showing HelpText with completion in bash seems super tricky, so
this feature will be used in other shells (fish, zsh...).
Reviewers: v.g.vassilev, teemperor, ruiu
Subscribers: cfe-commits, hiraditya
Differential Revision: https://reviews.llvm.org/D35759
llvm-svn: 309113
Yuka Takahashi [Wed, 26 Jul 2017 13:30:36 +0000 (13:30 +0000)]
[Bash-completion] Fixed a bug that file doesn't autocompleted after =
Summary:
File path wasn't autocompleted after `-fmodule-cache-path=[tab]`, so
fixed this bug by checking if $flags contains only a newline or not.
Differential Revision: https://reviews.llvm.org/D35763
llvm-svn: 309112
Daniel Sanders [Wed, 26 Jul 2017 13:28:40 +0000 (13:28 +0000)]
Revert r309094: [globalisel][tablegen] Fuse the generated tables together.
The ARM bots have started failing and while this patch should be an improvement
for these bots, it's also the only suspect in the blamelist. Reverting while
Diana and I investigate the problem.
llvm-svn: 309111
Michael Kruse [Wed, 26 Jul 2017 13:25:28 +0000 (13:25 +0000)]
[ScopInfo] Avoid use of getStmtFor(BB). NFC.
Since there will be no more a 1:1 correspondence between statements and
basic blocks, we would like to get rid of the method getStmtFor(BB)
and its uses. Here we remove one of its uses in ScopInfo by fetching
the statement in which the call instruction lies.
Contributed-by: Nandini Singhal <cs15mtech01004@iith.ac.in>
Differential Revision: https://reviews.llvm.org/D35691
llvm-svn: 309110
Michael Kruse [Wed, 26 Jul 2017 13:05:45 +0000 (13:05 +0000)]
[SCEVValidator] Loop exit values of loops before the SCoP are synthesizable.
In the following loop:
int i;
for (i = 0; i < func(); i+=1)
;
SCoP:
for (int j = 0; j<n; j+=1)
S(i, j)
The value i is synthesizable in the SCoP that includes only the j-loop.
This is because i is fixed within the SCoP, it is irrelevant whether
it originates from another loop.
This fixes a strange case where a PHI was synthesiable in a SCoP,
but not its incoming value, triggering an assertion.
This should fix MultiSource/Applications/sgefa/sgefa of the
perf-x86_64-penryn-O3-polly-before-vectorizer-unprofitable buildbot.
llvm-svn: 309109
Zvi Rackover [Wed, 26 Jul 2017 12:57:03 +0000 (12:57 +0000)]
DAGCombiner: Extend reduceBuildVecToTrunc to handle non-zero offset
Summary:
Adding support for combining power2-strided build_vector's where the
first build_vectori's operand is extracted from a non-zero index.
Example:
v4i32 build_vector((extract_elt V, 1),
(extract_elt V, 3),
(extract_elt V, 5),
(extract_elt V, 7))
-->
v4i32 truncate (bitcast (shuffle<1,u,3,u,5,u,7,u> V, u) to v4i64)
Reviewers: delena, RKSimon, guyblank
Reviewed By: RKSimon
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D35700
llvm-svn: 309108
Simon Pilgrim [Wed, 26 Jul 2017 12:49:20 +0000 (12:49 +0000)]
[X86] Regenerated BT tests
Test on 32/64 bit targets where appropriate
llvm-svn: 309107
Alex Lorenz [Wed, 26 Jul 2017 12:20:57 +0000 (12:20 +0000)]
Recommit r308327 2nd time: Add a warning for missing
'#pragma pack (pop)' and suspicious uses of '#pragma pack' in included files
The first recommit (r308441) caused a "non-default #pragma pack value might
change the alignment of struct or union members in the included file" warning
in LLVM itself. This recommit tweaks the added warning to avoid warnings for
#includes that don't have any records that are affected by the non-default
alignment. This tweak avoids the previously emitted warning in LLVM.
Original message:
This commit adds a new -Wpragma-pack warning. It warns in the following cases:
- When a translation unit is missing terminating #pragma pack (pop) directives.
- When entering an included file if the current alignment value as determined
by '#pragma pack' directives is different from the default alignment value.
- When leaving an included file that changed the state of the current alignment
value.
rdar://
10184173
Differential Revision: https://reviews.llvm.org/D35484
llvm-svn: 309106
Martin Storsjo [Wed, 26 Jul 2017 11:19:17 +0000 (11:19 +0000)]
[COFF, ARM64] Fix symbol offsets in ADRP/ADD/LDR/STR relocations
In COFF, a symbol offset can't be stored in the relocation (as is
done in ELF or MachO), but is stored as the immediate in the
instruction itself. The immediate in the ADRP thus is the symbol
offset in bytes, not in pages. For the PAGEOFFSET_12A/L relocations,
ignore any offset outside of the lowest 12 bits; they won't have any
effect on the ADD/LDR/STR instruction itself but only on the associated
ADRP.
This is similar to how the same issue is handled for MOVW/MOVT
instructions in ELF (see e.g. SVN r307713, and r307728 in lld).
This fixes "fixup out of range" errors while building larger object
files, where temporary symbols end up as a plain section symbol and
an offset, and fixes any cases where the symbol offset mean that
the actual target ended up on a different page than the symbol
itself.
Differential Revision: https://reviews.llvm.org/D35791
llvm-svn: 309105
Simon Pilgrim [Wed, 26 Jul 2017 11:07:45 +0000 (11:07 +0000)]
[X86] Add urem vector test for non-uniform pow2 constants
llvm-svn: 309104
Simon Pilgrim [Wed, 26 Jul 2017 11:05:16 +0000 (11:05 +0000)]
[X86] Regenerated urem pow2 tests on 32/64 bit targets
llvm-svn: 309103
Simon Pilgrim [Wed, 26 Jul 2017 11:04:18 +0000 (11:04 +0000)]
[X86] Regenerated umul overflow tests on 32/64 bit targets
llvm-svn: 309102
Diana Picus [Wed, 26 Jul 2017 11:01:13 +0000 (11:01 +0000)]
[ARM] GlobalISel: Map G_GLOBAL_VALUE to GPR
A G_GLOBAL_VALUE is basically a pointer, so it should live in the GPR.
llvm-svn: 309101
Simon Pilgrim [Wed, 26 Jul 2017 10:54:51 +0000 (10:54 +0000)]
[X86][AVX] Regenerated and cleaned up AVX1 intrinsic tests.
Cleaned up triple settings, added 32-bit/64-bit targets where useful, added broadcast comments
llvm-svn: 309100
Simon Pilgrim [Wed, 26 Jul 2017 10:47:51 +0000 (10:47 +0000)]
[X86][AVX2] Regenerated and cleaned up broadcast tests.
llvm-svn: 309099
Simon Pilgrim [Wed, 26 Jul 2017 10:39:55 +0000 (10:39 +0000)]
[X86][AVX512] Regenerated and added 32-bit targets to select tests
llvm-svn: 309098
Simon Pilgrim [Wed, 26 Jul 2017 10:37:12 +0000 (10:37 +0000)]
[X86][AVX] Regenerated and cleaned up masked gather/scatter tests.
Remove unused KNL checks and triple settings, added broadcast comments
llvm-svn: 309097
George Rimar [Wed, 26 Jul 2017 10:25:49 +0000 (10:25 +0000)]
[ELF] - Ignore --warn-once option.
Was discussed in D35797 thread.
llvm-svn: 309096
Simon Pilgrim [Wed, 26 Jul 2017 10:22:56 +0000 (10:22 +0000)]
[X86][AVX] Regenerate lzcnt test.
Tidied up triples and checks.
llvm-svn: 309095
Daniel Sanders [Wed, 26 Jul 2017 10:20:56 +0000 (10:20 +0000)]
[globalisel][tablegen] Fuse the generated tables together.
Summary:
Now that we have control flow in place, fuse the per-rule tables into a
single table. This is a compile-time saving at this point. However, this will
also enable the optimization of a table so that similar instructions can be
tested together, reducing the time spent on the matching the code.
This is NFC in terms of externally visible behaviour but some internals have
changed slightly. State.MIs is no longer reset between each rule that is
attempted because it's not necessary to do so. As a consequence of this the
restriction on the order that instructions are added to State.MIs has been
relaxed to only affect recorded instructions that require new elements to be
added to the vector. GIM_RecordInsn can now write to any element from 1 to
State.MIs.size() instead of just State.MIs.size().
Reviewers: ab, t.p.northover, qcolombet, rovka, aditya_nandakumar
Reviewed By: rovka
Subscribers: kristof.beyls, igorb, llvm-commits
Differential Revision: https://reviews.llvm.org/D35681
llvm-svn: 309094
Simon Pilgrim [Wed, 26 Jul 2017 10:20:49 +0000 (10:20 +0000)]
[X86][FMA] Regenerate test with broadcast comments.
llvm-svn: 309093
Alexander Kornienko [Wed, 26 Jul 2017 10:14:55 +0000 (10:14 +0000)]
Follow up for r307085: a better fix for a dangling StringRef.
llvm-svn: 309092
George Rimar [Wed, 26 Jul 2017 09:46:59 +0000 (09:46 +0000)]
[ELF] - Change way how we handle --noinhibit-exec
Previously we handled this option implicitly, only
for infering unresolved symbols handling policy.
ld man says: "--noinhibit-exec Retain the executable
output file whenever it is still usable",
and we may want to handle other cases too.
Differential revision: https://reviews.llvm.org/D35793
llvm-svn: 309091
Diana Picus [Wed, 26 Jul 2017 09:25:15 +0000 (09:25 +0000)]
[ARM] GlobalISel: Mark G_GLOBAL_VALUE as legal
llvm-svn: 309090
George Rimar [Wed, 26 Jul 2017 09:21:10 +0000 (09:21 +0000)]
[ELF] - Print options aliases in --help
This is PR30422,
previously LLD did not render all option aliases in --help.
With this patch it will.
Differential revision: https://reviews.llvm.org/D35477
llvm-svn: 309089
George Rimar [Wed, 26 Jul 2017 09:10:17 +0000 (09:10 +0000)]
Update after LLVM change r309087
llvm-svn: 309088
George Rimar [Wed, 26 Jul 2017 09:09:56 +0000 (09:09 +0000)]
[libOption] - Add flag allowing to print options aliases in help text.
By default, we display only options that are not
hidden and have help texts. This patch adds flag
allowing to display aliases that have no help text.
In this case help text of aliased option used instead.
Differential revision: https://reviews.llvm.org/D35476
llvm-svn: 309087
Michael Zuckerman [Wed, 26 Jul 2017 08:10:14 +0000 (08:10 +0000)]
[X86][LLVM]Expanding Supports lowerInterleavedStore() in X86InterleavedAccess.
This patch expands the support of lowerInterleavedStore to 32x8i stride 4.
LLVM creates suboptimal shuffle code-gen for AVX2. In overall, this patch is a specific fix for the pattern (Strid=4 VF=32) and we plan to include more patterns in the future. To reach our goal of "more patterns". We include two mask creators. The first function creates shuffle's mask equivalent to unpacklo/unpackhi instructions. The other creator creates mask equivalent to a concat of two half vectors(high/low).
The patch goal is to optimize the following sequence:
At the end of the computation, we have ymm2, ymm0, ymm12 and ymm3 holding
each 32 chars:
c0, c1, , c31
m0, m1, , m31
y0, y1, , y31
k0, k1, ., k31
And these need to be transposed/interleaved and stored like so:
c0 m0 y0 k0 c1 m1 y1 k1 c2 m2 y2 k2 c3 m3 y3 k3 ....
Reviewers:
dorit
Farhana
RKSimon
guyblank
DavidKreitzer
Differential Revision: https://reviews.llvm.org/D34601
llvm-svn: 309086
Zvi Rackover [Wed, 26 Jul 2017 08:06:58 +0000 (08:06 +0000)]
TargetLowering: Change isShuffleMaskLegal's mask argument type to ArrayRef<int>. NFCI.
Changing mask argument type from const SmallVectorImpl<int>& to
ArrayRef<int>.
This came up in D35700 where a mask is received as an ArrayRef<int> and
we want to pass it to TargetLowering::isShuffleMaskLegal().
Also saves a few lines of code.
llvm-svn: 309085
Michael Zuckerman [Wed, 26 Jul 2017 07:45:02 +0000 (07:45 +0000)]
[X86][LLVM]Expanding Supports lowerInterleavedStore() in X86InterleavedAccess part1.
splitting patch D34601 into two part. This part changes the location of two functions.
The second part will be based on that patch. This was requested by @RKSimon.
Reviewers:
1. dorit
2. Farhana
3. RKSimon
4. guyblank
5. DavidKreitzer
llvm-svn: 309084
Petr Hosek [Wed, 26 Jul 2017 06:46:11 +0000 (06:46 +0000)]
Revert "[sanitizer] Support compiler-rt builtins"
This reverts commit
fd63314d6770e0da62572a3fea2c41c4cc0fc58a.
llvm-svn: 309083
Petr Hosek [Wed, 26 Jul 2017 06:46:10 +0000 (06:46 +0000)]
Revert "[sanitizer] Support libc++abi in addition to libstdc++"
This reverts commit
d1997bff31cf6b484eb59c2ee1fc3155442e338c.
llvm-svn: 309082
Mandeep Singh Grang [Wed, 26 Jul 2017 05:29:40 +0000 (05:29 +0000)]
[clang] Add ARM64 support to armintr.h for MSVC compatibility
Summary: This fixes compiling with headers from the Windows SDK for ARM64.
Reviewers: compnerd, ruiu, mstorsjo
Reviewed By: compnerd, mstorsjo
Subscribers: mgorny, aemerson, javed.absar, kristof.beyls, llvm-commits, cfe-commits
Differential Revision: https://reviews.llvm.org/D35862
llvm-svn: 309081
Max Kazantsev [Wed, 26 Jul 2017 04:55:54 +0000 (04:55 +0000)]
[SCEV] Cache results of computeExitLimit
This patch adds a cache for computeExitLimit to save compilation time. A lot of examples of
tests that take extensive time to compile are attached to the bug 33494.
Differential Revision: https://reviews.llvm.org/D35827
llvm-svn: 309080
Craig Topper [Wed, 26 Jul 2017 04:31:04 +0000 (04:31 +0000)]
[X86] Prevent selecting masked aligned load instructions if the load should be non-temporal
Summary: The aligned load predicates don't suppress themselves if the load is non-temporal the way the unaligned predicates do. For the most part this isn't a problem because the aligned predicates are mostly used for instructions that only load the the non-temporal loads have priority over those. The exception are masked loads.
Reviewers: RKSimon, zvi
Reviewed By: RKSimon
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D35712
llvm-svn: 309079
Dehao Chen [Wed, 26 Jul 2017 02:00:43 +0000 (02:00 +0000)]
Add test coverage for new PM PGOOpt handling.
Summary: This patch adds flags and tests to cover the PGOOpt handling logic in new PM.
Reviewers: chandlerc, davide
Reviewed By: chandlerc
Subscribers: sanjoy, llvm-commits
Differential Revision: https://reviews.llvm.org/D35807
llvm-svn: 309076
Davide Italiano [Wed, 26 Jul 2017 01:47:17 +0000 (01:47 +0000)]
[gold] Enable data-sections by default for the gold-plugin.
Follow up to r309056.
llvm-svn: 309075
Petr Hosek [Wed, 26 Jul 2017 01:43:02 +0000 (01:43 +0000)]
[sanitizer] Support libc++abi in addition to libstdc++
This change adds sanitizer support for LLVM's libunwind and libc++abi
as an alternative to libstdc++. This allows using the in tree version
of libunwind and libc++abi which is useful when building a toolchain
for different target.
Differential Revision: https://reviews.llvm.org/D34501
llvm-svn: 309074
Wei Mi [Wed, 26 Jul 2017 01:34:46 +0000 (01:34 +0000)]
Add "REQUIRES: asserts" for test unswitch-equality-undef.ll.
llvm-svn: 309073
Sanjoy Das [Wed, 26 Jul 2017 01:32:19 +0000 (01:32 +0000)]
[SCEV] Remove unnecessary call to forgetMemoizedResults
`SCEVUnknown::allUsesReplacedWith` does not need to call `forgetMemoizedResults`
since RAUW does a value-equivalent replacement by assumption. If this
assumption was false then the later setValPtr(New) call would be incorrect too.
This is a non-trivial performance optimization for functions with a large number
of loops since `forgetMemoizedResults` walks all loop backedge taken counts to
see if any of them use the SCEVUnknown being RAUWed. However, this improvement
is difficult to demonstrate without checking in an excessively large IR file.
llvm-svn: 309072
Reid Kleckner [Wed, 26 Jul 2017 01:27:18 +0000 (01:27 +0000)]
[lit] Attempt to fix Python unittest adaptor logic
llvm-svn: 309071
Eric Beckmann [Wed, 26 Jul 2017 01:21:55 +0000 (01:21 +0000)]
Move manifest utils into separate lib, to reduce libxml2 deps.
Summary:
Previously were in support. Since many many things depend on support,
were all forced to also depend on libxml2, which we only want in a few cases.
This puts all the libxml2 deps in a separate lib to be used only in a few
places.
Reviewers: ruiu, thakis, rnk
Subscribers: mgorny, hiraditya, llvm-commits
Differential Revision: https://reviews.llvm.org/D35819
llvm-svn: 309070
Reid Kleckner [Wed, 26 Jul 2017 00:58:49 +0000 (00:58 +0000)]
[PDB] Remove stale GSI.h header that I intended to remove in the previous commit
llvm-svn: 309069
Spyridoula Gravani [Wed, 26 Jul 2017 00:52:31 +0000 (00:52 +0000)]
[DWARF] Generalized verification of .apple_names accelerator table to be applicable to any acceleration table. Added verification for .apple_types, .apple_namespaces and .apple_objc sections.
Differential Revision: https://reviews.llvm.org/D35853
llvm-svn: 309068
Felix Berger [Wed, 26 Jul 2017 00:45:41 +0000 (00:45 +0000)]
[clang-tidy] Do not issue fixit for explicit template specializations
Summary:
Do not issue fixit in UnnecessaryValueParamCheck if the function is an explicit template specialization as this could cause build breakages.
Reviewers: alexfh
Subscribers: JDevlieghere, xazax.hun, cfe-commits
Differential Revision: https://reviews.llvm.org/D35718
llvm-svn: 309067
Reid Kleckner [Wed, 26 Jul 2017 00:40:36 +0000 (00:40 +0000)]
[PDB] Improve GSI hash table dumping for publics and globals
The PDB "symbol stream" actually contains symbol records for the publics
and the globals stream. The globals and publics streams are essentially
hash tables that point into a single stream of records. In order to
match cvdump's behavior, we need to only dump symbol records referenced
from the hash table. This patch implements that, and then implements
global stream dumping, since it's just a subset of public stream
dumping.
Now we shouldn't see S_PROCREF or S_GDATA32 records when dumping
publics, and instead we should see those record in the globals stream.
llvm-svn: 309066
Eric Beckmann [Wed, 26 Jul 2017 00:25:12 +0000 (00:25 +0000)]
Reapply "llvm-mt: implement simple merging of manifests, not factoring namespaces.
This time with correct #if.
This reverts commit
9cf4eca0e0383040c1ff1416815c7f649650c2a0.
llvm-svn: 309064
Eugene Zelenko [Tue, 25 Jul 2017 23:51:02 +0000 (23:51 +0000)]
[AArch64] Fix some Clang-tidy modernize-use-using and Include What You Use warnings; other minor fixes (NFC).
llvm-svn: 309062
Peter Szecsi [Tue, 25 Jul 2017 23:49:16 +0000 (23:49 +0000)]
[StaticAnalyzer] LoopUnrolling - Attempt #2 to fix a crash in r309006.
llvm-svn: 309061
Petr Hosek [Tue, 25 Jul 2017 23:38:25 +0000 (23:38 +0000)]
[sanitizer] Support compiler-rt builtins
This change adds support for compiler-rt builtins as an alternative
compiler runtime to libgcc.
Differential Revision: https://reviews.llvm.org/D35165
llvm-svn: 309060
Wei Mi [Tue, 25 Jul 2017 23:37:17 +0000 (23:37 +0000)]
Disable loop unswitching for some patterns containing equality comparison with undef.
This is a workaround for the bug described in PR31652 and
http://lists.llvm.org/pipermail/llvm-dev/2017-July/115497.html. The temporary
solution is to add a function EqualityPropUnSafe. In EqualityPropUnSafe, for
some simple patterns we can know the equality comparison may contains undef,
so we regard such comparison as unsafe and will not do loop-unswitching for
them. We also need to disable the select simplification when one of select
operand is undef and its result feeds into equality comparison.
The patch cannot clear the safety issue caused by the bug, but it can suppress
the issue from happening to some extent.
Differential Revision: https://reviews.llvm.org/D35811
llvm-svn: 309059
David Majnemer [Tue, 25 Jul 2017 23:33:58 +0000 (23:33 +0000)]
[CodeGen] Correctly model std::byte's aliasing properties
std::byte, when defined as an enum, needs to be given special treatment
with regards to its aliasing properties. An array of std::byte is
allowed to be used as storage for other types.
This fixes PR33916.
Differential Revision: https://reviews.llvm.org/D35824
llvm-svn: 309058
Adrian Prantl [Tue, 25 Jul 2017 23:32:59 +0000 (23:32 +0000)]
Debug Info: Support fragmented variables in the MMI side table
This reapplies commit r309034 with a bugfix+test for inlined variables.
llvm-svn: 309057
Davide Italiano [Tue, 25 Jul 2017 23:32:50 +0000 (23:32 +0000)]
[gold] Enable function-sections by default.
This is needed, among others, to respect --section-ordering-file
with LTO. I'll follow up with a similar change for data sections.
I hope every version of gold available on the bots has support for
--section-ordering file.
llvm-svn: 309056
Rui Ueyama [Tue, 25 Jul 2017 23:32:05 +0000 (23:32 +0000)]
Simplify ignored options.
Since the flag is ignored anyway, it doesn't matter whether
it is an alias or not.
llvm-svn: 309055
Richard Smith [Tue, 25 Jul 2017 23:31:42 +0000 (23:31 +0000)]
Reorder tests to match latest SD-6 draft.
llvm-svn: 309054