line by line tracing (gprof? not sure what to use)
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Unix and Linux reviews > Free Unix support > Unix Programming > line by line tracing (gprof? not sure what to use)




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    line by line tracing (gprof? not sure what to use)  
lw


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
01-15-06 10:52 PM

I would like to be able to run a simple C program and have some tracer
or profiler log each time the C program line changes (timestamp the
event, etc).  then I'd like to have that log be shown in a text edit
window (something graphical) that would highlight the lines that were
'hit' during the run.  it would be nice to number the lines by the
order they were run in (that's 2 columns: the physical line # and the
order of execution number).

seems simple - seems like there should be some already-made solutions
for this (assuming unix, gcc, etc) - but I haven't found anything yet.
anyone have any ideas?

my dream solution would be to run a program that has been somehow
instrumented, have this logfile be simple enough so that I could load
it in emacs along with the source file and it could highlight the lines
that were run, based on that logfile.  just a quick way to sort out
which are the 'cold' sections of code during a particular run.

TIA,

/bryan






[ Post a follow-up to this message ]



    Re: line by line tracing (gprof? not sure what to use)  
Pascal Bourguignon


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
01-15-06 10:52 PM

"lw" <linux.works@gmail.com> writes:

> I would like to be able to run a simple C program and have some tracer
> or profiler log each time the C program line changes (timestamp the
> event, etc).  then I'd like to have that log be shown in a text edit
> window (something graphical) that would highlight the lines that were
> 'hit' during the run.  it would be nice to number the lines by the
> order they were run in (that's 2 columns: the physical line # and the
> order of execution number).
>
> seems simple - seems like there should be some already-made solutions
> for this (assuming unix, gcc, etc) - but I haven't found anything yet.
> anyone have any ideas?
>
> my dream solution would be to run a program that has been somehow
> instrumented, have this logfile be simple enough so that I could load
> it in emacs along with the source file and it could highlight the lines
> that were run, based on that logfile.  just a quick way to sort out
> which are the 'cold' sections of code during a particular run.

Google for: profile and coverage

--
__Pascal Bourguignon__                     http://www.informatimago.com/

NEW GRAND UNIFIED THEORY DISCLAIMER: The manufacturer may
technically be entitled to claim that this product is
ten-dimensional. However, the consumer is reminded that this
confers no legal rights above and beyond those applicable to
three-dimensional objects, since the seven new dimensions are
"rolled up" into such a small "area" that they cannot be
detected.





[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 05:10 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register