From 22bc8a01c19b88ecd0b60081322f4ec60032f78f Mon Sep 17 00:00:00 2001 From: Paul Daniel Faria Date: Fri, 4 Oct 2019 11:46:01 -0400 Subject: [PATCH] Add back cache invalidation to basic_blocks_and_local_decls_mut --- src/librustc/mir/mod.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/librustc/mir/mod.rs b/src/librustc/mir/mod.rs index 940f35cf4983..ea9de2fdae82 100644 --- a/src/librustc/mir/mod.rs +++ b/src/librustc/mir/mod.rs @@ -203,7 +203,7 @@ impl<'tcx> Body<'tcx> { #[inline] pub fn basic_blocks_mut(&mut self) -> &mut IndexVec> { - debug!("Clearing predecessors cache at: {:?}", self.span.data()); + debug!("bbm: Clearing predecessors cache for body at: {:?}", self.span.data()); self.predecessors_cache = None; &mut self.basic_blocks } @@ -212,6 +212,8 @@ impl<'tcx> Body<'tcx> { pub fn basic_blocks_and_local_decls_mut( &mut self, ) -> (&mut IndexVec>, &mut LocalDecls<'tcx>) { + debug!("bbaldm: Clearing predecessors cache for body at: {:?}", self.span.data()); + self.predecessors_cache = None; (&mut self.basic_blocks, &mut self.local_decls) }