Handle NonDivergingIntrinsic and CopyNonOverlapping

This commit is contained in:
Jannis Christopher Köhl 2022-10-05 20:19:11 +02:00
parent f99950f6ae
commit eab77320e6

View File

@ -116,10 +116,19 @@ pub trait ValueAnalysis<'tcx> {
fn super_intrinsic(
&self,
_intrinsic: &NonDivergingIntrinsic<'tcx>,
_state: &mut State<Self::Value>,
intrinsic: &NonDivergingIntrinsic<'tcx>,
state: &mut State<Self::Value>,
) {
todo!();
match intrinsic {
NonDivergingIntrinsic::Assume(..) => {
// Could use this, but ignoring it is sound.
}
NonDivergingIntrinsic::CopyNonOverlapping(CopyNonOverlapping { dst, .. }) => {
if let Some(place) = dst.place() {
state.flood(place.as_ref(), self.map());
}
}
}
}
fn handle_assign(