Skip to content

Commit 5a1b09e

Browse files
committed
Auto merge of rust-lang#2190 - RalfJung:rustup, r=RalfJung
rustup Cc rust-lang#97745
2 parents 92c2e3c + 32c0308 commit 5a1b09e

File tree

3 files changed

+6
-1
lines changed

3 files changed

+6
-1
lines changed

rust-version

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
c35035cefc709abddabfb28ecc6a326458d46ce2
1+
4e725bad73747a4c93a3ac53106e4b4006edc665

src/shims/windows/dlsym.rs

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ impl Dlsym {
1818
pub fn from_str<'tcx>(name: &str) -> InterpResult<'tcx, Option<Dlsym>> {
1919
Ok(match name {
2020
"GetSystemTimePreciseAsFileTime" => None,
21+
"SetThreadDescription" => None,
2122
"NtWriteFile" => Some(Dlsym::NtWriteFile),
2223
_ => throw_unsup_format!("unsupported Windows dlsym: {}", name),
2324
})

src/shims/windows/foreign_items.rs

+4
Original file line numberDiff line numberDiff line change
@@ -415,6 +415,10 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
415415
// There is only one thread, so this always succeeds and returns TRUE.
416416
this.write_scalar(Scalar::from_i32(1), dest)?;
417417
}
418+
"GetCurrentThread" if this.frame_in_std() => {
419+
let [] = this.check_shim(abi, Abi::System { unwind: false }, link_name, args)?;
420+
this.write_scalar(Scalar::from_machine_isize(1, this), dest)?;
421+
}
418422

419423
_ => return Ok(EmulateByNameResult::NotSupported),
420424
}

0 commit comments

Comments
 (0)