diff --git a/src/librustdoc/clean/inline.rs b/src/librustdoc/clean/inline.rs index c5e05875819..cb70f465f62 100644 --- a/src/librustdoc/clean/inline.rs +++ b/src/librustdoc/clean/inline.rs @@ -335,6 +335,8 @@ fn merge_attrs( return; } + let _prof_timer = cx.tcx.sess.prof.generic_activity("build_extern_trait_impl"); + let tcx = cx.tcx; let associated_trait = tcx.impl_trait_ref(did); diff --git a/src/librustdoc/passes/collect_trait_impls.rs b/src/librustdoc/passes/collect_trait_impls.rs index 91a0cb413eb..1beb3f2f4ab 100644 --- a/src/librustdoc/passes/collect_trait_impls.rs +++ b/src/librustdoc/passes/collect_trait_impls.rs @@ -31,9 +31,7 @@ for &cnum in cx.tcx.crates(()).iter() { for &(did, _) in cx.tcx.all_trait_implementations(cnum).iter() { - cx.tcx.sess.prof.generic_activity("build_extern_trait_impl").run(|| { - inline::build_impl(cx, None, did, None, &mut new_items); - }); + inline::build_impl(cx, None, did, None, &mut new_items); } }