| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This change teaches SCEV to see reduce `(extractvalue
0 (op.with.overflow X Y))` into `op X Y` (with a no-wrap tag if
possible).
This was first checked in at r265912 but reverted in r265950 because it
exposed some issues around how SCEV handled post-inc add recurrences.
Those issues have now been fixed.
Reviewers: atrick, regehr
Subscribers: mcrosier, mzolotukhin, llvm-commits
Differential Revision: http://reviews.llvm.org/D18684
llvm-svn: 271152
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes PR27315.
The post-inc version of an add recurrence needs to "follow the same
rules" as a normal add or subtract expression. Otherwise we miscompile
programs like
```
int main() {
int a = 0;
unsigned a_u = 0;
volatile long last_value;
do {
a_u += 3;
last_value = (long) ((int) a_u);
if (will_add_overflow(a, 3)) {
// Leave, and don't actually do the increment, so no UB.
printf("last_value = %ld\n", last_value);
exit(0);
}
a += 3;
} while (a != 46);
return 0;
}
```
This patch changes SCEV to put no-wrap flags on post-inc add recurrences
only when the poison from a potential overflow will go ahead to cause
undefined behavior.
To avoid regressing performance too much, I've assumed infinite loops
without side effects is undefined behavior to prove poison<->UB
equivalence in more cases. This isn't ideal, but is not new to LLVM as
a whole, and far better than the situation I'm trying to fix.
llvm-svn: 271151
|
| |
|
|
|
|
|
| |
This is a stripped down version of D19211, leaving out the questionable
"branching in poison is UB" bit.
llvm-svn: 271150
|
| |
|
|
| |
llvm-svn: 271149
|
| |
|
|
|
|
| |
Differential Revision: http://reviews.llvm.org/D20777
llvm-svn: 271148
|
| |
|
|
| |
llvm-svn: 271147
|
| |
|
|
| |
llvm-svn: 271146
|
| |
|
|
| |
llvm-svn: 271145
|
| |
|
|
|
|
| |
language due to build failure on ppc64/hexagon/systemz.
llvm-svn: 271144
|
| |
|
|
| |
llvm-svn: 271143
|
| |
|
|
| |
llvm-svn: 271142
|
| |
|
|
|
|
|
| |
If the begin iterator fails, we cannot dereference it's contents.
Instead, we must immediately stop processing symbols.
llvm-svn: 271141
|
| |
|
|
|
|
| |
This makes it easier to report errors up the stack.
llvm-svn: 271140
|
| |
|
|
| |
llvm-svn: 271139
|
| |
|
|
|
|
|
|
|
|
|
| |
This extends the blocks support to support blocks with a dynamically linked
blocks runtime. The previous code generation would work only for static builds
of the blocks runtime. Mark the block "isa" pointers and functions as dllimport
if no explicit declaration marked with __declspec(dllexport) is found. This
additional check allows for the use of the functionality in the runtime library
if desired.
llvm-svn: 271138
|
| |
|
|
| |
llvm-svn: 271137
|
| |
|
|
|
|
|
|
|
|
| |
OpenCL has large number of "builtin" functions ("builtin" in the sense of OpenCL spec) which are defined in header files. To compile OpenCL kernels using these builtin functions, a header file is needed.
This header file is based on the Khronos implementation (https://github.com/KhronosGroup/SPIR/blob/spirv-1.0/lib/Headers/opencl.h) with heavy refactoring.
Differential Revision: http://reviews.llvm.org/D18369
llvm-svn: 271136
|
| |
|
|
| |
llvm-svn: 271135
|
| |
|
|
| |
llvm-svn: 271134
|
| |
|
|
| |
llvm-svn: 271133
|
| |
|
|
| |
llvm-svn: 271132
|
| |
|
|
|
|
|
|
|
|
|
|
| |
intrinsics with generic IR (llvm)
This patch removes the llvm intrinsics VPMOVSX and (V)PMOVZX sign/zero extension intrinsics and auto-upgrades to SEXT/ZEXT calls instead. We already did this for SSE41 PMOVSX sometime ago so much of that implementation can be reused.
Reapplied now that the the companion patch (D20684) removes/auto-upgrade the clang intrinsics has been committed.
Differential Revision: http://reviews.llvm.org/D20686
llvm-svn: 271131
|
| |
|
|
| |
llvm-svn: 271130
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
When RF_NullMapMissingGlobalValues is set, mapValue can return null
for GlobalValue. When mapping the operands of a constant that is
referenced from metadata, we need to handle this case and actually
return null instead of mapping this constant.
Reviewers: dexonsmith, rafael
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D20713
llvm-svn: 271129
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add determination of statements that contain, in particular,
matrix multiplications and can be optimized with [1] to try to
get close-to-peak performance. It can be enabled
via polly-pm-based-opts, which is false by default.
Refs:
[1] - http://www.cs.utexas.edu/users/flame/pubs/TOMS-BLIS-Analytical.pdf
Contributed-by: Roman Gareev <gareevroman@gmail.com>
Reviewed-by: Tobias Grosser <tobias@grosser.es>
Differential Revision: http://reviews.llvm.org/D20575
llvm-svn: 271128
|
| |
|
|
| |
llvm-svn: 271125
|
| |
|
|
|
|
|
|
| |
We were producing R_X86_64_GOTPCRELX for invalid instructions and
sometimes producing R_X86_64_GOTPCRELX instead of
R_X86_64_REX_GOTPCRELX.
llvm-svn: 271118
|
| |
|
|
| |
llvm-svn: 271117
|
| |
|
|
|
|
|
| |
It doesn't make mach sense to fetch less than 64 bits from a got
entry.
llvm-svn: 271116
|
| |
|
|
| |
llvm-svn: 271115
|
| |
|
|
|
|
|
|
|
|
|
| |
(PR20347)
It would be better to check the valid/expected size of the immediate operand, but this is
generally better than what we print right now.
Differential Revision: http://reviews.llvm.org/D20385
llvm-svn: 271114
|
| |
|
|
|
|
|
|
| |
Otherwise we fallback to a blend of PSHUFBs later on.
Differential Revision: http://reviews.llvm.org/D19661
llvm-svn: 271113
|
| |
|
|
| |
llvm-svn: 271112
|
| |
|
|
| |
llvm-svn: 271111
|
| |
|
|
| |
llvm-svn: 271110
|
| |
|
|
|
|
| |
This is revert of r270366. The support for CS toolchain were dropped too early.
llvm-svn: 271109
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Quite a few libcxx tests seem to follow the format:
#if _LIBCPP_STD_VER > X
// Do test.
#else
// Empty test.
#endif
We should instead use the UNSUPPORTED lit directive to exclude the test on
earlier C++ standards. This gives us a more accurate number of test passes
for those standards and avoids unnecessary conflicts with other lit
directives on the same tests.
Reviewers: bcraig, ericwf, mclow.lists
Differential revision: http://reviews.llvm.org/D20730
llvm-svn: 271108
|
| |
|
|
|
|
|
|
|
| |
Rather than invoking emitFill with negative size, which may trigger
an undefined behavior, return immediately after emitting the warning.
Differential Revision: http://reviews.llvm.org/D20768
llvm-svn: 271107
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
generic IR (clang)
The VPMOVSX and (V)PMOVZX sign/zero extension intrinsics can be safely represented as generic __builtin_convertvector calls instead of x86 intrinsics.
This patch removes the clang builtins and their use in the sse2/avx headers - a companion patch will remove/auto-upgrade the llvm intrinsics.
Note: We already did this for SSE41 PMOVSX sometime ago.
Differential Revision: http://reviews.llvm.org/D20684
llvm-svn: 271106
|
| |
|
|
| |
llvm-svn: 271105
|
| |
|
|
| |
llvm-svn: 271104
|
| |
|
|
| |
llvm-svn: 271103
|
| |
|
|
|
|
|
|
|
| |
This matches the behavior of GNU assembler which supports symbolic
expressions in absolute expressions used in assembly directives.
Differential Revision: http://reviews.llvm.org/D20752
llvm-svn: 271102
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
This converts remaining uses of ByteStream, which was still
left in the symbol stream and type stream, to using the new
StreamInterface zero-copy classes.
RecordIterator is finally deleted, so this is the only way left
now. Additionally, more error checking is added when iterating
the various streams.
With this, the transition to zero copy pdb access is complete.
llvm-svn: 271101
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
In case of MIPS, GP-relative relocations always resolve to a definition
in a regular input file, ignoring the one-definition rule. Such
relocations are used to setup GP relative offsets in a function's
prologue. So we, for example, should not attempt to create a dynamic
relocation even if the target symbol is preemptible.
Fixes bug 27880.
Differential Revision: http://reviews.llvm.org/D20664
llvm-svn: 271100
|
| |
|
|
|
|
|
|
| |
This reverts commit r271096, as reverting it broke even more buildbots!
But that also means I'll break on ARM again... :(
llvm-svn: 271099
|
| |
|
|
| |
llvm-svn: 271098
|
| |
|
|
| |
llvm-svn: 271097
|
| |
|
|
|
|
| |
This reverts commit r271052, as it broke some ARM buildbots.
llvm-svn: 271096
|
| |
|
|
| |
llvm-svn: 271095
|