Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
GHC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gesh
GHC
Commits
d6297149
Commit
d6297149
authored
24 years ago
by
Simon Marlow
Browse files
Options
Downloads
Patches
Plain Diff
[project @ 2000-05-12 13:12:56 by simonmar]
Update for changes in the profile output.
parent
5ee90f9b
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
ghc/docs/users_guide/profiling.sgml
+38
-31
38 additions, 31 deletions
ghc/docs/users_guide/profiling.sgml
with
38 additions
and
31 deletions
ghc/docs/users_guide/profiling.sgml
+
38
−
31
View file @
d6297149
...
...
@@ -81,7 +81,7 @@ $
will contain something like this:</para>
<screen>
Tue Apr 18 12:52
2000 Time and Allocation Profiling Report (Final)
Fri May 12 14:06
2000 Time and Allocation Profiling Report (Final)
Main +RTS -p -RTS
...
...
@@ -93,15 +93,16 @@ COST CENTRE MODULE %time %alloc
nfib Main 100.0 100.0
COST CENTRE MODULE scc %time %alloc inner cafs
individual inherited
COST CENTRE MODULE scc %time %alloc %time %alloc
MAIN MAIN 0 0.0 0.0
0 1
main Main 0 0.0 0.0
0 1
CAF
PrelHandle 3 0.0 0.0
0
3
CAF
PrelAddr 1 0.0 0.0
0
0
CAF
Main 6 0.0 0.0
1
0
main Main 1 0.0 0.0
1 1
nfib Main 242785 100.0 100.0
242784 4
MAIN MAIN 0
0.0 0.0
100.0 100.0
main Main 0
0.0 0.0
0.0 0.0
CAF
PrelHandle 3
0.0 0.0 0
.0
0.0
CAF
PrelAddr 1
0.0 0.0
0.
0
0.
0
CAF
Main 6
0.0 0.0
100.0 100.
0
main Main 1
0.0 0.0
100.0 100.0
nfib Main 242785
100.0 100.0
100.0 100.0
</screen>
...
...
@@ -125,6 +126,12 @@ MAIN MAIN 0 0.0 0.0 0 1
the costly call to <function>nfib</function> came from
<function>main</function>.</para>
<para>The time and allocation incurred by a given part of the
program is displayed in two ways: “individual”, which
are the costs incurred by the code covered by this cost centre
stack alone, and “inherited”, which includes the costs
incurred by all the children of this node.</para>
<para>The usefulness of cost-centre stacks is better demonstrated
by modifying the example slightly:</para>
...
...
@@ -139,18 +146,18 @@ nfib n = if n < 2 then 1 else nfib (n-1) + nfib (n-2)
the new profiling results:</para>
<screen>
COST CENTRE MODULE scc %time %alloc
inner cafs
MAIN MAIN 0 0.0 0.0
0 1
main Main 0 0.0 0.0
0 1
CAF PrelHandle 3 0.0 0.0
0 3
CAF PrelAddr 1 0.0 0.0
0
0
CAF
Main 9 0.0 0.0
1
1
main Main 1 0.0 0.0
2 2
g Main 1 0.0 0.0
1 3
nfib Main 465 0.0 0.2
464
0
f Main 1 0.0 0.0
1 1
nfib Main 242785 100.0 99.8
242784 1
COST CENTRE MODULE scc
%time %alloc
%time %alloc
MAIN MAIN 0
0.0 0.0
100.0 100.0
main Main 0
0.0 0.0
0.0 0.0
CAF PrelHandle 3
0.0 0.0
0.0 0.0
CAF PrelAddr 1
0.0 0.0
0.
0
0.
0
CAF
Main 9
0.0 0.0 1
00.0 100.0
main Main 1
0.0 0.0
100.0 100.0
g Main 1
0.0 0.0
0.0 0.2
nfib Main 465
0.0 0.2
0.0
0
.2
f Main 1
0.0 0.0
100.0 99.8
nfib Main 242785
100.0 99.8
100.0 99.8
</screen>
<para>Now although we had two calls to <function>nfib</function>
...
...
@@ -161,7 +168,7 @@ MAIN MAIN 0 0.0 0.0 0 1
<variablelist>
<varlistentry>
<term>
scc
</term>
<term>
entries
</term>
<listitem>
<para>The number of times this particular point in the call
graph was entered.</para>
...
...
@@ -169,7 +176,7 @@ MAIN MAIN 0 0.0 0.0 0 1
</varlistentry>
<varlistentry>
<term>%time</term>
<term>
individual
%time</term>
<listitem>
<para>The percentage of the total run time of the program
spent at this point in the call graph.</para>
...
...
@@ -177,7 +184,7 @@ MAIN MAIN 0 0.0 0.0 0 1
</varlistentry>
<varlistentry>
<term>%alloc</term>
<term>
individual
%alloc</term>
<listitem>
<para>The percentage of the total memory allocations
(excluding profiling overheads) of the program made by this
...
...
@@ -186,19 +193,19 @@ MAIN MAIN 0 0.0 0.0 0 1
</varlistentry>
<varlistentry>
<term>in
ner
</term>
<term>in
herited %time
</term>
<listitem>
<para>The
number of times an inner call-graph context was
ent
ered from here (including recursive calls)
.</para>
<para>The
percentage of the total run time of the program
sp
ent
below this point in the call graph
.</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
cafs
</term>
<term>
inherited %alloc
</term>
<listitem>
<para>The
number of times a CAF context was entered from
here. CAFs are described in <xref
linkend="prof-rules">
.</para>
<para>The
percentage of the total memory allocations
(excluding profiling overheads) of the program made by this
call and all of its sub-calls
.</para>
</listitem>
</varlistentry>
</variablelist>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment