| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
| |
block. This prevents (at least in some cases) O(N^2) runtime in passes like DSE.
The limit in this patch is probably too high, but it is enough to stop DSE from going completely insane on a testcase I have (which has a single block with around 50,000 non-aliasing stores in it).
rdar://9471075
llvm-svn: 133111
|
|
|
|
|
|
| |
dependence for the given instruction exists in the given block". This cleans up all the existing hacks in memdep which represent this concept by returning clobber with various unrelated instructions.
llvm-svn: 133031
|
|
|
|
| |
llvm-svn: 132925
|
|
|
|
|
|
|
|
|
| |
Patch by: Jakub Staszak!
Introduces BranchProbability. Changes unsigned to uint32_t all over and
uint64_t only when overflow is expected.
llvm-svn: 132867
|
|
|
|
|
|
|
|
| |
default, since it usually has very few elements. This speeds up
alias queries in many cases, because AliasCache.clear() doesn't
have to visit as many buckets.
llvm-svn: 132862
|
|
|
|
| |
llvm-svn: 132797
|
|
|
|
|
|
| |
is disabled.
llvm-svn: 132632
|
|
|
|
|
|
|
|
|
|
| |
redundant with partially-aliasing loads.
When computing what portion of a clobbering load value is needed,
it doesn't consider phi-translation which may have occurred
between the clobbing load and the redundant load.
llvm-svn: 132631
|
|
|
|
| |
llvm-svn: 132625
|
|
|
|
| |
llvm-svn: 132620
|
|
|
|
| |
llvm-svn: 132616
|
|
|
|
|
|
|
|
|
|
|
| |
BranchProbabilityInfo provides an interface for IR passes to query the
likelihood that control follows a CFG edge. This patch provides an
initial implementation of static branch predication that will populate
BranchProbabilityInfo for branches with no external profile
information using very simple heuristics. It currently isn't hooked up
to any external profile data, so static prediction does all the work.
llvm-svn: 132613
|
|
|
|
|
|
| |
it exposed are fixed.
llvm-svn: 132611
|
|
|
|
|
|
|
|
|
| |
queries in the case of a DAG, where a query reaches a node
visited earlier, but it's not on a cycle. This avoids
MayAlias results in cases where BasicAA is expected to
return MustAlias or PartialAlias in order to protect TBAA.
llvm-svn: 132609
|
|
|
|
|
|
| |
of conservatively choosing MayAlias.
llvm-svn: 132579
|
|
|
|
| |
llvm-svn: 132558
|
|
|
|
|
|
| |
typedef decl itself. Use extra parameter to communicate this to DIBuilder.
llvm-svn: 132556
|
|
|
|
|
|
|
|
|
|
|
|
| |
instead of the first instruction in the block. This is a bit of a hack; "Clobber" isn't really the right marking in the first place. memdep doesn't really have any way of properly expressing "unanalyzable" at the moment. Using it on the terminator is much less ambiguous than using it on an arbitrary instruction, though.
In the given testcase, the "Clobber" was pointing to a load, and GVN was incorrectly assuming that meant that the "Clobber" load overlapped the load being analyzed (when they are actually unrelated).
The included testcase tests both this commit and r132434.
Part two of rdar://9429882. (r132434 was mislabeled.)
llvm-svn: 132442
|
|
|
|
|
|
|
|
| |
is is deemed unanalyzable (and we execute one of the "goto PredTranslationFailure" statements), make sure we don't put information about the predecessors of that block into the returned data structures; this can lead to, among other things, extraneous results (which will confuse passes using memdep). Fixes an assert in GVN compiling ruby. Part of rdar://problem/9521954 .
Testcase coming up soon.
llvm-svn: 132434
|
|
|
|
| |
llvm-svn: 132416
|
|
|
|
|
|
| |
so that their sign extended forms are congruent when no overflow occurs.
llvm-svn: 132360
|
|
|
|
|
|
| |
space, and the destination address space. Fix up the interface on MemIntrinsic and MemTransferInst to make this clear, and fix InstructionDereferencesPointer in LazyValueInfo.cpp to use the interface properly.
llvm-svn: 132356
|
|
|
|
| |
llvm-svn: 132202
|
|
|
|
|
|
|
| |
crc32.[8|16|32] have been renamed to .crc32.32.[8|16|32] and
crc64.[8|16|32] have been renamed to .crc32.64.[8|64].
llvm-svn: 132163
|
|
|
|
|
|
|
|
| |
metrics so that very long functions
with few basic blocks are not re-analyzed.
llvm-svn: 131994
|
|
|
|
|
|
|
|
| |
after checking for a GEP, so that it matches what GetUnderlyingObject
does. This fixes an obscure bug turned up by bugpoint in the testcase
for PR9931.
llvm-svn: 131971
|
|
|
|
|
|
|
|
| |
miscompilation of
UnitTests/ObjC/messages-2.m with the recent optimizer improvements.
llvm-svn: 131897
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
aligned.
Teach memcpyopt to not give up all hope when confonted with an underaligned
memcpy feeding an overaligned byval. If the *source* of the memcpy can be
determined to be adequeately aligned, or if it can be forced to be, we can
eliminate the memcpy.
This addresses PR9794. We now compile the example into:
define i32 @f(%struct.p* nocapture byval align 8 %q) nounwind ssp {
entry:
%call = call i32 @g(%struct.p* byval align 8 %q) nounwind
ret i32 %call
}
in both x86-64 and x86-32 mode. We still don't get a tailcall though,
because tailcalls apparently can't handle byval.
llvm-svn: 131884
|
|
|
|
|
|
| |
C99 runtimes don't have exp2).
llvm-svn: 131872
|
|
|
|
| |
llvm-svn: 131861
|
|
|
|
|
|
|
|
|
| |
Original log message:
When BasicAA can determine that two pointers have the same base but
differ by a dynamic offset, return PartialAlias instead of MayAlias.
See the comment in the code for details. This fixes PR9971.
llvm-svn: 131809
|
|
|
|
|
|
|
| |
differ by a dynamic offset, return PartialAlias instead of MayAlias.
See the comment in the code for details. This fixes PR9971.
llvm-svn: 131781
|
|
|
|
|
|
|
|
|
|
| |
No functionality enabled by default. Use -disable-iv-rewrite.
Extended IVUsers to keep track of the phi that represents the users' IV.
Added the WidenIV transform to replace a narrow IV with a wide IV
by doing a one-for-one replacement of IV users instead of expanding the
SCEV expressions. [sz]exts are removed and truncs are inserted.
llvm-svn: 131744
|
|
|
|
| |
llvm-svn: 131437
|
|
|
|
| |
llvm-svn: 131405
|
|
|
|
|
|
|
|
| |
set.
rdar://9423996
llvm-svn: 131283
|
|
|
|
| |
llvm-svn: 131088
|
|
|
|
|
|
|
| |
often expressed as "x >= y ? x : y", there is a good chance we can extract
the existing "x >= y" from it and use that as a replacement for "max(x,y)==x".
llvm-svn: 131049
|
|
|
|
|
|
| |
side of the icmp is an exact shift.
llvm-svn: 130954
|
|
|
|
| |
llvm-svn: 130920
|
|
|
|
|
|
|
|
| |
but according to my super-optimizer there are only two missed simplifications
of -instsimplify kind when compiling bzip2, and this is one of them. It amuses
me to have bzip2 be perfectly optimized as far as instsimplify goes!
llvm-svn: 130840
|
|
|
|
|
|
|
|
| |
This adds functionality to remove size/zero extension during indvars
without generating a canonical IV and rewriting all IV users. It's
disabled by default so should have no effect on codegen. Work in progress.
llvm-svn: 130829
|
|
|
|
|
|
|
|
| |
max(a,b) >= a -> true. According to my super-optimizer, these are
by far the most common simplifications (of the -instsimplify kind)
that occur in the testsuite and aren't caught by -std-compile-opts.
llvm-svn: 130780
|
|
|
|
| |
llvm-svn: 130756
|
|
|
|
|
|
| |
a vector compare, generate a vector result rather than i1 (and crashing).
llvm-svn: 130706
|
|
|
|
|
|
|
| |
This automagically provides a transform noticed by my super-optimizer
as occurring quite often: "rem x, (select cond, x, 1)" -> 0.
llvm-svn: 130694
|
|
|
|
|
|
|
|
|
|
|
| |
wider load would allow elimination of subsequent loads, and when the wider
load is still a native integer type. This eliminates a ton of loads on
various benchmarks involving struct fields, though it is somewhat hobbled
by clang not being very aggressive about field alignment.
This is yet another step along the way towards resolving PR6627.
llvm-svn: 130390
|
|
|
|
| |
llvm-svn: 130327
|
|
|
|
|
|
|
|
|
| |
only check arguments with pointer types. Update the documentation
of IntrReadArgMem reflect this.
While here, add support for TBAA tags on intrinsic calls.
llvm-svn: 130317
|
|
|
|
| |
llvm-svn: 130316
|