================
@@ -1031,6 +1032,7 @@ void ExprEngine::removeDead(ExplodedNode *Pred, 
ExplodedNodeSet &Out,
                             const LocationContext *LC,
                             const Stmt *DiagnosticStmt,
                             ProgramPoint::Kind K) {
+  llvm::TimeTraceScope TimeScope("ExprEngine::removeDead");
----------------
necto wrote:

I have considered it thanks you your comment. I wasn't aware of it. 
Unfortunately, it has the following drawbacks:
- it might be non-portable, which would cause a headache in the tests
- it produces a full function signature, which I find too verbose for a label
- it hides the real name of the time scope, which might make it slightly less 
clear

On the other hand, I can use the 
[`__func__`](https://en.cppreference.com/w/cpp/language/function#func) variable 
that is portable and short. Yet, it still suffers from the third, admittedly, 
rather small disadvantage, plus it omits the namespace and the class 
qualifiers, which I find would obscure the trace. However, it spares some 
repetition and protects against some C&P bugs. I have no strong preference one 
way or the other. Do you think I should use it instead?

https://github.com/llvm/llvm-project/pull/125884
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to