[clang] [llvm] Add source file name for template instantiations in -ftime-trace (PR #98320)

Ilya Biryukov via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 17 10:03:33 PDT 2024


================
@@ -83,16 +83,27 @@ namespace llvm {
 
 class raw_pwrite_stream;
 
+struct TimeTraceMetadata {
+  std::string Detail;
+  // Source file information for the event.
+  std::string Filename;
----------------
ilya-biryukov wrote:

NIT: Maybe use `File` here and `file` in JSON for brevity? 
I'm not too worried about the code, but it looks like the JSON trace format does attempt to be brief, and having a shorter name should be aligned with that (and will make the file slightly smaller, although not by a huge margin)

https://github.com/llvm/llvm-project/pull/98320


More information about the llvm-commits mailing list