repo.or.cz
/
mono-project.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
[System] Tweak socket test
[mono-project.git]
/
mono
/
profiler
/
test-monitor.cs
blob
8e77b2f0a5e7f915dad95775b4b1ab6c7c6ace13
1
using
System
;
2
using
System
.
Threading
;
3
4
class
T
{
5
6
static object
mutex
=
new object
();
7
static int
count
=
1000000
;
8
9
static void
dolock
()
10
{
11
for
(
int
i
=
0
;
i
<
count
; ++
i
) {
12
lock
(
mutex
) {
13
}
14
}
15
}
16
17
static void
Main
(
string
[]
args
) {
18
Thread t
=
new
Thread
(
dolock
);
19
t
.
Start
();
20
dolock
();
21
t
.
Join
();
22
}
23
}
24