@@ -338,12 +574,33 @@ PreservedAnalyses GlobalDCEPass::run(Module &M,
ModuleAnalysisManager &MAM) {
// The second pass drops the bodies of functions which are dead...
std::vector DeadFunctions;
- for (Function &F : M)
+ std::set DeadFunctionsSet;
+ auto funcRemovedInIn
@@ -34,12 +40,223 @@ static cl::opt
ClEnableVFE("enable-vfe", cl::Hidden, cl::init(true),
cl::desc("Enable virtual function elimination"));
+static cl::opt ClReadSummary(
+"globaldce-read-summary",
+cl::desc("Read summary from given bitcode before r
@@ -34,12 +40,223 @@ static cl::opt
ClEnableVFE("enable-vfe", cl::Hidden, cl::init(true),
cl::desc("Enable virtual function elimination"));
+static cl::opt ClReadSummary(
+"globaldce-read-summary",
+cl::desc("Read summary from given bitcode before r
@@ -775,6 +783,58 @@ static void computeVariableSummary(ModuleSummaryIndex
&Index,
Index.addGlobalValueSummary(V, std::move(GVarSummary));
}
+static void ComputeDependencies(
teresajohnson wrote:
nit: function should be lowerCamelCase
https://github.com/l
@@ -34,12 +40,223 @@ static cl::opt
ClEnableVFE("enable-vfe", cl::Hidden, cl::init(true),
cl::desc("Enable virtual function elimination"));
+static cl::opt ClReadSummary(
+"globaldce-read-summary",
+cl::desc("Read summary from given bitcode before r
https://github.com/manman-ren updated
https://github.com/llvm/llvm-project/pull/69735
>From 1adce63e663203f858de86cfa231527ee2284505 Mon Sep 17 00:00:00 2001
From: Manman Ren
Date: Thu, 5 Oct 2023 10:56:53 -0700
Subject: [PATCH] Support VFE in thinLTO
We add a run of GlobalDCEPass with ImportS
https://github.com/manman-ren created
https://github.com/llvm/llvm-project/pull/69735
We add a run of GlobalDCEPass with ImportSummary. When ImportSummary is true,
we remove virtual functions in vtables with VCallVisibility not Public. In this
run, the regular GlobalDCEPass::AddVirtualFunction