<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/74946>74946</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
ftime-trace and compilation of files generated with -E option
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
grandemk
</td>
</tr>
</table>
<pre>
If I use something like this to build my file:
```
clang la.cpp -ftime-trace -E > la-2.cpp # ftime-trace noop here it seems
clang -c la-2.cpp -o la.obj -ftime-trace
```
The generated json file will not contain any of the Source nodes which are very useful to debug compilation times issues.
That's kind of expected as all of the includes files were copied in the la-2.cpp file.
The info would still be very useful, especially for build done with FastBuild as it does this -E prepass all the time.
The generated la-2.cpp file contains the origin file of each line with preprocessor like ` # 2471 "C:\\Program Files (x86)\\Windows Kits\\10\\Include\\10.0.17763.0\\ucrt\\stdio.h" 3`, so it seems it would be possible to get this information back to print it in the json profiling file.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxsVEGPozgT_TXOpQQCQ0I4cJjJdKTWd_mkHWnPxi7A3caFXGYy-fcrQ3q6o10pCuBy-T2_92zFbEeP2Injd3H8cVBrnCh0Y1De4Px-6Mncu9cBXmFlBKYZ42T9CM6-I8TJMkSCfrXOwHyHwToU1TdR_BDFN3EqHr_tUzuV-lSulwWyIdoZsxiURsheQFQv4FQmt6KQFXyte6IFJgwINgIjzvx1xUx_dmaUAKh_ewL4Tzr7_88JYUSPQUU08Mbktz3AzToHniJo8lFZD8rfgQaIE8JftIaNlUGG22T1BCog_MJwTyINq0uaGOzXETTNi3UqWvKQCDFY5hU5fyahopANw7v1JqHg7wV1IqQYlHMfwNZrtybQRJHhlhTRtFg0YP02448QacYTBvzcFhgIbrQ6AxzTDvsn2kJeAHlBbZVzdxgoPJw15JMkcYKr4vh9G1Oc3DCEvMcge4El4KJ4p5zYpA0_SMAXFp96P9H9kJq3Xgp2tA8zkiJKT-DsB42EFEgjM4U9iuJUbLmRdVOCkPKSYni8iOPl_4HGoGa4bqIJef59PgnZ7sW_rTd0Y_ifjbyPlMX-fN3F_hjMi7xsmlOVP8qrDnF_42gs5ZOQEqqULnkBpj9JTS-74j3CQsy2d5jyMWLchUumhHmPSK_0eyouwfqYWh--bsFcAg3WpcP3L3cPpqtMW7XqgF3ZFLKsWylPh6kzRVlKU9Wql9VZK9kW6iybXqKu2nNZmoPtZCGrUhZt2ZZVfcrLqm3qomrk6di0RVGJusBZWZc792vOKYyHLcFdU7f16eBUj463y0NKj7c93kLKdJeELvVk_TqyqAtnOfLnKtFGh93XY668eTovNDyC_hmYzfzsBWhJMw5rcN0U48LJbHkV8jraOK19rmkW8pqwHo9sCfSGOgp53Q-gkNdtB_8EAAD__2Donl0">