llvm-6502/lib/Target/NVPTX
Jingyue Wu 1241b83d61 [NVPTX] enable SpeculativeExecution in NVPTX
Summary:
SpeculativeExecution enables a series straight line optimizations (such
as SLSR and NaryReassociate) on conditional code. For example,

  if (...)
    ... b * s ...
  if (...)
    ... (b + 1) * s ...

speculative execution can hoist b * s and (b + 1) * s from then-blocks,
so that we have

  ... b * s ...
  if (...)
    ...
  ... (b + 1) * s ...
  if (...)
    ...

Then, SLSR can rewrite (b + 1) * s to (b * s + s) because after
speculative execution b * s dominates (b + 1) * s.

The performance impact of this change is significant. It speeds up the
benchmarks running EigenFloatContractionKernelInternal16x16
(ba68f42fa6/unsupported/Eigen/CXX11/src/Tensor/TensorContractionCuda.h (cl-526))
by roughly 2%. Some internal benchmarks that have the above code pattern
are improved by up to 40%. No significant slowdowns are observed on
Eigen CUDA microbenchmarks.

Reviewers: jholewinski, broune, eliben

Subscribers: llvm-commits, jholewinski

Differential Revision: http://reviews.llvm.org/D11201

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@242437 91177308-0d34-0410-b5e6-96231b3b80d8
2015-07-16 20:13:48 +00:00
..
InstPrinter Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
MCTargetDesc MC: Remove MCSubtargetInfo() default constructor 2015-07-10 22:43:42 +00:00
TargetInfo
cl_common_defines.h Update a couple of header inclusion guards 2014-05-31 21:26:09 +00:00
CMakeLists.txt Add NVPTXPeephole pass to reduce unnecessary address cast 2015-06-24 20:20:16 +00:00
LLVMBuild.txt Update libdeps in NVPTXCodeGen, since r225944. 2015-01-14 23:01:36 +00:00
Makefile
ManagedStringPool.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTX.h Add NVPTXPeephole pass to reduce unnecessary address cast 2015-06-24 20:20:16 +00:00
NVPTX.td [NVPTX] Associate a minimum PTX version for each SM architecture 2015-03-30 19:30:55 +00:00
NVPTXAllocaHoisting.cpp NVPTX: move NVPTXAllocaHoisting into the cpp file 2015-03-10 19:20:52 +00:00
NVPTXAllocaHoisting.h NVPTX: move NVPTXAllocaHoisting into the cpp file 2015-03-10 19:20:52 +00:00
NVPTXAsmPrinter.cpp Move most user of TargetMachine::getDataLayout to the Module one 2015-07-16 06:11:10 +00:00
NVPTXAsmPrinter.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXAssignValidGlobalNames.cpp Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXFavorNonGenericAddrSpaces.cpp Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXFrameLowering.cpp [NVPTX] cleanups and refacotring in NVPTXFrameLowering.cpp 2015-06-30 21:28:31 +00:00
NVPTXFrameLowering.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXGenericToNVVM.cpp [opaque pointer type] More GEP IRBuilder API migrations... 2015-04-03 21:33:42 +00:00
NVPTXImageOptimizer.cpp Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXInstrFormats.td [NVPTX] Add more surface/texture intrinsics, including CUDA unified texture fetch 2014-07-17 11:59:04 +00:00
NVPTXInstrInfo.cpp [CodeGen] ArrayRef'ize cond/pred in various TII APIs. NFC. 2015-06-11 19:30:37 +00:00
NVPTXInstrInfo.h [CodeGen] ArrayRef'ize cond/pred in various TII APIs. NFC. 2015-06-11 19:30:37 +00:00
NVPTXInstrInfo.td Reapply r235977 "[DebugInfo] Add debug locations to constant SD nodes" 2015-04-28 14:05:47 +00:00
NVPTXIntrinsics.td NVPTX: support direct f16 <-> f64 conversions via intrinsics. 2014-07-18 08:30:10 +00:00
NVPTXISelDAGToDAG.cpp [NVPTX] roll forward r239082 2015-06-04 21:28:26 +00:00
NVPTXISelDAGToDAG.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXISelLowering.cpp Remove getDataLayout() from TargetLowering 2015-07-09 02:09:52 +00:00
NVPTXISelLowering.h Re-instate the EVT parameter to getScalarShiftAmountTy() for OOT user 2015-07-09 15:12:23 +00:00
NVPTXLowerAggrCopies.cpp [NVPTX] Don't leak dead instructions after unlinking them from the BasicBlock 2015-07-16 16:51:48 +00:00
NVPTXLowerAggrCopies.h Move unreferenced passes into the cpp file 2015-03-09 15:50:58 +00:00
NVPTXLowerAlloca.cpp Add NVPTXLowerAlloca pass to convert alloca'ed memory to local address 2015-06-17 22:31:02 +00:00
NVPTXLowerKernelArgs.cpp [NVPTX] noop when kernel pointers are already global 2015-06-26 22:35:43 +00:00
NVPTXMachineFunctionInfo.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXMCExpr.cpp MC: Add target hook to control symbol quoting 2015-06-09 00:31:39 +00:00
NVPTXMCExpr.h MC: Add target hook to control symbol quoting 2015-06-09 00:31:39 +00:00
NVPTXPeephole.cpp [NVPTX] Move NVPTXPeephole after NVPTXPrologEpilogPass 2015-07-01 20:08:06 +00:00
NVPTXPrologEpilogPass.cpp Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXRegisterInfo.cpp Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXRegisterInfo.h Have getCalleeSavedRegs take a non-null MachineFunction all the 2015-03-11 21:41:28 +00:00
NVPTXRegisterInfo.td Add NVPTXPeephole pass to reduce unnecessary address cast 2015-06-24 20:20:16 +00:00
NVPTXReplaceImageHandles.cpp Cosmetic cleanups - NFC 2015-07-08 16:33:21 +00:00
NVPTXSection.h Implement unique sections with an unique ID. 2015-04-04 18:02:01 +00:00
NVPTXSubtarget.cpp Remove getDataLayout() from TargetSelectionDAGInfo (had no users) 2015-07-09 02:10:08 +00:00
NVPTXSubtarget.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXTargetMachine.cpp [NVPTX] enable SpeculativeExecution in NVPTX 2015-07-16 20:13:48 +00:00
NVPTXTargetMachine.h Replace string GNU Triples with llvm::Triple in TargetMachine. NFC. 2015-06-11 19:41:26 +00:00
NVPTXTargetObjectFile.h Remove DataLayout from TargetLoweringObjectFile, redirect to Module 2015-07-16 06:04:17 +00:00
NVPTXTargetTransformInfo.cpp Enable partial and runtime loop unrolling for NVPTX. 2015-07-13 18:33:21 +00:00
NVPTXTargetTransformInfo.h Enable partial and runtime loop unrolling for NVPTX. 2015-07-13 18:33:21 +00:00
NVPTXUtilities.cpp Simplify boolean expressions with true and false using clang-tidy 2015-03-23 16:26:23 +00:00
NVPTXUtilities.h Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
NVPTXVector.td Reapply r235977 "[DebugInfo] Add debug locations to constant SD nodes" 2015-04-28 14:05:47 +00:00
NVVMReflect.cpp Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00