| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
allows to hold performance experiments
llvm-svn: 160361
|
| |
|
|
|
|
|
| |
When truncating a result of a vector that is split we need
to use the result of the split vector, and not re-split the dead node.
llvm-svn: 160357
|
| |
|
|
| |
llvm-svn: 160354
|
| |
|
|
| |
llvm-svn: 160352
|
| |
|
|
| |
llvm-svn: 160350
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
large immediates. Add dag combine logic to recover in case the large
immediates doesn't fit in cmp immediate operand field.
int foo(unsigned long l) {
return (l>> 47) == 1;
}
we produce
%shr.mask = and i64 %l, -140737488355328
%cmp = icmp eq i64 %shr.mask, 140737488355328
%conv = zext i1 %cmp to i32
ret i32 %conv
which codegens to
movq $0xffff800000000000,%rax
andq %rdi,%rax
movq $0x0000800000000000,%rcx
cmpq %rcx,%rax
sete %al
movzbl %al,%eax
ret
TargetLowering::SimplifySetCC would transform
(X & -256) == 256 -> (X >> 8) == 1
if the immediate fails the isLegalICmpImmediate() test. For x86,
that's immediates which are not a signed 32-bit immediate.
Based on a patch by Eli Friedman.
PR10328
rdar://9758774
llvm-svn: 160346
|
| |
|
|
|
|
| |
Speculatively fix crashes by code inspection. Can't reproduce them yet.
llvm-svn: 160344
|
| |
|
|
|
|
| |
Some units tests crashed on a different platform.
llvm-svn: 160341
|
| |
|
|
|
|
|
|
|
|
| |
This places limits on CollectSubexprs to constrains the number of
reassociation possibilities. It limits the recursion depth and skips
over chains of nested recurrences outside the current loop.
Fixes PR13361. Although underlying SCEV behavior is still potentially bad.
llvm-svn: 160340
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Define a 'null_frag' SDPatternOperator node, which if referenced in an
instruction Pattern, results in the pattern being collapsed to be as-if
'[]' had been specified instead. This allows supporting a multiclass
definition where some instaniations have ISel patterns associated and
others do not.
For example,
multiclass myMulti<RegisterClass rc, SDPatternOperator OpNode = null_frag> {
def _x : myI<(outs rc:), (ins rc:), []>;
def _r : myI<(outs rc:), (ins rc:), [(set rc:, (OpNode rc:))]>;
}
defm foo : myMulti<GRa, not>;
defm bar : myMulti<GRb>;
llvm-svn: 160333
|
| |
|
|
| |
llvm-svn: 160329
|
| |
|
|
|
|
| |
user-defined match classes have been checked. This allows the creation of MatchClass's that are supersets of a register class.
llvm-svn: 160327
|
| |
|
|
| |
llvm-svn: 160325
|
| |
|
|
| |
llvm-svn: 160317
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
uint32_t hi(uint64_t res)
{
uint_32t hi = res >> 32;
return !hi;
}
llvm IR looks like this:
define i32 @hi(i64 %res) nounwind uwtable ssp {
entry:
%lnot = icmp ult i64 %res, 4294967296
%lnot.ext = zext i1 %lnot to i32
ret i32 %lnot.ext
}
The optimizer has optimize away the right shift and truncate but the resulting
constant is too large to fit in the 32-bit immediate field. The resulting x86
code is worse as a result:
movabsq $4294967296, %rax ## imm = 0x100000000
cmpq %rax, %rdi
sbbl %eax, %eax
andl $1, %eax
This patch teaches the x86 lowering code to handle ult against a large immediate
with trailing zeros. It will issue a right shift and a truncate followed by
a comparison against a shifted immediate.
shrq $32, %rdi
testl %edi, %edi
sete %al
movzbl %al, %eax
It also handles a ugt comparison against a large immediate with trailing bits
set. i.e. X > 0x0ffffffff -> (X >> 32) >= 1
rdar://11866926
llvm-svn: 160312
|
| |
|
|
| |
llvm-svn: 160311
|
| |
|
|
|
|
|
| |
The first variant accepts immediate number as the second argument.
The second variant accepts register operand as the second argument.
llvm-svn: 160307
|
| |
|
|
|
|
|
|
|
|
|
| |
AssertZext value.
In the added testcase the constant 55 was behind an AssertZext of type i1, and ComputeDemandedBits
reported that some of the bits were both known to be one and known to be zero.
Together with Michael Kuperstein <michael.m.kuperstein@intel.com>
llvm-svn: 160305
|
| |
|
|
|
|
| |
This reverts commit 4ea70107c5e51230e9e60f0bf58a0f74aa4885ea.
llvm-svn: 160303
|
| |
|
|
|
|
| |
This reverts commit 600f7a90f3eef4c5108179b43e27cfd9e5de7cdc.
llvm-svn: 160302
|
| |
|
|
|
|
| |
This reverts commit e3013202259ed1e006c21817c63cf25d75982721.
llvm-svn: 160301
|
| |
|
|
|
|
| |
This reverts commit 11d3457afcda7848448dd7f11b2ede6552ffb9ea.
llvm-svn: 160300
|
| |
|
|
|
|
|
|
| |
<llvm/IRBuilder.h> and <llvm/TypeBuilder.h>"
This reverts commit 0258a6bdd30802f5cc0e8e57c8e768fde2aef590.
llvm-svn: 160299
|
| |
|
|
|
|
|
|
| |
AMDGPUCommonTableGen."
This reverts commit ebc934ba32ee71abbb8f0f2eb6a0fbaa613ba0d2.
llvm-svn: 160298
|
| |
|
|
|
|
|
|
| |
conditional operator..."
This reverts commit 29f28bc14ad5a907f5dc849f004fafeec0aab33a.
llvm-svn: 160297
|
| |
|
|
|
|
|
|
| |
nonreturn function, instead of assert(0)."
This reverts commit 4ba4acc1bc2561b944a571edbb6a2dc78e357dfe.
llvm-svn: 160296
|
| |
|
|
|
|
| |
This reverts commit fef4aa1b16fcf7a472559abbbcf4c1adc9eb5ca6.
llvm-svn: 160295
|
| |
|
|
|
|
|
|
| |
full sets.
Make it always return APInts with the same bitwidth for the same ConstantRange bitwidth to simply clients
llvm-svn: 160294
|
| |
|
|
| |
llvm-svn: 160293
|
| |
|
|
|
|
| |
chandlerc, partially implemented crash callback merging (under flag)
llvm-svn: 160290
|
| |
|
|
|
|
| |
to use an unsigned char to ensure the integer promotion happens properly. This fixes an assert in debug builds with CodeGen\X86\utf8.ll
llvm-svn: 160286
|
| |
|
|
|
|
| |
fully implemented yet, no functionality change except the BB order)
llvm-svn: 160284
|
| |
|
|
| |
llvm-svn: 160280
|
| |
|
|
|
|
| |
function, instead of assert(0).
llvm-svn: 160279
|
| |
|
|
|
|
| |
operator...
llvm-svn: 160278
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Mips shift instructions DSLL, DSRL and DSRA are transformed into
DSLL32, DSRL32 and DSRA32 respectively if the shift amount is between
32 and 63
Here is a description of DSLL:
Purpose: Doubleword Shift Left Logical Plus 32
To execute a left-shift of a doubleword by a fixed amount--32 to 63 bits
Description: GPR[rd] <- GPR[rt] << (sa+32)
The 64-bit doubleword contents of GPR rt are shifted left, inserting
zeros into the emptied bits; the result is placed in
GPR rd. The bit-shift amount in the range 0 to 31 is specified by sa.
This patch implements the direct object output of these instructions.
llvm-svn: 160277
|
| |
|
|
|
|
| |
AMDGPUCommonTableGen.
llvm-svn: 160276
|
| |
|
|
|
|
| |
and <llvm/TypeBuilder.h>
llvm-svn: 160275
|
| |
|
|
|
|
|
|
| |
1. FileCheck-ize epilogue.ll and allow another asm instruction to restore %rsp.
2. Remove check in widen_arith-3.ll that was hitting instruction in epilogue instead of
vector add.
llvm-svn: 160274
|
| |
|
|
| |
llvm-svn: 160273
|
| |
|
|
| |
llvm-svn: 160272
|
| |
|
|
| |
llvm-svn: 160271
|
| |
|
|
| |
llvm-svn: 160270
|
| |
|
|
|
|
| |
on-demand
llvm-svn: 160269
|
| |
|
|
|
|
|
|
|
|
|
|
| |
undef virtual register. The problem is that ProcessImplicitDefs removes the
definition of the register and marks all uses as undef. If we lose the undef
marker then we get a register which has no def, is not marked as undef. The
live interval analysis does not collect information for these virtual
registers and we crash in later passes.
Together with Michael Kuperstein <michael.m.kuperstein@intel.com>
llvm-svn: 160260
|
| |
|
|
|
|
|
|
|
|
|
|
| |
It turns out that ASan relied on the at-the-end block insertion order to
(purely by happenstance) disable some LLVM optimizations, which in turn
start firing when the ordering is made more "normal". These
optimizations in turn merge many of the instrumentation reporting calls
which breaks the return address based error reporting in ASan.
We're looking at several different options for fixing this.
llvm-svn: 160256
|
| |
|
|
|
|
|
|
|
| |
This is particularly useful to the backend code generators which try to
process things in the incoming function order.
Also, cleanup some uses of IRBuilder to be a bit simpler and more clear.
llvm-svn: 160254
|
| |
|
|
|
|
|
|
|
|
|
| |
functionality test.
In general, unless the functionality is substantially separated, we
should lump more basic testing into this file. The test running
infrastructure likes having a few test files with more comprehensive
testing within them.
llvm-svn: 160253
|
| |
|
|
|
|
|
|
|
| |
Added a basic unit test for this with CreateCondBr. I didn't go all the
way and test the switch side as the boilerplate for setting up the
switch IRBuilder unit tests is a lot more. Fortunately, the two share
all the interesting code paths.
llvm-svn: 160251
|
| |
|
|
|
|
|
| |
This is in anticipation of changing CreateCondBr and wanting to test
those changes.
llvm-svn: 160250
|