[llvm] 52d981a - [SampleFDO] Enable FSAFDO loading passes if --enable-fs-discriminator is enabled

Rong Xu via llvm-commits llvm-commits at lists.llvm.org
Sat Feb 5 22:37:54 PST 2022


Author: Rong Xu
Date: 2022-02-05T22:37:09-08:00
New Revision: 52d981a4c13a8b320feba59cd851d58923267bed

URL: https://github.com/llvm/llvm-project/commit/52d981a4c13a8b320feba59cd851d58923267bed
DIFF: https://github.com/llvm/llvm-project/commit/52d981a4c13a8b320feba59cd851d58923267bed.diff

LOG: [SampleFDO] Enable FSAFDO loading passes if --enable-fs-discriminator is enabled

FSAFDO profile loader is currently disabled even --enable-fs-discriminator is enabled.
They need to be turned on by options which makes it cumbersome for experiments.

This patch changes the FSAFDO profile loader enabled by default.  Since they are
guarded by EnableFSDiscriminator, they will only be turned on if
--enable-fs-discriminator is enabled. Note that --enable-fs-discriminator is
still disabled by default.

Differential Revision: https://reviews.llvm.org/D119033

Added: 
    

Modified: 
    llvm/lib/CodeGen/TargetPassConfig.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/CodeGen/TargetPassConfig.cpp b/llvm/lib/CodeGen/TargetPassConfig.cpp
index 05004fb935df8..2b7f0ed41e1c9 100644
--- a/llvm/lib/CodeGen/TargetPassConfig.cpp
+++ b/llvm/lib/CodeGen/TargetPassConfig.cpp
@@ -175,12 +175,12 @@ static cl::opt<bool>
 // Disable MIRProfileLoader before RegAlloc. This is for for debugging and
 // tuning purpose.
 static cl::opt<bool> DisableRAFSProfileLoader(
-    "disable-ra-fsprofile-loader", cl::init(true), cl::Hidden,
+    "disable-ra-fsprofile-loader", cl::init(false), cl::Hidden,
     cl::desc("Disable MIRProfileLoader before RegAlloc"));
 // Disable MIRProfileLoader before BloackPlacement. This is for for debugging
 // and tuning purpose.
 static cl::opt<bool> DisableLayoutFSProfileLoader(
-    "disable-layout-fsprofile-loader", cl::init(true), cl::Hidden,
+    "disable-layout-fsprofile-loader", cl::init(false), cl::Hidden,
     cl::desc("Disable MIRProfileLoader before BlockPlacement"));
 // Specify FSProfile file name.
 static cl::opt<std::string>


        


More information about the llvm-commits mailing list