~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/internal/my_pthread.h

  • Committer: Joseph Daly
  • Date: 2010-08-09 00:00:11 UTC
  • mto: (1698.2.1 build)
  • mto: This revision was merged to the branch mainline in revision 1699.
  • Revision ID: jdaly@rx7-20100809000011-fd17skydw7zcrtb9
remove increment calls

Show diffs side-by-side

added added

removed removed

Lines of Context:
194
194
        (pthread_mutex_lock((L)), (V)-=(C), pthread_mutex_unlock((L)))
195
195
#endif
196
196
 
197
 
/*
198
 
  statistics_xxx functions are for non critical statistic,
199
 
  maintained in global variables.
200
 
  - race conditions can occur, making the result slightly inaccurate.
201
 
  - the lock given is not honored.
202
 
*/
203
 
#define statistic_decrement(V,L) (V)--
204
 
#define statistic_increment(V,L) (V)++
205
 
#define statistic_add(V,C,L)     (V)+=(C)
206
 
#define statistic_sub(V,C,L)     (V)-=(C)
207
 
 
208
 
/*
209
 
  No locking needed, the counter is owned by the thread
210
 
*/
211
 
#define status_var_increment(V) (V)++
212
 
#define status_var_decrement(V) (V)--
213
 
#define status_var_add(V,C)     (V)+=(C)
214
 
#define status_var_sub(V,C)     (V)-=(C)
215
 
 
216
197
} /* namespace internal */
217
198
} /* namespace drizzled */
218
199