aboutsummaryrefslogtreecommitdiff
path: root/gcc/doc
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2017-10-18 07:36:38 +0000
committerSebastian Huber <sh@gcc.gnu.org>2017-10-18 07:36:38 +0000
commitf381d87aa5928ecdfe531b2c8706843f65c951b9 (patch)
treec904b831e08df4ea1a6bdb8641008a5f121d6e63 /gcc/doc
parent173a960ac907a353ac9de8bca9948ef9d41a7ec2 (diff)
downloadgcc-f381d87aa5928ecdfe531b2c8706843f65c951b9.zip
gcc-f381d87aa5928ecdfe531b2c8706843f65c951b9.tar.gz
gcc-f381d87aa5928ecdfe531b2c8706843f65c951b9.tar.bz2
Update -ffunction/data-sections documentation
gcc/ * doc/invoke.texi (ffunction-sections and fdata-sections): Update. From-SVN: r253842
Diffstat (limited to 'gcc/doc')
-rw-r--r--gcc/doc/invoke.texi32
1 files changed, 20 insertions, 12 deletions
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index 6518ac0..5e88279 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -9712,18 +9712,26 @@ file if the target supports arbitrary sections. The name of the
function or the name of the data item determines the section's name
in the output file.
-Use these options on systems where the linker can perform optimizations
-to improve locality of reference in the instruction space. Most systems
-using the ELF object format and SPARC processors running Solaris 2 have
-linkers with such optimizations. AIX may have these optimizations in
-the future.
-
-Only use these options when there are significant benefits from doing
-so. When you specify these options, the assembler and linker
-create larger object and executable files and are also slower.
-You cannot use @command{gprof} on all systems if you
-specify this option, and you may have problems with debugging if
-you specify both this option and @option{-g}.
+Use these options on systems where the linker can perform optimizations to
+improve locality of reference in the instruction space. Most systems using the
+ELF object format have linkers with such optimizations. On AIX, the linker
+rearranges sections (CSECTs) based on the call graph. The performance impact
+varies.
+
+Together with a linker garbage collection (linker @option{--gc-sections}
+option) these options may lead to smaller statically-linked executables (after
+stripping).
+
+On ELF/DWARF systems these options do not degenerate the quality of the debug
+information. There could be issues with other object files/debug info formats.
+
+Only use these options when there are significant benefits from doing so. When
+you specify these options, the assembler and linker create larger object and
+executable files and are also slower. These options affect code generation.
+They prevent optimizations by the compiler and assembler using relative
+locations inside a translation unit since the locations are unknown until
+link time. An example of such an optimization is relaxing calls to short call
+instructions.
@item -fbranch-target-load-optimize
@opindex fbranch-target-load-optimize