Fast Auxiliary Space Preconditioning
2.7.7 Aug/28/2022
Loading...
Searching...
No Matches
AuxTiming.c
Go to the documentation of this file.
1
13
#include <time.h>
14
15
#ifdef _OPENMP
16
#include <omp.h>
17
#endif
18
19
#include "
fasp.h
"
20
#include "fasp_functs.h"
21
// #include "sys/time.h" //! call gettimeofday() for struct timeval on Linux system.
22
23
/*---------------------------------*/
24
/*-- Public Functions --*/
25
/*---------------------------------*/
26
37
void
fasp_gettime
(
REAL
* time)
38
{
39
if
(time != NULL) {
40
#ifdef _OPENMP
41
*time = omp_get_wtime();
42
#else
43
*time = (
REAL
)clock() / CLOCKS_PER_SEC;
44
45
//struct timeval t;
46
//gettimeofday(&t, NULL); // Get system time
47
//*time = t.tv_sec + t.tv_usec / 1000000.0;
48
#endif
49
}
50
}
51
52
/*---------------------------------*/
53
/*-- End of File --*/
54
/*---------------------------------*/
fasp_gettime
void fasp_gettime(REAL *time)
Get system time.
Definition:
AuxTiming.c:37
fasp.h
Main header file for the FASP project.
REAL
#define REAL
Definition:
fasp.h:75
base
src
AuxTiming.c
Generated on Sun Jun 2 2024 11:18:00 for Fast Auxiliary Space Preconditioning by
1.9.5