Auto merge of #107406 - cjgillot:eliminate-witnesses, r=compiler-errors
Only compute mir_generator_witnesses query in drop_tracking_mir mode. Attempt to fix the perf regression in https://github.com/rust-lang/rust/pull/101692 r? `@ghost`
This commit is contained in:
commit
bcb064a7f4
3 changed files with 19 additions and 18 deletions
|
@ -1415,7 +1415,7 @@ impl<'a, 'tcx> EncodeContext<'a, 'tcx> {
|
|||
if encode_opt {
|
||||
record!(self.tables.optimized_mir[def_id.to_def_id()] <- tcx.optimized_mir(def_id));
|
||||
|
||||
if let DefKind::Generator = self.tcx.def_kind(def_id) {
|
||||
if let DefKind::Generator = self.tcx.def_kind(def_id) && tcx.sess.opts.unstable_opts.drop_tracking_mir {
|
||||
record!(self.tables.mir_generator_witnesses[def_id.to_def_id()] <- tcx.mir_generator_witnesses(def_id));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue