Permalink
Browse files

Split the main stats counters into their own file.

  • Loading branch information...
1 parent 6b84197 commit 40c0fef63a2e90bab9ea3a5418a3670815fb00ca @bsdphk bsdphk committed Nov 24, 2011
Showing with 366 additions and 321 deletions.
  1. +1 −3 bin/varnishd/cache/cache.h
  2. +1 −3 bin/varnishd/cache/cache_wrk.c
  3. +1 −0 include/Makefile.am
  4. +1 −3 include/tbl/vsc_all.h
  5. +361 −0 include/tbl/vsc_f_main.h
  6. +0 −309 include/tbl/vsc_fields.h
  7. +1 −3 man/vsc2rst.c
@@ -206,12 +206,10 @@ struct acct {
#define L0(t, n)
#define L1(t, n) t n;
#define VSC_F(n, t, l, f, e,d) L##l(t, n)
-#define VSC_DO_MAIN
struct dstat {
-#include "tbl/vsc_fields.h"
+#include "tbl/vsc_f_main.h"
};
#undef VSC_F
-#undef VSC_DO_MAIN
#undef L0
#undef L1
@@ -50,11 +50,9 @@ wrk_sumstat(struct worker *w)
Lck_AssertHeld(&wstat_mtx);
#define L0(n)
#define L1(n) (VSC_C_main->n += w->stats.n)
-#define VSC_DO_MAIN
#define VSC_F(n, t, l, f, d, e) L##l(n);
-#include "tbl/vsc_fields.h"
+#include "tbl/vsc_f_main.h"
#undef VSC_F
-#undef VSC_DO_MAIN
#undef L0
#undef L1
memset(&w->stats, 0, sizeof w->stats);
View
@@ -15,6 +15,7 @@ pkginclude_HEADERS = \
tbl/vrt_stv_var.h \
tbl/vsc_all.h \
tbl/vsc_fields.h \
+ tbl/vsc_f_main.h \
tbl/vsl_tags.h \
vapi/vsm.h \
vapi/vsm_int.h \
View
@@ -36,9 +36,7 @@ VSC_DO(LCK, lck, VSC_TYPE_LCK)
VSC_DONE(LCK, lck, VSC_TYPE_LCK)
VSC_DO(MAIN, main, VSC_TYPE_MAIN)
-#define VSC_DO_MAIN
-#include "tbl/vsc_fields.h"
-#undef VSC_DO_MAIN
+#include "tbl/vsc_f_main.h"
VSC_DONE(MAIN, main, VSC_TYPE_MAIN)
VSC_DO(SMA, sma, VSC_TYPE_SMA)
Oops, something went wrong.

0 comments on commit 40c0fef

Please sign in to comment.