jamieschmeiser requested changes to this revision.
jamieschmeiser added a comment.
This revision now requires changes to proceed.

This is a good start.  You should mention in the summary that when -c is not 
specified, the compiler is invoked with -o pointing at /tmp so the .json file 
will currently be placed there, which is confusing.



================
Comment at: clang/include/clang/Driver/Options.td:2832
+def ftime_trace_path : Joined<["-"], "ftime-trace-path=">, Group<f_Group>,
+  HelpText<"Path which stores the output files of time profiler">,
+  Flags<[CC1Option, CoreOption]>,
----------------
which specifies the output files for -ftime-trace


================
Comment at: clang/tools/driver/cc1_main.cpp:259
+    
Path.append(llvm::sys::path::filename(Clang->getFrontendOpts().OutputFile));
+    Path.append(".json");
     if (auto profilerOutput = Clang->createOutputFile(
----------------
What happens if the path specified does not exist?  This needs to be handled 
(if it isn't) and needs a lit test for this situation also.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D128048

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to