From: Maria Matejka Date: Mon, 7 Nov 2022 09:28:01 +0000 (+0100) Subject: Merge commit '37b64441' into thread-next X-Git-Tag: v3.0-alpha1~78 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7bbd0b5a3b670cfbe72df21054465b71a632962f;p=thirdparty%2Fbird.git Merge commit '37b64441' into thread-next --- 7bbd0b5a3b670cfbe72df21054465b71a632962f diff --cc conf/conf.h index ffefa519f,5ec924b02..ce4a3c5a3 --- a/conf/conf.h +++ b/conf/conf.h @@@ -132,11 -132,9 +132,12 @@@ struct symbol struct sym_scope { struct sym_scope *next; /* Next on scope stack */ struct symbol *name; /* Name of this scope */ + + HASH(struct symbol) hash; /* Local symbol hash */ + uint slots; /* Variable slots */ byte active; /* Currently entered */ + byte block; /* No independent stack frame */ byte soft_scopes; /* Number of soft scopes above */ }; diff --cc nest/cmds.c index 8a5bbdd46,bcc8d6c29..6717be0c2 --- a/nest/cmds.c +++ b/nest/cmds.c @@@ -118,12 -118,11 +118,13 @@@ cmd_show_memory(void print_size("Routing tables:", rmemsize(rt_table_pool)); print_size("Route attributes:", rmemsize(rta_pool)); print_size("Protocols:", rmemsize(proto_pool)); + print_size("Current config:", rmemsize(config_pool)); struct resmem total = rmemsize(&root_pool); #ifdef HAVE_MMAP - print_size("Standby memory:", (struct resmem) { .overhead = page_size * *pages_kept }); - total.overhead += page_size * *pages_kept; + int pk = atomic_load_explicit(&pages_kept, memory_order_relaxed) + + atomic_load_explicit(&pages_kept_locally, memory_order_relaxed); + print_size("Standby memory:", (struct resmem) { .overhead = page_size * pk }); + total.overhead += page_size * pk; #endif print_size("Total:", total); cli_msg(0, "");