summaryrefslogtreecommitdiffstats
path: root/llvm/test/Transforms/HardwareLoops/ARM/simple-do.ll
Commit message (Collapse)AuthorAgeFilesLines
* [ARM][LowOverheadLoops] Enable by defaultSam Parker2019-07-301-3/+2
| | | | | | | | | The code is now in a good enough state to pass the bunch of tests that I have run (after fixing the bugs), so let's enable it by default. Differential Revision: https://reviews.llvm.org/D65277 llvm-svn: 367297
* [ARM] WLS/LE Code GenerationSam Parker2019-07-011-19/+23
| | | | | | | | | | | | | | | | | Backend changes to enable WLS/LE low-overhead loops for armv8.1-m: 1) Use TTI to communicate to the HardwareLoop pass that we should try to generate intrinsics that guard the loop entry, as well as setting the loop trip count. 2) Lower the BRCOND that uses said intrinsic to an Arm specific node: ARMWLS. 3) ISelDAGToDAG the node to a new pseudo instruction: t2WhileLoopStart. 4) Add support in ArmLowOverheadLoops to handle the new pseudo instruction. Differential Revision: https://reviews.llvm.org/D63816 llvm-svn: 364733
* [ARM] DLS/LE low-overhead loop code generationSam Parker2019-06-251-0/+37
| | | | | | | | | | | | | | | | | Introduce three pseudo instructions to be used during DAG ISel to represent v8.1-m low-overhead loops. One maps to set_loop_iterations while loop_decrement_reg is lowered to two, so that we can separate the decrement and branching operations. The pseudo instructions are expanded pre-emission, where we can still decide whether we actually want to generate a low-overhead loop, in a new pass: ARMLowOverheadLoops. The pass currently bails, reverting to an sub, icmp and br, in the cases where a call or stack spill/restore happens between the decrement and branching instructions, or if the loop is too large. Differential Revision: https://reviews.llvm.org/D63476 llvm-svn: 364288
* [SCEV] Pass NoWrapFlags when expanding an AddExprSam Parker2019-06-141-2/+2
| | | | | | | | | | | | InsertBinop now accepts NoWrapFlags, so pass them through when expanding a simple add expression. This is the first re-commit of the functional changes from rL362687, which was previously reverted. Differential Revision: https://reviews.llvm.org/D61934 llvm-svn: 363364
* Revert rL363156.Sam Parker2019-06-121-2/+0
| | | | | | | The patch was to fix buildbots, but rL363157 should now be fixing it in a cleaner way. llvm-svn: 363174
* Attempt to fix non-Arm buildbotsSam Parker2019-06-121-0/+2
| | | | | | Adding REQUIRES: arm to failing tests llvm-svn: 363156
* [ARM] Implement TTI::isHardwareLoopProfitableSam Parker2019-06-121-0/+155
Implement the backend target hook to drive the HardwareLoops pass. The low-overhead branch extension for Arm M-class cores is flexible enough that we don't have to ensure correctness at this point, except checking that the loop counter variable can be stored in LR - a 32-bit register. For it to be profitable, we want to avoid loops that contain function calls, or any other instruction that alters the PC. This implementation uses TargetLoweringInfo, to query type and operation actions, looks at intrinsic calls and also performs some manual checks for remainder/division and FP operations. I think this should be a good base to start and extra details can be filled out later. Differential Revision: https://reviews.llvm.org/D62907 llvm-svn: 363149
OpenPOWER on IntegriCloud