From 5aea6849eed83009e300b04ef17786643ead9cbc Mon Sep 17 00:00:00 2001 From: xleroy Date: Sun, 14 Aug 2011 15:41:26 +0000 Subject: Locations.v: add Loc.diff_dec. ia32: lift restriction that 1st arg of ops cannot be ECX (could be useful for a future, better reloading strategy) git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@1711 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e --- backend/Locations.v | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'backend') diff --git a/backend/Locations.v b/backend/Locations.v index 1270e1d..8a0b5ea 100644 --- a/backend/Locations.v +++ b/backend/Locations.v @@ -280,6 +280,15 @@ Module Loc. apply overlap_aux_false_1. exact H0. Qed. + Definition diff_dec (l1 l2: loc) : { Loc.diff l1 l2 } + {~Loc.diff l1 l2}. + Proof. + intros. case (eq l1 l2); intros. + right. rewrite e. apply same_not_diff. + case_eq (overlap l1 l2); intros. + right. apply overlap_not_diff; auto. + left. apply non_overlap_diff; auto. + Qed. + (** We now redefine some standard notions over lists, using the [Loc.diff] predicate instead of standard disequality [<>]. -- cgit v1.2.3