- Aug 13, 2012
-
-
Jakob Stoklund Olesen authored
llvm-svn: 161782
-
Jakob Stoklund Olesen authored
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. llvm-svn: 161781
-
- Aug 11, 2012
-
-
Jakob Stoklund Olesen authored
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. llvm-svn: 161713
-
- Aug 10, 2012
-
-
Jakob Stoklund Olesen authored
They identify the PHI predecessors in both diamonds and triangles. llvm-svn: 161689
-
- Aug 08, 2012
-
-
Jakob Stoklund Olesen authored
llvm-svn: 161513
-
Jakob Stoklund Olesen authored
Thanks, Andy! llvm-svn: 161507
-
- Aug 07, 2012
-
-
Jakob Stoklund Olesen authored
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. llvm-svn: 161433
-
- Jul 30, 2012
-
-
Jakob Stoklund Olesen authored
By overriding Pass::verifyAnalysis(), the pass contents will be verified by the pass manager. llvm-svn: 160994
-
Jakob Stoklund Olesen authored
This function verifies the consistency of cached data in the MachineTraceMetrics analysis. llvm-svn: 160976
-
- Jul 28, 2012
-
-
Jakob Stoklund Olesen authored
llvm-svn: 160905
-
- Jul 26, 2012
-
-
Jakob Stoklund Olesen authored
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. llvm-svn: 160796
-
- Jul 11, 2012
-
-
Jakob Stoklund Olesen authored
It will surely be needed by heuristics. llvm-svn: 160027
-
Jakob Stoklund Olesen authored
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. llvm-svn: 160025
-
- Jul 06, 2012
-
-
Jakob Stoklund Olesen authored
llvm-svn: 159800
-
- Jul 04, 2012
-
-
Matt Beaumont-Gay authored
from IfConversion.cc), and fix some spelling and grammar in the surrounding prose. llvm-svn: 159699
-
Jakob Stoklund Olesen authored
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. llvm-svn: 159694
-