[PATCH] D84473: Dump Accumulator

2020-07-23 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/include/llvm/Analysis/DumpAccumulator.h:43 +// +// Note that ThinLTO is not supported yet. +// I'd clarify that transferring the data from pre-link thinlto to post-link isn't supported, but one could use this in po

[PATCH] D84473: Dump Accumulator

2020-07-27 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/include/llvm/Analysis/DumpAccumulator.h:43 +// +// Note that ThinLTO is not supported yet. +// kazu wrote: > mtrofin wrote: > > I'd clarify that transferring the data from pre-link thinlto to post-link > > isn't su

[PATCH] D84473: Dump Accumulator

2020-07-27 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin accepted this revision. mtrofin added a comment. This revision is now accepted and ready to land. lgtm Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D84473/new/ https://reviews.llvm.org/D84473 _

[PATCH] D81223: Size LTO (1/3): Standardizing the use of OptimizationLevel

2020-06-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/include/llvm/IR/PassManager.h:413 +/// LLVM-provided high-level optimization levels. +/// I think this change - moving OptimizationLevel out - should be in its own patch, to avoid noise. Commen

[PATCH] D132991: [Clang] Give error message for invalid profile path when compiling IR

2022-09-07 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D132991#3764877 , @aidengrossman wrote: > @xur I've modified the patch slightly (mainly fixing tests and changing the > error message printing in `CodeGenModule` to an assert as we should be > capturing everything in `Compil

[PATCH] D130620: Fix lack of cc1 flag in llvmcmd sections when assertions are enabled

2022-07-29 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D130620#3686357 , @aidengrossman wrote: > Thanks for the review and your suggestions. Do you mind pushing this commit? > I don't currently have commit access to LLVM. Thanks. I can do it. Repository: rG LLVM Github Monor

[PATCH] D130620: Fix lack of cc1 flag in llvmcmd sections when assertions are enabled

2022-07-29 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGafb4efd3bcc6: Fix lack of cc1 flag in llvmcmd sections when assertions are enabled (authored by aidengrossman, committed by mtrofin). Repository:

[PATCH] D131448: Introduce iterator sentinel to make graph traversal implementation more efficient and cleaner

2022-08-09 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. lgtm for the MLInlineAdvisor bit Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131448/new/ https://reviews.llvm.org/D131448 ___ cfe-commits mailing list cfe-commits@lists.llvm.or

[PATCH] D107025: Take OptimizationLevel class out of Pass Builder

2021-07-28 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/include/llvm/Passes/OptimizationLevel.h:14 +//===--===// + +class OptimizationLevel final { this should be in the llvm namespace

[PATCH] D107025: Take OptimizationLevel class out of Pass Builder

2021-07-29 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin accepted this revision. mtrofin added inline comments. This revision is now accepted and ready to land. Comment at: llvm/include/llvm/Passes/OptimizationLevel.h:128 +#endif \ No newline at end of file add a newline here (it helps diff tools) CHANGES SI

[PATCH] D107025: Take OptimizationLevel class out of Pass Builder

2021-07-29 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG7a797b290299: Take OptimizationLevel class out of Pass Builder (authored by tarinduj, committed by mtrofin). Repository: rG LLVM Github Monorepo

[PATCH] D119876: [nfc][codegen] Move RegisterBank[Info].h under CodeGen

2022-02-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: qcolombet. Herald added subscribers: foad, frasercrmck, kerbowa, luismarques, apazos, sameer.abuasal, pengfei, s.egerton, Jim, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, atanasyan, edward-jones, zzheng, jrtc27, niosHD, sabu

[PATCH] D119876: [nfc][codegen] Move RegisterBank[Info].h under CodeGen

2022-02-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/include/llvm/CodeGen/RegisterBankInfo.h:220 : ID(ID), Cost(Cost), OperandsMapping(OperandsMapping), - NumOperands(NumOperands) { -} + NumOperands(NumOperands) {} ah - `clang-format`

[PATCH] D72547: [llvm] Make new pass manager's OptimizationLevel a class

2020-01-10 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. Herald added subscribers: llvm-commits, cfe-commits, dang, dexonsmith, steven_wu, hiraditya, mehdi_amini. Herald added projects: clang, LLVM. mtrofin added reviewers: tejohnson, davidxl. mtrofin added a comment. Another example where there is a discrepancy with the

[PATCH] D72547: [llvm] Make new pass manager's OptimizationLevel a class

2020-01-10 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. Another example where there is a discrepancy with the old pass manager: in the old pass manager (PassManagerBuilder::addFunctionSimplificationPasses): if (OptLevel > 1) { if (EnableGVNHoist) MPM.add(createGVNHoistPass()); (before this change, new pass ma

[PATCH] D72547: [llvm] Make new pass manager's OptimizationLevel a class

2020-01-10 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 237464. mtrofin added a comment. Speedup level is actually '2' for Os and Oz Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72547/new/ https://reviews.llvm.org/D72547 Files: clang/lib/CodeGen/BackendUtil.cpp

[PATCH] D72547: [llvm] Make new pass manager's OptimizationLevel a class

2020-01-14 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 238107. mtrofin marked 2 inline comments as done. mtrofin added a comment. Alternative: expose speedup/size components to more closely align with legacy PM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72547/new

[PATCH] D72547: [llvm] Make new pass manager's OptimizationLevel a class

2020-01-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 238352. mtrofin marked 4 inline comments as done. mtrofin added a comment. Herald added a subscriber: zzheng. Incorporated feedback: - tests - updated patch description Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.

[PATCH] D87636: [ThinLTO] add post-thinlto-merge option to -lto-embed-bitcode

2020-09-14 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added reviewers: tejohnson, zapster. Herald added subscribers: llvm-commits, cfe-commits, dexonsmith, steven_wu, hiraditya, inglorion. Herald added a reviewer: alexshap. Herald added projects: clang, LLVM. mtrofin requested review of this revision. This will

[PATCH] D87636: [ThinLTO] add post-thinlto-merge option to -lto-embed-bitcode

2020-09-14 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: clang/test/CodeGen/Inputs/start-lib2.ll:4 -declare void @bar() - -define void @foo() { +define void @bar() { ret void The message that this was copied from llvm/test/LTO/X86/Inputs/start-lib1.ll is incorrect - this

[PATCH] D87636: [ThinLTO] add post-thinlto-merge option to -lto-embed-bitcode

2020-09-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 292040. mtrofin added a comment. feedback Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87636/new/ https://reviews.llvm.org/D87636 Files: clang/lib/CodeGen/BackendUtil.cpp clang/test/CodeGen/Inputs/start-l

[PATCH] D87636: [ThinLTO] add post-thinlto-merge option to -lto-embed-bitcode

2020-09-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/lib/LTO/LTOBackend.cpp:368 + LLVM_DEBUG( + dbgs() << "Post-ThinLTO merge bitcode embedding was requested, but " +"command line arguments are not available"); tejohnson wrote: > Upda

[PATCH] D87636: [ThinLTO] add post-thinlto-merge option to -lto-embed-bitcode

2020-09-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 292041. mtrofin marked 3 inline comments as done. mtrofin added a comment. comment update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87636/new/ https://reviews.llvm.org/D87636 Files: clang/lib/CodeGen/Bac

[PATCH] D87636: [ThinLTO] add post-thinlto-merge option to -lto-embed-bitcode

2020-09-15 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG61fc10d6a520: [ThinLTO] add post-thinlto-merge option to -lto-embed-bitcode (authored by mtrofin). Repository: rG LLVM Github Monorepo CHANGES SI

[PATCH] D87949: [ThinLTO] Option to bypass function importing.

2020-09-18 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: tejohnson. Herald added subscribers: llvm-commits, cfe-commits, dexonsmith, steven_wu, hiraditya, inglorion. Herald added a reviewer: alexshap. Herald added projects: clang, LLVM. mtrofin requested review of this revision. This completes th

[PATCH] D87949: [ThinLTO] Option to bypass function importing.

2020-09-21 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 293189. mtrofin marked 2 inline comments as done. mtrofin added a comment. feedback Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87949/new/ https://reviews.llvm.org/D87949 Files: clang/include/clang/CodeGen

[PATCH] D87949: [ThinLTO] Option to bypass function importing.

2020-09-22 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 293506. mtrofin added a comment. clang tidy Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87949/new/ https://reviews.llvm.org/D87949 Files: clang/include/clang/CodeGen/BackendUtil.h clang/lib/CodeGen/Backe

[PATCH] D87949: [ThinLTO] Option to bypass function importing.

2020-09-22 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGcf112382ddd0: [ThinLTO] Option to bypass function importing. (authored by mtrofin). Changed prior to commit: https://reviews.llvm.org/D87949?vs=293506&id=293555#toc Repository: rG LLVM Github Monorep

[PATCH] D88114: [clang]Test ensuring -fembed-bitcode passed to cc1 captures pre-opt bitcode.

2020-09-22 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added reviewers: steven_wu, tejohnson. Herald added a reviewer: alexshap. Herald added subscribers: cfe-commits, dexonsmith. Herald added a project: clang. mtrofin requested review of this revision. This is important to not regress because it allows us to cap

[PATCH] D88114: [clang]Test ensuring -fembed-bitcode passed to cc1 captures pre-opt bitcode.

2020-09-22 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D88114#2288732 , @steven_wu wrote: > I am not sure what exactly is expected here. What is your definition for > pre-optimized bitcode and how your test case ensures that? Can you explain a > bit more for context? Pre-optimize

[PATCH] D88114: [clang]Test ensuring -fembed-bitcode passed to cc1 captures pre-opt bitcode.

2020-09-22 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D88114#2288749 , @steven_wu wrote: > In D88114#2288737 , @mtrofin wrote: > >> In D88114#2288732 , @steven_wu >> wrote: >> >>> I am not sure what

[PATCH] D88114: [clang]Test ensuring -fembed-bitcode passed to cc1 captures pre-opt bitcode.

2020-09-23 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D88114#2288860 , @steven_wu wrote: > Ok, I guess we are on the same page. The idea sounds fine to me. > > I would suggest just check that the output matches the input file as much as > possible, rather than just check a label a

[PATCH] D88114: [clang]Test ensuring -fembed-bitcode passed to cc1 captures pre-opt bitcode.

2020-09-23 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 293761. mtrofin added a comment. Added a C test, strenghtened the checks Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88114/new/ https://reviews.llvm.org/D88114 Files: clang/test/Frontend/embed-bitcode-noop

[PATCH] D88114: [clang]Test ensuring -fembed-bitcode passed to cc1 captures pre-opt bitcode.

2020-09-23 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 293762. mtrofin added a comment. newline at end of file Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88114/new/ https://reviews.llvm.org/D88114 Files: clang/test/Frontend/embed-bitcode-noopt.c clang/test/

[PATCH] D88114: [clang]Test ensuring -fembed-bitcode passed to cc1 captures pre-opt bitcode.

2020-09-23 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG437358be7179: [clang]Test ensuring -fembed-bitcode passed to cc1 captures pre-opt bitcode. (authored by mtrofin). Repository: rG LLVM Github Monor

[PATCH] D93078: [utils] Fix UpdateTestChecks case where 2 runs differ for last label

2020-12-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 311359. mtrofin marked an inline comment as done. mtrofin added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. added check for when a prefix has conflicts for all functions Repository: rG LLVM Github Monorepo CHANGES SIN

[PATCH] D93078: [utils] Fix UpdateTestChecks case where 2 runs differ for last label

2020-12-14 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin marked an inline comment as done. mtrofin added a comment. In D93078#2451747 , @pengfei wrote: > What's the difference with the existing code? It looks to me that you just > brought the warning out of loop, right? Oh true! we can just do the chec

[PATCH] D93078: [utils] Fix UpdateTestChecks case where 2 runs differ for last label

2020-12-14 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 311593. mtrofin marked 3 inline comments as done. mtrofin added a comment. fix Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93078/new/ https://reviews.llvm.org/D93078 Files: clang/test/utils/update_cc_test_

[PATCH] D93078: [utils] Fix UpdateTestChecks case where 2 runs differ for last label

2020-12-14 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. cleanup Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93078/new/ https://reviews.llvm.org/D93078 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cg

[PATCH] D93078: [utils] Fix UpdateTestChecks case where 2 runs differ for last label

2020-12-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D93078#2453891 , @pengfei wrote: > LGTM. Thanks. > `update_test_prefix.py` assumes the conflicting output. You may need to > change the expection of it as well. oh yes - made it check the new warning. Thanks! Repository: r

[PATCH] D93078: [utils] Fix UpdateTestChecks case where 2 runs differ for last label

2020-12-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 311896. mtrofin added a comment. update_test_prefix.py change Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D93078/new/ https://reviews.llvm.org/D93078 Files: clang/test/utils/update_cc_test_checks/Inputs/pre

[PATCH] D93078: [utils] Fix UpdateTestChecks case where 2 runs differ for last label

2020-12-15 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGe2dc306b1ac7: [utils] Fix UpdateTestChecks case where 2 runs differ for last label (authored by mtrofin). Repository: rG LLVM Github Monorepo CHA

[PATCH] D93078: [utils] Fix UpdateTestChecks case where 2 runs differ for last label

2020-12-15 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/utils/update_analyze_test_checks.py:129 + +common.warn_on_failed_prefixes(func_dict) is_in_function = False pengfei wrote: > Can we move these warn to common.py? Come to think of it, maybe moving it to

[PATCH] D91229: [FileCheck] Flip -allow-unused-prefixes to false by default

2020-11-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: jhenderson. Herald added subscribers: llvm-commits, cfe-commits, frasercrmck, nikic, okura, jdoerfert, kuter, kerbowa, luismarques, apazos, sameer.abuasal, pzheng, pengfei, s.egerton, lenary, dmgreen, Jim, asbirlea, thopre, mstorsjo, jocewe

[PATCH] D91229: [FileCheck] Flip -allow-unused-prefixes to false by default

2020-11-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. FYI - I realize the change is enormous. I don't necessarily mean to land it as-is, we can chunk it by directories and iteratively update this as those land. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91229/new/ https://

[PATCH] D91229: [FileCheck] Flip -allow-unused-prefixes to false by default

2020-11-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91229#2387923 , @jhenderson wrote: > Maybe one way to do this is to do what @RKSimon suggests in the D90281 > , and to enable it on a per-directory basis > using lit.local.cfg. That would pote

[PATCH] D91229: [FileCheck] Flip -allow-unused-prefixes to false by default

2020-11-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91229#2389141 , @dblaikie wrote: >> because FileCheck won't accept more than one occurrence of >> --allow-unused-prefixes > > Perhaps this is a fixable issue? I think I was able to circumvent it in D91275

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-16 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added reviewers: aeubanks, jdoerfert, davidxl, eraman. Herald added subscribers: llvm-commits, cfe-commits, hiraditya. Herald added projects: clang, LLVM. mtrofin requested review of this revision. Enable performing mandatory inlinings upfront, by reusing the

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-16 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. Please note: the patch isn't 100% ready, there are those tests that check how the pipeline is composed, which are unpleasant to fix, so I want to defer them to after we get agreement over the larger points this patch brings (i.e. pre-performing always inlinings, value i

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-16 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91567#2398440 , @dblaikie wrote: >> Performing the mandatory inlinings first simplifies the problem the full >> inliner needs to solve > > That confuses me a bit - is that suggesting that we don't run the > AlwaysInliner when

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-16 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91567#2398623 , @dblaikie wrote: > In D91567#2398461 , @mtrofin wrote: > >> In D91567#2398440 , @dblaikie wrote: >> Performing the mandatory

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-17 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91567#2400207 , @aeubanks wrote: > What about removing the existing AlwaysInlinerPass and replacing it with this > one? Or is that something you were planning to do in a follow-up change? That's the plan, yes. >> open the op

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-17 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91567#2401021 , @dblaikie wrote: > In D91567#2398637 , @mtrofin wrote: > >> In D91567#2398623 , @dblaikie wrote: >> >>> In D91567#2398461

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-18 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 306141. mtrofin added a comment. Running just the always inliner variant, without other passes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91567/new/ https://reviews.llvm.org/D91567 Files: clang/test/Fron

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-18 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91567#2403173 , @aeubanks wrote: > In D91567#2400699 , @mtrofin wrote: > >> In D91567#2400207 , @aeubanks wrote: >> >>> What about removing the e

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-18 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91567#2403216 , @aeubanks wrote: >>> I'll run this through llvm-compile-time-tracker to see what the compile >>> time implications are. >> >> You mean for the variant where we ran some of the function passes, or you'd >> try

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-18 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91567#2403236 , @aeubanks wrote: > One thing that would be nice would be to have both inliners in the same CGSCC > pass manager to avoid doing SCC construction twice, but that would require > some shuffling of module/cgscc pa

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-18 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D91567#2403544 , @aeubanks wrote: > In D91567#2403252 , @mtrofin wrote: > >> In D91567#2403236 , @aeubanks wrote: >> >>> One thing that would be n

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-19 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 306593. mtrofin added a comment. Herald added subscribers: wenlei, steven_wu. patched up tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91567/new/ https://reviews.llvm.org/D91567 Files: clang/test/CodeG

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-30 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 308422. mtrofin added a comment. Fixed the LTO case. Also fixed the p46945 test, which, post - D90566 , was passing without the need of a preliminary always-inlier pass. The reason is that the order of the traversal of the f

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-30 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 308441. mtrofin marked 5 inline comments as done. mtrofin added a comment. fixes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D91567/new/ https://reviews.llvm.org/D91567 Files: clang/test/CodeGen/thinlto-dis

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-30 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/include/llvm/Analysis/InlineAdvisor.h:27 /// There are 3 scenarios we can use the InlineAdvisor: /// - Default - use manual heuristics. aeubanks wrote: > aeubanks wrote: > > 4 > ping sorry - done Repository:

[PATCH] D91567: [llvm][inliner] Reuse the inliner pass to implement 'always inliner'

2020-11-30 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG5fe10263ab39: [llvm][inliner] Reuse the inliner pass to implement 'always inliner' (authored by mtrofin). Repository: rG LLVM Github Monorepo CHA

[PATCH] D90278: [ThinLTO] Fix .llvmcmd emission

2020-10-27 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: tejohnson. Herald added subscribers: llvm-commits, cfe-commits, steven_wu, hiraditya, inglorion. Herald added projects: clang, LLVM. mtrofin requested review of this revision. llvm::EmbedBitcodeInModule needs (what used to be called) EmbedM

[PATCH] D90278: [ThinLTO] Fix .llvmcmd emission

2020-10-28 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D90278#2359674 , @tejohnson wrote: > LGTM but is there a functional reason why CmdArgs was changed to be passed by > reference? If just generic cleanup might be better to split up that into a > separate commit. It avoids havi

[PATCH] D90330: [NFC][ThinLTO] Change command line passing to EmbedBitcodeInModule

2020-10-28 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: tejohnson. Herald added subscribers: llvm-commits, cfe-commits, steven_wu, hiraditya, inglorion. Herald added projects: clang, LLVM. mtrofin requested review of this revision. Changing to pass by ref - less null checks to worry about. Rep

[PATCH] D90330: [NFC][ThinLTO] Change command line passing to EmbedBitcodeInModule

2020-10-28 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG6fa35541a0af: [NFC][ThinLTO] Change command line passing to EmbedBitcodeInModule (authored by mtrofin). Changed prior to commit: https://reviews.l

[PATCH] D90278: [ThinLTO] Fix .llvmcmd emission

2020-10-28 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 301391. mtrofin added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90278/new/ https://reviews.llvm.org/D90278 Files: clang/test/CodeGen/thinlto_embed_bitcode.ll llvm/include/llvm/Bitcode

[PATCH] D90278: [ThinLTO] Fix .llvmcmd emission

2020-10-28 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG735ab4be3569: [ThinLTO] Fix .llvmcmd emission (authored by mtrofin). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://revi

[PATCH] D90366: [ThinLTO] Strenghten the test for .llvmcmd embedding

2020-10-28 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: tejohnson. Herald added subscribers: cfe-commits, steven_wu, hiraditya, inglorion. Herald added a reviewer: alexshap. Herald added a project: clang. mtrofin requested review of this revision. Always populate the CodeGenOptions::CmdArgs - the

[PATCH] D90366: [ThinLTO] Strenghten the test for .llvmcmd embedding

2020-10-29 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D90366#2362052 , @tejohnson wrote: > The motivation and effects of the change are unclear to me. Does this mean > that the .llvmcmd section is always emitted? Or always emitted whenever any > bitcode embedding is requested? T

[PATCH] D90366: [ThinLTO] Strenghten the test for .llvmcmd embedding

2020-10-29 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 301641. mtrofin added a comment. fixed sentence Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90366/new/ https://reviews.llvm.org/D90366 Files: clang/lib/Frontend/CompilerInvocation.cpp clang/test/CodeGen/

[PATCH] D90366: [ThinLTO] Fix empty .llvmcmd sections

2020-10-29 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 301650. mtrofin marked an inline comment as done. mtrofin added a comment. updated description Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90366/new/ https://reviews.llvm.org/D90366 Files: clang/lib/Fronte

[PATCH] D90366: [ThinLTO] Fix empty .llvmcmd sections

2020-10-29 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG13aee94bc710: [ThinLTO] Fix empty .llvmcmd sections (authored by mtrofin). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:

[PATCH] D90430: [clang][NFC] Remove unused FileCheck prefix

2020-10-30 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin accepted this revision. mtrofin added a comment. In D90430#2365397 , @google-llvm-upstream-contributions wrote: > lgtm ugh, sorry, that's an alias I am auto-logged in on my personal account. Still LGTM :) Repository: rG LLVM Github Monorepo

[PATCH] D95249: [NFC] Disallow unused prefixes in clang/test/Analysis

2021-01-22 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D95249 Files: clang/test/Analysis/auto-obj-dtors-cfg-output.cpp clang/test/Analysis/

[PATCH] D95249: [NFC] Disallow unused prefixes in clang/test/Analysis

2021-01-25 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 319024. mtrofin added a comment. fixed trimmers.dot Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95249/new/ https://reviews.llvm.org/D95249 Files: clang/test/Analysis/auto-obj-dtors-cfg-output.cpp clang/t

[PATCH] D95249: [NFC] Disallow unused prefixes in clang/test/Analysis

2021-01-25 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG91b61abafb5a: [NFC] Disallow unused prefixes in clang/test/Analysis (authored by mtrofin). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95249/new/ https://

[PATCH] D95417: [NFC] Disallow unused prefixes under clang/test/CodeGen

2021-01-25 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: MaskRay. mtrofin requested review of this revision. Herald added a reviewer: jdoerfert. Herald added subscribers: cfe-commits, sstefan1. Herald added a project: clang. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D95417 F

[PATCH] D95417: [NFC] Disallow unused prefixes under clang/test/CodeGen

2021-01-26 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0c0d009a88f2: [NFC] Disallow unused prefixes under clang/test/CodeGen (authored by mtrofin). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95417/new/ https:

[PATCH] D95499: [NFC] Disallow unused prefixes under clang/test/CodeGenCXX

2021-01-26 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: rnk. mtrofin requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. The only test that needed change had 'QUAL' as an unused prefix. The rest of the changes are to simplify the prefix lists.

[PATCH] D95499: [NFC] Disallow unused prefixes under clang/test/CodeGenCXX

2021-01-28 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGcfcc1110d773: [NFC] Disallow unused prefixes under clang/test/CodeGenCXX (authored by mtrofin). Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D95660: [NFC] Disallow unused prefixes under clang/test/Driver

2021-01-28 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. Herald added subscribers: kerbowa, mstorsjo, nhaehnle, jvesely. mtrofin requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D95660 Files: clang/te

[PATCH] D95660: [NFC] Disallow unused prefixes under clang/test/Driver

2021-01-29 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 320246. mtrofin marked an inline comment as done. mtrofin added a comment. cleaned up the RUN line for rocm Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95660/new/ https://reviews.llvm.org/D95660 Files: cla

[PATCH] D95660: [NFC] Disallow unused prefixes under clang/test/Driver

2021-01-29 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: clang/test/Driver/rocm-device-libs.cl:82 // RUN: %s \ -// RUN: 2>&1 | FileCheck --check-prefixes=COMMON,COMMON-UNSAFE,GFX803,WAVE64 %s +// RUN: 2>&1 | FileCheck --check-prefixes=COMMON,GFX803,WAVE64 %s MaskRay wr

[PATCH] D95660: [NFC] Disallow unused prefixes under clang/test/Driver

2021-01-29 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 320256. mtrofin added a comment. indent Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95660/new/ https://reviews.llvm.org/D95660 Files: clang/test/Driver/amdgpu-macros.cl clang/test/Driver/cuda-detect.cu

[PATCH] D95660: [NFC] Disallow unused prefixes under clang/test/Driver

2021-02-01 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGc4d6f2707a1e: [NFC] Disallow unused prefixes under clang/test/Driv

[PATCH] D95842: [NFC] Remove unused prefixes under clang/test/OpenMP

2021-02-01 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: jdoerfert. Herald added subscribers: guansong, yaxunl. mtrofin requested review of this revision. Herald added subscribers: cfe-commits, sstefan1. Herald added a project: clang. The full list of pertinent tests is larger, so chunking the cha

[PATCH] D95849: [FileCheck] Default --allow-unused-prefixes to false

2021-02-02 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D95849#2535939 , @jhenderson wrote: > I assume this now runs cleanly. If so, LGTM. Probably worth mentioning on the > mailing list thread too, so wrap up that conversation. By the way, did we > ever figure out how many of the

[PATCH] D110891: [inliner] Mandatory inlining decisions produce remarks

2021-09-30 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added a reviewer: aeubanks. Herald added subscribers: ormris, wenlei, hiraditya, eraman. mtrofin requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. This also removes the need to disable

[PATCH] D110891: [inliner] Mandatory inlining decisions produce remarks

2021-10-01 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin marked an inline comment as done. mtrofin added inline comments. Comment at: llvm/lib/Analysis/InlineAdvisor.cpp:52 +namespace { +using namespace llvm::ore; wenlei wrote: > curious why do we need anonymous namespace here? iiuc it's preferred we place fi

[PATCH] D110891: [inliner] Mandatory inlining decisions produce remarks

2021-10-01 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin marked 3 inline comments as done. mtrofin added inline comments. Comment at: llvm/lib/Analysis/InlineAdvisor.cpp:52 +namespace { +using namespace llvm::ore; wenlei wrote: > mtrofin wrote: > > wenlei wrote: > > > curious why do we need anonymous namespac

[PATCH] D110891: [inliner] Mandatory inlining decisions produce remarks

2021-10-04 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 377091. mtrofin marked 2 inline comments as done. mtrofin added a comment. added test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D110891/new/ https://reviews.llvm.org/D110891 Files: clang/test/Frontend/opt

[PATCH] D110891: [inliner] Mandatory inlining decisions produce remarks

2021-10-04 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin marked an inline comment as done. mtrofin added inline comments. Comment at: llvm/lib/Analysis/InlineAdvisor.cpp:72-89 + void recordUnsuccessfulInliningImpl(const InlineResult &Result) override { +if (IsInliningRecommended) + ORE.emit([&]() { +return Opt

[PATCH] D113304: [NewPM] Only invalidate modified functions' analyses in CGSCC passes + turn on eagerly invalidate analyses

2021-11-08 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Comment at: llvm/lib/Transforms/IPO/Inliner.cpp:1017 +// invalidate analyses for all functions in this SCC later. +FAM.invalidate(F, PreservedAnalyses::none()); } Should we do this if !Changed? Actually, if this function

[PATCH] D98440: [NPM][CGSCC] FunctionAnalysisManagerCGSCCProxy: do not clear immutable function passes

2021-03-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin created this revision. mtrofin added reviewers: asbirlea, aeubanks. Herald added subscribers: steven_wu, hiraditya. mtrofin requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. Check with the analysis result by calling

[PATCH] D98440: [NPM][CGSCC] FunctionAnalysisManagerCGSCCProxy: do not clear immutable function passes

2021-03-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin updated this revision to Diff 330057. mtrofin marked an inline comment as done. mtrofin added a comment. feedback Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D98440/new/ https://reviews.llvm.org/D98440 Files: clang/test/CodeGen/thinlto-

[PATCH] D98440: [NPM][CGSCC] FunctionAnalysisManagerCGSCCProxy: do not clear immutable function passes

2021-03-11 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added a comment. In D98440#2620437 , @aeubanks wrote: > This doesn't break the pipeline tests in llvm/test/Other? > Running check-llvm with expensive checks is probably a good idea to see if > there are any weird issues. Done - nothing else broke

[PATCH] D98440: [NPM][CGSCC] FunctionAnalysisManagerCGSCCProxy: do not clear immutable function passes

2021-03-11 Thread Mircea Trofin via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG5eaeb0fa67e5: [NPM][CGSCC] FunctionAnalysisManagerCGSCCProxy: do not clear immutable function… (authored by mtrofin). Repository: rG LLVM Github

[PATCH] D79959: [SampleFDO] Add use-sample-profile function attribute

2021-11-17 Thread Mircea Trofin via Phabricator via cfe-commits
mtrofin added inline comments. Herald added subscribers: ormris, jdoerfert. Comment at: clang/lib/CodeGen/CodeGenFunction.cpp:856 + // Add use-sample-profile value. + if (!CGM.getCodeGenOpts().SampleProfileFile.empty()) MaskRay wrote: > The code self explains

  1   2   >