diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | src/or/circuituse.c | 5 | ||||
-rw-r--r-- | src/or/routerlist.c | 2 |
3 files changed, 9 insertions, 2 deletions
@@ -53,6 +53,10 @@ Changes in version 0.1.2.8-alpha - 2007-??-?? - Add STREAM_BW events to report per-entry-stream bandwidth use. (Patch from Robert Hogan.) + o Minor bugfixes (performance): + - Call router_have_min_dir_info half as often. (This is showing up in + some profiles, but not others.) + o Minor features: - Remove some never-implemented options. Mark PathlenCoinWeight as obsolete. diff --git a/src/or/circuituse.c b/src/or/circuituse.c index 6cc7f54f07..e85b7c0b4a 100644 --- a/src/or/circuituse.c +++ b/src/or/circuituse.c @@ -445,7 +445,10 @@ circuit_build_needed_circs(time_t now) connection_ap_attach_pending(); /* make sure any hidden services have enough intro points */ - if (router_have_minimum_dir_info()) + /* XXXX012 circuit_build_needed_circs is only called at all if + * router_have_minimum_dir_info is true; this check is redundant, + * and it appears to show up on some people's profiles. */ + if (1 || router_have_minimum_dir_info()) rend_services_introduce(); if (time_to_new_circuit < now) { diff --git a/src/or/routerlist.c b/src/or/routerlist.c index dc3f85c941..76e34aa515 100644 --- a/src/or/routerlist.c +++ b/src/or/routerlist.c @@ -4154,7 +4154,7 @@ static int need_to_update_have_min_dir_info = 1; int router_have_minimum_dir_info(void) { - if (need_to_update_have_min_dir_info) { + if (PREDICT_FALSE(need_to_update_have_min_dir_info)) { update_router_have_minimum_dir_info(); need_to_update_have_min_dir_info = 0; } |