fibb_tsc: poprawka timestamp(), zabezpieczenie EBX/RBX
This commit is contained in:
@@ -6,8 +6,11 @@
|
|||||||
.text
|
.text
|
||||||
|
|
||||||
timestamp:
|
timestamp:
|
||||||
|
push %ebx
|
||||||
|
|
||||||
xor %eax, %eax
|
xor %eax, %eax
|
||||||
cpuid
|
cpuid
|
||||||
rdtsc
|
rdtsc
|
||||||
|
|
||||||
|
pop %ebx
|
||||||
ret
|
ret
|
||||||
|
|||||||
@@ -6,6 +6,8 @@
|
|||||||
.text
|
.text
|
||||||
|
|
||||||
timestamp:
|
timestamp:
|
||||||
|
push %rbx
|
||||||
|
|
||||||
xor %rax, %rax
|
xor %rax, %rax
|
||||||
cpuid
|
cpuid
|
||||||
rdtsc
|
rdtsc
|
||||||
@@ -13,4 +15,5 @@ rdtsc
|
|||||||
shl $32, %rdx
|
shl $32, %rdx
|
||||||
or %rdx, %rax
|
or %rdx, %rax
|
||||||
|
|
||||||
|
pop %rbx
|
||||||
ret
|
ret
|
||||||
|
|||||||
Reference in New Issue
Block a user