Tell the compiler that rdtscp clobbers %ecx.
This commit is contained in:
parent
d06e21760c
commit
e402a8384b
@ -391,7 +391,7 @@ rdtscp(void)
|
||||
{
|
||||
uint32_t low, high;
|
||||
|
||||
__asm __volatile("rdtscp" : "=a" (low), "=d" (high));
|
||||
__asm __volatile("rdtscp" : "=a" (low), "=d" (high) : : "ecx");
|
||||
return (low | ((uint64_t)high << 32));
|
||||
}
|
||||
|
||||
|
@ -373,7 +373,7 @@ rdtscp(void)
|
||||
{
|
||||
uint64_t rv;
|
||||
|
||||
__asm __volatile("rdtscp" : "=A" (rv));
|
||||
__asm __volatile("rdtscp" : "=A" (rv) : : "ecx");
|
||||
return (rv);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user