Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
0410cf9c
Commit
0410cf9c
authored
Oct 07, 2015
by
Sebastian Lackner
Committed by
Alexandre Julliard
Oct 07, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vcomp: Implement _vcomp_get_thread_num.
Signed-off-by:
Sebastian Lackner
<
sebastian@fds-team.de
>
parent
aa39614e
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
17 additions
and
4 deletions
+17
-4
main.c
dlls/vcomp/main.c
+6
-0
vcomp.c
dlls/vcomp/tests/vcomp.c
+7
-0
vcomp.spec
dlls/vcomp/vcomp.spec
+1
-1
vcomp100.spec
dlls/vcomp100/vcomp100.spec
+1
-1
vcomp110.spec
dlls/vcomp110/vcomp110.spec
+1
-1
vcomp90.spec
dlls/vcomp90/vcomp90.spec
+1
-1
No files found.
dlls/vcomp/main.c
View file @
0410cf9c
...
...
@@ -480,6 +480,12 @@ int CDECL omp_get_thread_num(void)
return
vcomp_init_thread_data
()
->
thread_num
;
}
int
CDECL
_vcomp_get_thread_num
(
void
)
{
TRACE
(
"()
\n
"
);
return
vcomp_init_thread_data
()
->
thread_num
;
}
/* Time in seconds since "some time in the past" */
double
CDECL
omp_get_wtime
(
void
)
{
...
...
dlls/vcomp/tests/vcomp.c
View file @
0410cf9c
...
...
@@ -65,6 +65,7 @@ static void (CDECL *p_vcomp_for_static_init)(int first, int last, int step, i
static
void
(
CDECL
*
p_vcomp_for_static_simple_init
)(
unsigned
int
first
,
unsigned
int
last
,
int
step
,
BOOL
increment
,
unsigned
int
*
begin
,
unsigned
int
*
end
);
static
void
(
WINAPIV
*
p_vcomp_fork
)(
BOOL
ifval
,
int
nargs
,
void
*
wrapper
,
...);
static
int
(
CDECL
*
p_vcomp_get_thread_num
)(
void
);
static
void
(
CDECL
*
p_vcomp_leave_critsect
)(
CRITICAL_SECTION
*
critsect
);
static
int
(
CDECL
*
p_vcomp_master_begin
)(
void
);
static
void
(
CDECL
*
p_vcomp_master_end
)(
void
);
...
...
@@ -254,6 +255,7 @@ static BOOL init_vcomp(void)
VCOMP_GET_PROC
(
_vcomp_for_static_init
);
VCOMP_GET_PROC
(
_vcomp_for_static_simple_init
);
VCOMP_GET_PROC
(
_vcomp_fork
);
VCOMP_GET_PROC
(
_vcomp_get_thread_num
);
VCOMP_GET_PROC
(
_vcomp_leave_critsect
);
VCOMP_GET_PROC
(
_vcomp_master_begin
);
VCOMP_GET_PROC
(
_vcomp_master_end
);
...
...
@@ -306,6 +308,8 @@ static void CDECL num_threads_cb(BOOL nested, int parallel, int nested_threads,
thread_num
=
pomp_get_thread_num
();
ok
(
thread_num
>=
0
&&
thread_num
<
num_threads
,
"expected thread_num in range [0, %d], got %d
\n
"
,
num_threads
-
1
,
thread_num
);
ok
(
thread_num
==
p_vcomp_get_thread_num
(),
"expected _vcomp_get_thread_num to return the same value
\n
"
);
is_parallel
=
pomp_in_parallel
();
ok
(
is_parallel
==
parallel
,
"expected %d, got %d
\n
"
,
parallel
,
is_parallel
);
...
...
@@ -344,6 +348,9 @@ static void test_omp_get_num_threads(BOOL nested)
int
is_nested
,
is_parallel
,
max_threads
,
num_threads
,
thread_num
;
LONG
thread_count
;
ok
(
pomp_get_thread_num
!=
p_vcomp_get_thread_num
,
"expected omp_get_thread_num != _vcomp_get_thread_num
\n
"
);
pomp_set_nested
(
nested
);
is_nested
=
pomp_get_nested
();
ok
(
is_nested
==
nested
,
"expected %d, got %d
\n
"
,
nested
,
is_nested
);
...
...
dlls/vcomp/vcomp.spec
View file @
0410cf9c
...
...
@@ -65,7 +65,7 @@
@ cdecl _vcomp_for_static_simple_init(long long long long ptr ptr)
@ stub _vcomp_for_static_simple_init_i8
@ varargs _vcomp_fork(long long ptr)
@
stub _vcomp_get_thread_num
@
cdecl _vcomp_get_thread_num()
@ cdecl _vcomp_leave_critsect(ptr)
@ stub _vcomp_master_barrier
@ cdecl _vcomp_master_begin()
...
...
dlls/vcomp100/vcomp100.spec
View file @
0410cf9c
...
...
@@ -65,7 +65,7 @@
@ cdecl _vcomp_for_static_simple_init(long long long long ptr ptr) vcomp._vcomp_for_static_simple_init
@ stub _vcomp_for_static_simple_init_i8
@ varargs _vcomp_fork(long long ptr) vcomp._vcomp_fork
@
stub
_vcomp_get_thread_num
@
cdecl _vcomp_get_thread_num() vcomp.
_vcomp_get_thread_num
@ cdecl _vcomp_leave_critsect(ptr) vcomp._vcomp_leave_critsect
@ stub _vcomp_master_barrier
@ cdecl _vcomp_master_begin() vcomp._vcomp_master_begin
...
...
dlls/vcomp110/vcomp110.spec
View file @
0410cf9c
...
...
@@ -66,7 +66,7 @@
@ cdecl _vcomp_for_static_simple_init(long long long long ptr ptr) vcomp._vcomp_for_static_simple_init
@ stub _vcomp_for_static_simple_init_i8
@ varargs _vcomp_fork(long long ptr) vcomp._vcomp_fork
@
stub
_vcomp_get_thread_num
@
cdecl _vcomp_get_thread_num() vcomp.
_vcomp_get_thread_num
@ cdecl _vcomp_leave_critsect(ptr) vcomp._vcomp_leave_critsect
@ stub _vcomp_master_barrier
@ cdecl _vcomp_master_begin() vcomp._vcomp_master_begin
...
...
dlls/vcomp90/vcomp90.spec
View file @
0410cf9c
...
...
@@ -65,7 +65,7 @@
@ cdecl _vcomp_for_static_simple_init(long long long long ptr ptr) vcomp._vcomp_for_static_simple_init
@ stub _vcomp_for_static_simple_init_i8
@ varargs _vcomp_fork(long long ptr) vcomp._vcomp_fork
@
stub
_vcomp_get_thread_num
@
cdecl _vcomp_get_thread_num() vcomp.
_vcomp_get_thread_num
@ cdecl _vcomp_leave_critsect(ptr) vcomp._vcomp_leave_critsect
@ stub _vcomp_master_barrier
@ cdecl _vcomp_master_begin() vcomp._vcomp_master_begin
...
...
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