[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-04-30 Thread Anchu Rajendran S via cfe-commits
https://github.com/anchuraj edited https://github.com/llvm/llvm-project/pull/137996 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-04-30 Thread Anchu Rajendran S via cfe-commits
@@ -124,6 +128,8 @@ struct MLIRToLLVMPassPipelineConfig : public FlangEPCallBacks { bool UnsafeFPMath = false; ///< Set unsafe-fp-math attribute for functions. bool NSWOnLoopVarInc = true; ///< Add nsw flag to loop variable increments. bool EnableOpenMP = false; ///< Ena

[clang] [flang] [flang] Support flag -finstrument-functions (PR #137996)

2025-04-30 Thread Anchu Rajendran S via cfe-commits
https://github.com/anchuraj created https://github.com/llvm/llvm-project/pull/137996 `f-instrument-functions` helps in profiling functions. This PR adds support for the option by defining values for function attributes `instrument_function_entry` and `instrument_function_exit`. LLVM Backend a

[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-04-30 Thread Anchu Rajendran S via cfe-commits
https://github.com/anchuraj updated https://github.com/llvm/llvm-project/pull/137996 >From bb486c5e7cbe7b1c4a87469e06ca51bf49ddd081 Mon Sep 17 00:00:00 2001 From: Anchu Rajendran Date: Tue, 29 Apr 2025 14:41:55 -0500 Subject: [PATCH 1/2] [flang] Support flag -finstrument-functions --- clang/

[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-04-30 Thread Anchu Rajendran S via cfe-commits
https://github.com/anchuraj updated https://github.com/llvm/llvm-project/pull/137996 >From bb486c5e7cbe7b1c4a87469e06ca51bf49ddd081 Mon Sep 17 00:00:00 2001 From: Anchu Rajendran Date: Tue, 29 Apr 2025 14:41:55 -0500 Subject: [PATCH 1/3] [flang] Support flag -finstrument-functions --- clang/

[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-04-30 Thread Anchu Rajendran S via cfe-commits
@@ -310,6 +310,10 @@ static void parseCodeGenArgs(Fortran::frontend::CodeGenOptions &opts, args.filtered(clang::driver::options::OPT_fembed_offload_object_EQ)) opts.OffloadObjects.push_back(a->getValue()); + if (args.hasFlag(clang::driver::options::OPT_finstrument

[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-04-30 Thread Anchu Rajendran S via cfe-commits
https://github.com/anchuraj updated https://github.com/llvm/llvm-project/pull/137996 >From bb486c5e7cbe7b1c4a87469e06ca51bf49ddd081 Mon Sep 17 00:00:00 2001 From: Anchu Rajendran Date: Tue, 29 Apr 2025 14:41:55 -0500 Subject: [PATCH 1/3] [flang] Support flag -finstrument-functions --- clang/

[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-04-30 Thread Anchu Rajendran S via cfe-commits
@@ -81,6 +81,8 @@ class CodeGenOptions : public CodeGenOptionsBase { /// Options to add to the linker for the object file std::vector DependentLibs; + bool InstrumentFunctions{false}; anchuraj wrote: Updated. Thank you! https://github.com/llvm/llvm-proj

[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-05-01 Thread Anchu Rajendran S via cfe-commits
https://github.com/anchuraj updated https://github.com/llvm/llvm-project/pull/137996 >From bb486c5e7cbe7b1c4a87469e06ca51bf49ddd081 Mon Sep 17 00:00:00 2001 From: Anchu Rajendran Date: Tue, 29 Apr 2025 14:41:55 -0500 Subject: [PATCH 1/4] [flang] Support flag -finstrument-functions --- clang/

[clang] [flang] [flang][flang-driver] Support flag -finstrument-functions (PR #137996)

2025-05-01 Thread Anchu Rajendran S via cfe-commits
@@ -81,6 +81,8 @@ class CodeGenOptions : public CodeGenOptionsBase { /// Options to add to the linker for the object file std::vector DependentLibs; + bool InstrumentFunctions{false}; anchuraj wrote: Thank you for the review @tblah . Updated. https://gi