From: Simon Pilgrim Date: Thu, 16 Apr 2020 11:08:10 +0000 (+0100) Subject: Pass.h/cpp - cleanup includes and forward declaration. NFC. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ee66b5b0da7e54124b87268d33d9fad7a4a93b87;p=platform%2Fupstream%2Fllvm.git Pass.h/cpp - cleanup includes and forward declaration. NFC. Remove unused BasicBlock forward declaration from Pass.h and Attributes/BasicBlock includes from Pass.cpp Add BasicBlock forward declaration to UnifyFunctionExitNodes.h which was relying on Pass.h --- diff --git a/llvm/include/llvm/Pass.h b/llvm/include/llvm/Pass.h index 5ed4ca4..b0af15a 100644 --- a/llvm/include/llvm/Pass.h +++ b/llvm/include/llvm/Pass.h @@ -34,7 +34,6 @@ namespace llvm { class AnalysisResolver; class AnalysisUsage; -class BasicBlock; class Function; class ImmutablePass; class Module; diff --git a/llvm/include/llvm/Transforms/Utils/UnifyFunctionExitNodes.h b/llvm/include/llvm/Transforms/Utils/UnifyFunctionExitNodes.h index b8a4fe7..f1789ed 100644 --- a/llvm/include/llvm/Transforms/Utils/UnifyFunctionExitNodes.h +++ b/llvm/include/llvm/Transforms/Utils/UnifyFunctionExitNodes.h @@ -22,6 +22,8 @@ namespace llvm { +class BasicBlock; + struct UnifyFunctionExitNodes : public FunctionPass { BasicBlock *ReturnBlock = nullptr; BasicBlock *UnwindBlock = nullptr; diff --git a/llvm/lib/IR/Pass.cpp b/llvm/lib/IR/Pass.cpp index dbdbbf4..893cf2f 100644 --- a/llvm/lib/IR/Pass.cpp +++ b/llvm/lib/IR/Pass.cpp @@ -14,8 +14,6 @@ #include "llvm/Pass.h" #include "llvm/Config/llvm-config.h" -#include "llvm/IR/Attributes.h" -#include "llvm/IR/BasicBlock.h" #include "llvm/IR/Function.h" #include "llvm/IR/IRPrintingPasses.h" #include "llvm/IR/LLVMContext.h"