A
ты чего?
Size: a a a
A
d
A
d
A
d
E
A
A
E
0x0F31 rdtsc
d
E
d
E
E
d
d
unsigned long long testfreq() {
auto ts = __rdtsc();
Sleep(1000);
return (__rdtsc() - ts) / 1000000;
}
E
d
d
00000010 <_testfreq>:
unsigned long long testfreq() {
10: 57 push %edi
11: 56 push %esi
12: 83 ec 14 sub $0x14,%esp
/* rdtsc */
extern __inline unsigned long long
__attribute__((__gnu_inline__, __always_inline__, __artificial__))
__rdtsc (void)
{
return __builtin_ia32_rdtsc ();
15: 0f 31 rdtsc
17: 89 c6 mov %eax,%esi
19: 89 d7 mov %edx,%edi
auto ts = __rdtsc();
Sleep(1000);
1b: c7 04 24 e8 03 00 00 movl $0x3e8,(%esp)
22: ff 15 00 00 00 00 call *0x0
28: 83 ec 04 sub $0x4,%esp
2b: 0f 31 rdtsc
return (__rdtsc() - ts) / 1000000;
2d: 29 f0 sub %esi,%eax
2f: c7 44 24 08 40 42 0f movl $0xf4240,0x8(%esp)
36: 00
37: 19 fa sbb %edi,%edx
39: c7 44 24 0c 00 00 00 movl $0x0,0xc(%esp)
40: 00
41: 89 04 24 mov %eax,(%esp)
44: 89 54 24 04 mov %edx,0x4(%esp)
48: e8 00 00 00 00 call 4d <_testfreq+0x3d>
}
4d: 83 c4 14 add $0x14,%esp
50: 5e pop %esi
51: 5f pop %edi
52: c3 ret