[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-07-01 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 274855. ellis added a comment. Add `isLanguageVersionSupported` for Objective-C Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82904/new/ https://reviews.llvm.org/D82904 Files: clang-tools-extra/clang-tidy/bugp

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-07-06 Thread Ellis Hoag via Phabricator via cfe-commits
ellis marked an inline comment as done. ellis added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/BugproneTidyModule.cpp:82 "bugprone-bool-pointer-implicit-conversion"); -CheckFactories.registerCheck( -"bugprone-branch-clone"); +Check

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-07-06 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 275826. ellis marked 9 inline comments as done. ellis added a comment. Use `LangOpts.Blocks` instead of `LangOpts.ObjC` and add FIXME about grabbing the use location of a `CapturedVar`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-07-06 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/NoEscapeCheck.cpp:34 + const BlockDecl *EscapingBlockDecl = MatchedEscapingBlock->getBlockDecl(); + for (const BlockDecl::Capture &CapturedVar : EscapingBlockDecl->captures()) { +const VarDecl *V

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-07-07 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 276095. ellis added a comment. Add RUN line to test in C Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82904/new/ https://reviews.llvm.org/D82904 Files: clang-tools-extra/clang-tidy/bugprone/BugproneTidyModule

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-07-07 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 276118. ellis added a comment. Update commit message Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82904/new/ https://reviews.llvm.org/D82904 Files: clang-tools-extra/clang-tidy/bugprone/BugproneTidyModule.cpp

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-07-07 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. Hey @aaron.ballman, thanks for accepting my diff! Would you mind landing my diff since I don't have commit access yet? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82904/new/ https://reviews.llvm.org/D82904 _

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-07-07 Thread Ellis Hoag via Phabricator via cfe-commits
ellis marked an inline comment as done. ellis added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/bugprone-no-escape.rst:13 + + .. code-block:: objc +void foo(__attribute__((noescape)) int *p) { It looks like I triggered a build failu

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-06-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added subscribers: cfe-commits, xazax.hun, mgorny. Herald added a project: clang. ellis added a reviewer: clang-tools-extra. The block arguments in `dispatch_async()` and `dispatch_after()` are guaranteed to escape. If those blocks capture any pointers with the

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-06-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 274618. ellis added a comment. Applied changes suggested in comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82904/new/ https://reviews.llvm.org/D82904 Files: clang-tools-extra/clang-tidy/bugprone/Bugpro

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-06-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 274622. ellis added a comment. Add double backtick to doc Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D82904/new/ https://reviews.llvm.org/D82904 Files: clang-tools-extra/clang-tidy/bugprone/BugproneTidyModul

[PATCH] D82904: [clang-tidy] Warn pointer captured in async block

2020-06-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis marked an inline comment as done. ellis added inline comments. Comment at: clang-tools-extra/clang-tidy/bugprone/BugproneTidyModule.cpp:125 +CheckFactories.registerCheck( +"bugprone-no-escape"); CheckFactories.registerCheck( Not sure if we

[PATCH] D125693: [DebugInfo] Support types, imports and static locals declared in a lexical block (3/5)

2022-07-05 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: llvm/test/Instrumentation/InstrProfiling/debug-info-correlate.ll:23 call void @llvm.instrprof.increment(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @__profn_foo, i32 0, i32 0), i64 12345678, i32 2, i32 0) - ret void + ret void, !

[PATCH] D125693: [DebugInfo] Support types, imports and static locals declared in a lexical block (3/5)

2022-07-06 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: llvm/test/Instrumentation/InstrProfiling/debug-info-correlate.ll:23 call void @llvm.instrprof.increment(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @__profn_foo, i32 0, i32 0), i64 12345678, i32 2, i32 0) - ret void + ret void, !

[PATCH] D125693: [DebugInfo] Support types, imports and static locals declared in a lexical block (3/5)

2022-07-06 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: llvm/test/Instrumentation/InstrProfiling/debug-info-correlate.ll:23 call void @llvm.instrprof.increment(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @__profn_foo, i32 0, i32 0), i64 12345678, i32 2, i32 0) - ret void + ret void, !

[PATCH] D130807: [InstrProf] Add the omitprofile attribute

2022-07-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added subscribers: Enna1, wenlei, jdoerfert, hiraditya. Herald added a project: All. ellis edited the summary of this revision. ellis added reviewers: phosek, davidxl. ellis published this revision for review. Herald added projects: clang, LLVM. Herald added subs

[PATCH] D130808: [InstrProf] Add new format for -fprofile-list=

2022-07-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a project: All. ellis edited the summary of this revision. ellis added a reviewer: phosek. ellis edited the summary of this revision. ellis added a reviewer: davidxl. ellis published this revision for review. Herald added a project: clang. Herald added a su

[PATCH] D130807: [InstrProf] Add the omitprofile attribute

2022-08-01 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D130807#3688798 , @paulkirth wrote: > Do you expect the difference between `noprofile` and `omitprofile` to be > confusing to users? I can certainly see how users could be confused by what > the difference is between `noprofile

[PATCH] D130807: [InstrProf] Add the omitprofile attribute

2022-08-02 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 449463. ellis added a comment. Rename `omitprofile` => `skipprofile` since this seems slightly better to me. Of course I'm still open to more suggestions. Also, fix the `profile-function-groups.c` test. Repository: rG LLVM Github Monorepo CHANGES SINCE LA

[PATCH] D130808: [InstrProf] Add new format for -fprofile-list=

2022-08-02 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 449469. ellis added a comment. Rebase and rename `omitprofile` => `skipprofile`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130808/new/ https://reviews.llvm.org/D130808 Files: clang/docs/UsersManual.rst c

[PATCH] D130808: [InstrProf] Add new format for -fprofile-list=

2022-08-04 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 449994. ellis added a comment. Fix case. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130808/new/ https://reviews.llvm.org/D130808 Files: clang/docs/UsersManual.rst clang/include/clang/Basic/ProfileList.h

[PATCH] D130807: [InstrProf] Add the skipprofile attribute

2022-08-04 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 449995. ellis added a comment. Rebase and update docs Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D130807/new/ https://reviews.llvm.org/D130807 Files: clang/lib/CodeGen/CodeGenFunction.h clang/lib/CodeGen/C

[PATCH] D130807: [InstrProf] Add the skipprofile attribute

2022-08-04 Thread Ellis Hoag 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 rG12e78ff88105: [InstrProf] Add the skipprofile attribute (authored by ellis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION http

[PATCH] D130808: [InstrProf] Add new format for -fprofile-list=

2022-08-04 Thread Ellis Hoag 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 rGb692312ca432: [InstrProf] Add new format for -fprofile-list= (authored by ellis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D130808: [InstrProf] Add new format for -fprofile-list=

2022-08-04 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D130808#3700074 , @thakis wrote: > Reverted in 0eb7d86f5873ce897894339a3cc5bc69ca507bee > for now. Thanks for reverting. I'm looking into it. Repository:

[PATCH] D131195: [InstrProf][attempt 2] Add new format for -fprofile-list=

2022-08-04 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a project: All. ellis added reviewers: phosek, davidxl, thakis. ellis published this revision for review. ellis added inline comments. Herald added a project: clang. Herald added a subscriber: cfe-commits. Comment at: clang/test/CodeGen/p

[PATCH] D131195: [InstrProf][attempt 2] Add new format for -fprofile-list=

2022-08-04 Thread Ellis Hoag via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rG6f4c3c0f6463: [InstrProf][attempt 2] Add new format for -fprofile-list= (authored by ellis). Repository: rG LLVM Github

[PATCH] D107024: [DIBuilder] Do not replace empty enum types

2021-07-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. ellis added a reviewer: aprantl. Herald added subscribers: dexonsmith, lxfind, hiraditya. ellis requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. It looks like this array was missed in 4276d4a8d0

[PATCH] D107024: [DIBuilder] Do not replace empty enum types

2021-07-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 362614. ellis added a comment. Remove whitespace changes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D107024/new/ https://reviews.llvm.org/D107024 Files: clang/test/CodeGen/debug-info-codeview-heapallocsite.c

[PATCH] D107024: [DIBuilder] Do not replace empty enum types

2021-07-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 362637. ellis added a comment. Fix broken coro test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D107024/new/ https://reviews.llvm.org/D107024 Files: clang/test/CodeGen/debug-info-codeview-heapallocsite.c cl

[PATCH] D129413: [InstrProf] Allow compiler generated functions in SCL

2022-07-11 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a project: All. ellis retitled this revision from "[instrprof] Allow compiler generated functions in SCL" to "[InstrProf] Allow compiler generated functions in SCL". ellis edited the summary of this revision. ellis added reviewers: kyulee, phosek. ellis pu

[PATCH] D129413: [InstrProf] Allow compiler generated functions in SCL

2022-07-11 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:3894-3896 + if (getCodeGenOpts().getProfileInstr() != CodeGenOptions::ProfileNone) +if (isProfileInstrExcluded(F, SourceLocation())) + F->addFnAttr(llvm::Attribute::NoProfile);

[PATCH] D129413: [InstrProf] Allow compiler generated functions in SCL

2022-07-11 Thread Ellis Hoag via Phabricator via cfe-commits
ellis planned changes to this revision. ellis added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:3894-3896 + if (getCodeGenOpts().getProfileInstr() != CodeGenOptions::ProfileNone) +if (isProfileInstrExcluded(F, SourceLocation())) + F->addFnAttr(llvm:

[PATCH] D129413: [InstrProf] Allow compiler generated functions in SCL

2022-07-12 Thread Ellis Hoag via Phabricator via cfe-commits
ellis abandoned this revision. ellis added a comment. The function `__clang_call_terminate` seems to be a special case that clang builds itself. This diff might be too much for this rare specific case. Closing. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.l

[PATCH] D129594: [InstrProf] Add options to profile function groups

2022-07-13 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a subscriber: Enna1. Herald added a project: All. ellis edited the summary of this revision. ellis added reviewers: ianlevesque, kyulee, MaskRay, phosek, wenlei, davidxl. Herald added a subscriber: StephenFan. ellis updated this revision to Diff 444091. ell

[PATCH] D129594: [InstrProf] Add options to profile function groups

2022-07-13 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: clang/lib/CodeGen/CodeGenModule.cpp:2871 + if (NumGroups > 1) { +auto Group = llvm::MD5Hash(Fn->getName()) % NumGroups; +if (Group != getCodeGenOpts().ProfileSelectedFunctionGroup) ianlevesque wrote: > In D87953 I

[PATCH] D129594: [InstrProf] Add options to profile function groups

2022-07-13 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 444327. ellis added a comment. Use `crc32` rather than `md5` to compute function hashes faster. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129594/new/ https://reviews.llvm.org/D129594 Files: clang/docs/Clan

[PATCH] D129594: [InstrProf] Add options to profile function groups

2022-07-14 Thread Ellis Hoag via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGaf58684f2720: [InstrProf] Add options to profile function groups (authored by ellis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D129594/new/ https://revi

[PATCH] D88329: [objc] Consolidate ObjC name mangle code to AST

2020-09-25 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. ellis requested review of this revision. This reduces code duplication between CGObjCMac.cpp and Mangle.cpp for generating the mangled name of an Objective-C method. This has no intended functiona

[PATCH] D88329: [objc] Consolidate ObjC name mangle code to AST

2020-09-25 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 294395. ellis added a comment. Fix variable name Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88329/new/ https://reviews.llvm.org/D88329 Files: clang/include/clang/AST/Mangle.h clang/lib/AST/Mangle.cpp cl

[PATCH] D88329: [objc] Consolidate ObjC name mangle code to AST

2020-09-25 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 294461. ellis added a comment. Rename `mangleObjCMethodName` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88329/new/ https://reviews.llvm.org/D88329 Files: clang/include/clang/AST/Mangle.h clang/lib/AST/Man

[PATCH] D88329: [objc] Consolidate ObjC name mangle code to AST

2020-09-26 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 294503. ellis added a comment. Update call sites Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88329/new/ https://reviews.llvm.org/D88329 Files: clang/include/clang/AST/Mangle.h clang/lib/AST/ItaniumMangle.c

[PATCH] D88329: [objc] Consolidate ObjC name mangle code to AST

2020-09-26 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. Thanks for accepting @rjmccall. Could you land this? I don't have commit access yet. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88329/new/ https://reviews.llvm.org/D88329 ___ c

[PATCH] D88329: [objc] Consolidate ObjC name mangle code to AST

2020-09-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 295000. ellis added a comment. [objc] Fix memory leak in CGObjCMac.cpp CGObjCMac.cpp was leaking a MangleContext everytime it mangled an ObjC method. We now have an instance variable that allocates and deallocates the context. Repository: rG LLVM Github Mo

[PATCH] D88329: [objc] Consolidate ObjC name mangle code to AST

2020-09-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. Oops, I meant to create a new commit rather than amend to this one Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88329/new/ https://reviews.llvm.org/D88329 ___ cfe-commits mailing

[PATCH] D88497: [objc] Fix memory leak in CGObjCMac.cpp

2020-09-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. ellis added a reviewer: rjmccall. Herald added a project: clang. Herald added a subscriber: cfe-commits. ellis requested review of this revision. A memory leak was introduced in https://reviews.llvm.org/D88329 CGObjCMac.cpp was leaking a MangleContext everytime it man

[PATCH] D88329: [objc] Consolidate ObjC name mangle code to AST

2020-09-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. https://reviews.llvm.org/D88497 will fix the leak Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88329/new/ https://reviews.llvm.org/D88329 ___ cfe-commits mailing list cfe-commits@

[PATCH] D88497: [objc] Fix memory leak in CGObjCMac.cpp

2020-09-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. Yes please commit for me :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88497/new/ https://reviews.llvm.org/D88497 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https:/

[PATCH] D88497: [objc] Fix memory leak in CGObjCMac.cpp

2020-09-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 295055. ellis added a subscriber: vsapsai. ellis added a comment. Herald added a reviewer: JDevlieghere. Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Fix a comment to reference the correct method. Thanks to @vsapsai for pointing this o

[PATCH] D109703: [DebugInfo] Fix scope for local static variables

2021-09-22 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D109703#2998350 , @krisb wrote: > But it seems imported declarations are broken not just for static locals, but > for all inlined entities, for example > > namespace ns { > inline __attribute__((always_inline)) > int foo()

[PATCH] D109703: [DebugInfo] Fix scope for local static variables

2021-09-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D109703#3018935 , @krisb wrote: > @dblaikie yeah, the problem(s) seemed easier and smaller :( > > Basically, we have two issues with local scopes here: > (1) function-scoped entities like static variables, type > definitions/typ

[PATCH] D104088: Add clang frontend flags for MIP

2021-06-10 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added subscribers: dang, phosek, mgorny, emaste. Herald added a reviewer: alexshap. Herald added a reviewer: rupprecht. Herald added a reviewer: jhenderson. ellis requested review of this revision. Herald added subscribers: llvm-commits, cfe-commits, MaskRay. Her

[PATCH] D104088: Add clang frontend flags for MIP

2021-06-11 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 351604. ellis added a comment. Move llvm-strip logic into its own commit Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104088/new/ https://reviews.llvm.org/D104088 Files: clang/include/clang/Driver/Options.td

[PATCH] D104088: Add clang frontend flags for MIP

2021-06-14 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 352007. ellis added a comment. MIP does not support windows Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104088/new/ https://reviews.llvm.org/D104088 Files: clang/include/clang/Driver/Options.td clang/inclu

[PATCH] D104088: Add clang frontend flags for MIP

2021-06-22 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 353705. ellis added a comment. Correctly link the runtime symbol for Mach-O. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104088/new/ https://reviews.llvm.org/D104088 Files: clang/include/clang/Driver/Options

[PATCH] D107024: [DIBuilder] Do not replace empty enum types

2021-08-04 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D107024#2917202 , @aprantl wrote: > I think that looks fine — I wonder if we should change the IR pretty printer > to display empty arrays inline as `elements: !{}`, too. I think that's a good idea, but it would require changin

[PATCH] D107024: [DIBuilder] Do not replace empty enum types

2021-08-10 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. @aprantl @dblaikie Can I get a review soon to avoid merge conflicts on these tests? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D107024/new/ https://reviews.llvm.org/D107024 ___

[PATCH] D104088: Add clang frontend flags for MIP

2021-06-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 355066. ellis added a comment. Add min instruction count frontend flag. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104088/new/ https://reviews.llvm.org/D104088 Files: clang/include/clang/Driver/Options.td

[PATCH] D114268: [InstrProf] Use i32 for GEP index from lowering llvm.instrprof.increment

2021-11-19 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added subscribers: wenlei, arphaman, hiraditya. ellis updated this revision to Diff 388564. ellis added a comment. ellis edited the summary of this revision. ellis added a reviewer: MaskRay. ellis retitled this revision from "[InstrProf] Use i32 for GEP index" to

[PATCH] D114268: [InstrProf] Use i32 for GEP index from lowering llvm.instrprof.increment

2021-11-19 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D114268#3143976 , @MaskRay wrote: >> Add names to pgo registers for clarity. > > This may increase memory usage, especially for large LTO applications. Unless > this is very helpful I might omit it. I'll omit it. Thanks for the

[PATCH] D114268: [InstrProf] Use i32 for GEP index from lowering llvm.instrprof.increment

2021-11-19 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 388652. ellis added a comment. Remove register names Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114268/new/ https://reviews.llvm.org/D114268 Files: clang/test/CodeGen/profile-filter.c clang/test/Profile/b

[PATCH] D114565: [InstrProf] Attach debug info to counters

2021-11-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added subscribers: ormris, wenlei, hiraditya. ellis edited the summary of this revision. ellis added reviewers: MaskRay, alanphipps, wenlei, kyulee, davidxl. ellis edited the summary of this revision. ellis published this revision for review. Herald added project

[PATCH] D114565: [InstrProf] Attach debug info to counters

2021-11-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: compiler-rt/lib/profile/InstrProfilingWriter.c:273 - if (!DataSize) + if (!CountersSize) return 0; kyulee wrote: > Is it no diff change? I wonder if there is a case where `CountersSize` is 0 > but not `DataSize`

[PATCH] D114565: [InstrProf] Attach debug info to counters

2021-11-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 390855. ellis added a comment. Emit metadata as `ConstantAsMetadata` instead of the more complicated `DIExpression`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114565/new/ https://reviews.llvm.org/D114565 Fi

[PATCH] D114565: [InstrProf] Attach debug info to counters

2021-12-03 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp:961 + DB.finalize(); +} + } kyulee wrote: > I think when `-debug-info-correlate` is used without debug info, we should > fail or emit a warning here instead

[PATCH] D114565: [InstrProf] Attach debug info to counters

2021-12-03 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 391780. ellis added a comment. Add warning when debug info is missing. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114565/new/ https://reviews.llvm.org/D114565 Files: clang/lib/CodeGen/BackendUtil.cpp comp

[PATCH] D136385: Add support for MC/DC in LLVM Source-Based Code Coverage

2022-10-24 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: llvm/lib/ProfileData/InstrProfCorrelator.cpp:208 maybeSwap(CounterOffset), + maybeSwap(BitmaskOffset), maybeSwap(FunctionPtr), Since `BitmaskOffset` and `NumBitmaskBytes` are always zero, I would rather

[PATCH] D135926: [clang] Fix crash with -funique-internal-linkage-names

2022-10-13 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a project: All. ellis added reviewers: tmsriram, hoy, dblaikie. ellis published this revision for review. Herald added a project: clang. Herald added a subscriber: cfe-commits. Calling `getFunctionLinkage(CalleeInfo.getCalleeDecl())` will crash when the d

[PATCH] D135926: [clang] Fix crash with -funique-internal-linkage-names

2022-10-17 Thread Ellis Hoag via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG970e1ea01aa0: [clang] Fix crash with -funique-internal-linkage-names (authored by ellis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135926/new/ https://

[PATCH] D157913: [Coverage] Allow Clang coverage to be used with debug info correlation.

2023-09-19 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D157913#4648296 , @zequanwu wrote: > For some unknown reasons, linker still generates __llvm_prf_names section in > the final binary on mac even if the object file doesn't have this section. > And I cannot use llvm-objdump to g

[PATCH] D154014: [SpecialCaseList] Use Globs instead of Regex

2023-07-20 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 542732. ellis added a comment. If `#!special-case-list-v2` is the first line in the special case list, then we will use globs to match patterns. Otherwise, we fall back to the original behavior of using regexes to match patterns. Once this feature is stable, a

[PATCH] D157632: [Profile] Allow online merging with debug info correlation.

2023-08-10 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. Thanks for working on this! Comment at: compiler-rt/lib/profile/InstrProfilingMerge.c:103-104 COMPILER_RT_VISIBILITY int __llvm_profile_merge_from_buffer(const char *ProfileData, uint64_t ProfileSize) { __llvm_pr

[PATCH] D157632: [Profile] Allow online merging with debug info correlation.

2023-08-10 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. I've just published https://reviews.llvm.org/D157664, so you'll want to rebase ontop of it if it lands soon. I would also like to see some more tests added to `instrprof-merge-error.c` to make sure two different binaries can't merge profiles together with `--debug-info-co

[PATCH] D157632: [Profile] Allow online merging with debug info correlation.

2023-08-11 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D157632#4580576 , @zequanwu wrote: > BTW, I noticed something strange with `-pgo-function-entry-coverage` when > merging via llvm-profdata. This is intentional. The two raw profiles individually store blocks as either covered

[PATCH] D157904: Improve reliability of CompilationDatabaseTest

2023-08-14 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a subscriber: ChuanqiXu. Herald added a project: All. ellis 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/D157904 Files: clang/un

[PATCH] D157632: [Profile] Allow online merging with debug info correlation.

2023-08-14 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: compiler-rt/test/profile/Darwin/instrprof-debug-info-correlate.c:24 + +// RUN: rm -rf %t.profdir && mkdir %t.profdir + Let's move this line down since we don't use it until line 31. Comment at: compiler-

[PATCH] D157904: Improve reliability of CompilationDatabaseTest

2023-08-14 Thread Ellis Hoag 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 rG9e11d6850a5a: Improve reliability of CompilationDatabaseTest (authored by ellis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D157632: [Profile] Allow online merging with debug info correlation.

2023-08-22 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added inline comments. Comment at: compiler-rt/lib/profile/InstrProfilingMerge.c:146 +if (!(__llvm_profile_get_version() & VARIANT_MASK_DBG_CORRELATE)) { + PROF_ERR("%s\n", "Missing profile data section."); + return 1; aeubanks wrote: > aeuban

[PATCH] D154014: [SpecialCaseList] Use Globs instead of Regex

2023-08-08 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 548349. ellis added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154014/new/ https://reviews.llvm.org/D154014 Files: clang/docs/SanitizerSpecialCaseList.rst clang/lib/Basic/ProfileList.cpp

[PATCH] D154014: [SpecialCaseList] Use Globs instead of Regex

2023-08-09 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 548693. ellis added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154014/new/ https://reviews.llvm.org/D154014 Files: clang/docs/SanitizerSpecialCaseList.rst clang/lib/Basic/ProfileList.cpp

[PATCH] D157913: [Coverage] Allow Clang coverage to be used with debug info correlation.

2023-09-12 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D157913#4638845 , @zequanwu wrote: > In D157913#4638569 , @phosek wrote: > >> In D157913#4626007 , @zequanwu >> wrote: >> It seems that the

[PATCH] D157913: [Coverage] Allow Clang coverage to be used with debug info correlation.

2023-09-14 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. It looks like `debug-info-correlate-coverage.ll` was renamed twice. Is this intended? Comment at: compiler-rt/lib/profile/InstrProfilingWriter.c:276-277 __llvm_profile_get_num_counters(CountersBegin, CountersEnd); - const uint64_t NamesSize = Deb

[PATCH] D157913: [Coverage] Allow Clang coverage to be used with debug info correlation.

2023-09-14 Thread Ellis Hoag via Phabricator via cfe-commits
ellis accepted this revision. ellis added a comment. This revision is now accepted and ready to land. In D157913#4646201 , @zequanwu wrote: > In D157913#4646184 , @ellis wrote: > >> It looks like `debug-info-corre

[PATCH] D159000: Reland "[Profile] Allow online merging with debug info correlation."

2023-08-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis accepted this revision. ellis added a comment. This revision is now accepted and ready to land. Thanks for adding the test case! Can you also link the original diff in the summary? Comment at: compiler-rt/test/profile/instrprof-merge-empty-data.test:1 +// Test +// RUN:

[PATCH] D154014: [SpecialCaseList] Use Globs instead of Regex

2023-08-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 554089. ellis added a comment. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154014/new/ https://reviews.llvm.org/D154014 Files: clang/docs/SanitizerSpecialCaseList.rst clang/lib/Basic/ProfileList.cpp

[PATCH] D157913: [Coverage] Allow Clang coverage to be used with debug info correlation.

2023-08-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. Thanks for working on this! I've added a few other reviewers that might be interested. In particular it might conflict with the stack D138846 IIRC It seems that the `__llvm_prf_names` is retained in this mode. What is the overhead of thi

[PATCH] D154014: [SpecialCaseList] Add option to use Globs instead of Regex to match patterns

2023-09-01 Thread Ellis Hoag 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 rG8eb34700c2b1: [SpecialCaseList] Add option to use Globs instead of Regex to match patterns (authored by ellis). Repository: rG LLVM Github Monorep

[PATCH] D157913: [Coverage] Allow Clang coverage to be used with debug info correlation.

2023-09-01 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D157913#4626007 , @zequanwu wrote: >> It seems that the `__llvm_prf_names` is retained in this mode. What is the >> overhead of this section generally? Can we instead use debug info to lookup >> function names? > > With debug i

[PATCH] D152762: [clang][docs] Update SanitizerSpecialCaseList docs

2023-06-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis abandoned this revision. ellis added a comment. Moved to https://reviews.llvm.org/D154014 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D152762/new/ https://reviews.llvm.org/D152762 ___ cfe-commits

[PATCH] D154014: [SpecialCaseList] Use Globs instead of Regex

2023-06-28 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a subscriber: hiraditya. Herald added a project: All. ellis edited the summary of this revision. ellis added reviewers: MaskRay, phosek, vitalybuka, samsonov, hctim. ellis updated this revision to Diff 535560. ellis added a comment. ellis published this rev

[PATCH] D154014: [SpecialCaseList] Use Globs instead of Regex

2023-06-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D154014#4461076 , @rupprecht wrote: > In D154014#4457883 , @MaskRay wrote: > >>> This is a breaking change since some SCLs might use .* or (abc|def) which >>> are supported regexes but n

[PATCH] D154014: [SpecialCaseList] Use Globs instead of Regex

2023-06-29 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 536003. ellis added a comment. Fix memory bug and add TODO about a regex/glob config. Lets wait for others to comment before I put work into this. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154014/new/ https:

[PATCH] D154014: [SpecialCaseList] Use Globs instead of Regex

2023-06-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis added a comment. In D154014#4462886 , @MaskRay wrote: > In D154014#4461076 , @rupprecht > wrote: > >> In D154014#4457883 , @MaskRay >> wrote: >> This is a bre

[PATCH] D151589: [lld] add context-sensitive PGO options for MachO

2023-05-26 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added subscribers: wlei, ormris, wenlei, steven_wu, hiraditya. Herald added projects: lld-macho, All. Herald added a reviewer: lld-macho. ellis added reviewers: int3, tejohnson, xur. ellis updated this revision to Diff 526199. ellis added a comment. ellis edited

[PATCH] D151589: [lld] add context-sensitive PGO options for MachO

2023-05-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 526751. ellis marked 3 inline comments as done. ellis added a comment. Add test to check that `PGOInstrumentationGen`(`Use`) are run Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151589/new/ https://reviews.llvm.

[PATCH] D151589: [lld] add context-sensitive PGO options for MachO

2023-05-30 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 526825. ellis marked 3 inline comments as not done. ellis added a comment. Rename test function to `foo` since `_start` is not a necessary symbol Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151589/new/ https://

[PATCH] D151589: [lld] add context-sensitive PGO options for MachO

2023-05-31 Thread Ellis Hoag via Phabricator via cfe-commits
ellis updated this revision to Diff 527205. ellis added a comment. Fix paths in clang test to support windows Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151589/new/ https://reviews.llvm.org/D151589 Files: clang/lib/Driver/ToolChains/Clang.cpp

[PATCH] D151589: [lld] add context-sensitive PGO options for MachO

2023-05-31 Thread Ellis Hoag 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 rG85af42df5dbb: [lld] add context-sensitive PGO options for MachO (authored by ellis). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTIO

[PATCH] D152762: [clang][docs] Update SanitizerSpecialCaseList docs

2023-06-12 Thread Ellis Hoag via Phabricator via cfe-commits
ellis created this revision. Herald added a project: All. ellis retitled this revision from "[clang][docs] Update Sanitizer docs and test" to "[clang][docs] Update SanitizerSpecialCaseList docs". ellis edited the summary of this revision. ellis added reviewers: vlad.tsyrklevich, MaskRay. ellis pub

[PATCH] D152762: [clang][docs] Update SanitizerSpecialCaseList docs

2023-06-14 Thread Ellis Hoag via Phabricator via cfe-commits
ellis planned changes to this revision. ellis added a comment. In D152762#4421630 , @phosek wrote: > This is unrelated to this change but related to the issue this change is > addressing. The use of regular expressions for special case list with the > s

  1   2   >