diff options
author | Hal Finkel <hfinkel@anl.gov> | 2015-09-03 23:23:00 +0000 |
---|---|---|
committer | Hal Finkel <hfinkel@anl.gov> | 2015-09-03 23:23:00 +0000 |
commit | 75afa2b6b61e26ccc560732d33dcad3c1fc9f871 (patch) | |
tree | 9e41a4f4eace0abdf236fb757e7345c2fa6252a9 /llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp | |
parent | b47128aaf37bc027d66a0bc331beaad4a84da4dd (diff) | |
download | bcm5719-llvm-75afa2b6b61e26ccc560732d33dcad3c1fc9f871.tar.gz bcm5719-llvm-75afa2b6b61e26ccc560732d33dcad3c1fc9f871.zip |
[PowerPC] Always use aggressive interleaving on the A2
On the A2, with an eye toward QPX unaligned-load merging, we should always use
aggressive interleaving. It is generally superior to only using concatenation
unrolling.
llvm-svn: 246819
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp')
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp b/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp index 937d9c6810d..124556e2d17 100644 --- a/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp +++ b/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp @@ -197,6 +197,13 @@ void PPCTTIImpl::getUnrollingPreferences(Loop *L, } bool PPCTTIImpl::enableAggressiveInterleaving(bool LoopHasReductions) { + // On the A2, always unroll aggressively. For QPX unaligned loads, we depend + // on combining the loads generated for consecutive accesses, and failure to + // do so is particularly expensive. This makes it much more likely (compared + // to only using concatenation unrolling). + if (ST->getDarwinDirective() == PPC::DIR_A2) + return true; + return LoopHasReductions; } |