@@ -73,7 +73,7 @@ struct Opts {
73
73
default_value = "error" ,
74
74
help = "Custom regression definition" ,
75
75
long_help = "Custom regression definition \
76
- [error|non-error|ice|success]"
76
+ [error|non-error|ice|non-ice| success]"
77
77
) ]
78
78
regress : String ,
79
79
@@ -563,6 +563,9 @@ impl Config {
563
563
( OutputProcessingMode :: RegressOnIceAlone , _) => {
564
564
if saw_ice ( ) { TestOutcome :: Regressed } else { TestOutcome :: Baseline }
565
565
}
566
+ ( OutputProcessingMode :: RegressOnNotIce , _) => {
567
+ if saw_ice ( ) { TestOutcome :: Baseline } else { TestOutcome :: Regressed }
568
+ }
566
569
567
570
( OutputProcessingMode :: RegressOnNonCleanError , true ) => TestOutcome :: Regressed ,
568
571
( OutputProcessingMode :: RegressOnNonCleanError , false ) => {
@@ -578,6 +581,7 @@ impl Config {
578
581
"error" => OutputProcessingMode :: RegressOnErrorStatus ,
579
582
"non-error" => OutputProcessingMode :: RegressOnNonCleanError ,
580
583
"ice" => OutputProcessingMode :: RegressOnIceAlone ,
584
+ "non-ice" => OutputProcessingMode :: RegressOnNotIce ,
581
585
"success" => OutputProcessingMode :: RegressOnSuccessStatus ,
582
586
setting => panic ! ( "Unknown --regress setting: {:?}" , setting) ,
583
587
}
@@ -616,6 +620,14 @@ enum OutputProcessingMode {
616
620
/// You explicitly opt into this seting via `--regress=ice`.
617
621
RegressOnIceAlone ,
618
622
623
+ /// `RegressOnNotIce`: Marks test outcome as `Regressed` if and only if
624
+ /// the `rustc` process does not issue a diagnostic indicating that an
625
+ /// internal compiler error (ICE) occurred. This covers the use case for
626
+ /// when you want to bisect to see when an ICE was fixed.
627
+ ///
628
+ /// You explicitly opt into this setting via `--regress=non-ice`
629
+ RegressOnNotIce ,
630
+
619
631
/// `RegressOnNonCleanError`: Marks test outcome as `Baseline` if and only
620
632
/// if the `rustc` process reports error status and does not issue any
621
633
/// diagnostic indicating that an internal compiler error (ICE) occurred.
@@ -639,7 +651,8 @@ impl OutputProcessingMode {
639
651
OutputProcessingMode :: RegressOnSuccessStatus => false ,
640
652
641
653
OutputProcessingMode :: RegressOnNonCleanError |
642
- OutputProcessingMode :: RegressOnIceAlone => true ,
654
+ OutputProcessingMode :: RegressOnIceAlone |
655
+ OutputProcessingMode :: RegressOnNotIce => true ,
643
656
}
644
657
}
645
658
}
0 commit comments