cflow man page on DigitalUNIX

Man page or keyword search:  
man Server   12896 pages
apropos Keyword Search (all sections)
Output format
DigitalUNIX logo
[printable version]

cflow(1)							      cflow(1)

       cflow - Generates a C language flow graph of external references

       cflow  [-r]  [-d	 number]  [-D name[=def]]... [-i incl] [-I dir]... [-U
       dir]... [-MA] [-Ndnumber] [-Nlnumber] [-Nnnumber] [-Ntnumber] file...

       The token -- (double-dash) is accepted as a  delimiter  indicating  the
       end  of options.	 Any following arguments are treated as operands, even
       if they begin with the - character.

       Interfaces documented on this reference page conform to industry	 stan‐
       dards as follows:

       cflow:  XCU5.0

       Refer  to  the  standards(5)  reference page for more information about
       industry standards and associated tags.

       Indicates the depth at which the flow graph is cut  off.	 The  argument
       number  is  a  decimal integer. By default this is a very large number.
       Attempts to set the cut-off depth to a nonpositive integer are ignored.
       Defines	name,  as  if by a C-language #define directive. If no =def is
       given, a value of 1 is used.  Changes the number of  included  symbols.
       The  incl  parameter  is one of the following characters: (Underscore).
       Includes names that begin with an  underscore  character.  By  default,
       these  functions are excluded (and corresponding data if -i x is used).
       [Tru64 UNIX]  Disables ANSI function prototypes. By default,  undefined
       function	 information  is  filled  in with available prototype declara‐
       tions.  Includes external and static data  symbols.  By	default,  only
       functions  are  included.   Adds	 the directory specified by dir to the
       list of directories in which the lint  program  searches	 for  #include
       files.	[Tru64	UNIX]  Specifies  that	the first pass of the modified
       lint command is operated in ANSI mode. The default mode of operation is
       extended	 mode.	[Tru64 UNIX]  Changes the dimension table size to num‐
       ber. The default value of number is 2000.   [Tru64  UNIX]  Changes  the
       number  of  type	 nodes to number. The default value of number is 8000.
       [Tru64 UNIX]  Changes the symbol table  size  to	 number.  The  default
       value  of  number  is  1500.   [Tru64 UNIX]  Changes the number of tree
       nodes to number. The default value of  number  is  1000.	  Produces  an
       inverted	 listing  that	shows  the callers of each function, sorted by
       called function.	 Removes any initial definition of name, where name is
       a reserved symbol that is predefined by the particular preprocessor.

       The  cflow  command analyzes a collection of object files or assembler,
       C-language, lex, or yacc source files, and attempts to write a chart of
       their external references to standard output.

       Files suffixed in are processed by lex and yacc and preprocessed by the
       compiler preprocessor phase (bypassed for files)	 as  appropriate.  The
       output  is  then	 run through a modified first pass of lint. Files suf‐
       fixed with are assembled and information is  extracted  (as  in	files)
       from the symbol table.

       From  this output, cflow() writes a flow graph to standard output. Each
       line of output provides the following information (in order  from  left
       to  right):  A  line number followed by sufficient tabs to indicate the
       level of nesting The name of the global, a colon, and its definition

       The name is normally a function not defined as external and not	begin‐
       ning  with  an  underline  character  (see  the -i _ and -i x inclusion
       options).  For information extracted from C source files,  the  defini‐
       tion consists of an abstract type declaration (for example, char*), the
       name of the source file surrounded by angle brackets, and the line num‐
       ber  on	which  the  definition	was found.  Definitions extracted from
       object files contain the filename and section under  which  the	symbol
       appeared,  such	as  text  or  data.  The cflow command deletes leading
       underline characters in C-style external names.

       Once the cflow command displays a name, later references	 to  the  name
       contain	only  the cflow line number where the definition can be found.
       For undefined references, cflow displays only <> (angled brackets).  If
       the  nesting level becomes too deep to display in available space, pipe
       the output from the cflow command to the pr command using the -e option
       to compress the tab expansion to less than eight spaces per tab stop.

       To  ensure  that	 the line numbers produced by cflow match your lex and
       yacc files, you must send the or file to the cflow command.

       Given the following in file.c:

	      int i; main() {
		      f(); } f() {
		      i = h(); }

	      the command: cflow -i x file.c

	      produces the following output: 1	     main: () int, <file.c  4>
	      2			  f:	 ()	int,	 <file.c     11>     3
	      h:   <>	4			  i:   int,   <file.c	1>   5
	      g:  <>  To  generate  a default flow graph of these C files that
	      comprise a program, enter: cflow	timeout.c  kill.c  error.c  To
	      produce  a  C flow graph with a single level of nesting of func‐
	      tions, enter: cflow -d1 resam.c pptp.c  ptpt.c  rrr.c  whn.c  To
	      generate	a cflow graph of a lex program, enter: cflow scan.l To
	      generate a cflow graph of a yacc	program,  enter:  cflow	 yacc‐
	      file.y To generate an inverted listing that shows the callers of
	      each of the functions in the C files used in the previous	 exam‐
	      ples, enter: cflow -r resam.c pptp.c ptpt.c rrr.c whn.c

       The  following environment variables affect the behavior of cflow: Pro‐
       vides a default value for the locale category variables	that  are  not
       set  or	null.	If set, overrides the values of all other locale vari‐
       ables.  Determines the order in which  output  is  sorted  for  the  -r
       option.	Determines the locale for the interpretation of byte sequences
       as characters (single-byte or multibyte) in input parameters and files.
       Determines  the	locale used to affect the format and contents of diag‐
       nostic messages displayed by the command.  Determines the  location  of
       message catalogs for processing of LC_MESSAGES.

       Commands:  lex(1), lint(1), nm(1), pr(1), yacc(1)

       Standards:  standards(5)


List of man pages available for DigitalUNIX

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
Vote for polarhome
Free Shell Accounts :: the biggest list on the net