| NCCNAV(1) | General Commands Manual | NCCNAV(1) |
nccnav, nccnavi - explore the output of nccgen on a text-mode console
nccnav [Code.map]
nccnavi [Code.map]
This manual page documents briefly the nccnav command which can be used to browse the output generated by nccgen on a set of C / C++ files.
When first invoked, nccnav will display a list of source files.
This mode is oriented around a resource which can be a: file, function, global variable, member of structure, structure
For any of the above, all the related resources are listed. For example, in the case of a <function> there are:
1. File(s) with <function> definition (may not exist)
2. Functions calling <function> (Blue)
3. Global variables used by <function> (Red)
4. <function-herself>
5. Functions called by <function>
Dim grey: functions that do not call any other functions.
Brown: functions that do call other functions.
Red: Recursion detector alert (if enabled)
6. Structure members used by <function> (Dark grey)
Pressing <SPACE> on:
Note that if a function reports to be defined in more than one files, this will probably fail. This happens because nccgen does not distinguish different static functions with the same name. They are considered the same thing and their resources are mixed in nccnav. Currently, if nccnav detects more than one files for a function it will issue a warning.
By default, the internal source viewer uses less. When invoked via the nccnavi command, the source code is automatically indented and viewed through less.
The recursion detector is enabled by default.
It can be disabled by pressing 'R' while in MODE 2. (it's supposed to be expensive and may be confusing)
The recursion detector works in MODE 2 and if the current resource is a function. In this case it will paint RED all the functions called by the current function, which will eventually lead back to it by some way of recursion.
Pressing 'r' on one of the red ones will display one of the possible paths through which recursion can happen. Currently there is no way to view alternative paths.
In this mode, 'q' will get you back while enter will proceed ahead deeper into MODE 2 for the selected resource.
This is an alternative way to browse the call flow and is entered by pressing 'm' on a function in MODE 2.
Pop-up menus are generated, where the top element is a function and below it all the functions called by it. Movement is possible with the UP/DOWN arrows.
<enter> or RIGHT will expand a new pop-up for the current function. q or LEFT will close the current pop-up and activate the previous one. SPACE is available to view the source code.
BACKSPACE will close all the popups and return to MODE 2.
Pressing '2' will enter MODE 2 for the current selected element. In this case, HISTORY and BACKSPACE are set at this breakpoint.
At any time you can press '<' and '>' to browse through all the previous screens. <enter> on one of them will jump back to that screen. Any other key will exit the HISTORY MODE.
Supposing you've compiled the linux kernel with nccgen. Collecting all the .nccout files can be done with :
nccnav was written by Stelios Xanthakis <sxanth@ceid.upatras.gr>.
| September 10, 2006 |