| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
| |
Math functions are mark as readonly because they read the floating point
rounding mode. Because we don't vectorize loops that would contain function
calls that set the rounding mode it is safe to ignore this memory read.
llvm-svn: 185299
|
|
|
|
| |
llvm-svn: 185294
|
|
|
|
| |
llvm-svn: 185292
|
|
|
|
|
|
| |
argument with the 'returned' attribute (rather than generate invalid IR); however, if both can be eliminated, both will be
llvm-svn: 185290
|
|
|
|
|
|
|
|
| |
trying to remove a sext from a compare.
Fixes PR16462.
llvm-svn: 185284
|
|
|
|
|
|
|
|
|
| |
X is a power of two
This allows us to simplify urem instructions involving the add+xor to
turn into simpler math.
llvm-svn: 185272
|
|
|
|
|
|
| |
Avoids unused variable warnings in release builds.
llvm-svn: 185271
|
|
|
|
|
|
|
|
|
| |
don't match.
Inserting a zext or trunc is sufficient. This pattern is somewhat common in
LLVM's pointer mangling code.
llvm-svn: 185270
|
|
|
|
|
|
|
| |
operator++ on an enum is not legal. clang happens to accept it anyways, I think
that's a known bug.
llvm-svn: 185269
|
|
|
|
| |
llvm-svn: 185268
|
|
|
|
| |
llvm-svn: 185267
|
|
|
|
| |
llvm-svn: 185266
|
|
|
|
| |
llvm-svn: 185263
|
|
|
|
| |
llvm-svn: 185262
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Changing the sign when comparing the base pointer would introduce all
sorts of unexpected things like:
%gep.i = getelementptr inbounds [1 x i8]* %a, i32 0, i32 0
%gep2.i = getelementptr inbounds [1 x i8]* %b, i32 0, i32 0
%cmp.i = icmp ult i8* %gep.i, %gep2.i
%cmp.i1 = icmp ult [1 x i8]* %a, %b
%cmp = icmp ne i1 %cmp.i, %cmp.i1
ret i1 %cmp
into:
%cmp.i = icmp slt [1 x i8]* %a, %b
%cmp.i1 = icmp ult [1 x i8]* %a, %b
%cmp = xor i1 %cmp.i, %cmp.i1
ret i1 %cmp
By preserving the original sign, we now get:
ret i1 false
This fixes PR16483.
llvm-svn: 185259
|
|
|
|
| |
llvm-svn: 185258
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Real world code sometimes has the denominator of a 'udiv' be a
'select'. LLVM can handle such cases but only when the 'select'
operands are symmetric in structure (both select operands are a constant
power of two or a left shift, etc.). This falls apart if we are dealt a
'udiv' where the code is not symetric or if the select operands lead us
to more select instructions.
Instead, we should treat the LHS and each select operand as a distinct
divide operation and try to optimize them independently. If we can
to simplify each operation, then we can replace the 'udiv' with, say, a
'lshr' that has a new select with a bunch of new operands for the
select.
llvm-svn: 185257
|
|
|
|
| |
llvm-svn: 185251
|
|
|
|
| |
llvm-svn: 185250
|
|
|
|
|
|
|
|
|
| |
No functionality change.
It should suffice to check the type of a debug info metadata, instead of
calling Verify. For cases where we know the type of a DI metadata, use
assert.
llvm-svn: 185249
|
|
|
|
| |
llvm-svn: 185243
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We may, after other optimizations, find ourselves with IR that looks
like:
%shl = shl i32 1, %y
%cmp = icmp ult i32 %shl, 32
Instead, we should just compare the shift count:
%cmp = icmp ult i32 %y, 5
llvm-svn: 185242
|
|
|
|
| |
llvm-svn: 185238
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes PR16418, which reports that a function calling
__builtin_unwind_init() asserts. The cause is that this generates a
spill/restore for VRSAVE, and we support that only on Darwin (because VRSAVE is
only really used on Darwin).
The test case checks only that we don't crash. We can add correctness checks
once someone verifies what behavior the function is supposed to have.
llvm-svn: 185235
|
|
|
|
|
|
|
| |
To support this we have to insert 'extractelement' instructions to pick the right lane.
We had this functionality before but I removed it when we moved to the multi-block design because it was too complicated.
llvm-svn: 185230
|
|
|
|
|
|
|
|
| |
Change assert("text") to assert(0 && "text"). The first case is a const char *
to bool conversion, which always evaluates to true, never triggering the
assert. The second case will always trigger the assert.
llvm-svn: 185227
|
|
|
|
| |
llvm-svn: 185226
|
|
|
|
|
|
| |
retaining references to returned objects
llvm-svn: 185221
|
|
|
|
| |
llvm-svn: 185219
|
|
|
|
|
|
| |
Hopefully, this fixes the PPC64 buildbots.
llvm-svn: 185218
|
|
|
|
|
|
|
|
|
| |
blocks.
In this code we keep track of pointers that we are allowed to read from, if they are accessed by non-predicated blocks.
We use this list to allow vectorization of conditional loads in predicated blocks because we know that these addresses don't segfault.
llvm-svn: 185214
|
|
|
|
|
|
|
|
| |
Patch By: Alex Deucher
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
llvm-svn: 185209
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Based on GCC's output for TLS variables (OP_constNu, x@dtpoff,
OP_lo_user), this implements debug info support for TLS in ELF. Verified
that this output is correct/sufficient on Linux (using gold - if you're
using binutils-ld, you'll need something with the fix for
http://sourceware.org/bugzilla/show_bug.cgi?id=15685 in it).
Support on non-ELF is sort of "arbitrary" at the moment - if Apple folks
want to discuss (or just go ahead & implement) how this should work in
MachO, etc, I'm open.
llvm-svn: 185203
|
|
|
|
|
|
|
| |
This is a precursor to adding debug info support for TLS which requires
non-default relocations applied to TLS symbols.
llvm-svn: 185202
|
|
|
|
|
|
|
|
|
| |
Under certain (evidently rare) circumstances, this code used to convert OR(a,
AND(x, y)) into OR(a, x). This was incorrect.
While there, I've added a comment to the code immediately above.
llvm-svn: 185201
|
|
|
|
|
|
| |
- should unbreak Windows builds
llvm-svn: 185198
|
|
|
|
|
|
| |
- missed svn add...
llvm-svn: 185194
|
|
|
|
|
|
|
|
| |
- Build debug metadata for 'bare' Modules using DIBuilder
- DebugIR can be constructed to generate an IR file (to be seen by a debugger)
or not in cases where the user already has an IR file on disk.
llvm-svn: 185193
|
|
|
|
|
|
| |
is trying to do.
llvm-svn: 185191
|
|
|
|
| |
llvm-svn: 185190
|
|
|
|
| |
llvm-svn: 185189
|
|
|
|
| |
llvm-svn: 185188
|
|
|
|
| |
llvm-svn: 185187
|
|
|
|
|
|
|
|
|
|
|
|
| |
should expand ATOMIC_CMP_SWAP nodes the same way that it does for ATOMIC_SWAP.
Since ATOMIC_LOADs on some targets (e.g. older ARM variants) get legalized to
ATOMIC_CMP_SWAPs, the missing case had been causing i64 atomic loads to crash
during isel.
<rdar://problem/14074644>
llvm-svn: 185186
|
|
|
|
|
|
|
|
| |
- Use static functions instead of anonymous namespace.
- Appease the Doxygen lobby.
- Use 0-based induction variable.
llvm-svn: 185185
|
|
|
|
|
|
|
|
|
|
|
| |
Allow a BlockFrequency to be divided by a non-zero BranchProbability
with saturating arithmetic. This will be used to compute the frequency
of a loop header given the probability of leaving the loop.
Our long division algorithm already saturates on overflow, so that was a
freebie.
llvm-svn: 185184
|
|
|
|
| |
llvm-svn: 185180
|
|
|
|
|
|
| |
This makes it more consistent with the ZeroOrNegativeOneBooleanContent flag
llvm-svn: 185179
|
|
|
|
| |
llvm-svn: 185178
|
|
|
|
|
|
|
|
| |
Fix ABI handling for function
returning bool -- use st.param.b32 to return the value
and use ld.param.b32 in caller to load the return value.
llvm-svn: 185177
|