binopt man page on OpenIndiana

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

binopt(1)							     binopt(1)

NAME
       binopt - SPARC Binary Optimizer

SYNOPSIS
       binopt [-binstrument[=on|off]] [-bdata=datafile]
       [-o filename] [-V] [-flags] [-Q[y|n]]
       [-xinline=[[,v...]]]   binfile

       binopt [-buse[=on|off]] [-blevel=0|1|2]
       [-bdata=datafile] [-bfinal[=on|off]] [-o filename]
       [-V] [-flags] [-Q[y|n]]
       [-xinline=[[,v...]]]   binfile

DESCRIPTION
       The binopt command is used to optimize SPARC binaries (executables or
       shared objects). It can optimize binaries irrespective of the source
       language used. It can also optimize mixed source language binaries.  To
       be able to effectively optimize, binaries must be built with some
       explicit level of optimization (-xOn) and on a newer Solaris 10 system
       with patch 127111-07 installed.	On Solaris systems without the patch,
       the -xbinopt=prepare compiler option would need to be used (see cc(1),
       CC(1), f95(1) for option details).

       The Binary Optimizer may also be used to instrument a binary for pro‐
       file collection. The instrumented binary must then be run with an input
       data training set representing a typical user's data. This training run
       will create a binary file with profile data. This file must then be fed
       back to the Binary Optimizer to create a profile optimized binary.

       The binopt command performs several levels of optimizations.  At higher
       levels of optimization, more optimizations are performed, leading to a
       potentially more optimal binary. A possible side-effect is increased
       build time.

       By default, if no output file name is specified, the input file is
       overwritten with the optimized binary. Unless the -bfinal option is
       given, binaries created by the binopt command may be optimized by a
       future invocation of the Binary Optimizer.

OPTIONS
       -binstrument[=on|off]
	      Instrument the binary for profile collection. All optimizations
	      are automatically turned off. The -bdata option may be used to
	      modify the default file used to store the profile data. This
	      cannot be used with the -buse flag.

       -buse[=on|off]
	      Perform profile guided optimizations using profile data. Again,
	      the -bdata flag may be used to modify the default file location.
	      This cannot be used with the -binstrument flag.

       -blevel=0|1|2
	      Perform different levels of optimizations.
	      At level 0, no optimizations are performed.
	      At level 1, do code reordering optimizations (this is the
	      default behavior).
	      At level 2, data-flow information is constructed and more
	      aggressive optimizations like inlining and address related opti‐
	      mizations are performed.

       -bdata=datafile
	      Specifies the file where the profile data will be stored. This
	      option is used only with -binstrument or -buse and is ignored
	      otherwise. If this option is not used, the default file name is
	      binfile.instrdata.

       -bfinal[=on|off]
	      Finalize the output binary so that no future binary optimiza‐
	      tions may be performed.  This option is useful in the final
	      build step after which no further transformations are planned.
	      For example, this may be used with the -buse option when gener‐
	      ating the final optimal binary.  The default is -bfinal=off.

       -o filename
	      Names the output file filename, instead of overwriting the input
	      binfile file by default.

       -V     Print the version number of the tool on the standard error out‐
	      put.

       -flags Prints a one-line summary of available options.

       -Q[y|n]
	      Emits or does not emit the Binary Optimizer version identifica‐
	      tion information the output file. If -Qy is used, identification
	      information will be added to the output files (the default
	      behavior). -Qn suppresses this information.

       -xinline=[[,v...]]
	      v can be %auto func_name no%func_name
	      -xinline tries to inline only those functions specified in the
	      list. The list is comprised of either a comma-separated list of
	      function names, or a comma-separated list of no%func_name val‐
	      ues, or the value %auto. If you specify %nofunc_name, the com‐
	      piler is not to inline the named function. If you specify %auto,
	      binopt will attempt to automatically inline functions.
	      By default automatic inlining is enabled at optimization level
	      2.

OPERAND
       binfile
	      Binary file to be optimized.

EXAMPLES
       Example 1: Prepare and optimize a binary

       The following entry prepares the created binary for optimizations and
       then optimizes it with the binopt command, overwriting the binary file
       in place.

       % cc -O -xbinopt=prepare *.c -o a.out
       % binopt a.out

       Example 2: Instrument, run, and perform profile guided optimizations.

       The following example instruments a binary, performs a training run and
       then uses the profile data to perform profile guided optimizations.

       % binopt -binstrument -bdata=a.out.data -o a.out.instr a.out
       % ./a.out.instr
       % binopt -buse -bdata=a.out.data -o a.out.opt a.out

       Example 3: Perform level 2 optimizations and finalize.

       The following example performs binary optimizations at level 2 and then
       finalizes the binary so that the binary may not be optimized in the
       future.

       % binopt -blevel=2 -bfinal a.out

SEE ALSO
       cc(1), CC(1), f95(1).

				 October 2005			     binopt(1)
[top]

List of man pages available for OpenIndiana

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]
Tweet
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