[PATCH] D116328: [ast-matchers] Add hasSubstatement() traversal matcher for caseStmt(), defaultStmt(), labelStmt()

Richard via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 13 12:14:17 PST 2022


LegalizeAdulthood added a comment.

In D116328#3241329 <https://reviews.llvm.org/D116328#3241329>, @aaron.ballman wrote:

> In D116328#3223344 <https://reviews.llvm.org/D116328#3223344>, @LegalizeAdulthood wrote:
>
>> My takeaway:
>>
>> - if `has` isn't expensive, I can either ditch this public matcher or move it to be a private matcher used in my check
>
> [...] if you profiled something and notice a measurable difference
> between `has()` and `hasSubstatement()` in practice, that would
> be really good for the community to know.

Do we have some sort of benchmarking facility in place, or do I
have to homebrew something?


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D116328/new/

https://reviews.llvm.org/D116328



More information about the cfe-commits mailing list