<Para>
<IndexTerm><Primary>profiling, with cost-centres</Primary></IndexTerm>
<IndexTerm><Primary>cost-centre profiling</Primary></IndexTerm>
-</Para>
-
-<Para>
Glasgow Haskell comes with a time and space profiling system. Its
purpose is to help you improve your understanding of your program's
execution behaviour, so you can improve it.
</Para>
<Para>
-The costs of the evaluating the expressions bound to <Literal>output1</Literal>,
-<Literal>output2</Literal> and <Literal>output3</Literal> will be attributed to the ``cost
-centres'' <Literal>Pass1</Literal>, <Literal>Pass2</Literal> and <Literal>Pass3</Literal>, respectively.
+The costs of the evaluating the expressions bound to <VarName>output1</VarName>,
+<VarName>output2</VarName> and <VarName>output3</VarName> will be attributed to the ``cost
+centres'' <VarName>Pass1</VarName>, <VarName>Pass2</VarName> and <VarName>Pass3</VarName>, respectively.
</Para>
<Para>
The costs of evaluating other expressions, e.g., <Literal>concat output4</Literal>,
-will be inherited by the scope which referenced the function <Literal>f</Literal>.
+will be inherited by the scope which referenced the function <Function>f</Function>.
</Para>
<Para>
-You can put in cost-centres via <Literal>_scc_</Literal> constructs by hand, as in the
+You can put in cost-centres via <Function>_scc_</Function> constructs by hand, as in the
example above. Perfectly cool. That's probably what you
<Emphasis>would</Emphasis> do if your program divided into obvious ``passes'' or
``phases'', or whatever.
<Para>
If your program is large or you have no clue what might be gobbling
-all the time, you can get GHC to mark all functions with <Literal>_scc_</Literal>
-constructs, automagically. Add an <Literal>-auto</Literal> compilation flag to the
-usual <Literal>-prof</Literal> option.
+all the time, you can get GHC to mark all functions with <Function>_scc_</Function>
+constructs, automagically. Add an <Option>-auto</Option> compilation flag to the
+usual <Option>-prof</Option> option.
</Para>
<Para>
<Para>
To make use of the cost centre profiling system <Emphasis>all</Emphasis> modules must
-be compiled and linked with the <Literal>-prof</Literal> option.<IndexTerm><Primary>-prof option</Primary></IndexTerm>
-Any <Literal>_scc_</Literal> constructs you've put in your source will spring to life.
+be compiled and linked with the <Option>-prof</Option> option.<IndexTerm><Primary>-prof option</Primary></IndexTerm>
+Any <Function>_scc_</Function> constructs you've put in your source will spring to life.
</Para>
<Para>
-Without a <Literal>-prof</Literal> option, your <Literal>_scc_</Literal>s are ignored; so you can
-compiled <Literal>_scc_</Literal>-laden code without changing it.
+Without a <Option>-prof</Option> option, your <Function>_scc_</Function>s are ignored; so you can
+compiled <Function>_scc_</Function>-laden code without changing it.
</Para>
<Para>
There are a few other profiling-related compilation options. Use them
-<Emphasis>in addition to</Emphasis> <Literal>-prof</Literal>. These do not have to be used
+<Emphasis>in addition to</Emphasis> <Option>-prof</Option>. These do not have to be used
consistently for all modules in a program.
</Para>
<VariableList>
<VarListEntry>
-<Term><Literal>-auto</Literal>:</Term>
+<Term><Option>-auto</Option>:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-auto option</Primary></IndexTerm>
<IndexTerm><Primary>cost centres, automatically inserting</Primary></IndexTerm>
-GHC will automatically add <Literal>_scc_</Literal> constructs for
+GHC will automatically add <Function>_scc_</Function> constructs for
all top-level, exported functions.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-auto-all</Literal>:</Term>
+<Term><Option>-auto-all</Option>:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-auto-all option</Primary></IndexTerm>
<Emphasis>All</Emphasis> top-level functions, exported or not, will be automatically
-<Literal>_scc_</Literal>'d.
+<Function>_scc_</Function>'d.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-caf-all</Literal>:</Term>
+<Term><Option>-caf-all</Option>:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-caf-all option</Primary></IndexTerm>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-ignore-scc</Literal>:</Term>
+<Term><Option>-ignore-scc</Option>:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-ignore-scc option</Primary></IndexTerm>
-Ignore any <Literal>_scc_</Literal> constructs,
-so a module which already has <Literal>_scc_</Literal>s can be
+Ignore any <Function>_scc_</Function> constructs,
+so a module which already has <Function>_scc_</Function>s can be
compiled for profiling with the annotations ignored.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-G<group></Literal>:</Term>
+<Term><Option>-G<group></Option>:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-G<group> option</Primary></IndexTerm>
</Para>
<Para>
-In addition to the <Literal>-prof</Literal> option your system might be setup to enable
-you to compile and link with the <Literal>-prof-details</Literal> <IndexTerm><Primary>-prof-details
+In addition to the <Option>-prof</Option> option your system might be setup to enable
+you to compile and link with the <Option>-prof-details</Option> <IndexTerm><Primary>-prof-details
option</Primary></IndexTerm> option instead. This enables additional detailed counts
-to be reported with the <Literal>-P</Literal> RTS option.
+to be reported with the <Option>-P</Option> RTS option.
</Para>
</Sect1>
</Para>
<Para>
-It isn't enough to compile your program for profiling with <Literal>-prof</Literal>!
+It isn't enough to compile your program for profiling with <Option>-prof</Option>!
</Para>
<Para>
</Para>
<Para>
-Executive summary: <Literal>./a.out +RTS -pT</Literal> produces a time profile in
-<Literal>a.out.prof</Literal>; <Literal>./a.out +RTS -hC</Literal> produces space-profiling
-info which can be mangled by <Literal>hp2ps</Literal> and viewed with <Literal>ghostview</Literal>
+Executive summary: <Command>./a.out +RTS -pT</Command> produces a time profile in
+<Filename>a.out.prof</Filename>; <Command>./a.out +RTS -hC</Command> produces space-profiling
+info which can be mangled by <Command>hp2ps</Command> and viewed with <Command>ghostview</Command>
(or equivalent).
</Para>
<Para>
Profiling runtime flags are passed to your program between the usual
-<Literal>+RTS</Literal> and <Literal>-RTS</Literal> options.
+<Option>+RTS</Option> and <Option>-RTS</Option> options.
</Para>
<Para>
<VariableList>
<VarListEntry>
-<Term><Literal>-p<sort></Literal> or <Literal>-P<sort></Literal>:</Term>
+<Term><Option>-p<sort></Option> or <Option>-P<sort></Option>:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-p<sort> RTS option (profiling)</Primary></IndexTerm>
<IndexTerm><Primary>-P<sort> RTS option (profiling)</Primary></IndexTerm>
<IndexTerm><Primary>time profile</Primary></IndexTerm>
<IndexTerm><Primary>serial time profile</Primary></IndexTerm>
-The <Literal>-p?</Literal> option produces a standard <Emphasis>time profile</Emphasis> report.
-It is written into the file <Literal><program>@.prof</Literal>.
+The <Option>-p?</Option> option produces a standard <Emphasis>time profile</Emphasis> report.
+It is written into the file <Filename><program>@.prof</Filename>.
</Para>
<Para>
-The <Literal>-P?</Literal> option produces a more detailed report containing the
+The <Option>-P?</Option> option produces a more detailed report containing the
actual time and allocation data as well. (Not used much.)
</Para>
<VariableList>
<VarListEntry>
-<Term><Literal>T</Literal>:</Term>
+<Term><Option>T</Option>:</Term>
<ListItem>
<Para>
by time, largest first (the default);
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>A</Literal>:</Term>
+<Term><Option>A</Option>:</Term>
<ListItem>
<Para>
by bytes allocated, largest first;
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>C</Literal>:</Term>
+<Term><Option>C</Option>:</Term>
<ListItem>
<Para>
alphabetically by group, module and cost centre.
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-i<secs></Literal>:</Term>
+<Term><Option>-i<secs></Option>:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-i<secs> RTS option
(profiling)</Primary></IndexTerm> Set the profiling (sampling) interval to <Literal><secs></Literal>
seconds (the default is 1 second). Fractions are allowed: for example
-<Literal>-i0.2</Literal> will get 5 samples per second.
+<Option>-i0.2</Option> will get 5 samples per second.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-h<break-down></Literal>:</Term>
+<Term><Option>-h<break-down></Option>:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-h<break-down> RTS option (profiling)</Primary></IndexTerm>
<Para>
Produce a detailed <Emphasis>space profile</Emphasis> of the heap occupied by live
-closures. The profile is written to the file <Literal><program>@.hp</Literal> from
-which a PostScript graph can be produced using <Literal>hp2ps</Literal> (see
+closures. The profile is written to the file <Filename><program>@.hp</Filename> from
+which a PostScript graph can be produced using <Command>hp2ps</Command> (see
<XRef LinkEnd="hp2ps">).
</Para>
<VariableList>
<VarListEntry>
-<Term><Literal>-hC</Literal>:</Term>
+<Term><Option>-hC</Option>:</Term>
<ListItem>
<Para>
cost centre which produced the closure (the default).
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-hM</Literal>:</Term>
+<Term><Option>-hM</Option>:</Term>
<ListItem>
<Para>
cost centre module which produced the closure.
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-hG</Literal>:</Term>
+<Term><Option>-hG</Option>:</Term>
<ListItem>
<Para>
cost centre group which produced the closure.
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-hD</Literal>:</Term>
+<Term><Option>-hD</Option>:</Term>
<ListItem>
<Para>
closure description—a string describing the closure.
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-hY</Literal>:</Term>
+<Term><Option>-hY</Option>:</Term>
<ListItem>
<Para>
closure type—a string describing the closure's type.
<Para>
Heap (space) profiling uses hash tables. If these tables
should fill the run will abort. The
-<Literal>-z<tbl><size></Literal><IndexTerm><Primary>-z<tbl><size> RTS option (profiling)</Primary></IndexTerm> option is used to
+<Option>-z<tbl><size></Option><IndexTerm><Primary>-z<tbl><size> RTS option (profiling)</Primary></IndexTerm> option is used to
increase the size of the relevant hash table (<Literal>C</Literal>, <Literal>M</Literal>,
<Literal>G</Literal>, <Literal>D</Literal> or <Literal>Y</Literal>, defined as for <Literal><break-down></Literal> above). The
actual size used is the next largest power of 2.
<VariableList>
<VarListEntry>
-<Term><Literal>-c{<mod>:<lab>,<mod>:<lab>...</Literal>}:</Term>
+<Term><Option>-c{<mod>:<lab>,<mod>:<lab>...</Option>}:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-c{<lab></Primary></IndexTerm> RTS option (profiling)}
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-m{<mod>,<mod>...</Literal>}:</Term>
+<Term><Option>-m{<mod>,<mod>...</Option>}:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-m{<mod></Primary></IndexTerm> RTS option (profiling)}
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-g{<grp>,<grp>...</Literal>}:</Term>
+<Term><Option>-g{<grp>,<grp>...</Option>}:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-g{<grp></Primary></IndexTerm> RTS option (profiling)}
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-d{<des>,<des>...</Literal>}:</Term>
+<Term><Option>-d{<des>,<des>...</Option>}:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-d{<des></Primary></IndexTerm> RTS option (profiling)}
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-y{<typ>,<typ>...</Literal>}:</Term>
+<Term><Option>-y{<typ>,<typ>...</Option>}:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-y{<typ></Primary></IndexTerm> RTS option (profiling)}
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-k{<knd>,<knd>...</Literal>}:</Term>
+<Term><Option>-k{<knd>,<knd>...</Option>}:</Term>
<ListItem>
<Para>
<IndexTerm><Primary>-k{<knd></Primary></IndexTerm> RTS option (profiling)}
</Para>
<Para>
-When you run your profiled program with the <Literal>-p</Literal> RTS option <IndexTerm><Primary>-p
+When you run your profiled program with the <Option>-p</Option> RTS option <IndexTerm><Primary>-p
RTS option</Primary></IndexTerm>, you get the following information about your ``cost
centres'':
</Para>
<ListItem>
<Para>
How many times this cost-centre was entered; think
-of it as ``I got to the <Literal>_scc_</Literal> construct this many times…''
+of it as ``I got to the <Function>_scc_</Function> construct this many times…''
</Para>
</ListItem>
</VarListEntry>
</Para>
<Para>
-In addition you can use the <Literal>-P</Literal> RTS option <IndexTerm><Primary></Primary></IndexTerm> to get the following additional information:
+In addition you can use the <Option>-P</Option> RTS option <IndexTerm><Primary></Primary></IndexTerm> to get the following additional information:
<VariableList>
<VarListEntry>
</Para>
<Para>
-Finally if you built your program with <Literal>-prof-details</Literal>
-<IndexTerm><Primary></Primary></IndexTerm> the <Literal>-P</Literal> RTS option will also
+Finally if you built your program with <Option>-prof-details</Option>
+<IndexTerm><Primary></Primary></IndexTerm> the <Option>-P</Option> RTS option will also
produce the following information:
<VariableList>
</Para>
<Sect2 id="hp2ps">
-<Title><Literal>hp2ps</Literal>--heap profile to PostScript
+<Title><Command>hp2ps</Command>--heap profile to PostScript
</Title>
<Para>
</Para>
<Para>
-The program <Literal>hp2ps</Literal><IndexTerm><Primary>hp2ps program</Primary></IndexTerm> converts a heap profile
-as produced by the <Literal>-h<break-down></Literal><IndexTerm><Primary>-h<break-down> RTS
+The program <Command>hp2ps</Command><IndexTerm><Primary>hp2ps program</Primary></IndexTerm> converts a heap profile
+as produced by the <Option>-h<break-down></Option><IndexTerm><Primary>-h<break-down> RTS
option</Primary></IndexTerm> runtime option into a PostScript graph of the heap
-profile. By convention, the file to be processed by <Literal>hp2ps</Literal> has a
-<Literal>.hp</Literal> extension. The PostScript output is written to <Literal><file>@.ps</Literal>. If
-<Literal><file></Literal> is omitted entirely, then the program behaves as a filter.
+profile. By convention, the file to be processed by <Command>hp2ps</Command> has a
+<Filename>.hp</Filename> extension. The PostScript output is written to <Filename><file>@.ps</Filename>. If
+<Filename><file></Filename> is omitted entirely, then the program behaves as a filter.
</Para>
<Para>
-<Literal>hp2ps</Literal> is distributed in <Literal>ghc/utils/hp2ps</Literal> in a GHC source
+<Command>hp2ps</Command> is distributed in <Filename>ghc/utils/hp2ps</Filename> in a GHC source
distribution. It was originally developed by Dave Wakeling as part of
the HBC/LML heap profiler.
</Para>
<VariableList>
<VarListEntry>
-<Term><Literal>-d</Literal></Term>
+<Term><Option>-d</Option></Term>
<ListItem>
<Para>
-In order to make graphs more readable, <Literal>hp2ps</Literal> sorts the shaded
+In order to make graphs more readable, <Command>hp2ps</Command> sorts the shaded
bands for each identifier. The default sort ordering is for the bands
with the largest area to be stacked on top of the smaller ones. The
-<Literal>-d</Literal> option causes rougher bands (those representing series of
+<Option>-d</Option> option causes rougher bands (those representing series of
values with the largest standard deviations) to be stacked on top of
smoother ones.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-b</Literal></Term>
+<Term><Option>-b</Option></Term>
<ListItem>
<Para>
-Normally, <Literal>hp2ps</Literal> puts the title of the graph in a small box at the
+Normally, <Command>hp2ps</Command> puts the title of the graph in a small box at the
top of the page. However, if the JOB string is too long to fit in a
small box (more than 35 characters), then
-<Literal>hp2ps</Literal> will choose to use a big box instead. The <Literal>-b</Literal>
-option forces <Literal>hp2ps</Literal> to use a big box.
+<Command>hp2ps</Command> will choose to use a big box instead. The <Option>-b</Option>
+option forces <Command>hp2ps</Command> to use a big box.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-e<float>[in|mm|pt]</Literal></Term>
+<Term><Option>-e<float>[in|mm|pt]</Option></Term>
<ListItem>
<Para>
Generate encapsulated PostScript suitable for inclusion in LaTeX
documents. Usually, the PostScript graph is drawn in landscape mode
-in an area 9 inches wide by 6 inches high, and <Literal>hp2ps</Literal> arranges
+in an area 9 inches wide by 6 inches high, and <Command>hp2ps</Command> arranges
for this area to be approximately centred on a sheet of a4 paper.
This format is convenient of studying the graph in detail, but it is
-unsuitable for inclusion in LaTeX documents. The <Literal>-e</Literal> option
+unsuitable for inclusion in LaTeX documents. The <Option>-e</Option> option
causes the graph to be drawn in portrait mode, with float specifying
the width in inches, millimetres or points (the default). The
resulting PostScript file conforms to the Encapsulated PostScript
(EPS) convention, and it can be included in a LaTeX document using
-Rokicki's dvi-to-PostScript converter <Literal>dvips</Literal>.
+Rokicki's dvi-to-PostScript converter <Command>dvips</Command>.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-g</Literal></Term>
+<Term><Option>-g</Option></Term>
<ListItem>
<Para>
-Create output suitable for the <Literal>gs</Literal> PostScript previewer (or
+Create output suitable for the <Command>gs</Command> PostScript previewer (or
similar). In this case the graph is printed in portrait mode without
scaling. The output is unsuitable for a laser printer.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-l</Literal></Term>
+<Term><Option>-l</Option></Term>
<ListItem>
<Para>
Normally a profile is limited to 20 bands with additional identifiers
-being grouped into an <Literal>OTHER</Literal> band. The <Literal>-l</Literal> flag removes this
+being grouped into an <Literal>OTHER</Literal> band. The <Option>-l</Option> flag removes this
20 band and limit, producing as many bands as necessary. No key is
produced as it won't fit!. It is useful for creation time profiles
with many bands.
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-m<int></Literal></Term>
+<Term><Option>-m<int></Option></Term>
<ListItem>
<Para>
Normally a profile is limited to 20 bands with additional identifiers
-being grouped into an <Literal>OTHER</Literal> band. The <Literal>-m</Literal> flag specifies an
+being grouped into an <Literal>OTHER</Literal> band. The <Option>-m</Option> flag specifies an
alternative band limit (the maximum is 20).
</Para>
<Para>
-<Literal>-m0</Literal> requests the band limit to be removed. As many bands as
+<Option>-m0</Option> requests the band limit to be removed. As many bands as
necessary are produced. However no key is produced as it won't fit! It
is useful for displaying creation time profiles with many bands.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-p</Literal></Term>
+<Term><Option>-p</Option></Term>
<ListItem>
<Para>
Use previous parameters. By default, the PostScript graph is
automatically scaled both horizontally and vertically so that it fills
the page. However, when preparing a series of graphs for use in a
presentation, it is often useful to draw a new graph using the same
-scale, shading and ordering as a previous one. The <Literal>-p</Literal> flag causes
+scale, shading and ordering as a previous one. The <Option>-p</Option> flag causes
the graph to be drawn using the parameters determined by a previous
-run of <Literal>hp2ps</Literal> on <Literal>file</Literal>. These are extracted from
-<Literal>file@.aux</Literal>.
+run of <Command>hp2ps</Command> on <Filename>file</Filename>. These are extracted from
+<Filename>file@.aux</Filename>.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-s</Literal></Term>
+<Term><Option>-s</Option></Term>
<ListItem>
<Para>
Use a small box for the title.
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-t<float></Literal></Term>
+<Term><Option>-t<float></Option></Term>
<ListItem>
<Para>
Normally trace elements which sum to a total of less than 1% of the
-profile are removed from the profile. The <Literal>-t</Literal> option allows this
+profile are removed from the profile. The <Option>-t</Option> option allows this
percentage to be modified (maximum 5%).
</Para>
<Para>
-<Literal>-t0</Literal> requests no trace elements to be removed from the profile,
+<Option>-t0</Option> requests no trace elements to be removed from the profile,
ensuring that all the data will be displayed.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
-<Term><Literal>-?</Literal></Term>
+<Term><Option>-?</Option></Term>
<ListItem>
<Para>
Print out usage information.
</Sect2>
<Sect2 id="stat2resid">
-<Title><Literal>stat2resid</Literal>—residency info from GC stats
+<Title><Command>stat2resid</Command>—residency info from GC stats
</Title>
<Para>
</Para>
<Para>
-The program <Literal>stat2resid</Literal><IndexTerm><Primary>stat2resid</Primary></IndexTerm> converts a detailed
+The program <Command>stat2resid</Command><IndexTerm><Primary>stat2resid</Primary></IndexTerm> converts a detailed
garbage collection statistics file produced by the
-<Literal>-S</Literal><IndexTerm><Primary>-S RTS option</Primary></IndexTerm> runtime option into a PostScript heap
+<Option>-S</Option><IndexTerm><Primary>-S RTS option</Primary></IndexTerm> runtime option into a PostScript heap
residency graph. The garbage collection statistics file can be
produced without compiling your program for profiling.
</Para>
<Para>
-By convention, the file to be processed by <Literal>stat2resid</Literal> has a
-<Literal>.stat</Literal> extension. If the <Literal><outfile></Literal> is not specified the
-PostScript will be written to <Literal><file>@.resid.ps</Literal>. If
-<Literal><file></Literal> is omitted entirely, then the program behaves as a filter.
+By convention, the file to be processed by <Command>stat2resid</Command> has a
+<Filename>.stat</Filename> extension. If the <Filename><outfile></Filename> is not specified the
+PostScript will be written to <Filename><file>@.resid.ps</Filename>. If
+<Filename><file></Filename> is omitted entirely, then the program behaves as a filter.
</Para>
<Para>
The plot can not be produced from the statistics file for a
generational collector, though a suitable stats file can be produced
-using the <Literal>-F2s</Literal><IndexTerm><Primary>-F2s RTS option</Primary></IndexTerm> runtime option when the
+using the <Option>-F2s</Option><IndexTerm><Primary>-F2s RTS option</Primary></IndexTerm> runtime option when the
program has been compiled for generational garbage collection (the
default).
</Para>
<Para>
-<Literal>stat2resid</Literal> is distributed in <Literal>ghc/utils/stat2resid</Literal> in a GHC source
+<Command>stat2resid</Command> is distributed in <Filename>ghc/utils/stat2resid</Filename> in a GHC source
distribution.
</Para>
<Para>
To get your compiled program to spit out the ticky-ticky numbers, use
-a <Literal>-r</Literal> RTS option<IndexTerm><Primary>-r RTS option</Primary></IndexTerm>. See <XRef LinkEnd="runtime-control">.
+a <Option>-r</Option> RTS option<IndexTerm><Primary>-r RTS option</Primary></IndexTerm>. See <XRef LinkEnd="runtime-control">.
</Para>
<Para>
-Compiling your program with the <Literal>-ticky</Literal> switch yields an executable
+Compiling your program with the <Option>-ticky</Option> switch yields an executable
that performs these counts. Here is a sample ticky-ticky statistics
-file, generated by the invocation <Literal>foo +RTS -rfoo.ticky</Literal>.
+file, generated by the invocation <Command>foo +RTS -rfoo.ticky</Command>.
</Para>
<Para>