<div dir="auto"><div><div class="gmail_extra"><div class="gmail_quote">Am 19.02.2018 11:01 schrieb "Ondrej Pokorny" <<a href="mailto:lazarus@kluug.net">lazarus@kluug.net</a>>:<br type="attribution"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="quoted-text">On 19.02.2018 10:25, Anton Shepelev wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Simon Ameis:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
However I think, FPC should generate the profiling<br>
code itself. Then there is no need to modify the<br>
code before and after the compilation.<br>
</blockquote>
Not, I think, for the naive light-weight profiling<br>
that FPProfiler offers. Its functionality is easily<br>
decoupled from that of the compiler and I think<br>
should stay so, for better modularity.<br>
</blockquote>
<br></div>
I agree with Simon here. It's a similar scenario like heaptrc. Why not to add a compiler parameter to include profiling info? That would be just great.</blockquote></div></div></div><div dir="auto"><br></div><div dir="auto">It's not the same scenario as heaptrc is entirely working in the RTL without any compiler extension (aside from the -gh parameter). Profiling code however would require extensions to the compiler whereby it would also need to handle exceptions correctly and such things.</div><div dir="auto"><br></div><div dir="auto">Regards, </div><div dir="auto">Sven </div></div>