Do not flood on copy_nonoverlapping.

This commit is contained in:
Camille GILLOT 2023-04-25 19:50:22 +00:00
parent add5124dce
commit 79c073746b

View File

@ -123,16 +123,18 @@ pub trait ValueAnalysis<'tcx> {
fn super_intrinsic( fn super_intrinsic(
&self, &self,
intrinsic: &NonDivergingIntrinsic<'tcx>, intrinsic: &NonDivergingIntrinsic<'tcx>,
state: &mut State<Self::Value>, _state: &mut State<Self::Value>,
) { ) {
match intrinsic { match intrinsic {
NonDivergingIntrinsic::Assume(..) => { NonDivergingIntrinsic::Assume(..) => {
// Could use this, but ignoring it is sound. // Could use this, but ignoring it is sound.
} }
NonDivergingIntrinsic::CopyNonOverlapping(CopyNonOverlapping { dst, .. }) => { NonDivergingIntrinsic::CopyNonOverlapping(CopyNonOverlapping {
if let Some(place) = dst.place() { dst: _,
state.flood(place.as_ref(), self.map()); src: _,
} count: _,
}) => {
// This statement represents `*dst = *src`, `count` times.
} }
} }
} }