Skip to content

Commit

Permalink
Split a bool argument into two named functions
Browse files Browse the repository at this point in the history
  • Loading branch information
oli-obk committed Feb 15, 2024
1 parent 4232e7f commit fda1555
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/shims/intrinsics/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,12 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriInterpCxExt<'mir, 'tcx> {
"volatile_load" => {
let [place] = check_arg_count(args)?;
let place = this.deref_pointer(place)?;
this.copy_op(&place, dest, /*allow_transmute*/ false)?;
this.copy_op(&place, dest)?;
}
"volatile_store" => {
let [place, dest] = check_arg_count(args)?;
let place = this.deref_pointer(place)?;
this.copy_op(dest, &place, /*allow_transmute*/ false)?;
this.copy_op(dest, &place)?;
}

"write_bytes" | "volatile_set_memory" => {
Expand Down
3 changes: 0 additions & 3 deletions src/shims/x86/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,6 @@ fn bin_op_simd_float_first<'tcx, F: rustc_apfloat::Float>(
this.copy_op(
&this.project_index(&left, i)?,
&this.project_index(&dest, i)?,
/*allow_transmute*/ false,
)?;
}

Expand Down Expand Up @@ -424,7 +423,6 @@ fn unary_op_ss<'tcx>(
this.copy_op(
&this.project_index(&op, i)?,
&this.project_index(&dest, i)?,
/*allow_transmute*/ false,
)?;
}

Expand Down Expand Up @@ -484,7 +482,6 @@ fn round_first<'tcx, F: rustc_apfloat::Float>(
this.copy_op(
&this.project_index(&left, i)?,
&this.project_index(&dest, i)?,
/*allow_transmute*/ false,
)?;
}

Expand Down
1 change: 0 additions & 1 deletion src/shims/x86/sse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,6 @@ pub(super) trait EvalContextExt<'mir, 'tcx: 'mir>:
this.copy_op(
&this.project_index(&left, i)?,
&this.project_index(&dest, i)?,
/*allow_transmute*/ false,
)?;
}
}
Expand Down
2 changes: 0 additions & 2 deletions src/shims/x86/sse2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,6 @@ pub(super) trait EvalContextExt<'mir, 'tcx: 'mir>:
this.copy_op(
&this.project_index(&op, i)?,
&this.project_index(&dest, i)?,
/*allow_transmute*/ false,
)?;
}
}
Expand Down Expand Up @@ -584,7 +583,6 @@ pub(super) trait EvalContextExt<'mir, 'tcx: 'mir>:
this.copy_op(
&this.project_index(&left, i)?,
&this.project_index(&dest, i)?,
/*allow_transmute*/ false,
)?;
}
}
Expand Down
1 change: 0 additions & 1 deletion src/shims/x86/sse41.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ pub(super) trait EvalContextExt<'mir, 'tcx: 'mir>:
this.copy_op(
&this.project_index(&left, i)?,
&dest,
/*allow_transmute*/ false,
)?;
}
}
Expand Down

0 comments on commit fda1555

Please sign in to comment.