rdtsc intrinsics

PHOTO EMBED

Mon Oct 25 2021 13:57:16 GMT+0000 (UTC)

Saved by @luisjdominguezp #c #c++

// rdtsc.cpp
// processor: x86, x64
#include <stdio.h>
#include <intrin.h>

#pragma intrinsic(__rdtsc)

int main()
{
    unsigned __int64 i;
    i = __rdtsc();
    printf_s("%I64d ticks\n", i);
}
content_copyCOPY