Man Page uncover.1




NAME

     uncover - Code Coverage Tool



SYNOPSIS

     uncover
	  [-?]	[-h] [-v] [-V] [-d dir]	target
	  where	target is the binary file for which the	code cov-
	  erage	data is	to be generated.

     uncover
	  [-?]	[-h] [-v] [-V] [-e {on|of}] [-H	dir] [-t file]
	  [-n] target.uc
	  where	target.uc is the directory where the code cover-
	  age data is generated	and stored.


DESCRIPTION

     uncover is	a command line tool to measure code  coverage  of
     the  user applications. This tool can display information on
     areas of the application being exercised during testing. The
     coverage  information  reported  by  this tool could be at	a
     function, statement, basic	block, or instruction level.

     uncover works with	any optimized binaries.	Measurements  are
     done  by  first  instrumenting the	binary and then	executing
     it. After execution, you display and query	the coverage data
     as	 an  experiment	 in the	Oracle Solaris Studio Performance
     Analyzer or as HTML in your web browser. You can execute the
     binary  multiple  times,  and  the	coverage data will be the
     accumulation of these multiple executions.

     uncover can be used with binaries generated  by  the  Oracle
     Solaris  Studio  Express  6/10 and	later C, C++, and Fortran
     compilers,	as well	as the GCC  compilers  for  Sun	 Systems,
     hereafter referred	to as 'gccfss'.


OPTIONS

     uncover accepts the following options:

     -?	or -h
	  Output the help message.

     -v	  Turn on the verbose mode, which shows	detailed informa-
	  tion on steps	of the command.

     -V	  Print	the current version.

     -d	directory
	  Create coverage data	inside	the  specified	directory
	  directory.   If  not	specified,  the	 current  working
	  directory is used.   The  coverage  data  directory  in
	  directory is named target.uc.
     -e	{on|off}
	  Turn on  or  off  the	 generation  of	 the  Performance
	  Analyzer experiment. Default is on.

     -H	dir
	  Store	the coverage data in HTML  format  inside  direc-
	  tory.	  When	specified,  the	 default  browser will be
	  invoked to display the coverage data stored  in  direc-
	  tory.

     -n	  Do not start the default browser to display the  cover-
	  age  data.  When both	-n and -H options are absent, the
	  Oracle Solaris Studio	Performance Analyzer  is  invoked
	  to display the coverage data.

     -t	file
	  Store	the coverage data in ASCII text	in the file file.



EXAMPLES

  Example #1
     This example instruments  the  binary  a.out,  executes  the
     binary,  and  displays  the coverage data of a.out	stored in
     a.out.uc by invoking the Performance Analyzer.

	  % uncover a.out
	  % a.out
	  % uncover a.out.uc

     NOTE: You need to instrument the  binary  of  interest  only
     once.


  Example #2
     Similar to	example	 #1,  but  the	coverage  data	directory
     a.out.uc is generated in the directory abc.

	  % uncover -d abc a.out
	  % a.out
	  % uncover abc/a.out.uc


  Example #3
     Similar to	example	#1, but	 the  binary  is  executed  three
     times.  The coverage data to be displayed are stored in HTML
     format inside the directory a.out.html. The default  browser
     is	invoked	to display this	data.

	  % uncover a.out
	  % a.out; a.out; a.out
	  % uncover -H a.out.html a.out.uc


SEE ALSO

     CC(1), cc(1), f95(1), gcc(1), g++(1).