summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/TargetInstrInfo.cpp
diff options
context:
space:
mode:
authorGerolf Hoflehner <ghoflehner@apple.com>2016-04-22 02:15:19 +0000
committerGerolf Hoflehner <ghoflehner@apple.com>2016-04-22 02:15:19 +0000
commitb32f11fc62ef12de1762adf588de6ee6bd4b2bb0 (patch)
tree6b86fb22b492753a5a4735482ae05a367c41f92e /llvm/lib/CodeGen/TargetInstrInfo.cpp
parent6fb3f19959b39cb2f5cff276db55698464c59fa4 (diff)
downloadbcm5719-llvm-b32f11fc62ef12de1762adf588de6ee6bd4b2bb0.tar.gz
bcm5719-llvm-b32f11fc62ef12de1762adf588de6ee6bd4b2bb0.zip
[MachineCombiner] Support for floating-point FMA on ARM64
Evaluates fmul+fadd -> fmadd combines and similar code sequences in the machine combiner. It adds support for float and double similar to the existing integer implementation. The key features are: - DAGCombiner checks whether it should combine greedily or let the machine combiner do the evaluation. This is only supported on ARM64. - It gives preference to throughput over latency: the heuristic used is to combine always in loops. The targets decides whether the machine combiner should optimize for throughput or latency. - Supports for fmadd, f(n)msub, fmla, fmls patterns - On by default at O3 ffast-math llvm-svn: 267098
Diffstat (limited to 'llvm/lib/CodeGen/TargetInstrInfo.cpp')
-rw-r--r--llvm/lib/CodeGen/TargetInstrInfo.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/TargetInstrInfo.cpp b/llvm/lib/CodeGen/TargetInstrInfo.cpp
index 86517d9afbc..800ad6d1bb4 100644
--- a/llvm/lib/CodeGen/TargetInstrInfo.cpp
+++ b/llvm/lib/CodeGen/TargetInstrInfo.cpp
@@ -655,7 +655,11 @@ bool TargetInstrInfo::getMachineCombinerPatterns(
return false;
}
-
+/// Return true when a code sequence can improve loop throughput.
+bool
+TargetInstrInfo::isThroughputPattern(MachineCombinerPattern Pattern) const {
+ return false;
+}
/// Attempt the reassociation transformation to reduce critical path length.
/// See the above comments before getMachineCombinerPatterns().
void TargetInstrInfo::reassociateOps(
OpenPOWER on IntegriCloud