Disable SimplifyBranchSame optimization for now
This commit is contained in:
@@ -544,6 +544,12 @@ pub struct SimplifyBranchSame;
|
|||||||
|
|
||||||
impl<'tcx> MirPass<'tcx> for SimplifyBranchSame {
|
impl<'tcx> MirPass<'tcx> for SimplifyBranchSame {
|
||||||
fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
|
fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
|
||||||
|
// This optimization is disabled by default for now due to
|
||||||
|
// soundness concerns; see issue #89485 and PR #89489.
|
||||||
|
if !tcx.sess.opts.debugging_opts.unsound_mir_opts {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
trace!("Running SimplifyBranchSame on {:?}", body.source);
|
trace!("Running SimplifyBranchSame on {:?}", body.source);
|
||||||
let finder = SimplifyBranchSameOptimizationFinder { body, tcx };
|
let finder = SimplifyBranchSameOptimizationFinder { body, tcx };
|
||||||
let opts = finder.find();
|
let opts = finder.find();
|
||||||
|
|||||||
Reference in New Issue
Block a user