LLVM  3.7.0
UnrollLoop.h
Go to the documentation of this file.
1 //===- llvm/Transforms/Utils/UnrollLoop.h - Unrolling utilities -*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file defines some loop unrolling utilities. It does not define any
11 // actual pass or policy, but provides a single function to perform loop
12 // unrolling.
13 //
14 //===----------------------------------------------------------------------===//
15 
16 #ifndef LLVM_TRANSFORMS_UTILS_UNROLLLOOP_H
17 #define LLVM_TRANSFORMS_UTILS_UNROLLLOOP_H
18 
19 #include "llvm/ADT/StringRef.h"
20 
21 namespace llvm {
22 
23 class AssumptionCache;
24 class Loop;
25 class LoopInfo;
26 class LPPassManager;
27 class MDNode;
28 class Pass;
29 
30 bool UnrollLoop(Loop *L, unsigned Count, unsigned TripCount, bool AllowRuntime,
31  bool AllowExpensiveTripCount, unsigned TripMultiple,
32  LoopInfo *LI, Pass *PP, LPPassManager *LPM,
33  AssumptionCache *AC);
34 
35 bool UnrollRuntimeLoopProlog(Loop *L, unsigned Count,
36  bool AllowExpensiveTripCount, LoopInfo *LI,
37  LPPassManager *LPM);
38 
39 MDNode *GetUnrollMetadata(MDNode *LoopID, StringRef Name);
40 }
41 
42 #endif
aarch64 type AArch64 Type Promotion Pass
MDNode * GetUnrollMetadata(MDNode *LoopID, StringRef Name)
Given an llvm.loop loop id metadata node, returns the loop hint metadata node with the given name (fo...
Definition: LoopUnroll.cpp:564
bool UnrollRuntimeLoopProlog(Loop *L, unsigned Count, bool AllowExpensiveTripCount, LoopInfo *LI, LPPassManager *LPM)
Insert code in the prolog code when unrolling a loop with a run-time trip-count.
bool UnrollLoop(Loop *L, unsigned Count, unsigned TripCount, bool AllowRuntime, bool AllowExpensiveTripCount, unsigned TripMultiple, LoopInfo *LI, Pass *PP, LPPassManager *LPM, AssumptionCache *AC)
Unroll the given loop by Count.
Definition: LoopUnroll.cpp:163