~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to mysys/my_getsystime.c

Merging Monty's work

Show diffs side-by-side

added added

removed removed

Lines of Context:
139
139
    Value in microseconds from some undefined point in time
140
140
*/
141
141
 
142
 
#define DELTA_FOR_SECONDS 500000000LL  /* Half a second */
143
142
 
144
143
uint64_t my_micro_time_and_time(time_t *time_arg)
145
144
{
148
147
    Solaris has a very slow time() call. We optimize this by using the very
149
148
    fast gethrtime() call and only calling time() every 1/2 second
150
149
  */
 
150
 
 
151
#define DELTA_FOR_SECONDS 500000000LL  /* Half a second */
 
152
 
151
153
  static hrtime_t prev_gethrtime= 0;
152
154
  static time_t cur_time= 0;
153
155
  hrtime_t cur_gethrtime;