[fpc-pascal] fpc and intel vtune (now about gprof)

Peter Vreman peter at freepascal.org
Wed Apr 26 08:51:27 CEST 2006


>>> I hope you can see the difference between a linker, which is needed  no
>>> matte how you want to use the compiler, and a tool like Valgrind  or
>>> gprof.
>
> VS> With this difference, compiling -gv succeeds, even if Valgrind is not
> VS> installed. Compiling -pg fails, if gprof/cygwin is not installed.
>
> VS> One might argue, that this is a good thing, compiling with -pg without
> VS> having gprof is useless anyway.
>
> What is better?
>    1. immediate access violation crash with "-gd"
>     -- well, I wouldn't use dbx in win32 anyway

Already fixed in 2.1.1 and now also in 2.03 so this is a non-issue.


>    2. confusing linker error "cannot find -lc" with "-pg"
>     -- well, I can't use gprof without cygwin anyhow
>        (while gprof.exe itself does not use extras except shipped
> cygwin1.dll)

It is not confusing. It is expected that you know what you are doing when
using low-level tools like gprof for profiling.


>    3. successful build with "-gv"
>     -- well, I can say that my file is bigger!
>        (but valgrind is not going to support win32)

It is clear the -g already generates debuginfo only. The 'v' adapts it for
valgrind. So it is obvious that the .exe is bigger.






More information about the fpc-pascal mailing list