diff options
author | reillyg <reillyg@chromium.org> | 2015-02-09 12:18:33 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-02-09 20:19:19 +0000 |
commit | 9a77a7236aeab865e82dcb0baef21ab6e039cd2b (patch) | |
tree | 38b03be4cfb2ef13d1dbd94edda2350b8559f20d /net/cert/nss_cert_database.cc | |
parent | c4f022a6bd3426307459d3773a0b86553d3efeea (diff) | |
download | chromium_src-9a77a7236aeab865e82dcb0baef21ab6e039cd2b.zip chromium_src-9a77a7236aeab865e82dcb0baef21ab6e039cd2b.tar.gz chromium_src-9a77a7236aeab865e82dcb0baef21ab6e039cd2b.tar.bz2 |
Pass FROM_HERE to ObserverListThreadSafe::Notify to improve profile.
ObserverListThreadSafe::Notify is the 4th most called function in a
profile generated on my host. This is because all tasks posted from it
are stamped with this callsite, providing very little information.
This patch forces callers to pass in their own tracking data so that
the profile will differentiate between each observer list holder.
TBR=garykac@chromium.org,rdsmith@chromium.org,stuartmorgan@chromium.org,gbillock@chromium.org
Review URL: https://codereview.chromium.org/877993003
Cr-Commit-Position: refs/heads/master@{#315372}
Diffstat (limited to 'net/cert/nss_cert_database.cc')
-rw-r--r-- | net/cert/nss_cert_database.cc | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/net/cert/nss_cert_database.cc b/net/cert/nss_cert_database.cc index 8e9c692d..e1b3198 100644 --- a/net/cert/nss_cert_database.cc +++ b/net/cert/nss_cert_database.cc @@ -438,18 +438,20 @@ void NSSCertDatabase::NotifyCertRemovalAndCallBack( } void NSSCertDatabase::NotifyObserversOfCertAdded(const X509Certificate* cert) { - observer_list_->Notify(&Observer::OnCertAdded, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCertAdded, + make_scoped_refptr(cert)); } void NSSCertDatabase::NotifyObserversOfCertRemoved( const X509Certificate* cert) { - observer_list_->Notify(&Observer::OnCertRemoved, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCertRemoved, + make_scoped_refptr(cert)); } void NSSCertDatabase::NotifyObserversOfCACertChanged( const X509Certificate* cert) { - observer_list_->Notify( - &Observer::OnCACertChanged, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCACertChanged, + make_scoped_refptr(cert)); } // static |