From ddbd423f54e2fd92659a0d277ee844659eee8ba1 Mon Sep 17 00:00:00 2001 From: Gertjan van den Burg Date: Wed, 15 Jan 2014 00:35:21 +0100 Subject: added documentation, restart git usage, start implementing kernels --- src/timer.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'src/timer.c') diff --git a/src/timer.c b/src/timer.c index 2187fb2..3a763a0 100644 --- a/src/timer.c +++ b/src/timer.c @@ -1,7 +1,25 @@ +/** + * @file timer.c + * @author Gertjan van den Burg + * @date January, 2014 + * @brief Function for calculating time difference + * + * @details + * This file contains a simple function for calculating the time in seconds + * elapsed between two clock() calls. + */ + #include #include "timer.h" +/** + * @brief Calculate the time between two clocks + * + * @param[in] s_time starting time + * @param[in] e_time end time + * @returns time elapsed in seconds + */ double elapsed_time(clock_t s_time, clock_t e_time) { return ((double) (e_time - s_time))/((double) CLOCKS_PER_SEC); -- cgit v1.2.3