Re: [Rd] Profiling C functions called from R.

From: Pavel N. Krivitsky <pavel_at_stat.washington.edu>
Date: Wed 02 Mar 2005 - 18:08:03 EST

Hi,

Thank you for the reply. I think I've figured out the problem. In case someone else might find this useful, the vanishing profile file turns out to be the result of a semi-documented quirk (not in R). When using

LD_PROFILE=/$PATH_TO_LIB/$LIB_NAME.so R

the resulting $LIB_NAME.so.profile will be created in /var/tmp/$PATH_TO_LIB/

_only_if_ /var/tmp/$PATH_TO_LIB/ already exists. If it doesn't, it'll
give an error message (that got buried in other output in my case) and no profile will be created. If LD_PROFILE_OUTPUT is used to control where the profile file goes:

export LD_PROFILE=/$PATH_TO_LIB/$LIB_NAME.so export LD_PROFILE_OUPUT=/$PUT_PROFILE_HERE/ R
unset LD_PROFILE
unset LD_PROFILE_OUTPUT

then $LIB_NAME.so.profile will be created in /$PUT_PROFILE_HERE/$PATH_TO_LIB/ again, only if the directory already exists.

                             Thanks,
                             Pavel Krivitsky


______________________________________________
R-devel@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Wed Mar 02 18:07:51 2005

This archive was generated by hypermail 2.1.8 : Wed 02 Mar 2005 - 18:34:39 EST