#167 0.9.4: execvp call for opjitconv does not work

closed-fixed
hanseld
None
5
2009-07-31
2008-08-06
Anonymous
No

Hi,
I was doing an opagent implementation for the cacao jvm and as such installed oprofile 0.9.4 into my home (--prefix=/home/rschus/INSTALL/oprofile).

I found these error messages in the oprofiled.log:
Failed to exec /home/rschus/INSTALL/oprofile/bin//opjitconv: No such file or directory
JIT dump processing exited abnormally: 1

This made samples taken in JIT compiled code not show up in the summaries.

By looking at daemon/init.c I found out that you should provide opjitconv_path as the first argument to the execvp() function instead of "opjitconv" (which should go into the first place in the argument array then).

With that change the error messages in the log disappeared and instead the samples taken in the JIT compiled code showed up in the summaries. Yay!

Attached is patch is used.

If you need this signed of line:

Signed-off-by: Robert Schuster <robertschuster@fsfe.org>

Discussion

  • hanseld
    hanseld
    2008-08-08

    Logged In: YES
    user_id=1958718
    Originator: NO

    Hi Robert!

    I've taken a look into that problem.
    On my tests there were no issues according this implementation part.
    But after reading the description of execvp() function I've seen that
    the current implementation does not follow the description.

    Because of that your patch is accepted and will be integrated
    as soon as possible.

    Thank you.

    Kind regards,
    Daniel Hansel

     
  • Logged In: NO

    Hi Daniel,
    you will only experience the bug if you install oprofile to a directory that is not in your $PATH because then looking up "opjitconv" will fail.

    Thanks for applying the patch. I think this can be closed now.

    Regards
    Robert

     
  • hanseld
    hanseld
    2008-08-08

    • assigned_to: nobody --> hanseld
    • status: open --> open-fixed
     
    • status: open-fixed --> closed-fixed