Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
8b543906
Commit
8b543906
authored
Jun 21, 2010
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Fix the initial FPU control word on 64-bit.
parent
2a26e954
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
8 deletions
+6
-8
thread.c
dlls/kernel32/tests/thread.c
+3
-2
signal_x86_64.c
dlls/ntdll/signal_x86_64.c
+3
-6
No files found.
dlls/kernel32/tests/thread.c
View file @
8b543906
...
...
@@ -1387,10 +1387,11 @@ static WORD get_thread_fpu_cw(void)
static
void
test_thread_fpu_cw
(
void
)
{
WORD
initial_cw
,
cw
;
WORD
initial_cw
,
cw
,
expect
;
initial_cw
=
get_fpu_cw
();
ok
(
initial_cw
==
0x37f
,
"Expected FPU control word 0x37f, got %#x.
\n
"
,
initial_cw
);
expect
=
sizeof
(
void
*
)
>
sizeof
(
int
)
?
0x27f
:
0x37f
;
ok
(
initial_cw
==
expect
,
"Expected FPU control word expect, got %#x.
\n
"
,
initial_cw
);
cw
=
get_thread_fpu_cw
();
ok
(
cw
==
0x27f
,
"Expected FPU control word 0x27f, got %#x.
\n
"
,
cw
);
...
...
dlls/ntdll/signal_x86_64.c
View file @
8b543906
...
...
@@ -2330,6 +2330,7 @@ void signal_free_thread( TEB *teb )
*/
void
signal_init_thread
(
TEB
*
teb
)
{
const
WORD
fpu_cw
=
0x27f
;
stack_t
ss
;
#if defined __linux__
...
...
@@ -2345,15 +2346,11 @@ void signal_init_thread( TEB *teb )
ss
.
ss_flags
=
0
;
if
(
sigaltstack
(
&
ss
,
NULL
)
==
-
1
)
perror
(
"sigaltstack"
);
if
(
teb
->
Peb
->
ProcessHeap
)
/* Not for the inital thread. */
{
const
WORD
fpu_cw
=
0x27f
;
#ifdef __GNUC__
__asm__
volatile
(
"fninit; fldcw %0"
:
:
"m"
(
fpu_cw
));
__asm__
volatile
(
"fninit; fldcw %0"
:
:
"m"
(
fpu_cw
));
#else
FIXME
(
"FPU setup not implemented for this platform.
\n
"
);
FIXME
(
"FPU setup not implemented for this platform.
\n
"
);
#endif
}
}
/**********************************************************************
...
...
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