#include <stdio.h>
#include <time.h>
#include "../base.h"

int main()
{
	struct timespec start, stop;
	struct timespec start2, stop2;
	double diff_time;

	clock_gettime(CLOCK_MONOTONIC, &start);
	clock_gettime(CLOCK_MONOTONIC, &stop);

	clock_gettime(CLOCK_MONOTONIC, &start2);
	for (int i=0; i<1000; i++) {
		diff_time = calc_diff_time(&start, &stop);
		printf("%f\n", diff_time);
	}
	clock_gettime(CLOCK_MONOTONIC, &stop2);
	printf("The time of calc: %f\n", calc_diff_time(&start2, &stop2));
}
