1SIZE(1)                      GNU Development Tools                     SIZE(1)
2
3
4

NAME

6       size - list section sizes and total size.
7

SYNOPSIS

9       size [-A|-B|--format=compatibility]
10            [--help]
11            [-d|-o|-x|--radix=number]
12            [--common]
13            [-t|--totals]
14            [--target=bfdname] [-V|--version]
15            [objfile...]
16

DESCRIPTION

18       The GNU size utility lists the section sizes---and the total size---for
19       each of the object or archive files objfile in its argument list.  By
20       default, one line of output is generated for each object file or each
21       module in an archive.
22
23       objfile... are the object files to be examined.  If none are specified,
24       the file "a.out" will be used.
25

OPTIONS

27       The command line options have the following meanings:
28
29       -A
30       -B
31       --format=compatibility
32           Using one of these options, you can choose whether the output from
33           GNU size resembles output from System V size (using -A, or
34           --format=sysv), or Berkeley size (using -B, or --format=berkeley).
35           The default is the one-line format similar to Berkeley's.
36
37           Here is an example of the Berkeley (default) format of output from
38           size:
39
40                   $ size --format=Berkeley ranlib size
41                   text    data    bss     dec     hex     filename
42                   294880  81920   11592   388392  5ed28   ranlib
43                   294880  81920   11888   388688  5ee50   size
44
45           This is the same data, but displayed closer to System V
46           conventions:
47
48                   $ size --format=SysV ranlib size
49                   ranlib  :
50                   section         size         addr
51                   .text         294880         8192
52                   .data          81920       303104
53                   .bss           11592       385024
54                   Total         388392
55
56
57                   size  :
58                   section         size         addr
59                   .text         294880         8192
60                   .data          81920       303104
61                   .bss           11888       385024
62                   Total         388688
63
64       --help
65           Show a summary of acceptable arguments and options.
66
67       -d
68       -o
69       -x
70       --radix=number
71           Using one of these options, you can control whether the size of
72           each section is given in decimal (-d, or --radix=10); octal (-o, or
73           --radix=8); or hexadecimal (-x, or --radix=16).  In --radix=number,
74           only the three values (8, 10, 16) are supported.  The total size is
75           always given in two radices; decimal and hexadecimal for -d or -x
76           output, or octal and hexadecimal if you're using -o.
77
78       --common
79           Print total size of common symbols in each file.  When using
80           Berkeley format these are included in the bss size.
81
82       -t
83       --totals
84           Show totals of all objects listed (Berkeley format listing mode
85           only).
86
87       --target=bfdname
88           Specify that the object-code format for objfile is bfdname.  This
89           option may not be necessary; size can automatically recognize many
90           formats.
91
92       -V
93       --version
94           Display the version number of size.
95
96       @file
97           Read command-line options from file.  The options read are inserted
98           in place of the original @file option.  If file does not exist, or
99           cannot be read, then the option will be treated literally, and not
100           removed.
101
102           Options in file are separated by whitespace.  A whitespace
103           character may be included in an option by surrounding the entire
104           option in either single or double quotes.  Any character (including
105           a backslash) may be included by prefixing the character to be
106           included with a backslash.  The file may itself contain additional
107           @file options; any such options will be processed recursively.
108

SEE ALSO

110       ar(1), objdump(1), readelf(1), and the Info entries for binutils.
111
113       Copyright (c) 1991-2016 Free Software Foundation, Inc.
114
115       Permission is granted to copy, distribute and/or modify this document
116       under the terms of the GNU Free Documentation License, Version 1.3 or
117       any later version published by the Free Software Foundation; with no
118       Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
119       Texts.  A copy of the license is included in the section entitled "GNU
120       Free Documentation License".
121
122
123
124binutils-2.27                     2016-08-03                           SIZE(1)
Impressum