Add compare-mode-next-solver

This commit is contained in:
Michael Goulet 2023-01-20 02:05:57 +00:00
parent 21f6839352
commit 2489889231
3 changed files with 7 additions and 0 deletions

View File

@ -123,6 +123,7 @@ pub enum FailMode {
pub enum CompareMode {
Polonius,
Chalk,
NextSolver,
SplitDwarf,
SplitDwarfSingle,
}
@ -132,6 +133,7 @@ impl CompareMode {
match *self {
CompareMode::Polonius => "polonius",
CompareMode::Chalk => "chalk",
CompareMode::NextSolver => "next-solver",
CompareMode::SplitDwarf => "split-dwarf",
CompareMode::SplitDwarfSingle => "split-dwarf-single",
}
@ -141,6 +143,7 @@ impl CompareMode {
match s.as_str() {
"polonius" => CompareMode::Polonius,
"chalk" => CompareMode::Chalk,
"next-solver" => CompareMode::NextSolver,
"split-dwarf" => CompareMode::SplitDwarf,
"split-dwarf-single" => CompareMode::SplitDwarfSingle,
x => panic!("unknown --compare-mode option: {}", x),

View File

@ -701,6 +701,7 @@ impl Config {
match self.compare_mode {
Some(CompareMode::Polonius) => name == "compare-mode-polonius",
Some(CompareMode::Chalk) => name == "compare-mode-chalk",
Some(CompareMode::NextSolver) => name == "compare-mode-next-solver",
Some(CompareMode::SplitDwarf) => name == "compare-mode-split-dwarf",
Some(CompareMode::SplitDwarfSingle) => name == "compare-mode-split-dwarf-single",
None => false,

View File

@ -2013,6 +2013,9 @@ impl<'test> TestCx<'test> {
Some(CompareMode::Chalk) => {
rustc.args(&["-Ztrait-solver=chalk"]);
}
Some(CompareMode::NextSolver) => {
rustc.args(&["-Ztrait-solver=next"]);
}
Some(CompareMode::SplitDwarf) if self.config.target.contains("windows") => {
rustc.args(&["-Csplit-debuginfo=unpacked", "-Zunstable-options"]);
}