iPXE
Functions
profile.h File Reference

Profiling. More...

#include <stdint.h>

Go to the source code of this file.

Functions

 FILE_LICENCE (GPL2_OR_LATER_OR_UBDL)
static __attribute__ ((always_inline)) uint64_t profile_timestamp(void)
 Get profiling timestamp.

Detailed Description

Profiling.

Definition in file profile.h.


Function Documentation

FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL  )
static __attribute__ ( (always_inline)  ) [inline, static]

Get profiling timestamp.

Return values:
timestampTimestamp

Definition at line 19 of file profile.h.

References __asm__().

                           {
        uint64_t tsc;

        /* Read timestamp counter */
        __asm__ __volatile__ ( "rdtsc" : "=A" ( tsc ) );
        return tsc;
}