Skip to content

Commit 4d76dd1

Browse files
committed
temporarily disable validation on Windows
1 parent 9b58492 commit 4d76dd1

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

src/eval.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,16 @@ pub fn create_ecx<'mir, 'tcx: 'mir>(
3535
Evaluator::new(),
3636
);
3737

38+
// FIXME(https://github.com/rust-lang/miri/pull/803): no validation on Windows.
39+
let target_os = ecx.tcx.tcx.sess.target.target.target_os.to_lowercase();
40+
let validate = if target_os == "windows" {
41+
false
42+
} else {
43+
config.validate
44+
};
45+
3846
// FIXME: InterpretCx::new should take an initial MemoryExtra
39-
ecx.memory_mut().extra = MemoryExtra::new(config.seed.map(StdRng::seed_from_u64), config.validate);
47+
ecx.memory_mut().extra = MemoryExtra::new(config.seed.map(StdRng::seed_from_u64), validate);
4048

4149
let main_instance = ty::Instance::mono(ecx.tcx.tcx, main_id);
4250
let main_mir = ecx.load_mir(main_instance.def)?;

tests/compiletest.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@ fn miri_pass(path: &str, target: &str, opt: bool, noseed: bool) {
8383
flags.push("-Zmir-opt-level=3".to_owned());
8484
} else if !noseed {
8585
// Run with intptrcast. Avoid test matrix explosion by doing either this or opt-level=3.
86-
#[cfg(not(windows))] // FIXME re-enable on Windows
8786
flags.push("-Zmiri-seed=".to_owned());
8887
}
8988

@@ -113,7 +112,9 @@ fn run_pass_miri(opt: bool) {
113112
}
114113

115114
fn compile_fail_miri(opt: bool) {
116-
compile_fail("tests/compile-fail", &get_target(), opt);
115+
if !cfg!(windows) { // FIXME re-enable on Windows
116+
compile_fail("tests/compile-fail", &get_target(), opt);
117+
}
117118
}
118119

119120
fn test_runner(_tests: &[&()]) {

0 commit comments

Comments
 (0)