Skip to content

Commit c73cbf2

Browse files
committed
[SampleFDO] Add missing #includes to unbreak modules build after D96455
Bot: http://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/28999 ``` /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/include/llvm/Transforms/Utils/SampleProfileLoaderBaseImpl.h:124:19: error: missing '#include "llvm/Analysis/PostDominators.h"'; 'PostDominatorTree' must be declared before it is used std::unique_ptr<PostDominatorTree> PDT; ^ /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/include/llvm/Analysis/PostDominators.h:28:7: note: declaration here is not visible class PostDominatorTree : public PostDomTreeBase<BasicBlock> { ^ While building module 'LLVM_Transforms' imported from /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/lib/Transforms/CFGuard/CFGuard.cpp:15: In file included from <module-includes>:191: /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/include/llvm/Transforms/Utils/SampleProfileLoaderBaseImpl.h:125:19: error: missing '#include "llvm/Analysis/LoopInfo.h"'; 'LoopInfo' must be declared before it is used std::unique_ptr<LoopInfo> LI; ^ /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/include/llvm/Analysis/LoopInfo.h:1079:7: note: declaration here is not visible class LoopInfo : public LoopInfoBase<BasicBlock, Loop> { ^ While building module 'LLVM_Transforms' imported from /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/lib/Transforms/CFGuard/CFGuard.cpp:15: In file included from <module-includes>:191: /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/include/llvm/Transforms/Utils/SampleProfileLoaderBaseImpl.h:149:3: error: missing '#include "llvm/Analysis/OptimizationRemarkEmitter.h"'; 'OptimizationRemarkEmitter' must be declared before it is used OptimizationRemarkEmitter *ORE = nullptr; ^ /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/include/llvm/Analysis/OptimizationRemarkEmitter.h:33:7: note: declaration here is not visible class OptimizationRemarkEmitter { ^ /Users/buildslave/jenkins/workspace/lldb-cmake/llvm-project/llvm/lib/Transforms/CFGuard/CFGuard.cpp:15:10: fatal error: could not build module 'LLVM_Transforms' ```
1 parent d6e8057 commit c73cbf2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

llvm/include/llvm/Transforms/Utils/SampleProfileLoaderBaseImpl.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@
2121
#include "llvm/ADT/SmallPtrSet.h"
2222
#include "llvm/ADT/SmallSet.h"
2323
#include "llvm/ADT/SmallVector.h"
24+
#include "llvm/Analysis/LoopInfo.h"
25+
#include "llvm/Analysis/OptimizationRemarkEmitter.h"
26+
#include "llvm/Analysis/PostDominators.h"
2427
#include "llvm/IR/BasicBlock.h"
2528
#include "llvm/IR/CFG.h"
2629
#include "llvm/IR/DebugInfoMetadata.h"

0 commit comments

Comments
 (0)