Print this page
6282 ONBLD man pages not pbchk clean
Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>
Reviewed by: Josef Sipek <jeffpc@josefsipek.net>

Split Close
Expand all
Collapse all
          --- old/usr/src/tools/lintdump/lintdump.1onbld
          +++ new/usr/src/tools/lintdump/lintdump.1onbld
↓ open down ↓ 11 lines elided ↑ open up ↑
  12   12  .\" " When distributing Covered Code, include this CDDL HEADER in each
  13   13  .\" " file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  14   14  .\" " If applicable, add the following below this CDDL HEADER, with the
  15   15  .\" " fields enclosed by brackets "[]" replaced with your own identifying
  16   16  .\" " information: Portions Copyright [yyyy] [name of copyright owner]
  17   17  .\" "
  18   18  .\" " CDDL HEADER END
  19   19  .\" "
  20   20  .\" "Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
  21   21  .\" "Use is subject to license terms.
  22      -.TH lintdump 1ONBLD "28 Mar 2008"
       22 +.TH LINTDUMP 1ONBLD "Mar 28, 2008"
  23   23  .I lintdump
  24   24  \- dump the contents of one or more lint objects
  25   25  .SH SYNOPSIS
  26   26  \fBlintdump [-i] [-p 1|2|3] [-r] \fIlintobj\fP [ \fIlintobj\fP ... ]
  27      -.LP
  28   27  .SH DESCRIPTION
  29      -.IX "OS-Net build tools" "lintdump" "" "\fBlintdump\fP"
  30   28  .LP
  31   29  The lintdump utility dumps the contents of one or more lint
  32   30  objects.  This is chiefly useful when trying to understand the cause of
  33   31  unexpected or obtuse lint warnings (see EXAMPLES), but can also be used to
  34   32  find differences between lint objects across builds or releases, or to
  35   33  debug problems in lint itself.
  36   34  .LP
  37   35  A lint object is a binary file (typically suffixed with ".ln") constructed
  38   36  from a C source file via the "-c" option to lint(1).  Multiple lint
  39   37  objects may be combined into a lint library object (typically prefixed
↓ open down ↓ 10 lines elided ↑ open up ↑
  50   48  STRINGS.  Generally speaking, PASS1 contains definitions, PASS2 contains
  51   49  declarations, and PASS3 contains information on whether or how functions
  52   50  or variables are used.  The STRINGS section holds the strings for
  53   51  printf(3C)/scanf(3C) checking.
  54   52  .LP
  55   53  Each PASS section consists of a sequence of binary records of assorted
  56   54  types.  The sequence of records is further partitioned by FILE records,
  57   55  which indicate the source or header file that is responsible for the
  58   56  records that follow.  The remaining record types provide lint with
  59   57  information about the functions, variables, and structures defined or used
  60      -by the object. 
       58 +by the object.
  61   59  .SH OPTIONS
  62   60  .TP 10
  63   61  .B -i
  64   62  Do not output structure tag IDs (see EXAMPLES).
  65   63  .TP 10
  66   64  .B -p 1|2|3
  67   65  Just output the PASS1, PASS2, or PASS3 section.
  68   66  .TP 10
  69   67  .B -r
  70   68  Output records using relative paths (see EXAMPLES).
  71      -.LP
  72   69  .SH OUTPUT
  73   70  .LP
  74   71  The contents of each specified \fIlintobj\fP is dumped in command-line
  75   72  order.  For each \fIlintobj\fP, lintdump outputs a single line beginning
  76   73  with "LINTOBJ:" that provides its name.  For each lint module within that
  77   74  object, lintdump outputs a single line beginning with "LINTMOD:" that
  78   75  provides its module ID, the size of its PASS1, PASS2, PASS3, STRING
  79   76  sections, and its total size, in that order.
  80   77  .LP
  81   78  Next, unless the -p option is used, the contents of the PASS1, PASS2, and
↓ open down ↓ 63 lines elided ↑ open up ↑
 145  142           struct as <tag 98> {
 146  143               char as_name[];
 147  144               int as_flag;
 148  145           };
 149  146  SECTION: PASS2: 24 bytes
 150  147  SECTION: PASS3: 130 bytes
 151  148     FILE: /home/meem/hacks/liba.c
 152  149     FILE: liba.c
 153  150           int af(void) <returns value>;
 154  151  .fi
 155      -.LP
 156  152  .SH RECORD PROPERTIES
 157  153  .LP
 158  154  As discussed in OUTPUT, some records are displayed using an extended
 159  155  format to convey information that cannot be expressed in C.  The following
 160  156  extended information may be displayed:
 161      -.RE
 162  157  .LP
 163  158  .B <PRINTFLIKE\fIn\fP>
 164  159  .RS 4
 165  160  Indicates to lint that argument \fIn\fP to the variable-argument function
 166  161  is a format string in printf(3C) format, which enhances lint's argument
 167  162  checking.
 168  163  .RE
 169  164  .LP
 170  165  .B <SCANFLIKE\fIn\fP>
 171  166  .RS 4
↓ open down ↓ 23 lines elided ↑ open up ↑
 195  190  .B <use: unspecified context>
 196  191  .RS 4
 197  192  Indicates to lint that the associated function is used in an unspecified
 198  193  manner.
 199  194  .RE
 200  195  .LP
 201  196  .B <returns value>
 202  197  .RS 4
 203  198  Indicates to lint that the function returns a value.
 204  199  .RE
 205      -.LP
 206  200  .SH EXAMPLES
 207  201  .LP
 208  202  One common problem is that lint does not always provide sufficient
 209  203  information to understand the reason for a type mismatch.  For instance,
 210  204  sometimes lint will confusingly report a type mismatch between
 211  205  apparently-identical types:
 212  206  .LP
 213  207  .nf
 214  208  $ lint msghdr.c -lsocket
 215  209  function argument ( number ) used inconsistently
↓ open down ↓ 85 lines elided ↑ open up ↑
 301  295  >              unsigned char _magic;
 302  296  22a23,24
 303  297  >              unsigned int __extendedfd;
 304  298  >              unsigned int __xf_nocheck;
 305  299  \fI[ ... ]\fP
 306  300  .fi
 307  301  .LP
 308  302  Note that -r option removes spurious differences that would otherwise
 309  303  arise from different absolute paths to the same source file, and the -i
 310  304  option removes spurious differences due to ID generation inside lint.
 311      -.LP
 312  305  .SH SEE ALSO
 313  306  .LP
 314  307  .IR lint(1),
 315  308  .IR printf(3C),
 316  309  .IR scanf(3C)
 317  310  .SH NOTES
 318  311  This utility is provided as an interim solution until a stable utility
 319  312  can be bundled with Sun Studio.  As such, any use of this utility in
 320  313  scripts or embedded inside programs should be done with knowledge that
 321  314  subsequent changes will be required in order to transition to the stable
 322  315  solution.
 323  316  .LP
 324  317  The lint object file format does not have a way to represent bitfields. As
 325  318  such, bitfield size information cannot be displayed by lintdump.
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX