help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Call graph emacs tool


From: Suvayu Ali
Subject: Re: Call graph emacs tool
Date: Fri, 20 Aug 2010 20:04:56 -0700
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.7) Gecko/20100720 Fedora/3.1.1-1.fc13 Lightning/1.0b2pre Thunderbird/3.1.1

On Friday 20 August 2010 06:50 PM, Richard Riley wrote:
Suvayu Ali<address@hidden>  writes:

On Friday 20 August 2010 09:15 AM, George Kadianakis wrote:
I'm looking for a tool (preferably an Emacs tool, but_seriously_
anything will do) that will give me all possible code paths to a given
function of a C project.

For example:
Input: (magic-script function)
Output: 1) main() [main.c] ->   function_1() [main.c] ->   function_2() [oh.c] ->   
function_3() [oh.c] ->   function_4() [ohlol.c] ->   function() [yay.c]
          2) main() [main.c] ->   function_5() [yay.c] ->   function_3() [oh.c] -> 
  function_2() [oh.c] ->   function() [yay.c]
          3) etcetera

GNU cflow is actually doing that_but_  it doesn't support multiple
source files and it's not Emacs integrable.

Do you people know of any such tools?

I am not sure what you mean by all possible code paths to a function,
but if you mean something like this,
<http://i288.photobucket.com/albums/ll164/jalladandtux/screenies/emacs-symbol-reference-w-cedet.png>

What is that supposed to be? Is that a call stack?



Maybe I have misunderstood the OP's question.

Its the result of the command `semantic-symref-symbol'. It looks up your symbol in all your project include paths and presents all references to the symbol as links. You can jump to it with `RET' or you can view with `<space>'. In this case the symbol was a handy method I had written.

There is a similar function for tags with a small difference, instead of presenting it in a buffer, it cycles through all the matches in a "completion like" buffer. All of this is of course with the CVS version of CEDET.

Is that what the OP was looking for?

--
Suvayu

Open source is the future. It sets us free.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]