History log of /external/llvm/lib/CodeGen/EarlyIfConversion.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
986d76d7b3844b9a2f3d01a48975952749267a93 22-Aug-2012 David Blaikie <dblaikie@gmail.com> Tidy up a few more uses of MF.getFunction()->getName().

Based on CR feedback from r162301 and Craig Topper's refactoring in r162347
here are a few other places that could use the same API (& in one instance drop
a Function.h dependency).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162367 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
786556c26847befdb011298fd7b36ae86fd150b0 13-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Count triangles and diamonds in early if-conversion.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161783 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
5f6d36335b9468a16bd3b0c3ab8bab103841332a 13-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Delete dead typedef.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161782 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
bc70ff3cb977fd69e120d89b0e04f316d87cdbef 13-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Handle extra Tail predecessors in if-conversion.

It is still possible to if-convert if the tail block has extra
predecessors, but the tail phis must be rewritten instead of being
removed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161781 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
eb74c08192d9c9425b2d8cf08852e9e787a87881 11-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Add a proper if-conversion cost model.

Detect when there is not enough available ILP, so if-conversion can't
speculate instructions for free.

Compute the lengthening of the critical path when inserting a select
instruction that depends on the condition as well as both sides of the
if.

Reject conversions that would stretch the critical path by more than
half a mispredict penalty.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161713 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
870da6de2c3f3f40360e04882b9ddf42ded0930a 10-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Add getTPred() and getFPred() functions.

They identify the PHI predecessors in both diamonds and triangles.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161689 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
d6cf5f4224d0e600ebb810f1da09aabaeea7e6f3 08-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Heed -stress-early-ifcvt.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161513 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
0fac6aa076450f5474feb2ec697b7d63d33fa567 08-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Get the MispredictPenalty from MCSchedModel.

Thanks, Andy!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161507 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
84ef6ba44394f983d985b02e328cbb2dd779e4b0 07-Aug-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Add trace accessor methods, implement primitive if-conversion heuristic.

Compare the critical paths of the two traces through an if-conversion
candidate. If the difference is larger than the branch brediction
penalty, reject the if-conversion. If would never pay.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161433 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
ef6c76c984f821ea866902a7f9e695b16e971468 30-Jul-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Hook into PassManager's analysis verification.

By overriding Pass::verifyAnalysis(), the pass contents will be verified
by the pass manager.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160994 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
a1b2bf79796d8c44b1321a69a7236b85c33ef7ca 30-Jul-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Add MachineTraceMetrics::verify().

This function verifies the consistency of cached data in the
MachineTraceMetrics analysis.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160976 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
08f6ef6a7807250d84446661b7a6ec4afa762099 28-Jul-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Add more debug output to MachineTraceMetrics.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160905 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
9f63e104271eb91e545fa8cdb16fb9e10a8a9578 26-Jul-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Start scaffolding for a MachineTraceMetrics analysis pass.

This is still a work in progress.

Out-of-order CPUs usually execute instructions from multiple basic
blocks simultaneously, so it is necessary to look at longer traces when
estimating the performance effects of code transformations.

The MachineTraceMetrics analysis will pick a typical trace through a
given basic block and provide performance metrics for the trace. Metrics
will include:

- Instruction count through the trace.
- Issue count per functional unit.
- Critical path length, and per-instruction 'slack'.

These metrics can be used to determine the performance limiting factor
when executing the trace, and how it will be affected by a code
transformation.

Initially, this will be used by the early if-conversion pass.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160796 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
47730a774dd6392744ee62c7385665c780e1c4e1 11-Jul-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Require and preserve LoopInfo for early if-conversion.

It will surely be needed by heuristics.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160027 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
1f523dc45e29874bf8101e50b42ba707ffc8aff9 11-Jul-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Run early if-conversion in domtree post-order.

This ordering allows nested if-conversion without using a work list, and
it makes it possible to update the dominator tree on the fly as well.

Any erased basic blocks will always be dominated by the current
post-order position, so the domtree can be pruned without invalidating
the iterator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160025 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
86fc3100b552c8d400160581c2a00f2fd7b83b45 06-Jul-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Add some comments suggested in code review.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159800 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
00f43076a3d9cc76ef4736cf3e7215e19b05f6d5 04-Jul-2012 Matt Beaumont-Gay <matthewbg@google.com> Fix some ascii art in a comment to not have trailing backslashes (inspiration
from IfConversion.cc), and fix some spelling and grammar in the surrounding
prose.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159699 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp
33242fd3ed5586091e73254b58dd1825e9d53c60 04-Jul-2012 Jakob Stoklund Olesen <stoklund@2pi.dk> Add an experimental early if-conversion pass, off by default.

This pass performs if-conversion on SSA form machine code by
speculatively executing both sides of the branch and using a cmov
instruction to select the result. This can help lower the number of
branch mispredictions on architectures like x86 that don't have
predicable instructions.

The current implementation is very aggressive, and causes regressions on
mosts tests. It needs good heuristics that have yet to be implemented.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159694 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/CodeGen/EarlyIfConversion.cpp