Anyone can understand how gettimeofday works?
gettimeofday is a syscall of x86-86 according to this page (just search gettimeofday in the box): int gettimeofday(struct timeval *tv, struct timezone *tz); I thought the disas should be easy anough, just prepare the two pointers and call the related syscall . But its disas is doing much more: (gdb) disas gettimeofday Dump of assembler code for function gettimeofday: 0x00000034f408c2d0 <gettimeofday+0>: sub $0x8,%rsp 0x00000034f408c2d4 <gettimeofday+4>: mov $0xffffffffff600000,%rax 0x00000034f408c2db <gettimeofday+11>: callq *%rax 0x00000034f408c2dd <gettimeofday+13>: cmp $0xfffff001,%eax