Skip to content

Instantly share code, notes, and snippets.

@RicardasSim
RicardasSim / gist:2e9b06be341b4374697e47034fea0c3f
Last active November 27, 2019 01:10
profiling code, linux, c99
//gcc -std=c99 -Wall -Wextra -Wpedantic -Wshadow main.c
#define _POSIX_C_SOURCE 199309L
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h> //sleep();
#include <time.h>
void printTimeDiff(struct timespec *tm_start, struct timespec *tm_stop)