[flang-commits] [clang] [flang] [llvm] Add IR Profile-Guided Optimization (IR PGO) support to the Flang compiler (PR #136098)

Tom Eccles via flang-commits flang-commits at lists.llvm.org
Mon Apr 28 08:31:02 PDT 2025


================
@@ -20,8 +20,13 @@
 #include "mlir/IR/OwningOpRef.h"
 #include "llvm/ADT/StringRef.h"
 #include "llvm/IR/Module.h"
+#include "llvm/Support/CommandLine.h"
+#include "llvm/Support/PGOOptions.h"
 #include <memory>
 
+namespace llvm {
+extern cl::opt<llvm::PGOOptions::ColdFuncOpt> ClPGOColdFuncAttr;
+} // namespace llvm
----------------
tblah wrote:

nit: I would put this `extern` in `flang/lib/Frontend/FrontendActions.cpp` because there is no need for this implementation detail to be part of the public interface.

https://github.com/llvm/llvm-project/pull/136098


More information about the flang-commits mailing list