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
b7f3e6ba
Commit
b7f3e6ba
authored
Nov 27, 2018
by
Zebediah Figura
Committed by
Alexandre Julliard
Nov 28, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dbghelp: Avoid using inline assembly in do_x86cpuid().
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
fc2b2b1b
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
12 deletions
+19
-12
minidump.c
dlls/dbghelp/minidump.c
+19
-12
No files found.
dlls/dbghelp/minidump.c
View file @
b7f3e6ba
...
...
@@ -18,6 +18,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "config.h"
#include <time.h>
#define NONAMELESSUNION
...
...
@@ -542,20 +543,26 @@ static unsigned dump_modules(struct dump_context* dc, BOOL dump_elf)
return
sz
;
}
/* Calls cpuid with an eax of 'ax' and returns the 16 bytes in *p
* We are compiled with -fPIC, so we can't clobber ebx.
*/
static
inline
void
do_x86cpuid
(
unsigned
int
ax
,
unsigned
int
*
p
)
{
#if defined(__GNUC__) && defined(__i386__)
__asm__
(
"pushl %%ebx
\n\t
"
#ifdef __i386__
extern
void
do_x86cpuid
(
unsigned
int
ax
,
unsigned
int
*
p
);
__ASM_GLOBAL_FUNC
(
do_x86cpuid
,
"pushl %esi
\n\t
"
"pushl %ebx
\n\t
"
"movl 12(%esp),%eax
\n\t
"
"movl 16(%esp),%esi
\n\t
"
"cpuid
\n\t
"
"movl %%ebx, %%esi
\n\t
"
"popl %%ebx"
:
"=a"
(
p
[
0
]),
"=S"
(
p
[
1
]),
"=c"
(
p
[
2
]),
"=d"
(
p
[
3
])
:
"0"
(
ax
));
#endif
"movl %eax,(%esi)
\n\t
"
"movl %ebx,4(%esi)
\n\t
"
"movl %ecx,8(%esi)
\n\t
"
"movl %edx,12(%esi)
\n\t
"
"popl %ebx
\n\t
"
"popl %esi
\n\t
"
"ret"
)
#else
static
void
do_x86cpuid
(
unsigned
int
ax
,
unsigned
int
*
p
)
{
}
#endif
/* From xf86info havecpuid.c 1.11 */
static
inline
int
have_x86cpuid
(
void
)
...
...
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