LLVM  7.0.0
SampleProfile.h
Go to the documentation of this file.
1 //===- SampleProfile.h - SamplePGO pass ---------- --------------*- 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 /// \file
11 /// This file provides the interface for the sampled PGO loader pass.
12 //
13 //===----------------------------------------------------------------------===//
14 
15 #ifndef LLVM_TRANSFORMS_IPO_SAMPLEPROFILE_H
16 #define LLVM_TRANSFORMS_IPO_SAMPLEPROFILE_H
17 
18 #include "llvm/IR/PassManager.h"
19 #include <string>
20 
21 namespace llvm {
22 
23 class Module;
24 
25 /// The sample profiler data loader pass.
26 class SampleProfileLoaderPass : public PassInfoMixin<SampleProfileLoaderPass> {
27 public:
28  SampleProfileLoaderPass(std::string File = "", bool IsThinLTOPreLink = false)
29  : ProfileFileName(File), IsThinLTOPreLink(IsThinLTOPreLink) {}
30 
32 
33 private:
34  std::string ProfileFileName;
35  bool IsThinLTOPreLink;
36 };
37 
38 } // end namespace llvm
39 
40 #endif // LLVM_TRANSFORMS_SAMPLEPROFILE_H
Compute iterated dominance frontiers using a linear time algorithm.
Definition: AllocatorList.h:24
A Module instance is used to store all the information related to an LLVM module. ...
Definition: Module.h:63
PreservedAnalyses run(Module &M, ModuleAnalysisManager &AM)
The sample profiler data loader pass.
Definition: SampleProfile.h:26
A CRTP mix-in to automatically provide informational APIs needed for passes.
Definition: PassManager.h:365
A set of analyses that are preserved following a run of a transformation pass.
Definition: PassManager.h:153
SampleProfileLoaderPass(std::string File="", bool IsThinLTOPreLink=false)
Definition: SampleProfile.h:28
A container for analyses that lazily runs them and caches their results.
This header defines various interfaces for pass management in LLVM.