Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Alex D
GHC
Commits
f7db2c30
Commit
f7db2c30
authored
Sep 22, 2004
by
sof
Browse files
[project @ 2004-09-22 16:37:23 by sof]
Limit ThreadLabel API use to DEBUG only.
parent
907d2e9d
Changes
3
Hide whitespace changes
Inline
Side-by-side
ghc/rts/RtsStartup.c
View file @
f7db2c30
...
...
@@ -193,8 +193,10 @@ hs_init(int *argc, char **argv[])
/* initialise the stable pointer table */
initStablePtrTable
();
#if defined(DEBUG)
/* initialise thread label table (tso->char*) */
initThreadLabelTable
();
#endif
#if defined(PROFILING) || defined(DEBUG)
initProfiling1
();
...
...
ghc/rts/Schedule.c
View file @
f7db2c30
...
...
@@ -3441,8 +3441,10 @@ printAllThreads(void)
for
(
t
=
all_threads
;
t
!=
END_TSO_QUEUE
;
t
=
t
->
global_link
)
{
debugBelch
(
"
\t
thread %d @ %p "
,
t
->
id
,
(
void
*
)
t
);
#if defined(DEBUG)
label
=
lookupThreadLabel
(
t
->
id
);
if
(
label
)
debugBelch
(
"[
\"
%s
\"
] "
,(
char
*
)
label
);
#endif
printThreadStatus
(
t
);
debugBelch
(
"
\n
"
);
}
...
...
ghc/rts/ThreadLabels.c
View file @
f7db2c30
...
...
@@ -13,6 +13,8 @@
#include <stdlib.h>
#if defined(DEBUG)
/* to the end */
static
HashTable
*
threadLabels
=
NULL
;
void
...
...
@@ -45,3 +47,4 @@ removeThreadLabel(StgWord key)
stgFree
(
old
);
}
}
#endif
/* DEBUG */
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment