Guart statistics by option.

This commit is contained in:
Dale Weiler 2013-06-02 00:07:54 +00:00
parent 280dfdd3f8
commit 121e080697
3 changed files with 7 additions and 3 deletions

1
main.c
View file

@ -173,6 +173,7 @@ static bool options_parse(int argc, char **argv) {
OPTS_OPTION_U32(OPTION_STANDARD) = COMPILER_GMQCC;
OPTS_OPTION_BOOL(OPTION_STATISTICS) = true;
} else if (!strcmp(argarg, "qcc")) {

View file

@ -121,6 +121,7 @@
GMQCC_DEFINE_FLAG(MAX_ARRAY_SIZE)
GMQCC_DEFINE_FLAG(ADD_INFO)
GMQCC_DEFINE_FLAG(CORRECTION)
GMQCC_DEFINE_FLAG(STATISTICS)
#endif
/* some cleanup so we don't have to */

8
util.c
View file

@ -181,9 +181,11 @@ void util_meminfo() {
}
}
con_out("Additional Statistics:\n Total vectors used: %lu\n",
vectors
);
if (OPTS_OPTION_BOOL(OPTION_STATISTICS)) {
con_out("Additional Statistics:\n Total vectors used: %lu\n",
vectors
);
}
if (OPTS_OPTION_BOOL(OPTION_DEBUG) ||
OPTS_OPTION_BOOL(OPTION_MEMCHK)) {