840c0b18e9990fe15416283f869bc8532c1bbf3a
Stefan Schuermans add copyright headers and l...

Stefan Schuermans authored 4 years ago

libuptev/src/timing.h   1) /**
libuptev/src/timing.h   2)  * UProcTrace: User-space Process Tracing
libuptev/src/timing.h   3)  * Copyright 2020: Stefan Schuermans, Aachen, Germany <stefan@schuermans.info>
libuptev/src/timing.h   4)  * Copyleft: GNU LESSER GENERAL PUBLIC LICENSE version 3 (see LICENSE)
libuptev/src/timing.h   5)  */
libuptev/src/timing.h   6) 
Stefan Schuermans rename: lwproctrace -> upro...

Stefan Schuermans authored 4 years ago

libuptev/src/timing.h   7) #ifndef UPTEV_TIMING_H
libuptev/src/timing.h   8) #define UPTEV_TIMING_H
Stefan Schuermans proc_end: add proc_cpu_time

Stefan Schuermans authored 4 years ago

liblwpttr/src/timing.h  9) 
Stefan Schuermans rename: lwproctrace -> upro...

Stefan Schuermans authored 4 years ago

libuptev/src/timing.h  10) #include <uproctrace.pb-c.h>
Stefan Schuermans proc_end: add proc_cpu_time

Stefan Schuermans authored 4 years ago

liblwpttr/src/timing.h 11) 
Stefan Schuermans implement user/sys time + m...

Stefan Schuermans authored 4 years ago

libuptev/src/timing.h  12) #include <sys/time.h>
libuptev/src/timing.h  13) #include <time.h>
libuptev/src/timing.h  14) 
libuptev/src/timing.h  15) /**
libuptev/src/timing.h  16)  * @brief convert timeval to protobuf
libuptev/src/timing.h  17)  * @param[in] ts timeval to convert
libuptev/src/timing.h  18)  * @param[in,out] timestamp initialized structure to set to current time
libuptev/src/timing.h  19)  */
libuptev/src/timing.h  20) void uptev_timing_timeval_to_pb(struct timeval const *tv,
libuptev/src/timing.h  21)                                 struct _Uproctrace__Timespec *tsp);
libuptev/src/timing.h  22) 
libuptev/src/timing.h  23) /**
libuptev/src/timing.h  24)  * @brief convert timespec to protobuf
libuptev/src/timing.h  25)  * @param[in] ts timespec to convert
libuptev/src/timing.h  26)  * @param[in,out] timestamp initialized structure to set to current time
libuptev/src/timing.h  27)  */
libuptev/src/timing.h  28) void uptev_timing_timespec_to_pb(struct timespec const *ts,
libuptev/src/timing.h  29)                                  struct _Uproctrace__Timespec *tsp);
libuptev/src/timing.h  30) 
Stefan Schuermans proc_end: add proc_cpu_time

Stefan Schuermans authored 4 years ago

liblwpttr/src/timing.h 31) /**
liblwpttr/src/timing.h 32)  * @brief fill timestamp with current time
liblwpttr/src/timing.h 33)  * @param[in,out] timestamp initialized structure to set to current time
liblwpttr/src/timing.h 34)  */
Stefan Schuermans rename: lwproctrace -> upro...

Stefan Schuermans authored 4 years ago

libuptev/src/timing.h  35) void uptev_timing_get_timestamp(struct _Uproctrace__Timespec *timestamp);
Stefan Schuermans proc_end: add proc_cpu_time

Stefan Schuermans authored 4 years ago

liblwpttr/src/timing.h 36) 
liblwpttr/src/timing.h 37) /**
liblwpttr/src/timing.h 38)  * @brief fill timestamp with total CPU time used by process
liblwpttr/src/timing.h 39)  * @param[in,out] timestamp initialized structure to set to proccess CPU time
liblwpttr/src/timing.h 40)  */
Stefan Schuermans formatting

Stefan Schuermans authored 4 years ago

libuptev/src/timing.h  41) void uptev_timing_get_proc_cpu_time(
libuptev/src/timing.h  42)     struct _Uproctrace__Timespec *proc_cpu_time);
Stefan Schuermans proc_end: add proc_cpu_time

Stefan Schuermans authored 4 years ago

liblwpttr/src/timing.h 43)