Home | History | Annotate | Line # | Download | only in Scalar
      1 //===- LoopUnrollAndJamPass.h -----------------------------------*- C++ -*-===//
      2 //
      3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
      4 // See https://llvm.org/LICENSE.txt for license information.
      5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
      6 //
      7 //===----------------------------------------------------------------------===//
      8 
      9 #ifndef LLVM_TRANSFORMS_SCALAR_LOOPUNROLLANDJAMPASS_H
     10 #define LLVM_TRANSFORMS_SCALAR_LOOPUNROLLANDJAMPASS_H
     11 
     12 #include "llvm/IR/PassManager.h"
     13 #include "llvm/Transforms/Scalar/LoopPassManager.h"
     14 
     15 namespace llvm {
     16 class Function;
     17 
     18 /// A simple loop rotation transformation.
     19 class LoopUnrollAndJamPass : public PassInfoMixin<LoopUnrollAndJamPass> {
     20   const int OptLevel;
     21 
     22 public:
     23   explicit LoopUnrollAndJamPass(int OptLevel = 2) : OptLevel(OptLevel) {}
     24   PreservedAnalyses run(LoopNest &L, LoopAnalysisManager &AM,
     25                         LoopStandardAnalysisResults &AR, LPMUpdater &U);
     26 };
     27 
     28 } // end namespace llvm
     29 
     30 #endif // LLVM_TRANSFORMS_SCALAR_LOOPUNROLLANDJAMPASS_H
     31