Results 1 to 5 of 5

Thread: profiling with freepascal

  1. #1
    ddaedalus
    Guest

    profiling with freepascal

    Hi,

    Recently i tried to profile my program using gprof. Compiling with -pg resulted in the following:

    Code:
    bartek@bartek-laptop:~/Dev/Infor$ fpc -pg infor
    Free Pascal Compiler version 2.1.3 [2007/05/04] for i386
    Copyright (c) 1993-2007 by Florian Klaempfl
    Target OS: Linux for i386
    Compiling infor.pp
    Linking infor
    /usr/local/lib/fpc/2.1.3/units/i386-linux/rtl/si_c21g.o: In function `SI_C21G__FPC_LIBC21_GPROF_GMON_START':
    si_c21g.pp:(.text+0x2d): undefined reference to `__libc_atexit'
    infor.pp(177,1) Error: Error while linking
    infor.pp(177,1) Fatal: There were 1 errors compiling module, stopping
    Fatal: Compilation aborted
    Error: /usr/local/bin/ppc386 returned an error exitcode (normal if you did not specify a source file to be compiled)
    bartek@bartek-laptop:~/Dev/Infor$
    Linux Kubuntu 7.04
    FPC 2.1.3 ( fixes_2_2 branch )

    Thanks in advance

  2. #2

    profiling with freepascal

    "Because it is such bad weather today, let's break backward compatibility."

    This is the impression I sometimes get from the glibc maintainers. The gmon interface is highly unstable and breaks from time to time. We are rewriting gmon in Pascal to finally solve this problem structurally.

    Try 2.0.4, for some people that works better than 2.1.

  3. #3
    ddaedalus
    Guest

    profiling with freepascal

    Then I will wait for the re-write. It's not that important for me at the moment, therefore I can wait. Thanks for your effort.

  4. #4

    profiling with freepascal

    Valgrind might be another option? At least on *nix.

  5. #5
    ddaedalus
    Guest

    profiling with freepascal

    I'm using *nix. You mean the callgrind tool from valgrind. Yeah I used that. It does its job. But I simply wanted to compare the results and see which are more accurate.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •