Closed billyauhk closed 5 years ago
Hello, thanks for the report. It seems your CPU doesn't have RDTSCP instruction so it uses another code path that unfortunately doesn't work in user-space - my fault, I just implemented it based on an Intel paper without checking it has to run in kernel-space.
I will fix this tonight, however I'm not sure about the max error
Thanks for the explanation. I have to look up Intel manual and confirmed that RDTSCP is not available (It says "Support for RDTSCP is indicated by CPUID.80000001H:EDX[27]").
So "the other code path" is using RDTSC+CPUID to achieve the same effect but I still cannot understand why "mov %cr0, %rax" is generated (and why "mov %rax, %cr0" next to it). Any pointers to relevant portion of the code in the repository?
Closing as this should already be fixed.
When trying to run cult on older CPUs (to be exact, U7300, family 6 model 23 stepping 10), segfault occurs. GDB is pointing the error to the "mov %cr0, %rax" line in the following dump:
(Also attached here the CPUID dump)