bump rust
This commit is contained in:
parent
0e9e0f2d82
commit
2ff1f24f2b
2 changed files with 6 additions and 6 deletions
|
|
@ -1 +1 @@
|
|||
nightly-2018-11-05
|
||||
nightly-2018-11-07
|
||||
|
|
|
|||
|
|
@ -87,11 +87,11 @@ impl<'a, 'mir, 'tcx> EvalContextExt<'tcx> for super::MiriEvalContext<'a, 'mir, '
|
|||
|
||||
_ if intrinsic_name.starts_with("atomic_cxchg") => {
|
||||
let ptr = self.ref_to_mplace(self.read_immediate(args[0])?)?;
|
||||
let expect_old = self.read_immediate(args[1])?; // read as value for the sake of `binary_op_val()`
|
||||
let expect_old = self.read_immediate(args[1])?; // read as value for the sake of `binary_op_imm()`
|
||||
let new = self.read_scalar(args[2])?;
|
||||
let old = self.read_immediate(ptr.into())?; // read as value for the sake of `binary_op_val()`
|
||||
// binary_op_val will bail if either of them is not a scalar
|
||||
let (eq, _) = self.binary_op_val(mir::BinOp::Eq, old, expect_old)?;
|
||||
let old = self.read_immediate(ptr.into())?; // read as value for the sake of `binary_op_imm()`
|
||||
// binary_op_imm will bail if either of them is not a scalar
|
||||
let (eq, _) = self.binary_op_imm(mir::BinOp::Eq, old, expect_old)?;
|
||||
let res = Immediate::ScalarPair(old.to_scalar_or_undef(), eq.into());
|
||||
self.write_immediate(res, dest)?; // old value is returned
|
||||
// update ptr depending on comparison
|
||||
|
|
@ -234,7 +234,7 @@ impl<'a, 'mir, 'tcx> EvalContextExt<'tcx> for super::MiriEvalContext<'a, 'mir, '
|
|||
let a = self.read_immediate(args[0])?;
|
||||
let b = self.read_immediate(args[1])?;
|
||||
// check x % y != 0
|
||||
if self.binary_op_val(mir::BinOp::Rem, a, b)?.0.to_bytes()? != 0 {
|
||||
if self.binary_op_imm(mir::BinOp::Rem, a, b)?.0.to_bytes()? != 0 {
|
||||
return err!(ValidationFailure(format!("exact_div: {:?} cannot be divided by {:?}", a, b)));
|
||||
}
|
||||
self.binop_ignore_overflow(mir::BinOp::Div, a, b, dest)?;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue