From Torsten.Hothorn at rzmail.uni-erlangen.de  Tue Feb 21 08:28:32 2006
From: Torsten.Hothorn at rzmail.uni-erlangen.de (Torsten Hothorn)
Date: Tue, 21 Feb 2006 08:28:32 +0100 (CET)
Subject: [Rd] profiling C code
In-Reply-To: <39B6DDB9048D0F4DAD42CB26AAFF0AFAFED82C@usctmx1106.merck.com>
References: <39B6DDB9048D0F4DAD42CB26AAFF0AFAFED82C@usctmx1106.merck.com>
Message-ID: <Pine.LNX.4.64.0602210825150.29020@artemis.imbe.med.uni-erlangen.de>


On Mon, 20 Feb 2006, Liaw, Andy wrote:

> The last time I tried I didn't have much luck.  The gprof manual I could
> find seems to indicate that it can not profile code that are dynamically
> loaded.  (I was trying on Linux.)  The R source seems to hint otherwise.
> I'd very much appreciate pointers as well.
>

I happily use `oprofile' (web page at http://oprofile.sourceforge.net/) 
for profiling shared libs. You simply start a daemon, run your R code, 
and get the results. `opannotate' labels lines in C source files with the 
corresponding systime, very very cute.

Best,

Torsten

> Andy
>
> From: Ross Boylan
>>
>> Does anyone have any advice about profiling C/C++ code in a package
>> under R?  Does R need to be built specially for this to work?
>>
>> The FAQ has some entries about profiling but they cover R level
>> profiling; I'm try to get at the C++ code I've written that is called
>> from R.
>>
>> Primary target is Mac OS X.
>>
>> Thanks.
>>
>> Ross Boylan
>>
>> ______________________________________________
>> R-devel at r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-devel
>>
>>
>
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>
>



[Rd] profiling C code
Torsten Hothorn