summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.depend300
-rw-r--r--Changelog6
-rw-r--r--arm/Asmgenproof.v6
-rw-r--r--arm/Asmgenproof1.v14
-rw-r--r--arm/ConstpropOpproof.v16
-rw-r--r--arm/Op.v12
-rw-r--r--arm/PrintAsm.ml2
-rw-r--r--arm/SelectOpproof.v30
-rw-r--r--backend/CMlexer.mll1
-rw-r--r--backend/CMparser.mly31
-rw-r--r--backend/CMtypecheck.ml6
-rw-r--r--backend/CSEproof.v58
-rw-r--r--backend/Coloringaux.ml6
-rw-r--r--backend/Constpropproof.v20
-rw-r--r--backend/Inliningproof.v10
-rw-r--r--backend/Inliningspec.v6
-rw-r--r--backend/Linearizeaux.ml21
-rw-r--r--backend/PrintCminor.ml9
-rw-r--r--backend/PrintLTLin.ml8
-rw-r--r--backend/PrintMach.ml8
-rw-r--r--backend/PrintRTL.ml12
-rw-r--r--backend/RREproof.v8
-rw-r--r--backend/RREtyping.v4
-rw-r--r--backend/Reloadtyping.v2
-rw-r--r--backend/Renumberproof.v4
-rw-r--r--backend/Selectionproof.v6
-rw-r--r--backend/Stackingproof.v4
-rw-r--r--cfrontend/C2C.ml35
-rw-r--r--cfrontend/Cexec.v181
-rw-r--r--cfrontend/Cminorgenproof.v51
-rw-r--r--cfrontend/Cshmgenproof.v10
-rw-r--r--cfrontend/Cstrategy.v30
-rw-r--r--cfrontend/Initializersproof.v68
-rw-r--r--cfrontend/PrintClight.ml3
-rw-r--r--cfrontend/PrintCsyntax.ml2
-rw-r--r--cfrontend/SimplExpr.v134
-rw-r--r--cfrontend/SimplExprproof.v112
-rw-r--r--cfrontend/SimplExprspec.v212
-rw-r--r--cfrontend/SimplLocalsproof.v52
-rw-r--r--checklink/Asm_printers.ml17
-rw-r--r--checklink/Check.ml11
-rw-r--r--checklink/Frameworks.ml4
-rw-r--r--checklink/Library.ml26
-rw-r--r--common/AST.v12
-rw-r--r--common/Globalenvs.v72
-rw-r--r--common/Memory.v36
-rw-r--r--common/PrintAST.ml2
-rw-r--r--common/Values.v10
-rw-r--r--driver/Compiler.v12
-rw-r--r--driver/Driver.ml7
-rw-r--r--driver/Interp.ml6
-rw-r--r--extraction/extraction.v11
-rw-r--r--ia32/Asmgenproof.v22
-rw-r--r--ia32/Asmgenproof1.v20
-rw-r--r--ia32/ConstpropOpproof.v18
-rw-r--r--ia32/Op.v16
-rw-r--r--ia32/PrintAsm.ml2
-rw-r--r--ia32/SelectOpproof.v36
-rw-r--r--lib/Camlcoq.ml251
-rw-r--r--lib/Coqlib.v8
-rw-r--r--lib/Floats.v12
-rw-r--r--lib/Integers.v10
-rw-r--r--lib/Iteration.v2
-rw-r--r--lib/Postorder.v10
-rw-r--r--powerpc/Asmgenproof1.v2
-rw-r--r--powerpc/ConstpropOpproof.v20
-rw-r--r--powerpc/Op.v16
-rw-r--r--powerpc/PrintAsm.ml2
-rw-r--r--powerpc/SelectOpproof.v24
69 files changed, 1173 insertions, 1024 deletions
diff --git a/.depend b/.depend
index 9a4a2cc..bfaf24f 100644
--- a/.depend
+++ b/.depend
@@ -1,150 +1,150 @@
-lib/Axioms.vo lib/Axioms.glob: lib/Axioms.v
-lib/Coqlib.vo lib/Coqlib.glob: lib/Coqlib.v
-lib/Intv.vo lib/Intv.glob: lib/Intv.v lib/Coqlib.vo
-lib/Maps.vo lib/Maps.glob: lib/Maps.v lib/Coqlib.vo
-lib/Heaps.vo lib/Heaps.glob: lib/Heaps.v lib/Coqlib.vo lib/Ordered.vo
-lib/Lattice.vo lib/Lattice.glob: lib/Lattice.v lib/Coqlib.vo lib/Maps.vo
-lib/Ordered.vo lib/Ordered.glob: lib/Ordered.v lib/Coqlib.vo lib/Maps.vo lib/Integers.vo
-lib/Iteration.vo lib/Iteration.glob: lib/Iteration.v lib/Axioms.vo lib/Coqlib.vo lib/Wfsimpl.vo
-lib/Integers.vo lib/Integers.glob: lib/Integers.v lib/Axioms.vo lib/Coqlib.vo
-lib/Floats.vo lib/Floats.glob: lib/Floats.v lib/Axioms.vo lib/Coqlib.vo lib/Integers.vo flocq/Appli/Fappli_IEEE.vo flocq/Appli/Fappli_IEEE_bits.vo flocq/Core/Fcore.vo flocq/Calc/Fcalc_round.vo flocq/Calc/Fcalc_bracket.vo flocq/Prop/Fprop_Sterbenz.vo
-lib/Parmov.vo lib/Parmov.glob: lib/Parmov.v lib/Axioms.vo lib/Coqlib.vo
-lib/UnionFind.vo lib/UnionFind.glob: lib/UnionFind.v lib/Coqlib.vo
-lib/Wfsimpl.vo lib/Wfsimpl.glob: lib/Wfsimpl.v lib/Axioms.vo
-lib/Postorder.vo lib/Postorder.glob: lib/Postorder.v lib/Coqlib.vo lib/Maps.vo lib/Iteration.vo
-common/Errors.vo common/Errors.glob: common/Errors.v lib/Coqlib.vo
-common/AST.vo common/AST.glob: common/AST.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo lib/Floats.vo
-common/Events.vo common/Events.glob: common/Events.v lib/Coqlib.vo lib/Intv.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Errors.vo
-common/Globalenvs.vo common/Globalenvs.glob: common/Globalenvs.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo
-common/Memdata.vo common/Memdata.glob: common/Memdata.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo
-common/Memtype.vo common/Memtype.glob: common/Memtype.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memdata.vo
-common/Memory.vo common/Memory.glob: common/Memory.v lib/Axioms.vo lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memdata.vo common/Memtype.vo lib/Intv.vo
-common/Values.vo common/Values.glob: common/Values.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo
-common/Smallstep.vo common/Smallstep.glob: common/Smallstep.v lib/Coqlib.vo common/Events.vo common/Globalenvs.vo lib/Integers.vo
-common/Behaviors.vo common/Behaviors.glob: common/Behaviors.v lib/Coqlib.vo common/Events.vo common/Globalenvs.vo lib/Integers.vo common/Smallstep.vo
-common/Switch.vo common/Switch.glob: common/Switch.v lib/Coqlib.vo lib/Integers.vo lib/Ordered.vo
-common/Determinism.vo common/Determinism.glob: common/Determinism.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo common/Behaviors.vo
-backend/Cminor.vo backend/Cminor.glob: backend/Cminor.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Events.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo common/Switch.vo
-$(ARCH)/Op.vo $(ARCH)/Op.glob: $(ARCH)/Op.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Events.vo
-backend/CminorSel.vo backend/CminorSel.glob: backend/CminorSel.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Events.vo common/Values.vo common/Memory.vo backend/Cminor.vo $(ARCH)/Op.vo common/Globalenvs.vo common/Switch.vo common/Smallstep.vo
-$(ARCH)/SelectOp.vo $(ARCH)/SelectOp.glob: $(ARCH)/SelectOp.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/CminorSel.vo
-backend/Selection.vo backend/Selection.glob: backend/Selection.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Globalenvs.vo backend/Cminor.vo $(ARCH)/Op.vo backend/CminorSel.vo $(ARCH)/SelectOp.vo
-$(ARCH)/SelectOpproof.vo $(ARCH)/SelectOpproof.glob: $(ARCH)/SelectOpproof.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo backend/Cminor.vo $(ARCH)/Op.vo backend/CminorSel.vo $(ARCH)/SelectOp.vo
-backend/Selectionproof.vo backend/Selectionproof.glob: backend/Selectionproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo backend/Cminor.vo $(ARCH)/Op.vo backend/CminorSel.vo $(ARCH)/SelectOp.vo backend/Selection.vo $(ARCH)/SelectOpproof.vo
-backend/Registers.vo backend/Registers.glob: backend/Registers.v lib/Coqlib.vo common/AST.vo lib/Maps.vo lib/Ordered.vo
-backend/RTL.vo backend/RTL.glob: backend/RTL.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Events.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo
-backend/RTLgen.vo backend/RTLgen.glob: backend/RTLgen.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Switch.vo $(ARCH)/Op.vo backend/Registers.vo backend/CminorSel.vo backend/RTL.vo
-backend/RTLgenspec.vo backend/RTLgenspec.glob: backend/RTLgenspec.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Switch.vo $(ARCH)/Op.vo backend/Registers.vo backend/CminorSel.vo backend/RTL.vo backend/RTLgen.vo
-backend/RTLgenproof.vo backend/RTLgenproof.glob: backend/RTLgenproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Smallstep.vo common/Globalenvs.vo common/Switch.vo backend/Registers.vo backend/Cminor.vo $(ARCH)/Op.vo backend/CminorSel.vo backend/RTL.vo backend/RTLgen.vo backend/RTLgenspec.vo common/Errors.vo
-backend/Tailcall.vo backend/Tailcall.glob: backend/Tailcall.v lib/Coqlib.vo lib/Maps.vo common/AST.vo backend/Registers.vo $(ARCH)/Op.vo backend/RTL.vo backend/Conventions.vo
-backend/Tailcallproof.vo backend/Tailcallproof.glob: backend/Tailcallproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo $(ARCH)/Op.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo backend/Registers.vo backend/RTL.vo backend/Conventions.vo backend/Tailcall.vo
-backend/Inlining.vo backend/Inlining.glob: backend/Inlining.v lib/Coqlib.vo lib/Wfsimpl.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo
-backend/Inliningspec.vo backend/Inliningspec.glob: backend/Inliningspec.v lib/Coqlib.vo lib/Wfsimpl.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Globalenvs.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/Inlining.vo
-backend/Inliningproof.vo backend/Inliningproof.glob: backend/Inliningproof.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Events.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo backend/Inlining.vo backend/Inliningspec.vo backend/RTL.vo
-backend/Renumber.vo backend/Renumber.glob: backend/Renumber.v lib/Coqlib.vo lib/Maps.vo lib/Postorder.vo backend/RTL.vo
-backend/Renumberproof.vo backend/Renumberproof.glob: backend/Renumberproof.v lib/Coqlib.vo lib/Maps.vo lib/Postorder.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/Renumber.vo
-backend/RTLtyping.vo backend/RTLtyping.glob: backend/RTLtyping.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo common/Globalenvs.vo common/Values.vo lib/Integers.vo common/Events.vo backend/RTL.vo backend/Conventions.vo
-backend/Kildall.vo backend/Kildall.glob: backend/Kildall.v lib/Coqlib.vo lib/Iteration.vo lib/Maps.vo lib/Lattice.vo lib/Heaps.vo
-$(ARCH)/ConstpropOp.vo $(ARCH)/ConstpropOp.glob: $(ARCH)/ConstpropOp.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/Registers.vo
-backend/Constprop.vo backend/Constprop.glob: backend/Constprop.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo lib/Lattice.vo backend/Kildall.vo $(ARCH)/ConstpropOp.vo
-$(ARCH)/ConstpropOpproof.vo $(ARCH)/ConstpropOpproof.glob: $(ARCH)/ConstpropOpproof.v lib/Coqlib.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Events.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo $(ARCH)/ConstpropOp.vo backend/Constprop.vo
-backend/Constpropproof.vo backend/Constpropproof.glob: backend/Constpropproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Events.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo lib/Lattice.vo backend/Kildall.vo $(ARCH)/ConstpropOp.vo backend/Constprop.vo $(ARCH)/ConstpropOpproof.vo
-$(ARCH)/CombineOp.vo $(ARCH)/CombineOp.glob: $(ARCH)/CombineOp.v lib/Coqlib.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo $(ARCH)/SelectOp.vo
-backend/CSE.vo backend/CSE.glob: backend/CSE.v lib/Coqlib.vo lib/Maps.vo common/Errors.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Kildall.vo $(ARCH)/CombineOp.vo
-$(ARCH)/CombineOpproof.vo $(ARCH)/CombineOpproof.glob: $(ARCH)/CombineOpproof.v lib/Coqlib.vo lib/Integers.vo common/Values.vo common/Memory.vo $(ARCH)/Op.vo backend/RTL.vo $(ARCH)/CombineOp.vo backend/CSE.vo
-backend/CSEproof.vo backend/CSEproof.glob: backend/CSEproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo common/Errors.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Kildall.vo $(ARCH)/CombineOp.vo $(ARCH)/CombineOpproof.vo backend/CSE.vo
-$(ARCH)/Machregs.vo $(ARCH)/Machregs.glob: $(ARCH)/Machregs.v lib/Coqlib.vo lib/Maps.vo common/AST.vo
-backend/Locations.vo backend/Locations.glob: backend/Locations.v lib/Coqlib.vo common/AST.vo common/Values.vo $(ARCH)/Machregs.vo
-$(ARCH)/$(VARIANT)/Conventions1.vo $(ARCH)/$(VARIANT)/Conventions1.glob: $(ARCH)/$(VARIANT)/Conventions1.v lib/Coqlib.vo common/AST.vo backend/Locations.vo
-backend/Conventions.vo backend/Conventions.glob: backend/Conventions.v lib/Coqlib.vo common/AST.vo backend/Locations.vo $(ARCH)/$(VARIANT)/Conventions1.vo
-backend/LTL.vo backend/LTL.glob: backend/LTL.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Events.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo
-backend/LTLtyping.vo backend/LTLtyping.glob: backend/LTLtyping.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/Conventions.vo
-backend/InterfGraph.vo backend/InterfGraph.glob: backend/InterfGraph.v lib/Coqlib.vo lib/Ordered.vo backend/Registers.vo backend/Locations.vo
-backend/Coloring.vo backend/Coloring.glob: backend/Coloring.v lib/Coqlib.vo lib/Maps.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Locations.vo backend/Conventions.vo backend/InterfGraph.vo
-backend/Coloringproof.vo backend/Coloringproof.glob: backend/Coloringproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Locations.vo backend/Conventions.vo backend/InterfGraph.vo backend/Coloring.vo
-backend/Allocation.vo backend/Allocation.glob: backend/Allocation.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Lattice.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Kildall.vo backend/Locations.vo backend/Coloring.vo backend/LTL.vo
-backend/Allocproof.vo backend/Allocproof.glob: backend/Allocproof.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Smallstep.vo common/Globalenvs.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Locations.vo backend/Conventions.vo backend/Coloring.vo backend/Coloringproof.vo backend/Allocation.vo backend/LTL.vo
-backend/Alloctyping.vo backend/Alloctyping.glob: backend/Alloctyping.v lib/Coqlib.vo lib/Maps.vo common/Errors.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/Locations.vo backend/LTL.vo backend/Coloring.vo backend/Coloringproof.vo backend/Allocation.vo backend/Allocproof.vo backend/RTLtyping.vo backend/LTLtyping.vo backend/Conventions.vo
-backend/Tunneling.vo backend/Tunneling.glob: backend/Tunneling.v lib/Coqlib.vo lib/Maps.vo lib/UnionFind.vo common/AST.vo backend/LTL.vo
-backend/Tunnelingproof.vo backend/Tunnelingproof.glob: backend/Tunnelingproof.v lib/Coqlib.vo lib/Maps.vo lib/UnionFind.vo common/AST.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/Tunneling.vo
-backend/Tunnelingtyping.vo backend/Tunnelingtyping.glob: backend/Tunnelingtyping.v lib/Coqlib.vo lib/Maps.vo common/AST.vo backend/LTL.vo backend/LTLtyping.vo backend/Tunneling.vo backend/Tunnelingproof.vo
-backend/LTLin.vo backend/LTLin.glob: backend/LTLin.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo
-backend/LTLintyping.vo backend/LTLintyping.glob: backend/LTLintyping.v lib/Coqlib.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/LTLtyping.vo backend/Conventions.vo
-backend/Linearize.vo backend/Linearize.glob: backend/Linearize.v lib/Coqlib.vo lib/Maps.vo lib/Ordered.vo common/AST.vo common/Errors.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/LTLin.vo backend/Kildall.vo lib/Lattice.vo
-backend/Linearizeproof.vo backend/Linearizeproof.glob: backend/Linearizeproof.v lib/Coqlib.vo lib/Maps.vo lib/Ordered.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Errors.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/LTLtyping.vo backend/LTLin.vo backend/Linearize.vo lib/Lattice.vo
-backend/Linearizetyping.vo backend/Linearizetyping.glob: backend/Linearizetyping.v lib/Coqlib.vo lib/Maps.vo common/Errors.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/LTLtyping.vo backend/LTLin.vo backend/Linearize.vo backend/LTLintyping.vo backend/Conventions.vo
-backend/CleanupLabels.vo backend/CleanupLabels.glob: backend/CleanupLabels.v lib/Coqlib.vo lib/Ordered.vo backend/LTLin.vo
-backend/CleanupLabelsproof.vo backend/CleanupLabelsproof.glob: backend/CleanupLabelsproof.v lib/Coqlib.vo lib/Ordered.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/CleanupLabels.vo
-backend/CleanupLabelstyping.vo backend/CleanupLabelstyping.glob: backend/CleanupLabelstyping.v lib/Coqlib.vo lib/Maps.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/CleanupLabels.vo backend/LTLintyping.vo
-backend/Linear.vo backend/Linear.glob: backend/Linear.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/Conventions.vo
-backend/Lineartyping.vo backend/Lineartyping.glob: backend/Lineartyping.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/Linear.vo backend/Conventions.vo
-backend/Parallelmove.vo backend/Parallelmove.glob: backend/Parallelmove.v lib/Coqlib.vo lib/Parmov.vo common/Values.vo common/AST.vo backend/Locations.vo backend/Conventions.vo
-backend/Reload.vo backend/Reload.glob: backend/Reload.v lib/Coqlib.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/Conventions.vo backend/Parallelmove.vo backend/Linear.vo
-backend/Reloadproof.vo backend/Reloadproof.glob: backend/Reloadproof.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/RTLtyping.vo backend/LTLin.vo backend/LTLintyping.vo backend/Linear.vo backend/Parallelmove.vo backend/Reload.vo
-backend/Reloadtyping.vo backend/Reloadtyping.glob: backend/Reloadtyping.v lib/Coqlib.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/LTLintyping.vo backend/Linear.vo backend/Lineartyping.vo backend/Conventions.vo backend/Parallelmove.vo backend/Reload.vo backend/Reloadproof.vo
-backend/RRE.vo backend/RRE.glob: backend/RRE.v lib/Coqlib.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Linear.vo
-backend/RREproof.vo backend/RREproof.glob: backend/RREproof.v lib/Axioms.vo lib/Coqlib.vo common/AST.vo common/Values.vo common/Globalenvs.vo common/Events.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Linear.vo backend/RRE.vo
-backend/RREtyping.vo backend/RREtyping.glob: backend/RREtyping.v lib/Coqlib.vo common/AST.vo backend/Locations.vo backend/Linear.vo backend/Lineartyping.vo backend/Conventions.vo backend/RRE.vo backend/RREproof.vo
-backend/Mach.vo backend/Mach.glob: backend/Mach.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Globalenvs.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo
-backend/Machtyping.vo backend/Machtyping.glob: backend/Machtyping.v lib/Coqlib.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Mach.vo
-backend/Bounds.vo backend/Bounds.glob: backend/Bounds.v lib/Coqlib.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/Linear.vo backend/Lineartyping.vo backend/Conventions.vo
-$(ARCH)/$(VARIANT)/Stacklayout.vo $(ARCH)/$(VARIANT)/Stacklayout.glob: $(ARCH)/$(VARIANT)/Stacklayout.v lib/Coqlib.vo backend/Bounds.vo
-backend/Stacking.vo backend/Stacking.glob: backend/Stacking.v lib/Coqlib.vo common/Errors.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/Linear.vo backend/Bounds.vo backend/Mach.vo backend/Conventions.vo $(ARCH)/$(VARIANT)/Stacklayout.vo
-backend/Stackingproof.vo backend/Stackingproof.glob: backend/Stackingproof.v lib/Coqlib.vo common/Errors.vo common/AST.vo lib/Integers.vo common/Values.vo $(ARCH)/Op.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo backend/Locations.vo backend/LTL.vo backend/Linear.vo backend/Lineartyping.vo backend/Mach.vo backend/Machsem.vo backend/Bounds.vo backend/Conventions.vo $(ARCH)/$(VARIANT)/Stacklayout.vo backend/Stacking.vo
-backend/Stackingtyping.vo backend/Stackingtyping.glob: backend/Stackingtyping.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Linear.vo backend/Lineartyping.vo backend/Mach.vo backend/Machtyping.vo backend/Bounds.vo $(ARCH)/$(VARIANT)/Stacklayout.vo backend/Stacking.vo backend/Stackingproof.vo
-backend/Machsem.vo backend/Machsem.glob: backend/Machsem.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Mach.vo $(ARCH)/$(VARIANT)/Stacklayout.vo $(ARCH)/Asmgenretaddr.vo
-$(ARCH)/Asm.vo $(ARCH)/Asm.glob: $(ARCH)/Asm.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo backend/Locations.vo $(ARCH)/$(VARIANT)/Stacklayout.vo backend/Conventions.vo
-$(ARCH)/Asmgen.vo $(ARCH)/Asmgen.glob: $(ARCH)/Asmgen.v lib/Coqlib.vo common/Errors.vo common/AST.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/Locations.vo backend/Mach.vo $(ARCH)/Asm.vo
-$(ARCH)/Asmgenretaddr.vo $(ARCH)/Asmgenretaddr.glob: $(ARCH)/Asmgenretaddr.v lib/Coqlib.vo common/AST.vo common/Errors.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/Locations.vo backend/Mach.vo $(ARCH)/Asm.vo $(ARCH)/Asmgen.vo
-$(ARCH)/Asmgenproof1.vo $(ARCH)/Asmgenproof1.glob: $(ARCH)/Asmgenproof1.v lib/Coqlib.vo common/AST.vo common/Errors.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo $(ARCH)/Op.vo backend/Locations.vo backend/Mach.vo backend/Machsem.vo backend/Machtyping.vo $(ARCH)/Asm.vo $(ARCH)/Asmgen.vo backend/Conventions.vo
-$(ARCH)/Asmgenproof.vo $(ARCH)/Asmgenproof.glob: $(ARCH)/Asmgenproof.v lib/Coqlib.vo common/Errors.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Mach.vo backend/Machsem.vo backend/Machtyping.vo backend/Conventions.vo $(ARCH)/Asm.vo $(ARCH)/Asmgen.vo $(ARCH)/Asmgenretaddr.vo $(ARCH)/Asmgenproof1.vo
-cfrontend/Ctypes.vo cfrontend/Ctypes.glob: cfrontend/Ctypes.v lib/Coqlib.vo common/AST.vo common/Errors.vo
-cfrontend/Cop.vo cfrontend/Cop.glob: cfrontend/Cop.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo cfrontend/Ctypes.vo
-cfrontend/Csyntax.vo cfrontend/Csyntax.glob: cfrontend/Csyntax.v lib/Coqlib.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo
-cfrontend/Csem.vo cfrontend/Csem.glob: cfrontend/Csem.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo common/Smallstep.vo
-cfrontend/Cstrategy.vo cfrontend/Cstrategy.glob: cfrontend/Cstrategy.v lib/Axioms.vo lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Csem.vo
-cfrontend/Cexec.vo cfrontend/Cexec.glob: cfrontend/Cexec.v lib/Axioms.vo lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Determinism.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Cstrategy.vo
-cfrontend/Initializers.vo cfrontend/Initializers.glob: cfrontend/Initializers.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo
-cfrontend/Initializersproof.vo cfrontend/Initializersproof.glob: cfrontend/Initializersproof.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Globalenvs.vo common/Events.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Initializers.vo
-cfrontend/SimplExpr.vo cfrontend/SimplExpr.glob: cfrontend/SimplExpr.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Clight.vo
-cfrontend/SimplExprspec.vo cfrontend/SimplExprspec.glob: cfrontend/SimplExprspec.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Memory.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Clight.vo cfrontend/SimplExpr.vo
-cfrontend/SimplExprproof.vo cfrontend/SimplExprproof.glob: cfrontend/SimplExprproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo common/Errors.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Smallstep.vo common/Globalenvs.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Cstrategy.vo cfrontend/Clight.vo cfrontend/SimplExpr.vo cfrontend/SimplExprspec.vo
-cfrontend/Clight.vo cfrontend/Clight.glob: cfrontend/Clight.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo
-cfrontend/ClightBigstep.vo cfrontend/ClightBigstep.glob: cfrontend/ClightBigstep.v lib/Coqlib.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo
-cfrontend/SimplLocals.vo cfrontend/SimplLocals.glob: cfrontend/SimplLocals.v lib/Coqlib.vo lib/Ordered.vo common/Errors.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo
-cfrontend/SimplLocalsproof.vo cfrontend/SimplLocalsproof.glob: cfrontend/SimplLocalsproof.v lib/Coqlib.vo common/Errors.vo lib/Ordered.vo common/AST.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Events.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo cfrontend/SimplLocals.vo
-cfrontend/Cshmgen.vo cfrontend/Cshmgen.glob: cfrontend/Cshmgen.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo lib/Floats.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo backend/Cminor.vo cfrontend/Csharpminor.vo
-cfrontend/Cshmgenproof.vo cfrontend/Cshmgenproof.glob: cfrontend/Cshmgenproof.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/AST.vo common/Values.vo common/Events.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo backend/Cminor.vo cfrontend/Csharpminor.vo cfrontend/Cshmgen.vo
-cfrontend/Csharpminor.vo cfrontend/Csharpminor.glob: cfrontend/Csharpminor.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo backend/Cminor.vo common/Smallstep.vo
-cfrontend/Cminorgen.vo cfrontend/Cminorgen.glob: cfrontend/Cminorgen.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Ordered.vo common/AST.vo lib/Integers.vo lib/Floats.vo cfrontend/Csharpminor.vo backend/Cminor.vo
-cfrontend/Cminorgenproof.vo cfrontend/Cminorgenproof.glob: cfrontend/Cminorgenproof.v lib/Coqlib.vo lib/Intv.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo common/Switch.vo cfrontend/Csharpminor.vo backend/Cminor.vo cfrontend/Cminorgen.vo
-driver/Compiler.vo driver/Compiler.glob: driver/Compiler.v lib/Coqlib.vo common/Errors.vo common/AST.vo common/Smallstep.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Cstrategy.vo cfrontend/Cexec.vo cfrontend/Clight.vo cfrontend/Csharpminor.vo backend/Cminor.vo backend/CminorSel.vo backend/RTL.vo backend/LTL.vo backend/LTLin.vo backend/Linear.vo backend/Mach.vo backend/Machsem.vo $(ARCH)/Asm.vo cfrontend/Initializers.vo cfrontend/SimplExpr.vo cfrontend/SimplLocals.vo cfrontend/Cshmgen.vo cfrontend/Cminorgen.vo backend/Selection.vo backend/RTLgen.vo backend/Tailcall.vo backend/Inlining.vo backend/Renumber.vo backend/Constprop.vo backend/CSE.vo backend/Allocation.vo backend/Tunneling.vo backend/Linearize.vo backend/CleanupLabels.vo backend/Reload.vo backend/RRE.vo backend/Stacking.vo $(ARCH)/Asmgen.vo backend/RTLtyping.vo backend/LTLtyping.vo backend/LTLintyping.vo backend/Lineartyping.vo backend/Machtyping.vo cfrontend/SimplExprproof.vo cfrontend/SimplLocalsproof.vo cfrontend/Cshmgenproof.vo cfrontend/Cminorgenproof.vo backend/Selectionproof.vo backend/RTLgenproof.vo backend/Tailcallproof.vo backend/Inliningproof.vo backend/Renumberproof.vo backend/Constpropproof.vo backend/CSEproof.vo backend/Allocproof.vo backend/Alloctyping.vo backend/Tunnelingproof.vo backend/Tunnelingtyping.vo backend/Linearizeproof.vo backend/Linearizetyping.vo backend/CleanupLabelsproof.vo backend/CleanupLabelstyping.vo backend/Reloadproof.vo backend/Reloadtyping.vo backend/RREproof.vo backend/RREtyping.vo backend/Stackingproof.vo backend/Stackingtyping.vo $(ARCH)/Asmgenproof.vo
-driver/Complements.vo driver/Complements.glob: driver/Complements.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo common/Behaviors.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Cstrategy.vo cfrontend/Clight.vo backend/Cminor.vo backend/RTL.vo $(ARCH)/Asm.vo driver/Compiler.vo common/Errors.vo
-flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_float_prop.glob: flocq/Core/Fcore_float_prop.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo
-flocq/Core/Fcore_Zaux.vo flocq/Core/Fcore_Zaux.glob: flocq/Core/Fcore_Zaux.v
-flocq/Core/Fcore_rnd_ne.vo flocq/Core/Fcore_rnd_ne.glob: flocq/Core/Fcore_rnd_ne.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_ulp.vo
-flocq/Core/Fcore_FTZ.vo flocq/Core/Fcore_FTZ.glob: flocq/Core/Fcore_FTZ.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_FLX.vo
-flocq/Core/Fcore_FLT.vo flocq/Core/Fcore_FLT.glob: flocq/Core/Fcore_FLT.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_FLX.vo flocq/Core/Fcore_FIX.vo flocq/Core/Fcore_rnd_ne.vo
-flocq/Core/Fcore_defs.vo flocq/Core/Fcore_defs.glob: flocq/Core/Fcore_defs.v flocq/Core/Fcore_Raux.vo
-flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_Raux.glob: flocq/Core/Fcore_Raux.v flocq/Core/Fcore_Zaux.vo
-flocq/Core/Fcore_ulp.vo flocq/Core/Fcore_ulp.glob: flocq/Core/Fcore_ulp.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo
-flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_rnd.glob: flocq/Core/Fcore_rnd.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo
-flocq/Core/Fcore_FLX.vo flocq/Core/Fcore_FLX.glob: flocq/Core/Fcore_FLX.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_FIX.vo flocq/Core/Fcore_rnd_ne.vo
-flocq/Core/Fcore_FIX.vo flocq/Core/Fcore_FIX.glob: flocq/Core/Fcore_FIX.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_rnd_ne.vo
-flocq/Core/Fcore_digits.vo flocq/Core/Fcore_digits.glob: flocq/Core/Fcore_digits.v flocq/Core/Fcore_Zaux.vo
-flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_generic_fmt.glob: flocq/Core/Fcore_generic_fmt.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_float_prop.vo
-flocq/Core/Fcore.vo flocq/Core/Fcore.glob: flocq/Core/Fcore.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_rnd_ne.vo flocq/Core/Fcore_FIX.vo flocq/Core/Fcore_FLX.vo flocq/Core/Fcore_FLT.vo flocq/Core/Fcore_ulp.vo
-flocq/Prop/Fprop_Sterbenz.vo flocq/Prop/Fprop_Sterbenz.glob: flocq/Prop/Fprop_Sterbenz.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_generic_fmt.vo flocq/Calc/Fcalc_ops.vo
-flocq/Prop/Fprop_mult_error.vo flocq/Prop/Fprop_mult_error.glob: flocq/Prop/Fprop_mult_error.v flocq/Core/Fcore.vo flocq/Calc/Fcalc_ops.vo
-flocq/Prop/Fprop_relative.vo flocq/Prop/Fprop_relative.glob: flocq/Prop/Fprop_relative.v flocq/Core/Fcore.vo
-flocq/Prop/Fprop_div_sqrt_error.vo flocq/Prop/Fprop_div_sqrt_error.glob: flocq/Prop/Fprop_div_sqrt_error.v flocq/Core/Fcore.vo flocq/Calc/Fcalc_ops.vo flocq/Prop/Fprop_relative.vo
-flocq/Prop/Fprop_plus_error.vo flocq/Prop/Fprop_plus_error.glob: flocq/Prop/Fprop_plus_error.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_generic_fmt.vo flocq/Calc/Fcalc_ops.vo
-flocq/Calc/Fcalc_ops.vo flocq/Calc/Fcalc_ops.glob: flocq/Calc/Fcalc_ops.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo
-flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_bracket.glob: flocq/Calc/Fcalc_bracket.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo
-flocq/Calc/Fcalc_sqrt.vo flocq/Calc/Fcalc_sqrt.glob: flocq/Calc/Fcalc_sqrt.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_digits.vo flocq/Core/Fcore_float_prop.vo flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_digits.vo
-flocq/Calc/Fcalc_div.vo flocq/Calc/Fcalc_div.glob: flocq/Calc/Fcalc_div.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_digits.vo flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_digits.vo
-flocq/Calc/Fcalc_round.vo flocq/Calc/Fcalc_round.glob: flocq/Calc/Fcalc_round.v flocq/Core/Fcore.vo flocq/Core/Fcore_digits.vo flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_digits.vo
-flocq/Calc/Fcalc_digits.vo flocq/Calc/Fcalc_digits.glob: flocq/Calc/Fcalc_digits.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_digits.vo
-flocq/Appli/Fappli_IEEE_bits.vo flocq/Appli/Fappli_IEEE_bits.glob: flocq/Appli/Fappli_IEEE_bits.v flocq/Core/Fcore.vo flocq/Core/Fcore_digits.vo flocq/Calc/Fcalc_digits.vo flocq/Appli/Fappli_IEEE.vo
-flocq/Appli/Fappli_IEEE.vo flocq/Appli/Fappli_IEEE.glob: flocq/Appli/Fappli_IEEE.v flocq/Core/Fcore.vo flocq/Core/Fcore_digits.vo flocq/Calc/Fcalc_digits.vo flocq/Calc/Fcalc_round.vo flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_ops.vo flocq/Calc/Fcalc_div.vo flocq/Calc/Fcalc_sqrt.vo flocq/Prop/Fprop_relative.vo
-exportclight/Clightdefs.vo exportclight/Clightdefs.glob: exportclight/Clightdefs.v lib/Integers.vo lib/Floats.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo
+lib/Axioms.vo lib/Axioms.glob lib/Axioms.v.beautified: lib/Axioms.v
+lib/Coqlib.vo lib/Coqlib.glob lib/Coqlib.v.beautified: lib/Coqlib.v
+lib/Intv.vo lib/Intv.glob lib/Intv.v.beautified: lib/Intv.v lib/Coqlib.vo
+lib/Maps.vo lib/Maps.glob lib/Maps.v.beautified: lib/Maps.v lib/Coqlib.vo
+lib/Heaps.vo lib/Heaps.glob lib/Heaps.v.beautified: lib/Heaps.v lib/Coqlib.vo lib/Ordered.vo
+lib/Lattice.vo lib/Lattice.glob lib/Lattice.v.beautified: lib/Lattice.v lib/Coqlib.vo lib/Maps.vo
+lib/Ordered.vo lib/Ordered.glob lib/Ordered.v.beautified: lib/Ordered.v lib/Coqlib.vo lib/Maps.vo lib/Integers.vo
+lib/Iteration.vo lib/Iteration.glob lib/Iteration.v.beautified: lib/Iteration.v lib/Axioms.vo lib/Coqlib.vo lib/Wfsimpl.vo
+lib/Integers.vo lib/Integers.glob lib/Integers.v.beautified: lib/Integers.v lib/Axioms.vo lib/Coqlib.vo
+lib/Floats.vo lib/Floats.glob lib/Floats.v.beautified: lib/Floats.v lib/Axioms.vo lib/Coqlib.vo lib/Integers.vo flocq/Appli/Fappli_IEEE.vo flocq/Appli/Fappli_IEEE_bits.vo flocq/Core/Fcore.vo flocq/Calc/Fcalc_round.vo flocq/Calc/Fcalc_bracket.vo flocq/Prop/Fprop_Sterbenz.vo
+lib/Parmov.vo lib/Parmov.glob lib/Parmov.v.beautified: lib/Parmov.v lib/Axioms.vo lib/Coqlib.vo
+lib/UnionFind.vo lib/UnionFind.glob lib/UnionFind.v.beautified: lib/UnionFind.v lib/Coqlib.vo
+lib/Wfsimpl.vo lib/Wfsimpl.glob lib/Wfsimpl.v.beautified: lib/Wfsimpl.v lib/Axioms.vo
+lib/Postorder.vo lib/Postorder.glob lib/Postorder.v.beautified: lib/Postorder.v lib/Coqlib.vo lib/Maps.vo lib/Iteration.vo
+common/Errors.vo common/Errors.glob common/Errors.v.beautified: common/Errors.v lib/Coqlib.vo
+common/AST.vo common/AST.glob common/AST.v.beautified: common/AST.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo lib/Floats.vo
+common/Events.vo common/Events.glob common/Events.v.beautified: common/Events.v lib/Coqlib.vo lib/Intv.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Errors.vo
+common/Globalenvs.vo common/Globalenvs.glob common/Globalenvs.v.beautified: common/Globalenvs.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo
+common/Memdata.vo common/Memdata.glob common/Memdata.v.beautified: common/Memdata.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo
+common/Memtype.vo common/Memtype.glob common/Memtype.v.beautified: common/Memtype.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memdata.vo
+common/Memory.vo common/Memory.glob common/Memory.v.beautified: common/Memory.v lib/Axioms.vo lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memdata.vo common/Memtype.vo lib/Intv.vo
+common/Values.vo common/Values.glob common/Values.v.beautified: common/Values.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo
+common/Smallstep.vo common/Smallstep.glob common/Smallstep.v.beautified: common/Smallstep.v lib/Coqlib.vo common/Events.vo common/Globalenvs.vo lib/Integers.vo
+common/Behaviors.vo common/Behaviors.glob common/Behaviors.v.beautified: common/Behaviors.v lib/Coqlib.vo common/Events.vo common/Globalenvs.vo lib/Integers.vo common/Smallstep.vo
+common/Switch.vo common/Switch.glob common/Switch.v.beautified: common/Switch.v lib/Coqlib.vo lib/Integers.vo lib/Ordered.vo
+common/Determinism.vo common/Determinism.glob common/Determinism.v.beautified: common/Determinism.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo common/Behaviors.vo
+backend/Cminor.vo backend/Cminor.glob backend/Cminor.v.beautified: backend/Cminor.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Events.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo common/Switch.vo
+$(ARCH)/Op.vo $(ARCH)/Op.glob $(ARCH)/Op.v.beautified: $(ARCH)/Op.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Events.vo
+backend/CminorSel.vo backend/CminorSel.glob backend/CminorSel.v.beautified: backend/CminorSel.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Events.vo common/Values.vo common/Memory.vo backend/Cminor.vo $(ARCH)/Op.vo common/Globalenvs.vo common/Switch.vo common/Smallstep.vo
+$(ARCH)/SelectOp.vo $(ARCH)/SelectOp.glob $(ARCH)/SelectOp.v.beautified: $(ARCH)/SelectOp.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/CminorSel.vo
+backend/Selection.vo backend/Selection.glob backend/Selection.v.beautified: backend/Selection.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Globalenvs.vo backend/Cminor.vo $(ARCH)/Op.vo backend/CminorSel.vo $(ARCH)/SelectOp.vo
+$(ARCH)/SelectOpproof.vo $(ARCH)/SelectOpproof.glob $(ARCH)/SelectOpproof.v.beautified: $(ARCH)/SelectOpproof.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo backend/Cminor.vo $(ARCH)/Op.vo backend/CminorSel.vo $(ARCH)/SelectOp.vo
+backend/Selectionproof.vo backend/Selectionproof.glob backend/Selectionproof.v.beautified: backend/Selectionproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo backend/Cminor.vo $(ARCH)/Op.vo backend/CminorSel.vo $(ARCH)/SelectOp.vo backend/Selection.vo $(ARCH)/SelectOpproof.vo
+backend/Registers.vo backend/Registers.glob backend/Registers.v.beautified: backend/Registers.v lib/Coqlib.vo common/AST.vo lib/Maps.vo lib/Ordered.vo
+backend/RTL.vo backend/RTL.glob backend/RTL.v.beautified: backend/RTL.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Events.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo
+backend/RTLgen.vo backend/RTLgen.glob backend/RTLgen.v.beautified: backend/RTLgen.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Switch.vo $(ARCH)/Op.vo backend/Registers.vo backend/CminorSel.vo backend/RTL.vo
+backend/RTLgenspec.vo backend/RTLgenspec.glob backend/RTLgenspec.v.beautified: backend/RTLgenspec.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Switch.vo $(ARCH)/Op.vo backend/Registers.vo backend/CminorSel.vo backend/RTL.vo backend/RTLgen.vo
+backend/RTLgenproof.vo backend/RTLgenproof.glob backend/RTLgenproof.v.beautified: backend/RTLgenproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Smallstep.vo common/Globalenvs.vo common/Switch.vo backend/Registers.vo backend/Cminor.vo $(ARCH)/Op.vo backend/CminorSel.vo backend/RTL.vo backend/RTLgen.vo backend/RTLgenspec.vo common/Errors.vo
+backend/Tailcall.vo backend/Tailcall.glob backend/Tailcall.v.beautified: backend/Tailcall.v lib/Coqlib.vo lib/Maps.vo common/AST.vo backend/Registers.vo $(ARCH)/Op.vo backend/RTL.vo backend/Conventions.vo
+backend/Tailcallproof.vo backend/Tailcallproof.glob backend/Tailcallproof.v.beautified: backend/Tailcallproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo $(ARCH)/Op.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo backend/Registers.vo backend/RTL.vo backend/Conventions.vo backend/Tailcall.vo
+backend/Inlining.vo backend/Inlining.glob backend/Inlining.v.beautified: backend/Inlining.v lib/Coqlib.vo lib/Wfsimpl.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo
+backend/Inliningspec.vo backend/Inliningspec.glob backend/Inliningspec.v.beautified: backend/Inliningspec.v lib/Coqlib.vo lib/Wfsimpl.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Globalenvs.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/Inlining.vo
+backend/Inliningproof.vo backend/Inliningproof.glob backend/Inliningproof.v.beautified: backend/Inliningproof.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Events.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo backend/Inlining.vo backend/Inliningspec.vo backend/RTL.vo
+backend/Renumber.vo backend/Renumber.glob backend/Renumber.v.beautified: backend/Renumber.v lib/Coqlib.vo lib/Maps.vo lib/Postorder.vo backend/RTL.vo
+backend/Renumberproof.vo backend/Renumberproof.glob backend/Renumberproof.v.beautified: backend/Renumberproof.v lib/Coqlib.vo lib/Maps.vo lib/Postorder.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/Renumber.vo
+backend/RTLtyping.vo backend/RTLtyping.glob backend/RTLtyping.v.beautified: backend/RTLtyping.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo common/Globalenvs.vo common/Values.vo lib/Integers.vo common/Events.vo backend/RTL.vo backend/Conventions.vo
+backend/Kildall.vo backend/Kildall.glob backend/Kildall.v.beautified: backend/Kildall.v lib/Coqlib.vo lib/Iteration.vo lib/Maps.vo lib/Lattice.vo lib/Heaps.vo
+$(ARCH)/ConstpropOp.vo $(ARCH)/ConstpropOp.glob $(ARCH)/ConstpropOp.v.beautified: $(ARCH)/ConstpropOp.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/Registers.vo
+backend/Constprop.vo backend/Constprop.glob backend/Constprop.v.beautified: backend/Constprop.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo lib/Lattice.vo backend/Kildall.vo $(ARCH)/ConstpropOp.vo
+$(ARCH)/ConstpropOpproof.vo $(ARCH)/ConstpropOpproof.glob $(ARCH)/ConstpropOpproof.v.beautified: $(ARCH)/ConstpropOpproof.v lib/Coqlib.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Events.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo $(ARCH)/ConstpropOp.vo backend/Constprop.vo
+backend/Constpropproof.vo backend/Constpropproof.glob backend/Constpropproof.v.beautified: backend/Constpropproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Events.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo lib/Lattice.vo backend/Kildall.vo $(ARCH)/ConstpropOp.vo backend/Constprop.vo $(ARCH)/ConstpropOpproof.vo
+$(ARCH)/CombineOp.vo $(ARCH)/CombineOp.glob $(ARCH)/CombineOp.v.beautified: $(ARCH)/CombineOp.v lib/Coqlib.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo $(ARCH)/SelectOp.vo
+backend/CSE.vo backend/CSE.glob backend/CSE.v.beautified: backend/CSE.v lib/Coqlib.vo lib/Maps.vo common/Errors.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Kildall.vo $(ARCH)/CombineOp.vo
+$(ARCH)/CombineOpproof.vo $(ARCH)/CombineOpproof.glob $(ARCH)/CombineOpproof.v.beautified: $(ARCH)/CombineOpproof.v lib/Coqlib.vo lib/Integers.vo common/Values.vo common/Memory.vo $(ARCH)/Op.vo backend/RTL.vo $(ARCH)/CombineOp.vo backend/CSE.vo
+backend/CSEproof.vo backend/CSEproof.glob backend/CSEproof.v.beautified: backend/CSEproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo common/Errors.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Kildall.vo $(ARCH)/CombineOp.vo $(ARCH)/CombineOpproof.vo backend/CSE.vo
+$(ARCH)/Machregs.vo $(ARCH)/Machregs.glob $(ARCH)/Machregs.v.beautified: $(ARCH)/Machregs.v lib/Coqlib.vo lib/Maps.vo common/AST.vo
+backend/Locations.vo backend/Locations.glob backend/Locations.v.beautified: backend/Locations.v lib/Coqlib.vo common/AST.vo common/Values.vo $(ARCH)/Machregs.vo
+$(ARCH)/$(VARIANT)/Conventions1.vo $(ARCH)/$(VARIANT)/Conventions1.glob $(ARCH)/$(VARIANT)/Conventions1.v.beautified: $(ARCH)/$(VARIANT)/Conventions1.v lib/Coqlib.vo common/AST.vo backend/Locations.vo
+backend/Conventions.vo backend/Conventions.glob backend/Conventions.v.beautified: backend/Conventions.v lib/Coqlib.vo common/AST.vo backend/Locations.vo $(ARCH)/$(VARIANT)/Conventions1.vo
+backend/LTL.vo backend/LTL.glob backend/LTL.v.beautified: backend/LTL.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Events.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo
+backend/LTLtyping.vo backend/LTLtyping.glob backend/LTLtyping.v.beautified: backend/LTLtyping.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/Conventions.vo
+backend/InterfGraph.vo backend/InterfGraph.glob backend/InterfGraph.v.beautified: backend/InterfGraph.v lib/Coqlib.vo lib/Ordered.vo backend/Registers.vo backend/Locations.vo
+backend/Coloring.vo backend/Coloring.glob backend/Coloring.v.beautified: backend/Coloring.v lib/Coqlib.vo lib/Maps.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Locations.vo backend/Conventions.vo backend/InterfGraph.vo
+backend/Coloringproof.vo backend/Coloringproof.glob backend/Coloringproof.v.beautified: backend/Coloringproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Locations.vo backend/Conventions.vo backend/InterfGraph.vo backend/Coloring.vo
+backend/Allocation.vo backend/Allocation.glob backend/Allocation.v.beautified: backend/Allocation.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Lattice.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Kildall.vo backend/Locations.vo backend/Coloring.vo backend/LTL.vo
+backend/Allocproof.vo backend/Allocproof.glob backend/Allocproof.v.beautified: backend/Allocproof.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Smallstep.vo common/Globalenvs.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/RTLtyping.vo backend/Locations.vo backend/Conventions.vo backend/Coloring.vo backend/Coloringproof.vo backend/Allocation.vo backend/LTL.vo
+backend/Alloctyping.vo backend/Alloctyping.glob backend/Alloctyping.v.beautified: backend/Alloctyping.v lib/Coqlib.vo lib/Maps.vo common/Errors.vo common/AST.vo $(ARCH)/Op.vo backend/Registers.vo backend/RTL.vo backend/Locations.vo backend/LTL.vo backend/Coloring.vo backend/Coloringproof.vo backend/Allocation.vo backend/Allocproof.vo backend/RTLtyping.vo backend/LTLtyping.vo backend/Conventions.vo
+backend/Tunneling.vo backend/Tunneling.glob backend/Tunneling.v.beautified: backend/Tunneling.v lib/Coqlib.vo lib/Maps.vo lib/UnionFind.vo common/AST.vo backend/LTL.vo
+backend/Tunnelingproof.vo backend/Tunnelingproof.glob backend/Tunnelingproof.v.beautified: backend/Tunnelingproof.v lib/Coqlib.vo lib/Maps.vo lib/UnionFind.vo common/AST.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/Tunneling.vo
+backend/Tunnelingtyping.vo backend/Tunnelingtyping.glob backend/Tunnelingtyping.v.beautified: backend/Tunnelingtyping.v lib/Coqlib.vo lib/Maps.vo common/AST.vo backend/LTL.vo backend/LTLtyping.vo backend/Tunneling.vo backend/Tunnelingproof.vo
+backend/LTLin.vo backend/LTLin.glob backend/LTLin.v.beautified: backend/LTLin.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo
+backend/LTLintyping.vo backend/LTLintyping.glob backend/LTLintyping.v.beautified: backend/LTLintyping.v lib/Coqlib.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/LTLtyping.vo backend/Conventions.vo
+backend/Linearize.vo backend/Linearize.glob backend/Linearize.v.beautified: backend/Linearize.v lib/Coqlib.vo lib/Maps.vo lib/Ordered.vo common/AST.vo common/Errors.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/LTLin.vo backend/Kildall.vo lib/Lattice.vo
+backend/Linearizeproof.vo backend/Linearizeproof.glob backend/Linearizeproof.v.beautified: backend/Linearizeproof.v lib/Coqlib.vo lib/Maps.vo lib/Ordered.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Errors.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/LTLtyping.vo backend/LTLin.vo backend/Linearize.vo lib/Lattice.vo
+backend/Linearizetyping.vo backend/Linearizetyping.glob backend/Linearizetyping.v.beautified: backend/Linearizetyping.v lib/Coqlib.vo lib/Maps.vo common/Errors.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/LTLtyping.vo backend/LTLin.vo backend/Linearize.vo backend/LTLintyping.vo backend/Conventions.vo
+backend/CleanupLabels.vo backend/CleanupLabels.glob backend/CleanupLabels.v.beautified: backend/CleanupLabels.v lib/Coqlib.vo lib/Ordered.vo backend/LTLin.vo
+backend/CleanupLabelsproof.vo backend/CleanupLabelsproof.glob backend/CleanupLabelsproof.v.beautified: backend/CleanupLabelsproof.v lib/Coqlib.vo lib/Ordered.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/CleanupLabels.vo
+backend/CleanupLabelstyping.vo backend/CleanupLabelstyping.glob backend/CleanupLabelstyping.v.beautified: backend/CleanupLabelstyping.v lib/Coqlib.vo lib/Maps.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/CleanupLabels.vo backend/LTLintyping.vo
+backend/Linear.vo backend/Linear.glob backend/Linear.v.beautified: backend/Linear.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/Conventions.vo
+backend/Lineartyping.vo backend/Lineartyping.glob backend/Lineartyping.v.beautified: backend/Lineartyping.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTL.vo backend/Linear.vo backend/Conventions.vo
+backend/Parallelmove.vo backend/Parallelmove.glob backend/Parallelmove.v.beautified: backend/Parallelmove.v lib/Coqlib.vo lib/Parmov.vo common/Values.vo common/AST.vo backend/Locations.vo backend/Conventions.vo
+backend/Reload.vo backend/Reload.glob backend/Reload.v.beautified: backend/Reload.v lib/Coqlib.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/Conventions.vo backend/Parallelmove.vo backend/Linear.vo
+backend/Reloadproof.vo backend/Reloadproof.glob backend/Reloadproof.v.beautified: backend/Reloadproof.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/RTLtyping.vo backend/LTLin.vo backend/LTLintyping.vo backend/Linear.vo backend/Parallelmove.vo backend/Reload.vo
+backend/Reloadtyping.vo backend/Reloadtyping.glob backend/Reloadtyping.v.beautified: backend/Reloadtyping.v lib/Coqlib.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/LTLin.vo backend/LTLintyping.vo backend/Linear.vo backend/Lineartyping.vo backend/Conventions.vo backend/Parallelmove.vo backend/Reload.vo backend/Reloadproof.vo
+backend/RRE.vo backend/RRE.glob backend/RRE.v.beautified: backend/RRE.v lib/Coqlib.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Linear.vo
+backend/RREproof.vo backend/RREproof.glob backend/RREproof.v.beautified: backend/RREproof.v lib/Axioms.vo lib/Coqlib.vo common/AST.vo common/Values.vo common/Globalenvs.vo common/Events.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Linear.vo backend/RRE.vo
+backend/RREtyping.vo backend/RREtyping.glob backend/RREtyping.v.beautified: backend/RREtyping.v lib/Coqlib.vo common/AST.vo backend/Locations.vo backend/Linear.vo backend/Lineartyping.vo backend/Conventions.vo backend/RRE.vo backend/RREproof.vo
+backend/Mach.vo backend/Mach.glob backend/Mach.v.beautified: backend/Mach.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo common/Values.vo common/Globalenvs.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo
+backend/Machtyping.vo backend/Machtyping.glob backend/Machtyping.v.beautified: backend/Machtyping.v lib/Coqlib.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Mach.vo
+backend/Bounds.vo backend/Bounds.glob backend/Bounds.v.beautified: backend/Bounds.v lib/Coqlib.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/Linear.vo backend/Lineartyping.vo backend/Conventions.vo
+$(ARCH)/$(VARIANT)/Stacklayout.vo $(ARCH)/$(VARIANT)/Stacklayout.glob $(ARCH)/$(VARIANT)/Stacklayout.v.beautified: $(ARCH)/$(VARIANT)/Stacklayout.v lib/Coqlib.vo backend/Bounds.vo
+backend/Stacking.vo backend/Stacking.glob backend/Stacking.v.beautified: backend/Stacking.v lib/Coqlib.vo common/Errors.vo common/AST.vo lib/Integers.vo $(ARCH)/Op.vo backend/Locations.vo backend/Linear.vo backend/Bounds.vo backend/Mach.vo backend/Conventions.vo $(ARCH)/$(VARIANT)/Stacklayout.vo
+backend/Stackingproof.vo backend/Stackingproof.glob backend/Stackingproof.v.beautified: backend/Stackingproof.v lib/Coqlib.vo common/Errors.vo common/AST.vo lib/Integers.vo common/Values.vo $(ARCH)/Op.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo backend/Locations.vo backend/LTL.vo backend/Linear.vo backend/Lineartyping.vo backend/Mach.vo backend/Machsem.vo backend/Bounds.vo backend/Conventions.vo $(ARCH)/$(VARIANT)/Stacklayout.vo backend/Stacking.vo
+backend/Stackingtyping.vo backend/Stackingtyping.glob backend/Stackingtyping.v.beautified: backend/Stackingtyping.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo common/AST.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Linear.vo backend/Lineartyping.vo backend/Mach.vo backend/Machtyping.vo backend/Bounds.vo $(ARCH)/$(VARIANT)/Stacklayout.vo backend/Stacking.vo backend/Stackingproof.vo
+backend/Machsem.vo backend/Machsem.glob backend/Machsem.v.beautified: backend/Machsem.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Conventions.vo backend/Mach.vo $(ARCH)/$(VARIANT)/Stacklayout.vo $(ARCH)/Asmgenretaddr.vo
+$(ARCH)/Asm.vo $(ARCH)/Asm.glob $(ARCH)/Asm.v.beautified: $(ARCH)/Asm.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo backend/Locations.vo $(ARCH)/$(VARIANT)/Stacklayout.vo backend/Conventions.vo
+$(ARCH)/Asmgen.vo $(ARCH)/Asmgen.glob $(ARCH)/Asmgen.v.beautified: $(ARCH)/Asmgen.v lib/Coqlib.vo common/Errors.vo common/AST.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/Locations.vo backend/Mach.vo $(ARCH)/Asm.vo
+$(ARCH)/Asmgenretaddr.vo $(ARCH)/Asmgenretaddr.glob $(ARCH)/Asmgenretaddr.v.beautified: $(ARCH)/Asmgenretaddr.v lib/Coqlib.vo common/AST.vo common/Errors.vo lib/Integers.vo lib/Floats.vo $(ARCH)/Op.vo backend/Locations.vo backend/Mach.vo $(ARCH)/Asm.vo $(ARCH)/Asmgen.vo
+$(ARCH)/Asmgenproof1.vo $(ARCH)/Asmgenproof1.glob $(ARCH)/Asmgenproof1.v.beautified: $(ARCH)/Asmgenproof1.v lib/Coqlib.vo common/AST.vo common/Errors.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo $(ARCH)/Op.vo backend/Locations.vo backend/Mach.vo backend/Machsem.vo backend/Machtyping.vo $(ARCH)/Asm.vo $(ARCH)/Asmgen.vo backend/Conventions.vo
+$(ARCH)/Asmgenproof.vo $(ARCH)/Asmgenproof.glob $(ARCH)/Asmgenproof.v.beautified: $(ARCH)/Asmgenproof.v lib/Coqlib.vo common/Errors.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo $(ARCH)/Op.vo backend/Locations.vo backend/Mach.vo backend/Machsem.vo backend/Machtyping.vo backend/Conventions.vo $(ARCH)/Asm.vo $(ARCH)/Asmgen.vo $(ARCH)/Asmgenretaddr.vo $(ARCH)/Asmgenproof1.vo
+cfrontend/Ctypes.vo cfrontend/Ctypes.glob cfrontend/Ctypes.v.beautified: cfrontend/Ctypes.v lib/Coqlib.vo common/AST.vo common/Errors.vo
+cfrontend/Cop.vo cfrontend/Cop.glob cfrontend/Cop.v.beautified: cfrontend/Cop.v lib/Coqlib.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo cfrontend/Ctypes.vo
+cfrontend/Csyntax.vo cfrontend/Csyntax.glob cfrontend/Csyntax.v.beautified: cfrontend/Csyntax.v lib/Coqlib.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo
+cfrontend/Csem.vo cfrontend/Csem.glob cfrontend/Csem.v.beautified: cfrontend/Csem.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo common/Smallstep.vo
+cfrontend/Cstrategy.vo cfrontend/Cstrategy.glob cfrontend/Cstrategy.v.beautified: cfrontend/Cstrategy.v lib/Axioms.vo lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Csem.vo
+cfrontend/Cexec.vo cfrontend/Cexec.glob cfrontend/Cexec.v.beautified: cfrontend/Cexec.v lib/Axioms.vo lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Determinism.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Cstrategy.vo
+cfrontend/Initializers.vo cfrontend/Initializers.glob cfrontend/Initializers.v.beautified: cfrontend/Initializers.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo
+cfrontend/Initializersproof.vo cfrontend/Initializersproof.glob cfrontend/Initializersproof.v.beautified: cfrontend/Initializersproof.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Globalenvs.vo common/Events.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Initializers.vo
+cfrontend/SimplExpr.vo cfrontend/SimplExpr.glob cfrontend/SimplExpr.v.beautified: cfrontend/SimplExpr.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Clight.vo
+cfrontend/SimplExprspec.vo cfrontend/SimplExprspec.glob cfrontend/SimplExprspec.v.beautified: cfrontend/SimplExprspec.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Memory.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Clight.vo cfrontend/SimplExpr.vo
+cfrontend/SimplExprproof.vo cfrontend/SimplExprproof.glob cfrontend/SimplExprproof.v.beautified: cfrontend/SimplExprproof.v lib/Coqlib.vo lib/Maps.vo common/AST.vo common/Errors.vo lib/Integers.vo common/Values.vo common/Memory.vo common/Events.vo common/Smallstep.vo common/Globalenvs.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Cstrategy.vo cfrontend/Clight.vo cfrontend/SimplExpr.vo cfrontend/SimplExprspec.vo
+cfrontend/Clight.vo cfrontend/Clight.glob cfrontend/Clight.v.beautified: cfrontend/Clight.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo
+cfrontend/ClightBigstep.vo cfrontend/ClightBigstep.glob cfrontend/ClightBigstep.v.beautified: cfrontend/ClightBigstep.v lib/Coqlib.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/AST.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo
+cfrontend/SimplLocals.vo cfrontend/SimplLocals.glob cfrontend/SimplLocals.v.beautified: cfrontend/SimplLocals.v lib/Coqlib.vo lib/Ordered.vo common/Errors.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo
+cfrontend/SimplLocalsproof.vo cfrontend/SimplLocalsproof.glob cfrontend/SimplLocalsproof.v.beautified: cfrontend/SimplLocalsproof.v lib/Coqlib.vo common/Errors.vo lib/Ordered.vo common/AST.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Globalenvs.vo common/Events.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo cfrontend/SimplLocals.vo
+cfrontend/Cshmgen.vo cfrontend/Cshmgen.glob cfrontend/Cshmgen.v.beautified: cfrontend/Cshmgen.v lib/Coqlib.vo common/Errors.vo lib/Integers.vo lib/Floats.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo backend/Cminor.vo cfrontend/Csharpminor.vo
+cfrontend/Cshmgenproof.vo cfrontend/Cshmgenproof.glob cfrontend/Cshmgenproof.v.beautified: cfrontend/Cshmgenproof.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Integers.vo lib/Floats.vo common/AST.vo common/Values.vo common/Events.vo common/Memory.vo common/Globalenvs.vo common/Smallstep.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo backend/Cminor.vo cfrontend/Csharpminor.vo cfrontend/Cshmgen.vo
+cfrontend/Csharpminor.vo cfrontend/Csharpminor.glob cfrontend/Csharpminor.v.beautified: cfrontend/Csharpminor.v lib/Coqlib.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo backend/Cminor.vo common/Smallstep.vo
+cfrontend/Cminorgen.vo cfrontend/Cminorgen.glob cfrontend/Cminorgen.v.beautified: cfrontend/Cminorgen.v lib/Coqlib.vo common/Errors.vo lib/Maps.vo lib/Ordered.vo common/AST.vo lib/Integers.vo lib/Floats.vo cfrontend/Csharpminor.vo backend/Cminor.vo
+cfrontend/Cminorgenproof.vo cfrontend/Cminorgenproof.glob cfrontend/Cminorgenproof.v.beautified: cfrontend/Cminorgenproof.v lib/Coqlib.vo lib/Intv.vo common/Errors.vo lib/Maps.vo common/AST.vo lib/Integers.vo lib/Floats.vo common/Values.vo common/Memory.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo common/Switch.vo cfrontend/Csharpminor.vo backend/Cminor.vo cfrontend/Cminorgen.vo
+driver/Compiler.vo driver/Compiler.glob driver/Compiler.v.beautified: driver/Compiler.v lib/Coqlib.vo common/Errors.vo common/AST.vo common/Smallstep.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Cstrategy.vo cfrontend/Cexec.vo cfrontend/Clight.vo cfrontend/Csharpminor.vo backend/Cminor.vo backend/CminorSel.vo backend/RTL.vo backend/LTL.vo backend/LTLin.vo backend/Linear.vo backend/Mach.vo backend/Machsem.vo $(ARCH)/Asm.vo cfrontend/Initializers.vo cfrontend/SimplExpr.vo cfrontend/SimplLocals.vo cfrontend/Cshmgen.vo cfrontend/Cminorgen.vo backend/Selection.vo backend/RTLgen.vo backend/Tailcall.vo backend/Inlining.vo backend/Renumber.vo backend/Constprop.vo backend/CSE.vo backend/Allocation.vo backend/Tunneling.vo backend/Linearize.vo backend/CleanupLabels.vo backend/Reload.vo backend/RRE.vo backend/Stacking.vo $(ARCH)/Asmgen.vo backend/RTLtyping.vo backend/LTLtyping.vo backend/LTLintyping.vo backend/Lineartyping.vo backend/Machtyping.vo cfrontend/SimplExprproof.vo cfrontend/SimplLocalsproof.vo cfrontend/Cshmgenproof.vo cfrontend/Cminorgenproof.vo backend/Selectionproof.vo backend/RTLgenproof.vo backend/Tailcallproof.vo backend/Inliningproof.vo backend/Renumberproof.vo backend/Constpropproof.vo backend/CSEproof.vo backend/Allocproof.vo backend/Alloctyping.vo backend/Tunnelingproof.vo backend/Tunnelingtyping.vo backend/Linearizeproof.vo backend/Linearizetyping.vo backend/CleanupLabelsproof.vo backend/CleanupLabelstyping.vo backend/Reloadproof.vo backend/Reloadtyping.vo backend/RREproof.vo backend/RREtyping.vo backend/Stackingproof.vo backend/Stackingtyping.vo $(ARCH)/Asmgenproof.vo
+driver/Complements.vo driver/Complements.glob driver/Complements.v.beautified: driver/Complements.v lib/Coqlib.vo common/AST.vo lib/Integers.vo common/Values.vo common/Events.vo common/Globalenvs.vo common/Smallstep.vo common/Behaviors.vo cfrontend/Csyntax.vo cfrontend/Csem.vo cfrontend/Cstrategy.vo cfrontend/Clight.vo backend/Cminor.vo backend/RTL.vo $(ARCH)/Asm.vo driver/Compiler.vo common/Errors.vo
+flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_float_prop.glob flocq/Core/Fcore_float_prop.v.beautified: flocq/Core/Fcore_float_prop.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo
+flocq/Core/Fcore_Zaux.vo flocq/Core/Fcore_Zaux.glob flocq/Core/Fcore_Zaux.v.beautified: flocq/Core/Fcore_Zaux.v
+flocq/Core/Fcore_rnd_ne.vo flocq/Core/Fcore_rnd_ne.glob flocq/Core/Fcore_rnd_ne.v.beautified: flocq/Core/Fcore_rnd_ne.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_ulp.vo
+flocq/Core/Fcore_FTZ.vo flocq/Core/Fcore_FTZ.glob flocq/Core/Fcore_FTZ.v.beautified: flocq/Core/Fcore_FTZ.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_FLX.vo
+flocq/Core/Fcore_FLT.vo flocq/Core/Fcore_FLT.glob flocq/Core/Fcore_FLT.v.beautified: flocq/Core/Fcore_FLT.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_FLX.vo flocq/Core/Fcore_FIX.vo flocq/Core/Fcore_rnd_ne.vo
+flocq/Core/Fcore_defs.vo flocq/Core/Fcore_defs.glob flocq/Core/Fcore_defs.v.beautified: flocq/Core/Fcore_defs.v flocq/Core/Fcore_Raux.vo
+flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_Raux.glob flocq/Core/Fcore_Raux.v.beautified: flocq/Core/Fcore_Raux.v flocq/Core/Fcore_Zaux.vo
+flocq/Core/Fcore_ulp.vo flocq/Core/Fcore_ulp.glob flocq/Core/Fcore_ulp.v.beautified: flocq/Core/Fcore_ulp.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo
+flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_rnd.glob flocq/Core/Fcore_rnd.v.beautified: flocq/Core/Fcore_rnd.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo
+flocq/Core/Fcore_FLX.vo flocq/Core/Fcore_FLX.glob flocq/Core/Fcore_FLX.v.beautified: flocq/Core/Fcore_FLX.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_FIX.vo flocq/Core/Fcore_rnd_ne.vo
+flocq/Core/Fcore_FIX.vo flocq/Core/Fcore_FIX.glob flocq/Core/Fcore_FIX.v.beautified: flocq/Core/Fcore_FIX.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_rnd_ne.vo
+flocq/Core/Fcore_digits.vo flocq/Core/Fcore_digits.glob flocq/Core/Fcore_digits.v.beautified: flocq/Core/Fcore_digits.v flocq/Core/Fcore_Zaux.vo
+flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_generic_fmt.glob flocq/Core/Fcore_generic_fmt.v.beautified: flocq/Core/Fcore_generic_fmt.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_float_prop.vo
+flocq/Core/Fcore.vo flocq/Core/Fcore.glob flocq/Core/Fcore.v.beautified: flocq/Core/Fcore.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_rnd.vo flocq/Core/Fcore_generic_fmt.vo flocq/Core/Fcore_rnd_ne.vo flocq/Core/Fcore_FIX.vo flocq/Core/Fcore_FLX.vo flocq/Core/Fcore_FLT.vo flocq/Core/Fcore_ulp.vo
+flocq/Prop/Fprop_Sterbenz.vo flocq/Prop/Fprop_Sterbenz.glob flocq/Prop/Fprop_Sterbenz.v.beautified: flocq/Prop/Fprop_Sterbenz.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_generic_fmt.vo flocq/Calc/Fcalc_ops.vo
+flocq/Prop/Fprop_mult_error.vo flocq/Prop/Fprop_mult_error.glob flocq/Prop/Fprop_mult_error.v.beautified: flocq/Prop/Fprop_mult_error.v flocq/Core/Fcore.vo flocq/Calc/Fcalc_ops.vo
+flocq/Prop/Fprop_relative.vo flocq/Prop/Fprop_relative.glob flocq/Prop/Fprop_relative.v.beautified: flocq/Prop/Fprop_relative.v flocq/Core/Fcore.vo
+flocq/Prop/Fprop_div_sqrt_error.vo flocq/Prop/Fprop_div_sqrt_error.glob flocq/Prop/Fprop_div_sqrt_error.v.beautified: flocq/Prop/Fprop_div_sqrt_error.v flocq/Core/Fcore.vo flocq/Calc/Fcalc_ops.vo flocq/Prop/Fprop_relative.vo
+flocq/Prop/Fprop_plus_error.vo flocq/Prop/Fprop_plus_error.glob flocq/Prop/Fprop_plus_error.v.beautified: flocq/Prop/Fprop_plus_error.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_generic_fmt.vo flocq/Calc/Fcalc_ops.vo
+flocq/Calc/Fcalc_ops.vo flocq/Calc/Fcalc_ops.glob flocq/Calc/Fcalc_ops.v.beautified: flocq/Calc/Fcalc_ops.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo
+flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_bracket.glob flocq/Calc/Fcalc_bracket.v.beautified: flocq/Calc/Fcalc_bracket.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo
+flocq/Calc/Fcalc_sqrt.vo flocq/Calc/Fcalc_sqrt.glob flocq/Calc/Fcalc_sqrt.v.beautified: flocq/Calc/Fcalc_sqrt.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_digits.vo flocq/Core/Fcore_float_prop.vo flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_digits.vo
+flocq/Calc/Fcalc_div.vo flocq/Calc/Fcalc_div.glob flocq/Calc/Fcalc_div.v.beautified: flocq/Calc/Fcalc_div.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_digits.vo flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_digits.vo
+flocq/Calc/Fcalc_round.vo flocq/Calc/Fcalc_round.glob flocq/Calc/Fcalc_round.v.beautified: flocq/Calc/Fcalc_round.v flocq/Core/Fcore.vo flocq/Core/Fcore_digits.vo flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_digits.vo
+flocq/Calc/Fcalc_digits.vo flocq/Calc/Fcalc_digits.glob flocq/Calc/Fcalc_digits.v.beautified: flocq/Calc/Fcalc_digits.v flocq/Core/Fcore_Raux.vo flocq/Core/Fcore_defs.vo flocq/Core/Fcore_float_prop.vo flocq/Core/Fcore_digits.vo
+flocq/Appli/Fappli_IEEE_bits.vo flocq/Appli/Fappli_IEEE_bits.glob flocq/Appli/Fappli_IEEE_bits.v.beautified: flocq/Appli/Fappli_IEEE_bits.v flocq/Core/Fcore.vo flocq/Core/Fcore_digits.vo flocq/Calc/Fcalc_digits.vo flocq/Appli/Fappli_IEEE.vo
+flocq/Appli/Fappli_IEEE.vo flocq/Appli/Fappli_IEEE.glob flocq/Appli/Fappli_IEEE.v.beautified: flocq/Appli/Fappli_IEEE.v flocq/Core/Fcore.vo flocq/Core/Fcore_digits.vo flocq/Calc/Fcalc_digits.vo flocq/Calc/Fcalc_round.vo flocq/Calc/Fcalc_bracket.vo flocq/Calc/Fcalc_ops.vo flocq/Calc/Fcalc_div.vo flocq/Calc/Fcalc_sqrt.vo flocq/Prop/Fprop_relative.vo
+exportclight/Clightdefs.vo exportclight/Clightdefs.glob exportclight/Clightdefs.v.beautified: exportclight/Clightdefs.v lib/Integers.vo lib/Floats.vo common/AST.vo cfrontend/Ctypes.vo cfrontend/Cop.vo cfrontend/Clight.vo
diff --git a/Changelog b/Changelog
index 89551a2..8a278a3 100644
--- a/Changelog
+++ b/Changelog
@@ -1,3 +1,9 @@
+Release 1.12.1, 2013-01-29
+==========================
+
+Ported to Coq 8.4pl1. Otherwise functionally identical to release 1.12.
+
+
Release 1.12, 2013-01-11
========================
diff --git a/arm/Asmgenproof.v b/arm/Asmgenproof.v
index 8ee9c2e..b0598e9 100644
--- a/arm/Asmgenproof.v
+++ b/arm/Asmgenproof.v
@@ -1087,7 +1087,8 @@ Proof.
exploit eval_condition_lessdef. eapply preg_vals; eauto. eauto. eauto.
intros A.
exploit transl_cond_correct. eauto. eauto.
- instantiate (1 := rs). instantiate (1 := m'). unfold PregEq.t. rewrite A.
+ instantiate (1 := rs). instantiate (1 := m').
+ rewrite A || (unfold PregEq.t; rewrite A).
intros [rs2 [EX [RES OTH]]].
inv AT. simpl in H5.
generalize (functions_transl _ _ H4); intro FN.
@@ -1123,7 +1124,8 @@ Proof.
exploit eval_condition_lessdef. eapply preg_vals; eauto. eauto. eauto.
intros A.
exploit transl_cond_correct. eauto.
- instantiate (1 := rs). instantiate (1 := m'). unfold PregEq.t. rewrite A.
+ instantiate (1 := rs). instantiate (1 := m').
+ rewrite A || (unfold PregEq.t; rewrite A).
intros [rs2 [EX [RES OTH]]].
left; eapply exec_straight_steps; eauto with coqlib.
exists m'; split; auto.
diff --git a/arm/Asmgenproof1.v b/arm/Asmgenproof1.v
index e7d2509..19edcd9 100644
--- a/arm/Asmgenproof1.v
+++ b/arm/Asmgenproof1.v
@@ -539,7 +539,7 @@ Proof.
auto.
rewrite IHl. rewrite DISTR. decEq. decEq. auto.
intros. unfold decompose_int.
- destruct (decompose_int_rec 12 n Int.zero) as []_eqn.
+ destruct (decompose_int_rec 12 n Int.zero) eqn:?.
simpl. exploit decompose_int_rec_nil; eauto. congruence.
simpl. rewrite B. decEq.
generalize (DECOMP 12%nat n Int.zero Int.zero).
@@ -617,7 +617,7 @@ Lemma iterate_op_correct:
Proof.
intros until k; intros SEM2 SEM1.
unfold iterate_op.
- destruct (decompose_int n) as [ | i tl] _eqn.
+ destruct (decompose_int n) as [ | i tl] eqn:?.
unfold decompose_int in Heql. destruct (decompose_int_rec 12%nat n Int.zero); congruence.
revert k. pattern tl. apply List.rev_ind.
(* base case *)
@@ -1256,7 +1256,7 @@ Proof.
eapply exec_straight_trans. eauto.
apply exec_straight_two with rs2 m; auto.
simpl. unfold rs3, v.
- destruct (rs2 (crbit_for_cond c)) as []_eqn; auto.
+ destruct (rs2 (crbit_for_cond c)) eqn:?; auto.
destruct (Int.eq i Int.zero); auto.
decEq. decEq. apply extensionality; intros. unfold Pregmap.set.
destruct (PregEq.eq x (ireg_of res)); auto. subst.
@@ -1380,6 +1380,7 @@ Lemma transl_load_int_correct:
Proof.
intros. unfold transl_load_store_int.
exploit eval_addressing_lessdef. eapply preg_vals; eauto. eauto.
+ unfold PregEq.t.
intros [a' [A B]].
exploit Mem.loadv_extends; eauto. intros [v' [C D]].
apply transl_load_store_correct with ms; auto.
@@ -1421,6 +1422,7 @@ Lemma transl_load_float_correct:
Proof.
intros. unfold transl_load_store_int.
exploit eval_addressing_lessdef. eapply preg_vals; eauto. eauto.
+ unfold PregEq.t.
intros [a' [A B]].
exploit Mem.loadv_extends; eauto. intros [v' [C D]].
apply transl_load_store_correct with ms; auto.
@@ -1455,7 +1457,8 @@ Lemma transl_store_int_correct:
/\ agree (undef_temps ms) sp rs'.
Proof.
intros. unfold transl_load_store_int.
- exploit eval_addressing_lessdef. eapply preg_vals; eauto. eauto.
+ exploit eval_addressing_lessdef. eapply preg_vals; eauto. eauto.
+ unfold PregEq.t.
intros [a' [A B]].
exploit preg_val; eauto. instantiate (1 := rd). intros C.
exploit Mem.storev_extends; eauto. unfold preg_of; rewrite H2. intros [m2' [D E]].
@@ -1498,7 +1501,8 @@ Lemma transl_store_float_correct:
/\ agree (undef_temps ms) sp rs'.
Proof.
intros. unfold transl_load_store_float.
- exploit eval_addressing_lessdef. eapply preg_vals; eauto. eauto.
+ exploit eval_addressing_lessdef. eapply preg_vals; eauto. eauto.
+ unfold PregEq.t.
intros [a' [A B]].
exploit preg_val; eauto. instantiate (1 := rd). intros C.
exploit Mem.storev_extends; eauto. unfold preg_of; rewrite H2. intros [m2' [D E]].
diff --git a/arm/ConstpropOpproof.v b/arm/ConstpropOpproof.v
index 4c38d5e..e7e6a41 100644
--- a/arm/ConstpropOpproof.v
+++ b/arm/ConstpropOpproof.v
@@ -149,7 +149,7 @@ Proof.
destruct (propagate_float_constants tt); simpl; auto.
destruct (propagate_float_constants tt); simpl; auto.
unfold eval_static_condition_val, Val.of_optbool.
- destruct (eval_static_condition c vl0) as []_eqn.
+ destruct (eval_static_condition c vl0) eqn:?.
rewrite (eval_static_condition_correct _ _ _ m _ H Heqo).
destruct b; simpl; auto.
simpl; auto.
@@ -247,7 +247,7 @@ Proof.
intros; unfold make_shlimm.
predSpec Int.eq Int.eq_spec n Int.zero; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.shl_zero. auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; intros.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; intros.
econstructor; split. simpl; eauto. rewrite mk_shift_amount_eq; auto.
econstructor; split; eauto. simpl. congruence.
Qed.
@@ -261,7 +261,7 @@ Proof.
intros; unfold make_shrimm.
predSpec Int.eq Int.eq_spec n Int.zero; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.shr_zero. auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; intros.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; intros.
econstructor; split. simpl; eauto. rewrite mk_shift_amount_eq; auto.
econstructor; split; eauto. simpl. congruence.
Qed.
@@ -275,7 +275,7 @@ Proof.
intros; unfold make_shruimm.
predSpec Int.eq Int.eq_spec n Int.zero; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.shru_zero. auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; intros.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; intros.
econstructor; split. simpl; eauto. rewrite mk_shift_amount_eq; auto.
econstructor; split; eauto. simpl. congruence.
Qed.
@@ -291,7 +291,7 @@ Proof.
exists (Vint Int.zero); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.mul_zero; auto.
predSpec Int.eq Int.eq_spec n Int.one; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.mul_one; auto.
- destruct (Int.is_power2 n) as []_eqn; intros.
+ destruct (Int.is_power2 n) eqn:?; intros.
exploit Int.is_power2_range; eauto. intros R.
econstructor; split. simpl; eauto. rewrite mk_shift_amount_eq; auto.
rewrite (Val.mul_pow2 rs#r1 _ _ Heqo). auto.
@@ -306,8 +306,8 @@ Lemma make_divimm_correct:
exists w, eval_operation ge sp op rs##args m = Some w /\ Val.lessdef v w.
Proof.
intros; unfold make_divimm.
- destruct (Int.is_power2 n) as []_eqn.
- destruct (Int.ltu i (Int.repr 31)) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
+ destruct (Int.ltu i (Int.repr 31)) eqn:?.
exists v; split; auto. simpl. eapply Val.divs_pow2; eauto. congruence.
exists v; auto.
exists v; auto.
@@ -321,7 +321,7 @@ Lemma make_divuimm_correct:
exists w, eval_operation ge sp op rs##args m = Some w /\ Val.lessdef v w.
Proof.
intros; unfold make_divuimm.
- destruct (Int.is_power2 n) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
replace v with (Val.shru rs#r1 (Vint i)).
econstructor; split. simpl. rewrite mk_shift_amount_eq. eauto.
eapply Int.is_power2_range; eauto. auto.
diff --git a/arm/Op.v b/arm/Op.v
index cfe8b83..f26bccc 100644
--- a/arm/Op.v
+++ b/arm/Op.v
@@ -775,8 +775,8 @@ Opaque Int.add.
Val.cmpu_bool (Mem.valid_pointer m1) c v1 v2 = Some b ->
Val.cmpu_bool (Mem.valid_pointer m2) c v1' v2' = Some b).
intros. inv H; simpl in H1; try discriminate; inv H0; simpl in H1; try discriminate; simpl; auto.
- destruct (Mem.valid_pointer m1 b1 (Int.unsigned ofs1)) as []_eqn; try discriminate.
- destruct (Mem.valid_pointer m1 b0 (Int.unsigned ofs0)) as []_eqn; try discriminate.
+ destruct (Mem.valid_pointer m1 b1 (Int.unsigned ofs1)) eqn:?; try discriminate.
+ destruct (Mem.valid_pointer m1 b0 (Int.unsigned ofs0)) eqn:?; try discriminate.
rewrite (valid_pointer_inj _ H2 Heqb4).
rewrite (valid_pointer_inj _ H Heqb0). simpl.
destruct (zeq b1 b0); simpl in H1.
@@ -796,8 +796,8 @@ Opaque Int.add.
eapply CMPU; eauto.
eapply CMP. eauto. eapply eval_shift_inj. eauto. auto.
eapply CMPU. eauto. eapply eval_shift_inj. eauto. auto.
- eapply CMP; eauto.
- eapply CMPU; eauto.
+ eapply CMP; try eassumption; eauto.
+ eapply CMPU; try eassumption; eauto.
inv H3; inv H2; simpl in H0; inv H0; auto.
inv H3; inv H2; simpl in H0; inv H0; auto.
inv H3; simpl in H0; inv H0; auto.
@@ -871,7 +871,7 @@ Proof.
inv H4; simpl in *; inv H1. TrivialExists.
inv H4; simpl in *; inv H1. TrivialExists.
- subst v1. destruct (eval_condition c vl1 m1) as []_eqn.
+ subst v1. destruct (eval_condition c vl1 m1) eqn:?.
exploit eval_condition_inj; eauto. intros EQ; rewrite EQ.
destruct b; simpl; constructor.
simpl; constructor.
@@ -1005,7 +1005,7 @@ Hypothesis sp_inj: f sp1 = Some(sp2, delta).
Remark symbol_address_inject:
forall id ofs, val_inject f (symbol_address genv id ofs) (symbol_address genv id ofs).
Proof.
- intros. unfold symbol_address. destruct (Genv.find_symbol genv id) as []_eqn; auto.
+ intros. unfold symbol_address. destruct (Genv.find_symbol genv id) eqn:?; auto.
exploit (proj1 globals); eauto. intros.
econstructor; eauto. rewrite Int.add_zero; auto.
Qed.
diff --git a/arm/PrintAsm.ml b/arm/PrintAsm.ml
index 6415248..9d09fc1 100644
--- a/arm/PrintAsm.ml
+++ b/arm/PrintAsm.ml
@@ -719,7 +719,7 @@ let print_init oc = function
fprintf oc " .quad %Ld %s %.18g\n" (camlint64_of_coqint (Floats.Float.bits_of_double n))
comment (camlfloat_of_coqfloat n)
| Init_space n ->
- let n = camlint_of_z n in
+ let n = Z.to_int32 n in
if n > 0l then fprintf oc " .space %ld\n" n
| Init_addrof(symb, ofs) ->
fprintf oc " .word %a\n" print_symb_ofs (symb, ofs)
diff --git a/arm/SelectOpproof.v b/arm/SelectOpproof.v
index e25fb0c..ecc758f 100644
--- a/arm/SelectOpproof.v
+++ b/arm/SelectOpproof.v
@@ -204,10 +204,10 @@ Opaque mk_shift_amount.
red; intros until x. unfold shlimm.
predSpec Int.eq Int.eq_spec n Int.zero.
intros; subst. exists x; split; auto. destruct x; simpl; auto. rewrite Int.shl_zero; auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; simpl.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; simpl.
destruct (shlimm_match a); intros.
InvEval. simpl; rewrite Heqb. TrivialExists.
- destruct (Int.ltu (Int.add n n1) Int.iwordsize) as []_eqn.
+ destruct (Int.ltu (Int.add n n1) Int.iwordsize) eqn:?.
InvEval. subst x. exists (Val.shl v1 (Vint (Int.add n n1))); split. EvalOp.
simpl. rewrite mk_shift_amount_eq; auto.
destruct v1; simpl; auto. rewrite s_range. simpl. rewrite Heqb. rewrite Heqb0.
@@ -224,10 +224,10 @@ Proof.
red; intros until x. unfold shrimm.
predSpec Int.eq Int.eq_spec n Int.zero.
intros; subst. exists x; split; auto. destruct x; simpl; auto. rewrite Int.shr_zero; auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; simpl.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; simpl.
destruct (shrimm_match a); intros.
InvEval. simpl; rewrite Heqb. TrivialExists.
- destruct (Int.ltu (Int.add n n1) Int.iwordsize) as []_eqn.
+ destruct (Int.ltu (Int.add n n1) Int.iwordsize) eqn:?.
InvEval. subst x. exists (Val.shr v1 (Vint (Int.add n n1))); split. EvalOp.
simpl. rewrite mk_shift_amount_eq; auto.
destruct v1; simpl; auto. rewrite s_range. simpl. rewrite Heqb. rewrite Heqb0.
@@ -244,13 +244,13 @@ Proof.
red; intros until x. unfold shruimm.
predSpec Int.eq Int.eq_spec n Int.zero.
intros; subst. exists x; split; auto. destruct x; simpl; auto. rewrite Int.shru_zero; auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; simpl.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; simpl.
destruct (shruimm_match a); intros.
InvEval. simpl; rewrite Heqb. TrivialExists.
- destruct (Int.ltu (Int.add n n1) Int.iwordsize) as []_eqn.
+ destruct (Int.ltu (Int.add n n1) Int.iwordsize) eqn:?.
InvEval. subst x. exists (Val.shru v1 (Vint (Int.add n n1))); split. EvalOp.
simpl. rewrite mk_shift_amount_eq; auto.
- destruct v1; simpl; auto. destruct (Int.ltu n1 Int.iwordsize) as []_eqn; simpl; auto.
+ destruct v1; simpl; auto. destruct (Int.ltu n1 Int.iwordsize) eqn:?; simpl; auto.
rewrite Heqb; rewrite Heqb0. rewrite Int.add_commut. rewrite Int.shru_shru; auto. rewrite Int.add_commut; auto.
TrivialExists. simpl. rewrite mk_shift_amount_eq; auto.
TrivialExists. simpl. rewrite mk_shift_amount_eq; auto.
@@ -379,27 +379,27 @@ Proof.
rewrite Val.or_commut. apply eval_orimm; auto.
apply eval_orimm; auto.
(* shl - shru *)
- destruct (Int.eq (Int.add n1 n2) Int.iwordsize && same_expr_pure t1 t2) as []_eqn.
+ destruct (Int.eq (Int.add n1 n2) Int.iwordsize && same_expr_pure t1 t2) eqn:?.
destruct (andb_prop _ _ Heqb0).
generalize (Int.eq_spec (Int.add n1 n2) Int.iwordsize); rewrite H1; intros.
exploit eval_same_expr; eauto. intros [EQ1 EQ2]. subst.
exists (Val.ror v0 (Vint n2)); split. EvalOp.
destruct v0; simpl; auto.
- destruct (Int.ltu n1 Int.iwordsize) as []_eqn; auto.
- destruct (Int.ltu n2 Int.iwordsize) as []_eqn; auto.
+ destruct (Int.ltu n1 Int.iwordsize) eqn:?; auto.
+ destruct (Int.ltu n2 Int.iwordsize) eqn:?; auto.
simpl. rewrite <- Int.or_ror; auto.
subst. TrivialExists.
econstructor. EvalOp. simpl; eauto. econstructor; eauto. constructor.
simpl. auto.
(* shru - shr *)
- destruct (Int.eq (Int.add n2 n1) Int.iwordsize && same_expr_pure t1 t2) as []_eqn.
+ destruct (Int.eq (Int.add n2 n1) Int.iwordsize && same_expr_pure t1 t2) eqn:?.
destruct (andb_prop _ _ Heqb0).
generalize (Int.eq_spec (Int.add n2 n1) Int.iwordsize); rewrite H1; intros.
exploit eval_same_expr; eauto. intros [EQ1 EQ2]. subst.
exists (Val.ror v0 (Vint n1)); split. EvalOp.
destruct v0; simpl; auto.
- destruct (Int.ltu n1 Int.iwordsize) as []_eqn; auto.
- destruct (Int.ltu n2 Int.iwordsize) as []_eqn; auto.
+ destruct (Int.ltu n1 Int.iwordsize) eqn:?; auto.
+ destruct (Int.ltu n2 Int.iwordsize) eqn:?; auto.
simpl. rewrite Int.or_commut. rewrite <- Int.or_ror; auto.
subst. TrivialExists.
econstructor. EvalOp. simpl; eauto. econstructor; eauto. constructor.
@@ -490,7 +490,7 @@ Theorem eval_divuimm:
exists v, eval_expr ge sp e m le (divuimm a n) v /\ Val.lessdef z v.
Proof.
intros; unfold divuimm.
- destruct (Int.is_power2 n) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
replace z with (Val.shru x (Vint i)). apply eval_shruimm; auto.
eapply Val.divu_pow2; eauto.
TrivialExists.
@@ -516,7 +516,7 @@ Theorem eval_moduimm:
exists v, eval_expr ge sp e m le (moduimm a n) v /\ Val.lessdef z v.
Proof.
intros; unfold moduimm.
- destruct (Int.is_power2 n) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
replace z with (Val.and x (Vint (Int.sub n Int.one))). TrivialExists.
eapply Val.modu_pow2; eauto.
exploit Val.modu_divu; eauto. intros [v [A B]].
diff --git a/backend/CMlexer.mll b/backend/CMlexer.mll
index eac48e0..4083c95 100644
--- a/backend/CMlexer.mll
+++ b/backend/CMlexer.mll
@@ -14,6 +14,7 @@
(* *********************************************************************)
{
+open BinNums
open Camlcoq
open CMparser
exception Error of string
diff --git a/backend/CMparser.mly b/backend/CMparser.mly
index ff77c03..eb3b9ab 100644
--- a/backend/CMparser.mly
+++ b/backend/CMparser.mly
@@ -19,8 +19,7 @@
%{
open Datatypes
open Camlcoq
-open BinPos
-open BinInt
+open BinNums
open Integers
open AST
open Cminor
@@ -45,16 +44,16 @@ let mkef sg toks =
EF_vstore c
| [EFT_tok "volatile"; EFT_tok "load"; EFT_chunk c;
EFT_tok "global"; EFT_string s; EFT_int n] ->
- EF_vload_global(c, intern_string s, z_of_camlint n)
+ EF_vload_global(c, intern_string s, coqint_of_camlint n)
| [EFT_tok "volatile"; EFT_tok "store"; EFT_chunk c;
EFT_tok "global"; EFT_string s; EFT_int n] ->
- EF_vstore_global(c, intern_string s, z_of_camlint n)
+ EF_vstore_global(c, intern_string s, coqint_of_camlint n)
| [EFT_tok "malloc"] ->
EF_malloc
| [EFT_tok "free"] ->
EF_free
| [EFT_tok "memcpy"; EFT_tok "size"; EFT_int sz; EFT_tok "align"; EFT_int al] ->
- EF_memcpy(z_of_camlint sz, z_of_camlint al)
+ EF_memcpy(Z.of_sint32 sz, Z.of_sint32 al)
| [EFT_tok "annot"; EFT_string txt] ->
EF_annot(intern_string txt, sg.sig_args)
| [EFT_tok "annot_val"; EFT_string txt] ->
@@ -183,7 +182,7 @@ let mkwhile expr body =
let intconst n =
Rconst(Ointconst(coqint_of_camlint n))
-let exitnum n = nat_of_camlint n
+let exitnum n = Nat.of_int32 n
let mkswitch expr (cases, dfl) =
convert_accu := [];
@@ -211,25 +210,25 @@ let mkswitch expr (cases, dfl) =
***)
let mkmatch_aux expr cases =
- let ncases = Int32.of_int (List.length cases) in
+ let ncases = List.length cases in
let rec mktable n = function
| [] -> assert false
| [key, action] -> []
| (key, action) :: rem ->
- (coqint_of_camlint key, nat_of_camlint n)
- :: mktable (Int32.succ n) rem in
+ (coqint_of_camlint key, Nat.of_int n)
+ :: mktable (n + 1) rem in
let sw =
- Sswitch(expr, mktable 0l cases, nat_of_camlint (Int32.pred ncases)) in
+ Sswitch(expr, mktable 0 cases, Nat.of_int (ncases - 1)) in
let rec mkblocks body n = function
| [] -> assert false
| [key, action] ->
Sblock(Sseq(body, action))
| (key, action) :: rem ->
mkblocks
- (Sblock(Sseq(body, Sseq(action, Sexit (nat_of_camlint n)))))
- (Int32.pred n)
+ (Sblock(Sseq(body, Sseq(action, Sexit (Nat.of_int n)))))
+ (n - 1)
rem in
- mkblocks (Sblock sw) (Int32.pred ncases) cases
+ mkblocks (Sblock sw) (ncases - 1) cases
let mkmatch expr cases =
convert_accu := [];
@@ -377,7 +376,7 @@ global_declaration:
{ $1 }
| VAR STRINGLIT LBRACKET INTLIT RBRACKET /* old style */
{ (intern_string $2,
- Gvar{gvar_info = (); gvar_init = [Init_space(z_of_camlint $4)];
+ Gvar{gvar_info = (); gvar_init = [Init_space(Z.of_sint32 $4)];
gvar_readonly = false; gvar_volatile = false}) }
| VAR STRINGLIT is_readonly is_volatile LBRACE init_data_list RBRACE
{ (intern_string $2,
@@ -413,7 +412,7 @@ init_data:
| FLOAT64 FLOATLIT { Init_float64 (coqfloat_of_camlfloat $2) }
| FLOAT FLOATLIT { Init_float64 (coqfloat_of_camlfloat $2) }
| FLOATLIT { Init_float64 (coqfloat_of_camlfloat $1) }
- | LBRACKET INTLIT RBRACKET { Init_space (z_of_camlint $2) }
+ | LBRACKET INTLIT RBRACKET { Init_space (Z.of_sint32 $2) }
| INTLIT LPAREN STRINGLIT RPAREN { Init_addrof (intern_string $3, coqint_of_camlint $1) }
;
@@ -462,7 +461,7 @@ parameter_list:
stack_declaration:
/* empty */ { Z0 }
- | STACK INTLIT SEMICOLON { z_of_camlint $2 }
+ | STACK INTLIT SEMICOLON { Z.of_sint32 $2 }
;
var_declarations:
diff --git a/backend/CMtypecheck.ml b/backend/CMtypecheck.ml
index 408e9ec..39e8c51 100644
--- a/backend/CMtypecheck.ml
+++ b/backend/CMtypecheck.ml
@@ -64,7 +64,7 @@ let type_var env id =
raise (Error (sprintf "Unbound variable %s\n" (extern_atom id)))
let type_letvar env n =
- let n = camlint_of_nat n in
+ let n = Nat.to_int n in
try
List.nth env n
with Not_found ->
@@ -303,8 +303,8 @@ let rec type_stmt env blk ret s =
| Sblock s1 ->
type_stmt env (blk + 1) ret s1
| Sexit n ->
- if camlint_of_nat n >= blk then
- raise (Error (sprintf "Bad exit(%d)\n" (camlint_of_nat n)))
+ if Nat.to_int n >= blk then
+ raise (Error (sprintf "Bad exit(%d)\n" (Nat.to_int n)))
| Sswitch(e, cases, deflt) ->
unify (type_expr env [] e) tint
| Sreturn None ->
diff --git a/backend/CSEproof.v b/backend/CSEproof.v
index 5569123..44d23c8 100644
--- a/backend/CSEproof.v
+++ b/backend/CSEproof.v
@@ -94,7 +94,7 @@ Lemma wf_valnum_reg:
wf_numbering n' /\ Plt v n'.(num_next) /\ Ple n.(num_next) n'.(num_next).
Proof.
intros until v. unfold valnum_reg. intros WF VREG. inversion WF.
- destruct ((num_reg n)!r) as [v'|]_eqn.
+ destruct ((num_reg n)!r) as [v'|] eqn:?.
(* found *)
inv VREG. split. auto. split. eauto. apply Ple_refl.
(* not found *)
@@ -174,7 +174,7 @@ Lemma wf_forget_reg:
In r (PMap.get v (forget_reg n rd)) -> r <> rd /\ PTree.get r n.(num_reg) = Some v.
Proof.
unfold forget_reg; intros. inversion H.
- destruct ((num_reg n)!rd) as [vd|]_eqn.
+ destruct ((num_reg n)!rd) as [vd|] eqn:?.
rewrite PMap.gsspec in H0. destruct (peq v vd).
subst vd. rewrite in_remove in H0. destruct H0. split. auto. eauto.
split; eauto. exploit VAL; eauto. congruence.
@@ -201,7 +201,7 @@ Lemma wf_add_rhs:
wf_numbering (add_rhs n rd rh).
Proof.
intros. inversion H. unfold add_rhs.
- destruct (find_valnum_rhs rh n.(num_eqs)) as [vres|]_eqn.
+ destruct (find_valnum_rhs rh n.(num_eqs)) as [vres|] eqn:?.
(* found *)
exploit find_valnum_rhs_correct; eauto. intros IN.
split; simpl; intros.
@@ -226,16 +226,16 @@ Lemma wf_add_op:
wf_numbering n ->
wf_numbering (add_op n rd op rs).
Proof.
- intros. unfold add_op. destruct (is_move_operation op rs) as [r|]_eqn.
+ intros. unfold add_op. destruct (is_move_operation op rs) as [r|] eqn:?.
(* move *)
- destruct (valnum_reg n r) as [n' v]_eqn.
+ destruct (valnum_reg n r) as [n' v] eqn:?.
exploit wf_valnum_reg; eauto. intros [A [B C]]. inversion A.
constructor; simpl; intros.
eauto.
rewrite PTree.gsspec in H0. destruct (peq r0 rd). inv H0. auto. eauto.
eapply wf_update_reg; eauto.
(* not a move *)
- destruct (valnum_regs n rs) as [n' vs]_eqn.
+ destruct (valnum_regs n rs) as [n' vs] eqn:?.
exploit wf_valnum_regs; eauto. intros [A [B C]].
eapply wf_add_rhs; eauto.
Qed.
@@ -270,7 +270,7 @@ Remark kill_eqs_in:
Proof.
induction eqs; simpl; intros.
tauto.
- destruct (pred (snd a)) as []_eqn.
+ destruct (pred (snd a)) eqn:?.
exploit IHeqs; eauto. tauto.
simpl in H; destruct H. subst a. auto. exploit IHeqs; eauto. tauto.
Qed.
@@ -289,7 +289,7 @@ Lemma wf_add_store:
wf_numbering n -> wf_numbering (add_store n chunk addr rargs rsrc).
Proof.
intros. unfold add_store.
- destruct (valnum_regs n rargs) as [n1 vargs]_eqn.
+ destruct (valnum_regs n rargs) as [n1 vargs] eqn:?.
exploit wf_valnum_regs; eauto. intros [A [B C]].
assert (wf_numbering (kill_equations (filter_after_store chunk addr vargs) n1)).
apply wf_kill_equations. auto.
@@ -664,7 +664,7 @@ Lemma add_store_satisfiable:
numbering_satisfiable ge sp rs m' (add_store n chunk addr args src).
Proof.
intros. unfold add_store. destruct H0 as [valu A].
- destruct (valnum_regs n args) as [n1 vargs]_eqn.
+ destruct (valnum_regs n args) as [n1 vargs] eqn:?.
exploit valnum_regs_holds; eauto. intros [valu' [B [C D]]].
exploit wf_valnum_regs; eauto. intros [U [V W]].
set (n2 := kill_equations (filter_after_store chunk addr vargs) n1).
@@ -704,7 +704,7 @@ Lemma reg_valnum_correct:
forall n v r, wf_numbering n -> reg_valnum n v = Some r -> n.(num_reg)!r = Some v.
Proof.
unfold reg_valnum; intros. inv H.
- destruct ((num_val n)#v) as [| r1 rl]_eqn; inv H0.
+ destruct ((num_val n)#v) as [| r1 rl] eqn:?; inv H0.
eapply VAL. rewrite Heql. auto with coqlib.
Qed.
@@ -755,8 +755,8 @@ Lemma regs_valnums_correct:
Proof.
induction vl; simpl; intros.
inv H. auto.
- destruct (reg_valnum n a) as [r1|]_eqn; try discriminate.
- destruct (regs_valnums n vl) as [rx|]_eqn; try discriminate.
+ destruct (reg_valnum n a) as [r1|] eqn:?; try discriminate.
+ destruct (regs_valnums n vl) as [rx|] eqn:?; try discriminate.
inv H. simpl; decEq; auto.
eapply (proj2 n_holds); eauto. eapply reg_valnum_correct; eauto.
Qed.
@@ -770,13 +770,13 @@ Proof.
induction niter; simpl; intros.
discriminate.
destruct (f (fun v : valnum => find_valnum_num v (num_eqs n)) op args)
- as [[op1 args1] | ]_eqn.
+ as [[op1 args1] | ] eqn:?.
assert (sem op1 (map valu args1) = Some res).
rewrite <- H0. eapply f_sound; eauto.
simpl; intros. apply (proj1 n_holds). eapply find_valnum_num_correct; eauto.
- destruct (reduce_rec A f n niter op1 args1) as [[op2 rl2] | ]_eqn.
+ destruct (reduce_rec A f n niter op1 args1) as [[op2 rl2] | ] eqn:?.
inv H. eapply IHniter; eauto.
- destruct (regs_valnums n args1) as [rl|]_eqn.
+ destruct (regs_valnums n args1) as [rl|] eqn:?.
inv H. erewrite regs_valnums_correct; eauto.
discriminate.
discriminate.
@@ -790,7 +790,7 @@ Lemma reduce_sound:
sem op' rs##rl' = Some res.
Proof.
unfold reduce; intros.
- destruct (reduce_rec A f n 4%nat op vl) as [[op1 rl1] | ]_eqn; inv H.
+ destruct (reduce_rec A f n 4%nat op vl) as [[op1 rl1] | ] eqn:?; inv H.
eapply reduce_rec_sound; eauto. congruence.
auto.
Qed.
@@ -973,21 +973,21 @@ Proof.
(* Iop *)
exists (State s' (transf_function' f approx) sp pc' (rs#res <- v) m); split.
- destruct (is_trivial_op op) as []_eqn.
+ destruct (is_trivial_op op) eqn:?.
eapply exec_Iop'; eauto.
rewrite <- H0. apply eval_operation_preserved. exact symbols_preserved.
- destruct (valnum_regs approx!!pc args) as [n1 vl]_eqn.
+ destruct (valnum_regs approx!!pc args) as [n1 vl] eqn:?.
assert (wf_numbering approx!!pc). eapply wf_analyze; eauto.
destruct SAT as [valu1 NH1].
exploit valnum_regs_holds; eauto. intros [valu2 [NH2 [EQ AG]]].
assert (wf_numbering n1). eapply wf_valnum_regs; eauto.
- destruct (find_rhs n1 (Op op vl)) as [r|]_eqn.
+ destruct (find_rhs n1 (Op op vl)) as [r|] eqn:?.
(* replaced by move *)
assert (EV: rhs_evals_to ge sp valu2 (Op op vl) m rs#r). eapply find_rhs_correct; eauto.
assert (RES: rs#r = v). red in EV. congruence.
eapply exec_Iop'; eauto. simpl. congruence.
(* possibly simplified *)
- destruct (reduce operation combine_op n1 op args vl) as [op' args']_eqn.
+ destruct (reduce operation combine_op n1 op args vl) as [op' args'] eqn:?.
assert (RES: eval_operation ge sp op' rs##args' m = Some v).
eapply reduce_sound with (sem := fun op vl => eval_operation ge sp op vl m); eauto.
intros; eapply combine_op_sound; eauto.
@@ -1007,18 +1007,18 @@ Proof.
(* Iload *)
exists (State s' (transf_function' f approx) sp pc' (rs#dst <- v) m); split.
- destruct (valnum_regs approx!!pc args) as [n1 vl]_eqn.
+ destruct (valnum_regs approx!!pc args) as [n1 vl] eqn:?.
assert (wf_numbering approx!!pc). eapply wf_analyze; eauto.
destruct SAT as [valu1 NH1].
exploit valnum_regs_holds; eauto. intros [valu2 [NH2 [EQ AG]]].
assert (wf_numbering n1). eapply wf_valnum_regs; eauto.
- destruct (find_rhs n1 (Load chunk addr vl)) as [r|]_eqn.
+ destruct (find_rhs n1 (Load chunk addr vl)) as [r|] eqn:?.
(* replaced by move *)
assert (EV: rhs_evals_to ge sp valu2 (Load chunk addr vl) m rs#r). eapply find_rhs_correct; eauto.
assert (RES: rs#r = v). red in EV. destruct EV as [a' [EQ1 EQ2]]. congruence.
eapply exec_Iop'; eauto. simpl. congruence.
(* possibly simplified *)
- destruct (reduce addressing combine_addr n1 addr args vl) as [addr' args']_eqn.
+ destruct (reduce addressing combine_addr n1 addr args vl) as [addr' args'] eqn:?.
assert (ADDR: eval_addressing ge sp addr' rs##args' = Some a).
eapply reduce_sound with (sem := fun addr vl => eval_addressing ge sp addr vl); eauto.
intros; eapply combine_addr_sound; eauto.
@@ -1035,12 +1035,12 @@ Proof.
(* Istore *)
exists (State s' (transf_function' f approx) sp pc' rs m'); split.
- destruct (valnum_regs approx!!pc args) as [n1 vl]_eqn.
+ destruct (valnum_regs approx!!pc args) as [n1 vl] eqn:?.
assert (wf_numbering approx!!pc). eapply wf_analyze; eauto.
destruct SAT as [valu1 NH1].
exploit valnum_regs_holds; eauto. intros [valu2 [NH2 [EQ AG]]].
assert (wf_numbering n1). eapply wf_valnum_regs; eauto.
- destruct (reduce addressing combine_addr n1 addr args vl) as [addr' args']_eqn.
+ destruct (reduce addressing combine_addr n1 addr args vl) as [addr' args'] eqn:?.
assert (ADDR: eval_addressing ge sp addr' rs##args' = Some a).
eapply reduce_sound with (sem := fun addr vl => eval_addressing ge sp addr vl); eauto.
intros; eapply combine_addr_sound; eauto.
@@ -1093,12 +1093,12 @@ Proof.
eapply kill_loads_satisfiable; eauto.
(* Icond *)
- destruct (valnum_regs approx!!pc args) as [n1 vl]_eqn.
+ destruct (valnum_regs approx!!pc args) as [n1 vl] eqn:?.
assert (wf_numbering approx!!pc). eapply wf_analyze; eauto.
elim SAT; intros valu1 NH1.
exploit valnum_regs_holds; eauto. intros [valu2 [NH2 [EQ AG]]].
assert (wf_numbering n1). eapply wf_valnum_regs; eauto.
- destruct (reduce condition combine_cond n1 cond args vl) as [cond' args']_eqn.
+ destruct (reduce condition combine_cond n1 cond args vl) as [cond' args'] eqn:?.
assert (RES: eval_condition cond' rs##args' m = Some b).
eapply reduce_sound with (sem := fun cond vl => eval_condition cond vl m); eauto.
intros; eapply combine_cond_sound; eauto.
@@ -1124,8 +1124,8 @@ Proof.
(* internal function *)
monadInv H7. unfold transf_function in EQ.
- destruct (type_function f) as [tyenv|]_eqn; try discriminate.
- destruct (analyze f) as [approx|]_eqn; inv EQ.
+ destruct (type_function f) as [tyenv|] eqn:?; try discriminate.
+ destruct (analyze f) as [approx|] eqn:?; inv EQ.
assert (WTF: wt_function f tyenv). apply type_function_correct; auto.
econstructor; split.
eapply exec_function_internal; eauto.
diff --git a/backend/Coloringaux.ml b/backend/Coloringaux.ml
index 2fce25e..ddd3094 100644
--- a/backend/Coloringaux.ml
+++ b/backend/Coloringaux.ml
@@ -12,8 +12,6 @@
open Camlcoq
open Datatypes
-open BinPos
-open BinInt
open AST
open Maps
open Registers
@@ -766,8 +764,8 @@ let rec reuse_slot conflicts n mvlist =
let find_slot conflicts typ =
let rec find curr =
let l = S(Local(curr, typ)) in
- if Locset.mem l conflicts then find (coq_Zsucc curr) else l
- in find Z0
+ if Locset.mem l conflicts then find (Z.succ curr) else l
+ in find Z.zero
let assign_color n =
let conflicts = ref Locset.empty in
diff --git a/backend/Constpropproof.v b/backend/Constpropproof.v
index 1b90666..cd757cd 100644
--- a/backend/Constpropproof.v
+++ b/backend/Constpropproof.v
@@ -199,9 +199,9 @@ Lemma eval_static_load_sound:
val_match_approx ge sp (eval_static_load gapp chunk addr) v.
Proof.
intros. unfold eval_static_load. destruct addr; simpl; auto.
- destruct (gapp!i) as [il|]_eqn; auto.
+ destruct (gapp!i) as [il|] eqn:?; auto.
red in H1. subst vaddr. unfold symbol_address in H.
- destruct (Genv.find_symbol ge i) as [b'|]_eqn; simpl in H; try discriminate.
+ destruct (Genv.find_symbol ge i) as [b'|] eqn:?; simpl in H; try discriminate.
exploit H0; eauto. intros [A [B C]].
eapply eval_load_init_sound; eauto.
red; auto.
@@ -290,7 +290,7 @@ Proof.
\/ id0 <> id /\ ga!id0 = Some il).
destruct gd.
rewrite PTree.grspec in H0. destruct (PTree.elt_eq id0 id); [discriminate|auto].
- destruct (gvar_readonly v && negb (gvar_volatile v)) as []_eqn.
+ destruct (gvar_readonly v && negb (gvar_volatile v)) eqn:?.
rewrite PTree.gsspec in H0. destruct (peq id0 id).
inv H0. left. split; auto.
destruct v; simpl in *.
@@ -455,10 +455,10 @@ Lemma match_successor_rec:
Proof.
induction n; simpl; intros.
apply match_pc_base.
- destruct (fn_code f)!pc as [i|]_eqn; try apply match_pc_base.
+ destruct (fn_code f)!pc as [i|] eqn:?; try apply match_pc_base.
destruct i; try apply match_pc_base.
eapply match_pc_nop; eauto.
- destruct (eval_static_condition c (approx_regs app l)) as [b|]_eqn.
+ destruct (eval_static_condition c (approx_regs app l)) as [b|] eqn:?.
eapply match_pc_cond; eauto.
apply match_pc_base.
Qed.
@@ -607,7 +607,7 @@ Proof.
assert (MATCH'': regs_match_approx sp (analyze gapp f) # pc' rs # res <- v).
eapply analyze_correct_1 with (pc := pc); eauto. simpl; auto.
unfold transfer; rewrite H. auto.
- destruct (const_for_result a) as [cop|]_eqn; intros.
+ destruct (const_for_result a) as [cop|] eqn:?; intros.
(* constant is propagated *)
left; econstructor; econstructor; split.
eapply exec_Iop; eauto.
@@ -640,7 +640,7 @@ Proof.
eapply approx_regs_val_list; eauto.
assert (VM2: val_match_approx ge sp ap2 v).
eapply eval_static_load_sound; eauto.
- destruct (const_for_result ap2) as [cop|]_eqn; intros.
+ destruct (const_for_result ap2) as [cop|] eqn:?; intros.
(* constant-propagated *)
left; econstructor; econstructor; split.
eapply exec_Iop; eauto. eapply const_for_result_correct; eauto.
@@ -708,7 +708,7 @@ Proof.
(* Ibuiltin *)
rename pc'0 into pc.
Opaque builtin_strength_reduction.
- destruct (builtin_strength_reduction ef args (approx_regs (analyze gapp f)#pc args)) as [ef' args']_eqn.
+ destruct (builtin_strength_reduction ef args (approx_regs (analyze gapp f)#pc args)) as [ef' args'] eqn:?.
generalize (builtin_strength_reduction_correct ge sp (analyze gapp f)!!pc rs
MATCH2 ef args (approx_regs (analyze gapp f) # pc args) _ _ _ _ (refl_equal _) H0).
rewrite Heqp. intros P.
@@ -732,7 +732,7 @@ Opaque builtin_strength_reduction.
destruct (cond_strength_reduction cond args (approx_regs (analyze gapp f) # pc args)) as [cond' args'].
intros EV1 TCODE.
left; exists O; exists (State s' (transf_function gapp f) sp (if b then ifso else ifnot) rs' m'); split.
- destruct (eval_static_condition cond (approx_regs (analyze gapp f) # pc args)) as []_eqn.
+ destruct (eval_static_condition cond (approx_regs (analyze gapp f) # pc args)) eqn:?.
assert (eval_condition cond rs ## args m = Some b0).
eapply eval_static_condition_correct; eauto. eapply approx_regs_val_list; eauto.
assert (b = b0) by congruence. subst b0.
@@ -758,7 +758,7 @@ Opaque builtin_strength_reduction.
rename pc'0 into pc.
assert (A: (fn_code (transf_function gapp f))!pc = Some(Ijumptable arg tbl)
\/ (fn_code (transf_function gapp f))!pc = Some(Inop pc')).
- TransfInstr. destruct (approx_reg (analyze gapp f) # pc arg) as []_eqn; auto.
+ TransfInstr. destruct (approx_reg (analyze gapp f) # pc arg) eqn:?; auto.
generalize (MATCH2 arg). unfold approx_reg in Heqt. rewrite Heqt. rewrite H0.
simpl. intro EQ; inv EQ. rewrite H1. auto.
assert (B: rs'#arg = Vint n).
diff --git a/backend/Inliningproof.v b/backend/Inliningproof.v
index 8de8487..9536141 100644
--- a/backend/Inliningproof.v
+++ b/backend/Inliningproof.v
@@ -306,7 +306,7 @@ Lemma range_private_free_left:
range_private F m1 m' sp base hi.
Proof.
intros; red; intros.
- destruct (zlt ofs (base + Zmax sz 0)).
+ destruct (zlt ofs (base + Zmax sz 0)) as [z|z].
red; split.
replace ofs with ((ofs - base) + base) by omega.
eapply Mem.perm_inject; eauto.
@@ -342,7 +342,7 @@ Proof.
red; intros. exploit RP; eauto. intros [A B].
destruct UNCH as [U1 U2].
split. auto.
- intros. red in SEP. destruct (F b) as [[sp1 delta1] |]_eqn.
+ intros. red in SEP. destruct (F b) as [[sp1 delta1] |] eqn:?.
exploit INCR; eauto. intros EQ; rewrite H0 in EQ; inv EQ.
red; intros; eelim B; eauto. eapply PERM; eauto.
red. destruct (zlt b (Mem.nextblock m1)); auto.
@@ -710,7 +710,7 @@ Proof.
induction 1; intros.
apply match_stacks_nil with bound1; auto.
inv MG. constructor; intros; eauto.
- destruct (F1 b1) as [[b2' delta']|]_eqn.
+ destruct (F1 b1) as [[b2' delta']|] eqn:?.
exploit INCR; eauto. intros EQ; rewrite H0 in EQ; inv EQ. eapply IMAGE; eauto.
exploit SEP; eauto. intros [A B]. elim B. red. omega.
eapply match_stacks_cons; eauto.
@@ -919,7 +919,7 @@ Proof.
eapply agree_val_regs; eauto.
(* inlined *)
assert (fd = Internal f0).
- simpl in H0. destruct (Genv.find_symbol ge id) as [b|]_eqn; try discriminate.
+ simpl in H0. destruct (Genv.find_symbol ge id) as [b|] eqn:?; try discriminate.
exploit (funenv_program_compat prog); eauto. intros.
unfold ge in H0. congruence.
subst fd.
@@ -973,7 +973,7 @@ Proof.
eapply Mem.free_left_inject; eauto.
(* inlined *)
assert (fd = Internal f0).
- simpl in H0. destruct (Genv.find_symbol ge id) as [b|]_eqn; try discriminate.
+ simpl in H0. destruct (Genv.find_symbol ge id) as [b|] eqn:?; try discriminate.
exploit (funenv_program_compat prog); eauto. intros.
unfold ge in H0. congruence.
subst fd.
diff --git a/backend/Inliningspec.v b/backend/Inliningspec.v
index 014986d..06826c2 100644
--- a/backend/Inliningspec.v
+++ b/backend/Inliningspec.v
@@ -498,7 +498,7 @@ Proof.
(* tailcall *)
destruct (can_inline fe s1) as [|id f P Q].
(* not inlined *)
- destruct (retinfo ctx) as [[rpc rreg] | ]_eqn.
+ destruct (retinfo ctx) as [[rpc rreg] | ] eqn:?.
(* turned into a call *)
eapply tr_tailcall_call; eauto.
(* preserved *)
@@ -526,7 +526,7 @@ Proof.
red; simpl. subst s2; simpl in *; xomega.
red; auto.
(* return *)
- destruct (retinfo ctx) as [[rpc rreg] | ]_eqn.
+ destruct (retinfo ctx) as [[rpc rreg] | ] eqn:?.
(* inlined *)
eapply tr_return_inlined; eauto.
(* unchanged *)
@@ -671,7 +671,7 @@ Lemma transf_function_spec:
forall f f', transf_function fenv f = OK f' -> tr_function f f'.
Proof.
intros. unfold transf_function in H.
- destruct (expand_function fenv f initstate) as [ctx s i]_eqn.
+ destruct (expand_function fenv f initstate) as [ctx s i] eqn:?.
destruct (zle (st_stksize s) Int.max_unsigned); inv H.
monadInv Heqr. set (ctx := initcontext x x0 (max_def_function f) (fn_stacksize f)) in *.
Opaque initstate.
diff --git a/backend/Linearizeaux.ml b/backend/Linearizeaux.ml
index ce7788f..ac47ae8 100644
--- a/backend/Linearizeaux.ml
+++ b/backend/Linearizeaux.ml
@@ -10,7 +10,6 @@
(* *)
(* *********************************************************************)
-open BinPos
open Coqlib
open Datatypes
open LTL
@@ -33,18 +32,6 @@ let enumerate_aux f reach =
(* More clever enumeration that flattens basic blocks *)
-let rec int_of_pos = function
- | Coq_xI p -> (int_of_pos p lsl 1) + 1
- | Coq_xO p -> int_of_pos p lsl 1
- | Coq_xH -> 1
-
-let rec pos_of_int n =
- if n = 0 then assert false else
- if n = 1 then Coq_xH else
- if n land 1 = 0
- then Coq_xO (pos_of_int (n lsr 1))
- else Coq_xI (pos_of_int (n lsr 1))
-
module IntSet = Set.Make(struct type t = int let compare = compare end)
(* Determine join points: reachable nodes that have > 1 predecessor *)
@@ -54,7 +41,7 @@ let join_points f =
let reached = ref IntSet.empty in
let reached_twice = ref IntSet.empty in
let rec traverse pc =
- let npc = int_of_pos pc in
+ let npc = P.to_int pc in
if IntSet.mem npc !reached then begin
if not (IntSet.mem npc !reached_twice) then
reached_twice := IntSet.add npc !reached_twice
@@ -74,14 +61,14 @@ let basic_blocks f joins =
or a join point
or the successor of a conditional test *)
let rec start_block pc =
- let npc = int_of_pos pc in
+ let npc = P.to_int pc in
if not (IntSet.mem npc !visited) then begin
visited := IntSet.add npc !visited;
in_block [] max_int pc
end
(* in_block: add pc to block and check successors *)
and in_block blk minpc pc =
- let npc = int_of_pos pc in
+ let npc = P.to_int pc in
let blk = pc :: blk in
let minpc = min npc minpc in
match PTree.get pc f.fn_code with
@@ -103,7 +90,7 @@ let basic_blocks f joins =
(* next_in_block: check if join point and either extend block
or start block *)
and next_in_block blk minpc pc =
- let npc = int_of_pos pc in
+ let npc = P.to_int pc in
if IntSet.mem npc joins
then (end_block blk minpc; start_block pc)
else in_block blk minpc pc
diff --git a/backend/PrintCminor.ml b/backend/PrintCminor.ml
index 59178bd..ef6ba1d 100644
--- a/backend/PrintCminor.ml
+++ b/backend/PrintCminor.ml
@@ -18,7 +18,6 @@
open Format
open Camlcoq
open Datatypes
-open BinPos
open Integers
open AST
open PrintAST
@@ -212,15 +211,15 @@ let rec print_stmt p s =
fprintf p "@[<v 3>{{ %a@;<0 -3>}}@]"
print_stmt s
| Sexit n ->
- fprintf p "exit %d;" (camlint_of_nat n)
+ fprintf p "exit %d;" (Nat.to_int n)
| Sswitch(e, cases, dfl) ->
fprintf p "@[<v 2>switch (%a) {" print_expr e;
List.iter
(fun (n, x) ->
fprintf p "@ case %ld: exit %d;\n"
- (camlint_of_coqint n) (camlint_of_nat x))
+ (camlint_of_coqint n) (Nat.to_int x))
cases;
- fprintf p "@ default: exit %d;\n" (camlint_of_nat dfl);
+ fprintf p "@ default: exit %d;\n" (Nat.to_int dfl);
fprintf p "@;<0 -2>}@]"
| Sreturn None ->
fprintf p "return;"
@@ -247,7 +246,7 @@ let print_function p id f =
print_varlist (f.fn_params, true)
print_sig f.fn_sig;
fprintf p "@[<v 2>{@ ";
- let stksz = camlint_of_z f.fn_stackspace in
+ let stksz = Z.to_int32 f.fn_stackspace in
if stksz <> 0l then
fprintf p "stack %ld;@ " stksz;
if f.fn_vars <> [] then
diff --git a/backend/PrintLTLin.ml b/backend/PrintLTLin.ml
index 4dc311c..4e8efd1 100644
--- a/backend/PrintLTLin.ml
+++ b/backend/PrintLTLin.ml
@@ -71,18 +71,18 @@ let print_instruction pp i =
fprintf pp "%a = builtin %s(%a)@ "
reg res (name_of_external ef) regs args
| Llabel lbl ->
- fprintf pp "%ld:@ " (camlint_of_positive lbl)
+ fprintf pp "%ld:@ " (P.to_int32 lbl)
| Lgoto lbl ->
- fprintf pp "goto %ld@ " (camlint_of_positive lbl)
+ fprintf pp "goto %ld@ " (P.to_int32 lbl)
| Lcond(cond, args, lbl) ->
fprintf pp "if (%a) goto %ld@ "
(PrintOp.print_condition reg) (cond, args)
- (camlint_of_positive lbl)
+ (P.to_int32 lbl)
| Ljumptable(arg, tbl) ->
let tbl = Array.of_list tbl in
fprintf pp "@[<v 2>jumptable (%a)" reg arg;
for i = 0 to Array.length tbl - 1 do
- fprintf pp "@ case %d: goto %ld" i (camlint_of_positive tbl.(i))
+ fprintf pp "@ case %d: goto %ld" i (P.to_int32 tbl.(i))
done;
fprintf pp "@]@ "
| Lreturn None ->
diff --git a/backend/PrintMach.ml b/backend/PrintMach.ml
index dfbc66e..7e6c343 100644
--- a/backend/PrintMach.ml
+++ b/backend/PrintMach.ml
@@ -80,18 +80,18 @@ let print_instruction pp i =
| Mannot(ef, args) ->
fprintf pp "%s(%a)@ " (name_of_external ef) annot_params args
| Mlabel lbl ->
- fprintf pp "%ld:@ " (camlint_of_positive lbl)
+ fprintf pp "%ld:@ " (P.to_int32 lbl)
| Mgoto lbl ->
- fprintf pp "goto %ld@ " (camlint_of_positive lbl)
+ fprintf pp "goto %ld@ " (P.to_int32 lbl)
| Mcond(cond, args, lbl) ->
fprintf pp "if (%a) goto %ld@ "
(PrintOp.print_condition reg) (cond, args)
- (camlint_of_positive lbl)
+ (P.to_int32 lbl)
| Mjumptable(arg, tbl) ->
let tbl = Array.of_list tbl in
fprintf pp "@[<v 2>jumptable (%a)" reg arg;
for i = 0 to Array.length tbl - 1 do
- fprintf pp "@ case %d: goto %ld" i (camlint_of_positive tbl.(i))
+ fprintf pp "@ case %d: goto %ld" i (P.to_int32 tbl.(i))
done;
fprintf pp "@]@ "
| Mreturn ->
diff --git a/backend/PrintRTL.ml b/backend/PrintRTL.ml
index 4cd3871..0bafcde 100644
--- a/backend/PrintRTL.ml
+++ b/backend/PrintRTL.ml
@@ -25,7 +25,7 @@ open PrintOp
(* Printing of RTL code *)
let reg pp r =
- fprintf pp "x%ld" (camlint_of_positive r)
+ fprintf pp "x%ld" (P.to_int32 r)
let rec regs pp = function
| [] -> ()
@@ -37,14 +37,14 @@ let ros pp = function
| Coq_inr s -> fprintf pp "\"%s\"" (extern_atom s)
let print_succ pp s dfl =
- let s = camlint_of_positive s in
+ let s = P.to_int32 s in
if s <> dfl then fprintf pp " goto %ld@ " s
let print_instruction pp (pc, i) =
fprintf pp "%5ld: " pc;
match i with
| Inop s ->
- let s = camlint_of_positive s in
+ let s = P.to_int32 s in
if s = Int32.pred pc
then fprintf pp "nop@ "
else fprintf pp "goto %ld@ " s
@@ -77,12 +77,12 @@ let print_instruction pp (pc, i) =
| Icond(cond, args, s1, s2) ->
fprintf pp "if (%a) goto %ld else goto %ld@ "
(PrintOp.print_condition reg) (cond, args)
- (camlint_of_positive s1) (camlint_of_positive s2)
+ (P.to_int32 s1) (P.to_int32 s2)
| Ijumptable(arg, tbl) ->
let tbl = Array.of_list tbl in
fprintf pp "@[<v 2>jumptable (%a)" reg arg;
for i = 0 to Array.length tbl - 1 do
- fprintf pp "@ case %d: goto %ld" i (camlint_of_positive tbl.(i))
+ fprintf pp "@ case %d: goto %ld" i (P.to_int32 tbl.(i))
done;
fprintf pp "@]@ "
| Ireturn None ->
@@ -96,7 +96,7 @@ let print_function pp id f =
List.sort
(fun (pc1, _) (pc2, _) -> Pervasives.compare pc2 pc1)
(List.map
- (fun (pc, i) -> (camlint_of_positive pc, i))
+ (fun (pc, i) -> (P.to_int32 pc, i))
(PTree.elements f.fn_code)) in
print_succ pp f.fn_entrypoint
(match instrs with (pc1, _) :: _ -> pc1 | [] -> -1l);
diff --git a/backend/RREproof.v b/backend/RREproof.v
index 8926fe4..40632f7 100644
--- a/backend/RREproof.v
+++ b/backend/RREproof.v
@@ -248,7 +248,7 @@ Proof.
induction ll; intros; simpl.
apply H. simpl. auto.
apply IHll. intros. unfold Locmap.set.
- destruct (Loc.eq a l). auto. destruct (Loc.overlap a l) as []_eqn. auto.
+ destruct (Loc.eq a l). auto. destruct (Loc.overlap a l) eqn:?. auto.
apply H. simpl. split; auto. apply Loc.diff_sym. apply Loc.non_overlap_diff; auto.
Qed.
@@ -396,7 +396,7 @@ Opaque destroyed_at_move_regs.
simpl in SAFE.
assert (SAFE': sm = false \/ ~In r destroyed_at_move_regs /\ safe_move_insertion b = true).
destruct (in_dec mreg_eq r destroyed_at_move_regs); simpl in SAFE; intuition congruence.
- destruct (is_incoming sl) as []_eqn.
+ destruct (is_incoming sl) eqn:?.
(* incoming, stays as getstack *)
assert (UGS: forall rs, undef_getstack sl rs = Locmap.set (R IT1) Vundef rs).
destruct sl; simpl in Heqb0; discriminate || auto.
@@ -419,11 +419,11 @@ Opaque destroyed_at_move_regs.
rewrite <- EQ1; rewrite EQ; rewrite EQ2. rewrite locmap_set_reg_same.
apply match_states_regular with sm; auto; tauto.
(* found an equation *)
- destruct (find_reg_containing sl eqs) as [r'|]_eqn.
+ destruct (find_reg_containing sl eqs) as [r'|] eqn:?.
exploit EQH. eapply find_reg_containing_sound; eauto.
simpl; intro EQ.
(* turned into a move *)
- destruct (safe_move_insertion b) as []_eqn.
+ destruct (safe_move_insertion b) eqn:?.
left; econstructor; split. constructor. simpl; eauto.
rewrite UGS. rewrite <- EQ.
apply match_states_regular with true; auto.
diff --git a/backend/RREtyping.v b/backend/RREtyping.v
index 2501c7f..539fb20 100644
--- a/backend/RREtyping.v
+++ b/backend/RREtyping.v
@@ -91,9 +91,9 @@ Proof.
assert (WC: wt_code f c) by (red; auto with coqlib).
clear H.
inv WI; auto 10 with linearty.
- destruct (is_incoming s) as []_eqn. auto with linearty.
+ destruct (is_incoming s) eqn:?. auto with linearty.
destruct (contains_equation s r eqs). auto with linearty.
- destruct (find_reg_containing s eqs) as [r'|]_eqn; auto with linearty.
+ destruct (find_reg_containing s eqs) as [r'|] eqn:?; auto with linearty.
assert (mreg_type r' = mreg_type r).
exploit H0. eapply find_reg_containing_sound; eauto. simpl. congruence.
destruct (safe_move_insertion c); auto 10 with linearty.
diff --git a/backend/Reloadtyping.v b/backend/Reloadtyping.v
index 99c89ab..9f5563c 100644
--- a/backend/Reloadtyping.v
+++ b/backend/Reloadtyping.v
@@ -289,7 +289,7 @@ Proof.
destruct ros. destruct H2 as [A [B C]]. auto 10 with reloadty.
auto 10 with reloadty.
- destruct (ef_reloads ef) as [] _eqn.
+ destruct (ef_reloads ef) as [] eqn:?.
assert (arity_ok (sig_args (ef_sig ef)) = true) by intuition congruence.
assert (map mreg_type (regs_for args) = map Loc.type args).
apply wt_regs_for. apply arity_ok_enough. congruence.
diff --git a/backend/Renumberproof.v b/backend/Renumberproof.v
index d086010..4488e49 100644
--- a/backend/Renumberproof.v
+++ b/backend/Renumberproof.v
@@ -91,7 +91,7 @@ Proof.
(* induction *)
rewrite PTree.gsspec in H2. unfold renum_node. destruct (peq x k).
inv H2. rewrite H3. apply PTree.gss.
- destruct f!k as [y'|]_eqn.
+ destruct f!k as [y'|] eqn:?.
rewrite PTree.gso. eauto. red; intros; subst y'. elim n. eapply f_inj; eauto.
eauto.
Qed.
@@ -111,7 +111,7 @@ Proof.
intros.
destruct (postorder_correct (successors f) f.(fn_entrypoint)) as [A B].
fold (pnum f) in *.
- unfold renum_pc. destruct (pnum f)! pc as [pc'|]_eqn.
+ unfold renum_pc. destruct (pnum f)! pc as [pc'|] eqn:?.
simpl. eapply renum_cfg_nodes; eauto.
elim (B pc); auto. unfold successors. rewrite PTree.gmap1. rewrite H. simpl. congruence.
Qed.
diff --git a/backend/Selectionproof.v b/backend/Selectionproof.v
index 09dc0ff..0269438 100644
--- a/backend/Selectionproof.v
+++ b/backend/Selectionproof.v
@@ -166,10 +166,10 @@ Lemma classify_call_correct:
end.
Proof.
unfold classify_call; intros.
- destruct (expr_is_addrof_ident a) as [id|]_eqn.
+ destruct (expr_is_addrof_ident a) as [id|] eqn:?.
exploit expr_is_addrof_ident_correct; eauto. intros EQ; subst a.
inv H. inv H2.
- destruct (Genv.find_symbol ge id) as [b|]_eqn.
+ destruct (Genv.find_symbol ge id) as [b|] eqn:?.
rewrite Genv.find_funct_find_funct_ptr in H0.
rewrite H0.
destruct fd. exists b; auto.
@@ -567,7 +567,7 @@ Proof.
apply call_cont_commut; eauto.
rewrite H.
destruct (find_label lbl (sel_stmt ge (Cminor.fn_body f)) (call_cont k'0))
- as [[s'' k'']|]_eqn; intros; try contradiction.
+ as [[s'' k'']|] eqn:?; intros; try contradiction.
destruct H0.
left; econstructor; split.
econstructor; eauto.
diff --git a/backend/Stackingproof.v b/backend/Stackingproof.v
index 6c4e43f..b731487 100644
--- a/backend/Stackingproof.v
+++ b/backend/Stackingproof.v
@@ -2171,7 +2171,7 @@ Proof.
exists b; exists tf; split; auto. simpl.
generalize (AG m0). rewrite EQ. intro INJ. inv INJ.
inv MG. rewrite DOMAIN in H2. inv H2. simpl. auto. eapply FUNCTIONS; eauto.
- destruct (Genv.find_symbol ge i) as [b|]_eqn; try discriminate.
+ destruct (Genv.find_symbol ge i) as [b|] eqn:?; try discriminate.
exploit function_ptr_translated; eauto. intros [tf [A B]].
exists b; exists tf; split; auto. simpl.
rewrite symbols_preserved. auto.
@@ -2398,7 +2398,7 @@ Proof.
econstructor; split.
apply plus_one. eapply exec_Mgetparam; eauto.
rewrite (unfold_transf_function _ _ TRANSL). unfold fn_link_ofs.
- eapply index_contains_load_stack with (idx := FI_link). eauto. eapply agree_link; eauto.
+ eapply index_contains_load_stack with (idx := FI_link). eapply TRANSL. eapply agree_link; eauto.
simpl parent_sp.
change (offset_of_index (make_env (function_bounds f)) (FI_arg z t))
with (offset_of_index (make_env (function_bounds f0)) (FI_arg z t)).
diff --git a/cfrontend/C2C.ml b/cfrontend/C2C.ml
index d425693..3830ca7 100644
--- a/cfrontend/C2C.ml
+++ b/cfrontend/C2C.ml
@@ -125,16 +125,12 @@ let name_for_string_literal env s =
id
let typeStringLiteral s =
- Tarray(Tint(I8, Unsigned, noattr),
- z_of_camlint(Int32.of_int(String.length s + 1)),
- noattr)
+ Tarray(Tint(I8, Unsigned, noattr), Z.of_uint (String.length s + 1), noattr)
let global_for_string s id =
let init = ref [] in
let add_char c =
- init :=
- AST.Init_int8(coqint_of_camlint(Int32.of_int(Char.code c)))
- :: !init in
+ init := AST.Init_int8(Z.of_uint(Char.code c)) :: !init in
add_char '\000';
for i = String.length s - 1 downto 0 do add_char s.[i] done;
(id, Gvar {gvar_info = typeStringLiteral s; gvar_init = !init;
@@ -344,8 +340,8 @@ let supported_return_type env ty =
(** Floating point constants *)
let z_of_str hex str fst =
- let res = ref BinInt.Z0 in
- let base = if hex then 16l else 10l in
+ let res = ref Z.Z0 in
+ let base = if hex then 16 else 10 in
for i = fst to String.length str - 1 do
let d = int_of_char str.[i] in
let d =
@@ -356,27 +352,25 @@ let z_of_str hex str fst =
else
d - int_of_char '0'
in
- let d = Int32.of_int d in
- assert (d >= 0l && d < base);
- res := BinInt.coq_Zplus
- (BinInt.coq_Zmult (z_of_camlint base) !res) (z_of_camlint d)
+ assert (d >= 0 && d < base);
+ res := Z.add (Z.mul (Z.of_uint base) !res) (Z.of_uint d)
done;
!res
let convertFloat f kind =
let mant = z_of_str f.C.hex (f.C.intPart ^ f.C.fracPart) 0 in
match mant with
- | BinInt.Z0 -> Float.zero
- | BinInt.Zpos mant ->
+ | Z.Z0 -> Float.zero
+ | Z.Zpos mant ->
let sgExp = match f.C.exp.[0] with '+' | '-' -> true | _ -> false in
let exp = z_of_str false f.C.exp (if sgExp then 1 else 0) in
- let exp = if f.C.exp.[0] = '-' then BinInt.coq_Zopp exp else exp in
+ let exp = if f.C.exp.[0] = '-' then Z.neg exp else exp in
let shift_exp =
- Int32.of_int ((if f.C.hex then 4 else 1) * String.length f.C.fracPart) in
- let exp = BinInt.coq_Zminus exp (z_of_camlint shift_exp) in
+ (if f.C.hex then 4 else 1) * String.length f.C.fracPart in
+ let exp = Z.sub exp (Z.of_uint shift_exp) in
- let base = positive_of_camlint (if f.C.hex then 16l else 10l) in
+ let base = P.of_int (if f.C.hex then 16 else 10) in
begin match kind with
| FFloat ->
@@ -384,7 +378,8 @@ let convertFloat f kind =
| FDouble | FLongDouble ->
Float.build_from_parsed64 base mant exp
end
- | BinInt.Zneg _ -> assert false
+
+ | Z.Zneg _ -> assert false
(** Expressions *)
@@ -752,7 +747,7 @@ let string_of_errmsg msg =
let string_of_err = function
| Errors.MSG s -> camlstring_of_coqstring s
| Errors.CTX i -> extern_atom i
- | Errors.POS i -> sprintf "%ld" (camlint_of_positive i)
+ | Errors.POS i -> Z.to_string (Z.Zpos i)
in String.concat "" (List.map string_of_err msg)
let rec convertInit env init =
diff --git a/cfrontend/Cexec.v b/cfrontend/Cexec.v
index c370c60..ded6b72 100644
--- a/cfrontend/Cexec.v
+++ b/cfrontend/Cexec.v
@@ -132,7 +132,7 @@ Proof.
intros. destruct v; destruct t; simpl in H; inv H.
constructor.
constructor.
- destruct (Genv.invert_symbol ge b) as [id|]_eqn; inv H1.
+ destruct (Genv.invert_symbol ge b) as [id|] eqn:?; inv H1.
constructor. apply Genv.invert_find_symbol; auto.
Qed.
@@ -148,8 +148,8 @@ Lemma list_eventval_of_val_sound:
Proof with try discriminate.
induction vl; destruct tl; simpl; intros; inv H.
constructor.
- destruct (eventval_of_val a t) as [ev1|]_eqn...
- destruct (list_eventval_of_val vl tl) as [evl'|]_eqn...
+ destruct (eventval_of_val a t) as [ev1|] eqn:?...
+ destruct (list_eventval_of_val vl tl) as [evl'|] eqn:?...
inv H1. constructor. apply eventval_of_val_sound; auto. eauto.
Qed.
@@ -166,7 +166,7 @@ Proof.
intros. destruct ev; destruct t; simpl in H; inv H.
constructor.
constructor.
- destruct (Genv.find_symbol ge i) as [b|]_eqn; inv H1.
+ destruct (Genv.find_symbol ge i) as [b|] eqn:?; inv H1.
constructor. auto.
Qed.
@@ -207,8 +207,8 @@ Ltac mydestr :=
match goal with
| [ |- None = Some _ -> _ ] => intro X; discriminate
| [ |- Some _ = Some _ -> _ ] => intro X; inv X
- | [ |- match ?x with Some _ => _ | None => _ end = Some _ -> _ ] => destruct x as []_eqn; mydestr
- | [ |- match ?x with true => _ | false => _ end = Some _ -> _ ] => destruct x as []_eqn; mydestr
+ | [ |- match ?x with Some _ => _ | None => _ end = Some _ -> _ ] => destruct x eqn:?; mydestr
+ | [ |- match ?x with true => _ | false => _ end = Some _ -> _ ] => destruct x eqn:?; mydestr
| [ |- match ?x with left _ => _ | right _ => _ end = Some _ -> _ ] => destruct x; mydestr
| _ => idtac
end.
@@ -331,7 +331,7 @@ Lemma do_deref_loc_sound:
deref_loc ge ty m b ofs t v /\ possible_trace w t w'.
Proof.
unfold do_deref_loc; intros until v.
- destruct (access_mode ty) as []_eqn; mydestr.
+ destruct (access_mode ty) eqn:?; mydestr.
intros. exploit do_volatile_load_sound; eauto. intuition. eapply deref_loc_volatile; eauto.
split. eapply deref_loc_value; eauto. constructor.
split. eapply deref_loc_reference; eauto. constructor.
@@ -356,7 +356,7 @@ Lemma do_assign_loc_sound:
assign_loc ge ty m b ofs v t m' /\ possible_trace w t w'.
Proof.
unfold do_assign_loc; intros until m'.
- destruct (access_mode ty) as []_eqn; mydestr.
+ destruct (access_mode ty) eqn:?; mydestr.
intros. exploit do_volatile_store_sound; eauto. intuition. eapply assign_loc_volatile; eauto.
split. eapply assign_loc_value; eauto. constructor.
destruct v; mydestr. destruct a as [P [Q R]].
@@ -558,7 +558,7 @@ Proof with try congruence.
intros. exploit VSTORE; eauto. intros [A B]. split; auto. exists b; auto.
(* EF_malloc *)
unfold do_ef_malloc. destruct vargs... destruct v... destruct vargs...
- destruct (Mem.alloc m (-4) (Int.unsigned i)) as [m1 b]_eqn. mydestr.
+ destruct (Mem.alloc m (-4) (Int.unsigned i)) as [m1 b] eqn:?. mydestr.
split. econstructor; eauto. constructor.
(* EF_free *)
unfold do_ef_free. destruct vargs... destruct v... destruct vargs...
@@ -1170,7 +1170,7 @@ Definition list_reducts_ok (al: exprlist) (m: mem) (ll: reducts exprlist) : Prop
Ltac monadInv :=
match goal with
| [ H: match ?x with Some _ => _ | None => None end = Some ?y |- _ ] =>
- destruct x as []_eqn; [monadInv|discriminate]
+ destruct x eqn:?; [monadInv|discriminate]
| [ H: match ?x with left _ => _ | right _ => None end = Some ?y |- _ ] =>
destruct x; [monadInv|discriminate]
| _ => idtac
@@ -1338,8 +1338,8 @@ Lemma is_val_list_all_values:
forall al vtl, is_val_list al = Some vtl -> exprlist_all_values al.
Proof.
induction al; simpl; intros. auto.
- destruct (is_val r1) as [[v ty]|]_eqn; try discriminate.
- destruct (is_val_list al) as [vtl'|]_eqn; try discriminate.
+ destruct (is_val r1) as [[v ty]|] eqn:?; try discriminate.
+ destruct (is_val_list al) as [vtl'|] eqn:?; try discriminate.
rewrite (is_val_inv _ _ _ Heqo). eauto.
Qed.
@@ -1360,91 +1360,91 @@ Proof with (try (apply not_invert_ok; simpl; intro; myinv; intuition congruence;
(* Eval *)
split; intros. tauto. simpl; congruence.
(* Evar *)
- destruct (e!x) as [[b ty']|]_eqn.
+ destruct (e!x) as [[b ty']|] eqn:?.
destruct (type_eq ty ty')...
subst. apply topred_ok; auto. apply red_var_local; auto.
- destruct (Genv.find_symbol ge x) as [b|]_eqn...
- destruct (type_of_global ge b) as [ty'|]_eqn...
+ destruct (Genv.find_symbol ge x) as [b|] eqn:?...
+ destruct (type_of_global ge b) as [ty'|] eqn:?...
destruct (type_eq ty ty')...
subst. apply topred_ok; auto. apply red_var_global; auto.
(* Efield *)
- destruct (is_val a) as [[v ty'] | ]_eqn.
+ destruct (is_val a) as [[v ty'] | ] eqn:?.
rewrite (is_val_inv _ _ _ Heqo).
destruct v...
destruct ty'...
(* top struct *)
- destruct (field_offset f f0) as [delta|]_eqn...
+ destruct (field_offset f f0) as [delta|] eqn:?...
apply topred_ok; auto. apply red_field_struct; auto.
(* top union *)
apply topred_ok; auto. apply red_field_union; auto.
(* in depth *)
eapply incontext_ok; eauto.
(* Evalof *)
- destruct (is_loc a) as [[[b ofs] ty'] | ]_eqn. rewrite (is_loc_inv _ _ _ _ Heqo).
+ destruct (is_loc a) as [[[b ofs] ty'] | ] eqn:?. rewrite (is_loc_inv _ _ _ _ Heqo).
(* top *)
destruct (type_eq ty ty')... subst ty'.
- destruct (do_deref_loc w ty m b ofs) as [[[w' t] v] | ]_eqn.
+ destruct (do_deref_loc w ty m b ofs) as [[[w' t] v] | ] eqn:?.
exploit do_deref_loc_sound; eauto. intros [A B].
apply topred_ok; auto. red. split. apply red_rvalof; auto. exists w'; auto.
apply not_invert_ok; simpl; intros; myinv. exploit do_deref_loc_complete; eauto. congruence.
(* depth *)
eapply incontext_ok; eauto.
(* Ederef *)
- destruct (is_val a) as [[v ty'] | ]_eqn. rewrite (is_val_inv _ _ _ Heqo).
+ destruct (is_val a) as [[v ty'] | ] eqn:?. rewrite (is_val_inv _ _ _ Heqo).
(* top *)
destruct v... apply topred_ok; auto. apply red_deref; auto.
(* depth *)
eapply incontext_ok; eauto.
(* Eaddrof *)
- destruct (is_loc a) as [[[b ofs] ty'] | ]_eqn. rewrite (is_loc_inv _ _ _ _ Heqo).
+ destruct (is_loc a) as [[[b ofs] ty'] | ] eqn:?. rewrite (is_loc_inv _ _ _ _ Heqo).
(* top *)
apply topred_ok; auto. split. apply red_addrof; auto. exists w; constructor.
(* depth *)
eapply incontext_ok; eauto.
(* unop *)
- destruct (is_val a) as [[v ty'] | ]_eqn. rewrite (is_val_inv _ _ _ Heqo).
+ destruct (is_val a) as [[v ty'] | ] eqn:?. rewrite (is_val_inv _ _ _ Heqo).
(* top *)
- destruct (sem_unary_operation op v ty') as [v'|]_eqn...
+ destruct (sem_unary_operation op v ty') as [v'|] eqn:?...
apply topred_ok; auto. split. apply red_unop; auto. exists w; constructor.
(* depth *)
eapply incontext_ok; eauto.
(* binop *)
- destruct (is_val a1) as [[v1 ty1] | ]_eqn.
- destruct (is_val a2) as [[v2 ty2] | ]_eqn.
+ destruct (is_val a1) as [[v1 ty1] | ] eqn:?.
+ destruct (is_val a2) as [[v2 ty2] | ] eqn:?.
rewrite (is_val_inv _ _ _ Heqo). rewrite (is_val_inv _ _ _ Heqo0).
(* top *)
- destruct (sem_binary_operation op v1 ty1 v2 ty2 m) as [v|]_eqn...
+ destruct (sem_binary_operation op v1 ty1 v2 ty2 m) as [v|] eqn:?...
apply topred_ok; auto. split. apply red_binop; auto. exists w; constructor.
(* depth *)
eapply incontext2_ok; eauto.
eapply incontext2_ok; eauto.
(* cast *)
- destruct (is_val a) as [[v ty'] | ]_eqn. rewrite (is_val_inv _ _ _ Heqo).
+ destruct (is_val a) as [[v ty'] | ] eqn:?. rewrite (is_val_inv _ _ _ Heqo).
(* top *)
- destruct (sem_cast v ty' ty) as [v'|]_eqn...
+ destruct (sem_cast v ty' ty) as [v'|] eqn:?...
apply topred_ok; auto. split. apply red_cast; auto. exists w; constructor.
(* depth *)
eapply incontext_ok; eauto.
(* seqand *)
- destruct (is_val a1) as [[v ty'] | ]_eqn. rewrite (is_val_inv _ _ _ Heqo).
+ destruct (is_val a1) as [[v ty'] | ] eqn:?. rewrite (is_val_inv _ _ _ Heqo).
(* top *)
- destruct (bool_val v ty') as [v'|]_eqn... destruct v'.
+ destruct (bool_val v ty') as [v'|] eqn:?... destruct v'.
apply topred_ok; auto. split. eapply red_seqand_true; eauto. exists w; constructor.
apply topred_ok; auto. split. eapply red_seqand_false; eauto. exists w; constructor.
(* depth *)
eapply incontext_ok; eauto.
(* seqor *)
- destruct (is_val a1) as [[v ty'] | ]_eqn. rewrite (is_val_inv _ _ _ Heqo).
+ destruct (is_val a1) as [[v ty'] | ] eqn:?. rewrite (is_val_inv _ _ _ Heqo).
(* top *)
- destruct (bool_val v ty') as [v'|]_eqn... destruct v'.
+ destruct (bool_val v ty') as [v'|] eqn:?... destruct v'.
apply topred_ok; auto. split. eapply red_seqor_true; eauto. exists w; constructor.
apply topred_ok; auto. split. eapply red_seqor_false; eauto. exists w; constructor.
(* depth *)
eapply incontext_ok; eauto.
(* condition *)
- destruct (is_val a1) as [[v ty'] | ]_eqn. rewrite (is_val_inv _ _ _ Heqo).
+ destruct (is_val a1) as [[v ty'] | ] eqn:?. rewrite (is_val_inv _ _ _ Heqo).
(* top *)
- destruct (bool_val v ty') as [v'|]_eqn...
+ destruct (bool_val v ty') as [v'|] eqn:?...
apply topred_ok; auto. split. eapply red_condition; eauto. exists w; constructor.
(* depth *)
eapply incontext_ok; eauto.
@@ -1453,13 +1453,13 @@ Proof with (try (apply not_invert_ok; simpl; intro; myinv; intuition congruence;
(* alignof *)
apply topred_ok; auto. split. apply red_alignof. exists w; constructor.
(* assign *)
- destruct (is_loc a1) as [[[b ofs] ty1] | ]_eqn.
- destruct (is_val a2) as [[v2 ty2] | ]_eqn.
+ destruct (is_loc a1) as [[[b ofs] ty1] | ] eqn:?.
+ destruct (is_val a2) as [[v2 ty2] | ] eqn:?.
rewrite (is_loc_inv _ _ _ _ Heqo). rewrite (is_val_inv _ _ _ Heqo0).
(* top *)
destruct (type_eq ty1 ty)... subst ty1.
- destruct (sem_cast v2 ty2 ty) as [v|]_eqn...
- destruct (do_assign_loc w ty m b ofs v) as [[[w' t] m']|]_eqn.
+ destruct (sem_cast v2 ty2 ty) as [v|] eqn:?...
+ destruct (do_assign_loc w ty m b ofs v) as [[[w' t] m']|] eqn:?.
exploit do_assign_loc_sound; eauto. intros [P Q].
apply topred_ok; auto. split. apply red_assign; auto. exists w'; auto.
apply not_invert_ok; simpl; intros; myinv. exploit do_assign_loc_complete; eauto. congruence.
@@ -1467,12 +1467,12 @@ Proof with (try (apply not_invert_ok; simpl; intro; myinv; intuition congruence;
eapply incontext2_ok; eauto.
eapply incontext2_ok; eauto.
(* assignop *)
- destruct (is_loc a1) as [[[b ofs] ty1] | ]_eqn.
- destruct (is_val a2) as [[v2 ty2] | ]_eqn.
+ destruct (is_loc a1) as [[[b ofs] ty1] | ] eqn:?.
+ destruct (is_val a2) as [[v2 ty2] | ] eqn:?.
rewrite (is_loc_inv _ _ _ _ Heqo). rewrite (is_val_inv _ _ _ Heqo0).
(* top *)
destruct (type_eq ty1 ty)... subst ty1.
- destruct (do_deref_loc w ty m b ofs) as [[[w' t] v] | ]_eqn.
+ destruct (do_deref_loc w ty m b ofs) as [[[w' t] v] | ] eqn:?.
exploit do_deref_loc_sound; eauto. intros [A B].
apply topred_ok; auto. red. split. apply red_assignop; auto. exists w'; auto.
apply not_invert_ok; simpl; intros; myinv. exploit do_deref_loc_complete; eauto. congruence.
@@ -1480,30 +1480,30 @@ Proof with (try (apply not_invert_ok; simpl; intro; myinv; intuition congruence;
eapply incontext2_ok; eauto.
eapply incontext2_ok; eauto.
(* postincr *)
- destruct (is_loc a) as [[[b ofs] ty'] | ]_eqn. rewrite (is_loc_inv _ _ _ _ Heqo).
+ destruct (is_loc a) as [[[b ofs] ty'] | ] eqn:?. rewrite (is_loc_inv _ _ _ _ Heqo).
(* top *)
destruct (type_eq ty' ty)... subst ty'.
- destruct (do_deref_loc w ty m b ofs) as [[[w' t] v] | ]_eqn.
+ destruct (do_deref_loc w ty m b ofs) as [[[w' t] v] | ] eqn:?.
exploit do_deref_loc_sound; eauto. intros [A B].
apply topred_ok; auto. red. split. apply red_postincr; auto. exists w'; auto.
apply not_invert_ok; simpl; intros; myinv. exploit do_deref_loc_complete; eauto. congruence.
(* depth *)
eapply incontext_ok; eauto.
(* comma *)
- destruct (is_val a1) as [[v ty'] | ]_eqn. rewrite (is_val_inv _ _ _ Heqo).
+ destruct (is_val a1) as [[v ty'] | ] eqn:?. rewrite (is_val_inv _ _ _ Heqo).
(* top *)
destruct (type_eq (typeof a2) ty)... subst ty.
apply topred_ok; auto. split. apply red_comma; auto. exists w; constructor.
(* depth *)
eapply incontext_ok; eauto.
(* call *)
- destruct (is_val a) as [[vf tyf] | ]_eqn.
- destruct (is_val_list rargs) as [vtl | ]_eqn.
+ destruct (is_val a) as [[vf tyf] | ] eqn:?.
+ destruct (is_val_list rargs) as [vtl | ] eqn:?.
rewrite (is_val_inv _ _ _ Heqo). exploit is_val_list_all_values; eauto. intros ALLVAL.
(* top *)
- destruct (classify_fun tyf) as [tyargs tyres|]_eqn...
- destruct (Genv.find_funct ge vf) as [fd|]_eqn...
- destruct (sem_cast_arguments vtl tyargs) as [vargs|]_eqn...
+ destruct (classify_fun tyf) as [tyargs tyres|] eqn:?...
+ destruct (Genv.find_funct ge vf) as [fd|] eqn:?...
+ destruct (sem_cast_arguments vtl tyargs) as [vargs|] eqn:?...
destruct (type_eq (type_of_fundef fd) (Tfunction tyargs tyres))...
apply topred_ok; auto. red. split; auto. eapply red_Ecall; eauto.
eapply sem_cast_arguments_sound; eauto.
@@ -1516,11 +1516,11 @@ Proof with (try (apply not_invert_ok; simpl; intro; myinv; intuition congruence;
eapply incontext2_list_ok; eauto.
eapply incontext2_list_ok; eauto.
(* builtin *)
- destruct (is_val_list rargs) as [vtl | ]_eqn.
+ destruct (is_val_list rargs) as [vtl | ] eqn:?.
exploit is_val_list_all_values; eauto. intros ALLVAL.
(* top *)
- destruct (sem_cast_arguments vtl tyargs) as [vargs|]_eqn...
- destruct (do_external ef w vargs m) as [[[[? ?] v] m'] | ]_eqn...
+ destruct (sem_cast_arguments vtl tyargs) as [vargs|] eqn:?...
+ destruct (do_external ef w vargs m) as [[[[? ?] v] m'] | ] eqn:?...
exploit do_ef_external_sound; eauto. intros [EC PT].
apply topred_ok; auto. red. split; auto. eapply red_builtin; eauto.
eapply sem_cast_arguments_sound; eauto.
@@ -1537,9 +1537,9 @@ Proof with (try (apply not_invert_ok; simpl; intro; myinv; intuition congruence;
(* loc *)
split; intros. tauto. simpl; congruence.
(* paren *)
- destruct (is_val a) as [[v ty'] | ]_eqn. rewrite (is_val_inv _ _ _ Heqo).
+ destruct (is_val a) as [[v ty'] | ] eqn:?. rewrite (is_val_inv _ _ _ Heqo).
(* top *)
- destruct (sem_cast v ty' ty) as [v'|]_eqn...
+ destruct (sem_cast v ty' ty) as [v'|] eqn:?...
apply topred_ok; auto. split. apply red_paren; auto. exists w; constructor.
(* depth *)
eapply incontext_ok; eauto.
@@ -1556,8 +1556,8 @@ Lemma step_exprlist_val_list:
Proof.
induction al; simpl; intros.
auto.
- destruct (is_val r1) as [[v1 ty1]|]_eqn; try congruence.
- destruct (is_val_list al) as []_eqn; try congruence.
+ destruct (is_val r1) as [[v1 ty1]|] eqn:?; try congruence.
+ destruct (is_val_list al) eqn:?; try congruence.
rewrite (is_val_inv _ _ _ Heqo).
rewrite IHal. auto. congruence.
Qed.
@@ -1717,75 +1717,78 @@ with step_exprlist_context:
Proof.
induction 1; simpl; intros.
(* top *)
- red. destruct (step_expr k a m); auto. intros.
- replace (fun x => C1 x) with C1; auto. apply extensionality; auto.
+ red. destruct (step_expr k a m); auto.
+ try (* no eta in 8.3 *)
+ (intros;
+ replace (fun x => C1 x) with C1 by (apply extensionality; auto);
+ auto).
(* deref *)
eapply reducts_incl_trans with (C' := fun x => Ederef x ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* field *)
eapply reducts_incl_trans with (C' := fun x => Efield x f ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* valof *)
eapply reducts_incl_trans with (C' := fun x => Evalof x ty); eauto.
- destruct (is_loc (C a)) as [[[b ofs] ty']|]_eqn; eauto.
+ destruct (is_loc (C a)) as [[[b ofs] ty']|] eqn:?; eauto.
(* addrof *)
eapply reducts_incl_trans with (C' := fun x => Eaddrof x ty); eauto.
- destruct (is_loc (C a)) as [[[b ofs] ty']|]_eqn; eauto.
+ destruct (is_loc (C a)) as [[[b ofs] ty']|] eqn:?; eauto.
(* unop *)
eapply reducts_incl_trans with (C' := fun x => Eunop op x ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* binop left *)
eapply reducts_incl_trans with (C' := fun x => Ebinop op x e2 ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* binop right *)
eapply reducts_incl_trans with (C' := fun x => Ebinop op e1 x ty); eauto.
- destruct (is_val e1) as [[v1 ty1]|]_eqn; eauto.
- destruct (is_val (C a)) as [[v2 ty2]|]_eqn; eauto.
+ destruct (is_val e1) as [[v1 ty1]|] eqn:?; eauto.
+ destruct (is_val (C a)) as [[v2 ty2]|] eqn:?; eauto.
(* cast *)
eapply reducts_incl_trans with (C' := fun x => Ecast x ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* seqand *)
eapply reducts_incl_trans with (C' := fun x => Eseqand x r2 ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* seqor *)
eapply reducts_incl_trans with (C' := fun x => Eseqor x r2 ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* condition *)
eapply reducts_incl_trans with (C' := fun x => Econdition x r2 r3 ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* assign left *)
eapply reducts_incl_trans with (C' := fun x => Eassign x e2 ty); eauto.
- destruct (is_loc (C a)) as [[[b ofs] ty']|]_eqn; eauto.
+ destruct (is_loc (C a)) as [[[b ofs] ty']|] eqn:?; eauto.
(* assign right *)
eapply reducts_incl_trans with (C' := fun x => Eassign e1 x ty); eauto.
- destruct (is_loc e1) as [[[b ofs] ty1]|]_eqn; eauto.
- destruct (is_val (C a)) as [[v2 ty2]|]_eqn; eauto.
+ destruct (is_loc e1) as [[[b ofs] ty1]|] eqn:?; eauto.
+ destruct (is_val (C a)) as [[v2 ty2]|] eqn:?; eauto.
(* assignop left *)
eapply reducts_incl_trans with (C' := fun x => Eassignop op x e2 tyres ty); eauto.
- destruct (is_loc (C a)) as [[[b ofs] ty']|]_eqn; eauto.
+ destruct (is_loc (C a)) as [[[b ofs] ty']|] eqn:?; eauto.
(* assignop right *)
eapply reducts_incl_trans with (C' := fun x => Eassignop op e1 x tyres ty); eauto.
- destruct (is_loc e1) as [[[b ofs] ty1]|]_eqn; eauto.
- destruct (is_val (C a)) as [[v2 ty2]|]_eqn; eauto.
+ destruct (is_loc e1) as [[[b ofs] ty1]|] eqn:?; eauto.
+ destruct (is_val (C a)) as [[v2 ty2]|] eqn:?; eauto.
(* postincr *)
eapply reducts_incl_trans with (C' := fun x => Epostincr id x ty); eauto.
- destruct (is_loc (C a)) as [[[b ofs] ty']|]_eqn; eauto.
+ destruct (is_loc (C a)) as [[[b ofs] ty']|] eqn:?; eauto.
(* call left *)
eapply reducts_incl_trans with (C' := fun x => Ecall x el ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* call right *)
eapply reducts_incl_trans with (C' := fun x => Ecall e1 x ty). apply step_exprlist_context. auto.
- destruct (is_val e1) as [[v1 ty1]|]_eqn; eauto.
- destruct (is_val_list (C a)) as [vl|]_eqn; eauto.
+ destruct (is_val e1) as [[v1 ty1]|] eqn:?; eauto.
+ destruct (is_val_list (C a)) as [vl|] eqn:?; eauto.
(* builtin *)
eapply reducts_incl_trans with (C' := fun x => Ebuiltin ef tyargs x ty). apply step_exprlist_context. auto.
- destruct (is_val_list (C a)) as [vl|]_eqn; eauto.
+ destruct (is_val_list (C a)) as [vl|] eqn:?; eauto.
(* comma *)
eapply reducts_incl_trans with (C' := fun x => Ecomma x e2 ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
(* paren *)
eapply reducts_incl_trans with (C' := fun x => Eparen x ty); eauto.
- destruct (is_val (C a)) as [[v ty']|]_eqn; eauto.
+ destruct (is_val (C a)) as [[v ty']|] eqn:?; eauto.
induction 1; simpl; intros.
(* cons left *)
@@ -1804,7 +1807,7 @@ Lemma not_stuckred_imm_safe:
(forall C, ~In (C, Stuckred) (step_expr k a m)) -> imm_safe_t k a m.
Proof.
intros. generalize (step_expr_sound a k m). intros [A B].
- destruct (step_expr k a m) as [|[C rd] res]_eqn.
+ destruct (step_expr k a m) as [|[C rd] res] eqn:?.
specialize (B (refl_equal _)). destruct k.
destruct a; simpl in B; try congruence. constructor.
destruct a; simpl in B; try congruence. constructor.
@@ -1889,7 +1892,7 @@ Lemma do_alloc_variables_sound:
Proof.
induction l; intros; simpl.
constructor.
- destruct a as [id ty]. destruct (Mem.alloc m 0 (sizeof ty)) as [m1 b1]_eqn; simpl.
+ destruct a as [id ty]. destruct (Mem.alloc m 0 (sizeof ty)) as [m1 b1] eqn:?; simpl.
econstructor; eauto.
Qed.
@@ -2053,8 +2056,8 @@ Ltac myinv :=
[intro EQ; unfold ret in EQ; inv EQ; myinv | myinv]
| [ |- In _ (_ :: nil) -> _ ] =>
intro X; elim X; clear X; [intro EQ; inv EQ; myinv | myinv]
- | [ |- In _ (match ?x with Some _ => _ | None => _ end) -> _ ] => destruct x as []_eqn; myinv
- | [ |- In _ (match ?x with false => _ | true => _ end) -> _ ] => destruct x as []_eqn; myinv
+ | [ |- In _ (match ?x with Some _ => _ | None => _ end) -> _ ] => destruct x eqn:?; myinv
+ | [ |- In _ (match ?x with false => _ | true => _ end) -> _ ] => destruct x eqn:?; myinv
| [ |- In _ (match ?x with left _ => _ | right _ => _ end) -> _ ] => destruct x; myinv
| _ => idtac
end.
@@ -2078,7 +2081,7 @@ Proof with try (left; right; econstructor; eauto; fail).
(* goto *)
destruct p as [s' k']. myinv...
(* ExprState *)
- destruct (is_val r) as [[v ty]|]_eqn.
+ destruct (is_val r) as [[v ty]|] eqn:?.
(* expression is a value *)
rewrite (is_val_inv _ _ _ Heqo).
destruct k; myinv...
@@ -2102,7 +2105,7 @@ Proof with try (left; right; econstructor; eauto; fail).
(* callstate *)
destruct fd; myinv.
(* internal *)
- destruct (do_alloc_variables empty_env m (fn_params f ++ fn_vars f)) as [e m1]_eqn.
+ destruct (do_alloc_variables empty_env m (fn_params f ++ fn_vars f)) as [e m1] eqn:?.
myinv. left; right; apply step_internal_function with m1. auto.
change e with (fst (e,m1)). change m1 with (snd (e,m1)) at 2. rewrite <- Heqp.
apply do_alloc_variables_sound. eapply sem_bind_parameters_sound; eauto.
diff --git a/cfrontend/Cminorgenproof.v b/cfrontend/Cminorgenproof.v
index 62690d6..cff5b06 100644
--- a/cfrontend/Cminorgenproof.v
+++ b/cfrontend/Cminorgenproof.v
@@ -398,11 +398,11 @@ Proof.
else false
end
end).
- destruct (List.existsb pred (PTree.elements e)) as []_eqn.
+ destruct (List.existsb pred (PTree.elements e)) eqn:?.
(* yes *)
rewrite List.existsb_exists in Heqb.
destruct Heqb as [[id [b sz]] [A B]].
- simpl in B. destruct (f b) as [[sp' delta] |]_eqn; try discriminate.
+ simpl in B. destruct (f b) as [[sp' delta] |] eqn:?; try discriminate.
destruct (eq_block sp sp'); try discriminate.
destruct (andb_prop _ _ B).
left. apply is_reachable_intro with id b sz delta.
@@ -646,13 +646,13 @@ Proof.
constructor. auto. auto.
eapply match_temps_invariant; eauto.
eapply match_env_invariant; eauto.
- red in SEPARATED. intros. destruct (f1 b) as [[b' delta']|]_eqn.
+ red in SEPARATED. intros. destruct (f1 b) as [[b' delta']|] eqn:?.
exploit INCR; eauto. congruence.
exploit SEPARATED; eauto. intros [A B]. elim B. red. omega.
intros. assert (lo <= hi) by (eapply me_low_high; eauto).
- destruct (f1 b) as [[b' delta']|]_eqn.
+ destruct (f1 b) as [[b' delta']|] eqn:?.
apply INCR; auto.
- destruct (f2 b) as [[b' delta']|]_eqn; auto.
+ destruct (f2 b) as [[b' delta']|] eqn:?; auto.
exploit SEPARATED; eauto. intros [A B]. elim A. red. omega.
eapply match_bounds_invariant; eauto.
intros. eapply MAXPERMS; eauto. red. exploit me_bounded; eauto. omega.
@@ -884,7 +884,7 @@ Proof.
intros. destruct (In_dec peq id (map fst vars)).
apply cenv_remove_gss; auto.
rewrite cenv_remove_gso; auto.
- destruct (cenv!id) as [ofs|]_eqn; auto. elim n; eauto.
+ destruct (cenv!id) as [ofs|] eqn:?; auto. elim n; eauto.
eapply Mem.alloc_right_inject; eauto.
Qed.
@@ -917,7 +917,7 @@ Proof.
simpl; intros. inv H. omega.
Opaque assign_variable.
destruct a as [id s]. simpl. intros.
- destruct (assign_variable (cenv, sz) (id, s)) as [cenv1 sz1]_eqn.
+ destruct (assign_variable (cenv, sz) (id, s)) as [cenv1 sz1] eqn:?.
apply Zle_trans with sz1. eapply assign_variable_incr; eauto. eauto.
Transparent assign_variable.
Qed.
@@ -1014,7 +1014,7 @@ Proof.
destruct a as [id sz].
simpl in H0. inv H0. rewrite in_app in H6.
rewrite list_norepet_app in H7. destruct H7 as [P [Q R]].
- destruct (assign_variable (cenv1, sz1) (id, sz)) as [cenv' sz']_eqn.
+ destruct (assign_variable (cenv1, sz1) (id, sz)) as [cenv' sz'] eqn:?.
exploit assign_variable_sound.
eauto.
instantiate (1 := vars). tauto.
@@ -1377,12 +1377,12 @@ Proof.
intros. apply (val_match_approx_increasing Int1 a v); auto.
intros; unfold Approx.bitwise_and.
- destruct (Approx.bge Int1 a1) as []_eqn. simpl. apply Y; eauto. compute; auto.
- destruct (Approx.bge Int1 a2) as []_eqn. simpl. apply X; eauto. compute; auto.
- destruct (Approx.bge Int8u a1) as []_eqn. simpl. apply Y; eauto. compute; auto.
- destruct (Approx.bge Int8u a2) as []_eqn. simpl. apply X; eauto. compute; auto.
- destruct (Approx.bge Int16u a1) as []_eqn. simpl. apply Y; eauto. compute; auto.
- destruct (Approx.bge Int16u a2) as []_eqn. simpl. apply X; eauto. compute; auto.
+ destruct (Approx.bge Int1 a1) eqn:?. simpl. apply Y; eauto. compute; auto.
+ destruct (Approx.bge Int1 a2) eqn:?. simpl. apply X; eauto. compute; auto.
+ destruct (Approx.bge Int8u a1) eqn:?. simpl. apply Y; eauto. compute; auto.
+ destruct (Approx.bge Int8u a2) eqn:?. simpl. apply X; eauto. compute; auto.
+ destruct (Approx.bge Int16u a1) eqn:?. simpl. apply Y; eauto. compute; auto.
+ destruct (Approx.bge Int16u a2) eqn:?. simpl. apply X; eauto. compute; auto.
simpl; auto.
Qed.
@@ -1404,19 +1404,19 @@ Proof.
unfold Approx.bitwise_or.
- destruct (Approx.bge Int1 a1 && Approx.bge Int1 a2) as []_eqn.
+ destruct (Approx.bge Int1 a1 && Approx.bge Int1 a2) eqn:?.
destruct (andb_prop _ _ Heqb).
simpl. apply X. compute; auto.
apply (val_match_approx_increasing Int1 a1 v1); auto.
apply (val_match_approx_increasing Int1 a2 v2); auto.
- destruct (Approx.bge Int8u a1 && Approx.bge Int8u a2) as []_eqn.
+ destruct (Approx.bge Int8u a1 && Approx.bge Int8u a2) eqn:?.
destruct (andb_prop _ _ Heqb0).
simpl. apply X. compute; auto.
apply (val_match_approx_increasing Int8u a1 v1); auto.
apply (val_match_approx_increasing Int8u a2 v2); auto.
- destruct (Approx.bge Int16u a1 && Approx.bge Int16u a2) as []_eqn.
+ destruct (Approx.bge Int16u a1 && Approx.bge Int16u a2) eqn:?.
destruct (andb_prop _ _ Heqb1).
simpl. apply X. compute; auto.
apply (val_match_approx_increasing Int16u a1 v1); auto.
@@ -1574,8 +1574,8 @@ Proof.
apply val_inject_val_of_optbool.
Opaque Int.add.
unfold Val.cmpu. simpl.
- destruct (Mem.valid_pointer m b1 (Int.unsigned ofs1)) as []_eqn; simpl; auto.
- destruct (Mem.valid_pointer m b0 (Int.unsigned ofs0)) as []_eqn; simpl; auto.
+ destruct (Mem.valid_pointer m b1 (Int.unsigned ofs1)) eqn:?; simpl; auto.
+ destruct (Mem.valid_pointer m b0 (Int.unsigned ofs0)) eqn:?; simpl; auto.
exploit Mem.valid_pointer_inject_val. eauto. eexact Heqb. econstructor; eauto.
intros V1. rewrite V1.
exploit Mem.valid_pointer_inject_val. eauto. eexact Heqb0. econstructor; eauto.
@@ -1859,13 +1859,20 @@ Proof.
(forall b ofs, Mem.store chunk m1 b ofs v1 = Mem.store chunk m1 b ofs v1') ->
Mem.storev chunk m1 a1 v1' = Some n1).
intros. rewrite <- H0. destruct a1; simpl; auto.
- inv H2; (eapply Mem.storev_mapped_inject; [eauto|idtac|eauto|eauto]);
- auto; apply H3; intros.
+ inv H2; eapply Mem.storev_mapped_inject;
+ try eapply H; try eapply H1; try apply H3; intros.
rewrite <- Mem.store_int8_sign_ext. rewrite H4. apply Mem.store_int8_sign_ext.
+ auto.
rewrite <- Mem.store_int8_zero_ext. rewrite H4. apply Mem.store_int8_zero_ext.
+ auto.
rewrite <- Mem.store_int16_sign_ext. rewrite H4. apply Mem.store_int16_sign_ext.
+ auto.
rewrite <- Mem.store_int16_zero_ext. rewrite H4. apply Mem.store_int16_zero_ext.
+ auto.
rewrite <- Mem.store_float32_truncate. rewrite H4. apply Mem.store_float32_truncate.
+ auto.
+ eauto.
+ auto.
Qed.
Lemma make_store_correct:
@@ -2053,7 +2060,7 @@ Proof.
(* Eunop *)
exploit IHeval_expr; eauto. intros [tv1 [EVAL1 [INJ1 APP1]]].
unfold Csharpminor.eval_unop in H0.
- destruct (Approx.unop_is_redundant op x0) as []_eqn; inv EQ0.
+ destruct (Approx.unop_is_redundant op x0) eqn:?; inv EQ0.
(* -- eliminated *)
exploit approx_unop_is_redundant_sound; eauto. intros.
replace v with v1 by congruence.
diff --git a/cfrontend/Cshmgenproof.v b/cfrontend/Cshmgenproof.v
index 42eae5d..74a6da5 100644
--- a/cfrontend/Cshmgenproof.v
+++ b/cfrontend/Cshmgenproof.v
@@ -732,10 +732,10 @@ Lemma block_is_volatile_preserved:
forall b, block_is_volatile tge b = block_is_volatile ge b.
Proof.
intros. unfold block_is_volatile.
- destruct (Genv.find_var_info ge b) as []_eqn.
+ destruct (Genv.find_var_info ge b) eqn:?.
exploit var_info_translated; eauto. intros [tv [A B]]. rewrite A.
unfold transf_globvar in B. monadInv B. auto.
- destruct (Genv.find_var_info tge b) as []_eqn.
+ destruct (Genv.find_var_info tge b) eqn:?.
exploit var_info_rev_translated; eauto. intros [tv [A B]]. congruence.
auto.
Qed.
@@ -761,7 +761,7 @@ Lemma match_env_globals:
e!id = None ->
te!id = None.
Proof.
- intros. destruct (te!id) as [[b sz] | ]_eqn; auto.
+ intros. destruct (te!id) as [[b sz] | ] eqn:?; auto.
exploit me_local_inv; eauto. intros [ty EQ]. congruence.
Qed.
@@ -1284,7 +1284,7 @@ Proof.
destruct H0. inv MK.
econstructor; split.
eapply plus_left.
- destruct H0; subst ts'; constructor.
+ destruct H0; subst ts'. 2:constructor. constructor.
apply star_one. constructor. traceEq.
econstructor; eauto. constructor. econstructor; eauto.
@@ -1355,7 +1355,7 @@ Proof.
destruct H; subst x; monadInv TR; inv MTR; auto.
destruct H0. inv MK.
econstructor; split.
- apply plus_one. destruct H0; subst ts'; constructor.
+ apply plus_one. destruct H0; subst ts'. 2:constructor. constructor.
eapply match_states_skip; eauto.
diff --git a/cfrontend/Cstrategy.v b/cfrontend/Cstrategy.v
index b28409d..7988dfa 100644
--- a/cfrontend/Cstrategy.v
+++ b/cfrontend/Cstrategy.v
@@ -816,7 +816,7 @@ Ltac StepR REC C' a :=
(* field *)
StepR IHa (fun x => C(Efield x f0 ty)) a.
exploit safe_inv. eexact SAFE0. eauto. simpl.
- intros [b [ofs [EQ TY]]]. subst v. destruct (typeof a) as []_eqn; try contradiction.
+ intros [b [ofs [EQ TY]]]. subst v. destruct (typeof a) eqn:?; try contradiction.
destruct TY as [delta OFS]. exists b; exists (Int.add ofs (Int.repr delta)); econstructor; eauto.
exists b; exists ofs; econstructor; eauto.
(* valof *)
@@ -1075,7 +1075,7 @@ Ltac Base :=
Kind. Rec H RV C (fun x => Efield x f0 ty).
(* rvalof *)
Kind. Rec H LV C (fun x => Evalof x ty).
- destruct (type_is_volatile (typeof l)) as []_eqn.
+ destruct (type_is_volatile (typeof l)) eqn:?.
Base. rewrite H2; auto.
(* deref *)
Kind. Rec H RV C (fun x => Ederef x ty).
@@ -1198,7 +1198,7 @@ Proof.
eapply eval_simple_rvalue_steps with (C := fun x => C(Eassignop op (Eloc b ofs (typeof l)) x tyres (typeof l))); eauto.
eapply plus_left.
left; apply step_rred; auto. econstructor; eauto.
- destruct (sem_binary_operation op v1 (typeof l) v2 (typeof r) m) as [v3|]_eqn.
+ destruct (sem_binary_operation op v1 (typeof l) v2 (typeof r) m) as [v3|] eqn:?.
eapply star_left.
left; apply step_rred with (C := fun x => C(Eassign (Eloc b ofs (typeof l)) x (typeof l))); eauto. econstructor; eauto.
apply star_one.
@@ -1326,8 +1326,8 @@ Proof.
exploit (simple_can_eval_rval f k e m b2 (fun x => C(Eassignop op (Eloc b ofs (typeof b1)) x tyres ty))); eauto.
intros [v [E2 S2]].
exploit safe_inv. eexact S2. eauto. simpl. intros [t1 [v1 [A B]]].
- destruct (sem_binary_operation op v1 (typeof b1) v (typeof b2) m) as [v3|]_eqn.
- destruct (sem_cast v3 tyres (typeof b1)) as [v4|]_eqn.
+ destruct (sem_binary_operation op v1 (typeof b1) v (typeof b2) m) as [v3|] eqn:?.
+ destruct (sem_cast v3 tyres (typeof b1)) as [v4|] eqn:?.
destruct (classic (exists t2, exists m', assign_loc ge (typeof b1) m b ofs v4 t2 m')).
destruct H2 as [t2 [m' D]].
econstructor; econstructor; eapply step_assignop; eauto.
@@ -1341,8 +1341,8 @@ Proof.
exploit (simple_can_eval_lval f k e m b (fun x => C(Epostincr id x ty))); eauto.
intros [b1 [ofs [E1 S1]]].
exploit safe_inv. eexact S1. eauto. simpl. intros [t [v1 [A B]]].
- destruct (sem_incrdecr id v1 ty) as [v2|]_eqn.
- destruct (sem_cast v2 (typeconv ty) ty) as [v3|]_eqn.
+ destruct (sem_incrdecr id v1 ty) as [v2|] eqn:?.
+ destruct (sem_cast v2 (typeconv ty) ty) as [v3|] eqn:?.
destruct (classic (exists t2, exists m', assign_loc ge ty m b1 ofs v3 t2 m')).
destruct H0 as [t2 [m' D]].
econstructor; econstructor; eapply step_postincr; eauto.
@@ -1493,8 +1493,8 @@ Proof.
subst t2. exploit assign_loc_receptive; eauto. intros EQ; rewrite EQ in H.
econstructor; econstructor; eauto.
inv H10. exploit deref_loc_receptive; eauto. intros [EQ [v1' A]]. subst t0.
- destruct (sem_binary_operation op v1' (typeof l) v2 (typeof r) m) as [v3'|]_eqn.
- destruct (sem_cast v3' tyres (typeof l)) as [v4'|]_eqn.
+ destruct (sem_binary_operation op v1' (typeof l) v2 (typeof r) m) as [v3'|] eqn:?.
+ destruct (sem_cast v3' tyres (typeof l)) as [v4'|] eqn:?.
destruct (classic (exists t2', exists m'', assign_loc (Genv.globalenv p) (typeof l) m b ofs v4' t2' m'')).
destruct H1 as [t2' [m'' P]].
econstructor; econstructor. left; eapply step_assignop with (v1 := v1'); eauto. simpl; reflexivity.
@@ -1506,8 +1506,8 @@ Proof.
rewrite Heqo; auto.
(* assignop stuck *)
exploit deref_loc_receptive; eauto. intros [EQ [v1' A]]. subst t1.
- destruct (sem_binary_operation op v1' (typeof l) v2 (typeof r) m) as [v3'|]_eqn.
- destruct (sem_cast v3' tyres (typeof l)) as [v4'|]_eqn.
+ destruct (sem_binary_operation op v1' (typeof l) v2 (typeof r) m) as [v3'|] eqn:?.
+ destruct (sem_cast v3' tyres (typeof l)) as [v4'|] eqn:?.
destruct (classic (exists t2', exists m'', assign_loc (Genv.globalenv p) (typeof l) m b ofs v4' t2' m'')).
destruct H1 as [t2' [m'' P]].
econstructor; econstructor. left; eapply step_assignop with (v1 := v1'); eauto. simpl; reflexivity.
@@ -1522,8 +1522,8 @@ Proof.
subst t2. exploit assign_loc_receptive; eauto. intros EQ; rewrite EQ in H.
econstructor; econstructor; eauto.
inv H9. exploit deref_loc_receptive; eauto. intros [EQ [v1' A]]. subst t0.
- destruct (sem_incrdecr id v1' (typeof l)) as [v2'|]_eqn.
- destruct (sem_cast v2' (typeconv (typeof l)) (typeof l)) as [v3'|]_eqn.
+ destruct (sem_incrdecr id v1' (typeof l)) as [v2'|] eqn:?.
+ destruct (sem_cast v2' (typeconv (typeof l)) (typeof l)) as [v3'|] eqn:?.
destruct (classic (exists t2', exists m'', assign_loc (Genv.globalenv p) (typeof l) m b ofs v3' t2' m'')).
destruct H1 as [t2' [m'' P]].
econstructor; econstructor. left; eapply step_postincr with (v1 := v1'); eauto. simpl; reflexivity.
@@ -1535,8 +1535,8 @@ Proof.
rewrite Heqo; auto.
(* postincr stuck *)
exploit deref_loc_receptive; eauto. intros [EQ [v1' A]]. subst t1.
- destruct (sem_incrdecr id v1' (typeof l)) as [v2'|]_eqn.
- destruct (sem_cast v2' (typeconv (typeof l)) (typeof l)) as [v3'|]_eqn.
+ destruct (sem_incrdecr id v1' (typeof l)) as [v2'|] eqn:?.
+ destruct (sem_cast v2' (typeconv (typeof l)) (typeof l)) as [v3'|] eqn:?.
destruct (classic (exists t2', exists m'', assign_loc (Genv.globalenv p) (typeof l) m b ofs v3' t2' m'')).
destruct H1 as [t2' [m'' P]].
econstructor; econstructor. left; eapply step_postincr with (v1 := v1'); eauto. simpl; reflexivity.
diff --git a/cfrontend/Initializersproof.v b/cfrontend/Initializersproof.v
index 9bc1dd7..ca9c5b0 100644
--- a/cfrontend/Initializersproof.v
+++ b/cfrontend/Initializersproof.v
@@ -12,7 +12,6 @@
(** Compile-time evaluation of initializers for global C variables. *)
-Require Import Coq.Program.Equality.
Require Import Coqlib.
Require Import Errors.
Require Import Maps.
@@ -268,42 +267,58 @@ Proof.
induction 2; simpl; try tauto.
Qed.
+Lemma compat_eval_steps_aux f r e m r' m' s2 :
+ simple r ->
+ star step ge s2 nil (ExprState f r' Kstop e m') ->
+ estep ge (ExprState f r Kstop e m) nil s2 ->
+ exists r1,
+ s2 = ExprState f r1 Kstop e m /\
+ compat_eval RV e r r1 m /\ simple r1.
+Proof.
+ intros.
+ inv H1.
+ (* lred *)
+ assert (S: simple a) by (eapply simple_context_1; eauto).
+ exploit lred_compat; eauto. intros [A B]. subst m'0.
+ econstructor; split. eauto. split.
+ eapply compat_eval_context; eauto.
+ eapply simple_context_2; eauto. eapply lred_simple; eauto.
+ (* rred *)
+ assert (S: simple a) by (eapply simple_context_1; eauto).
+ exploit rred_compat; eauto. intros [A B]. subst m'0.
+ econstructor; split. eauto. split.
+ eapply compat_eval_context; eauto.
+ eapply simple_context_2; eauto. eapply rred_simple; eauto.
+ (* callred *)
+ assert (S: simple a) by (eapply simple_context_1; eauto).
+ inv H8; simpl in S; contradiction.
+ (* stuckred *)
+ inv H0. destruct H1; inv H0.
+Qed.
+
Lemma compat_eval_steps:
forall f r e m r' m',
star step ge (ExprState f r Kstop e m) E0 (ExprState f r' Kstop e m') ->
simple r ->
m' = m /\ compat_eval RV e r r' m.
Proof.
- intros. dependent induction H.
+ intros.
+ remember (ExprState f r Kstop e m) as S1.
+ remember E0 as t.
+ remember (ExprState f r' Kstop e m') as S2.
+ revert S1 t S2 H r m r' m' HeqS1 Heqt HeqS2 H0.
+ induction 1; intros; subst.
(* base case *)
- split. auto. red; auto.
+ inv HeqS2. split. auto. red; auto.
(* inductive case *)
destruct (app_eq_nil t1 t2); auto. subst. inv H.
(* expression step *)
- assert (X: exists r1, s2 = ExprState f r1 Kstop e m /\ compat_eval RV e r r1 m /\ simple r1).
- inv H3.
- (* lred *)
- assert (S: simple a) by (eapply simple_context_1; eauto).
- exploit lred_compat; eauto. intros [A B]. subst m'0.
- econstructor; split. eauto. split.
- eapply compat_eval_context; eauto.
- eapply simple_context_2; eauto. eapply lred_simple; eauto.
- (* rred *)
- assert (S: simple a) by (eapply simple_context_1; eauto).
- exploit rred_compat; eauto. intros [A B]. subst m'0.
- econstructor; split. eauto. split.
- eapply compat_eval_context; eauto.
- eapply simple_context_2; eauto. eapply rred_simple; eauto.
- (* callred *)
- assert (S: simple a) by (eapply simple_context_1; eauto).
- inv H9; simpl in S; contradiction.
- (* stuckred *)
- inv H2. destruct H; inv H.
- destruct X as [r1 [A [B C]]]. subst s2.
- exploit IHstar; eauto. intros [D E].
+ exploit compat_eval_steps_aux; eauto.
+ intros [r1 [A [B C]]]. subst s2.
+ exploit IHstar; eauto. intros [D E].
split. auto. destruct B; destruct E. split. congruence. auto.
(* statement steps *)
- inv H3.
+ inv H1.
Qed.
Theorem eval_simple_steps:
@@ -438,7 +453,7 @@ Lemma sem_cast_match:
forall v1' v2', match_val v1' v1 -> do_cast v1' ty1 ty2 = OK v2' ->
match_val v2' v2.
Proof.
- intros. unfold do_cast in H1. destruct (sem_cast v1' ty1 ty2) as [v2''|] _eqn; inv H1.
+ intros. unfold do_cast in H1. destruct (sem_cast v1' ty1 ty2) as [v2''|] eqn:?; inv H1.
unfold sem_cast in H; functional inversion Heqo; subst.
rewrite H2 in H. inv H0. inv H. constructor.
rewrite H2 in H. inv H0. inv H. constructor; auto.
@@ -888,3 +903,4 @@ Qed.
End SOUNDNESS.
+
diff --git a/cfrontend/PrintClight.ml b/cfrontend/PrintClight.ml
index 0e8b494..b05876a 100644
--- a/cfrontend/PrintClight.ml
+++ b/cfrontend/PrintClight.ml
@@ -40,8 +40,7 @@ let register_struct_union id fld =
(* Naming temporaries *)
-let temp_name (id: ident) =
- Printf.sprintf "$%ld" (camlint_of_positive id)
+let temp_name (id: ident) = Z.to_string (Z.Zpos id)
(* Declarator (identifier + type) -- reuse from PrintCsyntax *)
diff --git a/cfrontend/PrintCsyntax.ml b/cfrontend/PrintCsyntax.ml
index 7858545..67efd1b 100644
--- a/cfrontend/PrintCsyntax.ml
+++ b/cfrontend/PrintCsyntax.ml
@@ -396,7 +396,7 @@ let string_of_init id =
let chop_last_nul id =
match List.rev id with
- | Init_int8 BinInt.Z0 :: tl -> List.rev tl
+ | Init_int8 Z.Z0 :: tl -> List.rev tl
| _ -> id
let print_init p = function
diff --git a/cfrontend/SimplExpr.v b/cfrontend/SimplExpr.v
index ab35445..2dbd97e 100644
--- a/cfrontend/SimplExpr.v
+++ b/cfrontend/SimplExpr.v
@@ -24,8 +24,6 @@ Require Import Cop.
Require Import Csyntax.
Require Import Clight.
-Module C := Csyntax.
-
Open Local Scope string_scope.
(** State and error monad for generating fresh identifiers. *)
@@ -208,46 +206,46 @@ Definition finish (dst: destination) (sl: list statement) (a: expr) :=
| For_set tyl tmp => (sl ++ do_set tmp tyl a, a)
end.
-Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr) :=
+Fixpoint transl_expr (dst: destination) (a: Csyntax.expr) : mon (list statement * expr) :=
match a with
- | C.Eloc b ofs ty =>
- error (msg "SimplExpr.transl_expr: C.Eloc")
- | C.Evar x ty =>
+ | Csyntax.Eloc b ofs ty =>
+ error (msg "SimplExpr.transl_expr: Eloc")
+ | Csyntax.Evar x ty =>
ret (finish dst nil (Evar x ty))
- | C.Ederef r ty =>
+ | Csyntax.Ederef r ty =>
do (sl, a) <- transl_expr For_val r;
ret (finish dst sl (Ederef a ty))
- | C.Efield r f ty =>
+ | Csyntax.Efield r f ty =>
do (sl, a) <- transl_expr For_val r;
ret (finish dst sl (Efield a f ty))
- | C.Eval (Vint n) ty =>
+ | Csyntax.Eval (Vint n) ty =>
ret (finish dst nil (Econst_int n ty))
- | C.Eval (Vfloat n) ty =>
+ | Csyntax.Eval (Vfloat n) ty =>
ret (finish dst nil (Econst_float n ty))
- | C.Eval _ ty =>
- error (msg "SimplExpr.transl_expr: val")
- | C.Esizeof ty' ty =>
+ | Csyntax.Eval _ ty =>
+ error (msg "SimplExpr.transl_expr: Eval")
+ | Csyntax.Esizeof ty' ty =>
ret (finish dst nil (Esizeof ty' ty))
- | C.Ealignof ty' ty =>
+ | Csyntax.Ealignof ty' ty =>
ret (finish dst nil (Ealignof ty' ty))
- | C.Evalof l ty =>
+ | Csyntax.Evalof l ty =>
do (sl1, a1) <- transl_expr For_val l;
- do (sl2, a2) <- transl_valof (C.typeof l) a1;
+ do (sl2, a2) <- transl_valof (Csyntax.typeof l) a1;
ret (finish dst (sl1 ++ sl2) a2)
- | C.Eaddrof l ty =>
+ | Csyntax.Eaddrof l ty =>
do (sl, a) <- transl_expr For_val l;
ret (finish dst sl (Eaddrof a ty))
- | C.Eunop op r1 ty =>
+ | Csyntax.Eunop op r1 ty =>
do (sl1, a1) <- transl_expr For_val r1;
ret (finish dst sl1 (Eunop op a1 ty))
- | C.Ebinop op r1 r2 ty =>
+ | Csyntax.Ebinop op r1 r2 ty =>
do (sl1, a1) <- transl_expr For_val r1;
do (sl2, a2) <- transl_expr For_val r2;
ret (finish dst (sl1 ++ sl2) (Ebinop op a1 a2 ty))
- | C.Ecast r1 ty =>
+ | Csyntax.Ecast r1 ty =>
do (sl1, a1) <- transl_expr For_val r1;
ret (finish dst sl1 (Ecast a1 ty))
- | C.Eseqand r1 r2 ty =>
+ | Csyntax.Eseqand r1 r2 ty =>
do (sl1, a1) <- transl_expr For_val r1;
match dst with
| For_val =>
@@ -265,7 +263,7 @@ Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr
makeif a1 (makeseq sl2) (makeseq (do_set t tyl (Econst_int Int.zero ty))) :: nil,
dummy_expr)
end
- | C.Eseqor r1 r2 ty =>
+ | Csyntax.Eseqor r1 r2 ty =>
do (sl1, a1) <- transl_expr For_val r1;
match dst with
| For_val =>
@@ -283,7 +281,7 @@ Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr
makeif a1 (makeseq (do_set t tyl (Econst_int Int.one ty))) (makeseq sl2) :: nil,
dummy_expr)
end
- | C.Econdition r1 r2 r3 ty =>
+ | Csyntax.Econdition r1 r2 r3 ty =>
do (sl1, a1) <- transl_expr For_val r1;
match dst with
| For_val =>
@@ -303,11 +301,11 @@ Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr
ret (sl1 ++ makeif a1 (makeseq sl2) (makeseq sl3) :: nil,
dummy_expr)
end
- | C.Eassign l1 r2 ty =>
+ | Csyntax.Eassign l1 r2 ty =>
do (sl1, a1) <- transl_expr For_val l1;
do (sl2, a2) <- transl_expr For_val r2;
- let ty1 := C.typeof l1 in
- let ty2 := C.typeof r2 in
+ let ty1 := Csyntax.typeof l1 in
+ let ty2 := Csyntax.typeof r2 in
match dst with
| For_val | For_set _ _ =>
do t <- gensym ty2;
@@ -318,8 +316,8 @@ Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr
ret (sl1 ++ sl2 ++ make_assign a1 a2 :: nil,
dummy_expr)
end
- | C.Eassignop op l1 r2 tyres ty =>
- let ty1 := C.typeof l1 in
+ | Csyntax.Eassignop op l1 r2 tyres ty =>
+ let ty1 := Csyntax.typeof l1 in
do (sl1, a1) <- transl_expr For_val l1;
do (sl2, a2) <- transl_expr For_val r2;
do (sl3, a3) <- transl_valof ty1 a1;
@@ -335,8 +333,8 @@ Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr
ret (sl1 ++ sl2 ++ sl3 ++ make_assign a1 (Ebinop op a3 a2 tyres) :: nil,
dummy_expr)
end
- | C.Epostincr id l1 ty =>
- let ty1 := C.typeof l1 in
+ | Csyntax.Epostincr id l1 ty =>
+ let ty1 := Csyntax.typeof l1 in
do (sl1, a1) <- transl_expr For_val l1;
match dst with
| For_val | For_set _ _ =>
@@ -350,11 +348,11 @@ Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr
ret (sl1 ++ sl2 ++ make_assign a1 (transl_incrdecr id a2 ty1) :: nil,
dummy_expr)
end
- | C.Ecomma r1 r2 ty =>
+ | Csyntax.Ecomma r1 r2 ty =>
do (sl1, a1) <- transl_expr For_effects r1;
do (sl2, a2) <- transl_expr dst r2;
ret (sl1 ++ sl2, a2)
- | C.Ecall r1 rl2 ty =>
+ | Csyntax.Ecall r1 rl2 ty =>
do (sl1, a1) <- transl_expr For_val r1;
do (sl2, al2) <- transl_exprlist rl2;
match dst with
@@ -365,7 +363,7 @@ Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr
| For_effects =>
ret (sl1 ++ sl2 ++ Scall None a1 al2 :: nil, dummy_expr)
end
- | C.Ebuiltin ef tyargs rl ty =>
+ | Csyntax.Ebuiltin ef tyargs rl ty =>
do (sl, al) <- transl_exprlist rl;
match dst with
| For_val | For_set _ _ =>
@@ -375,33 +373,33 @@ Fixpoint transl_expr (dst: destination) (a: C.expr) : mon (list statement * expr
| For_effects =>
ret (sl ++ Sbuiltin None ef tyargs al :: nil, dummy_expr)
end
- | C.Eparen r1 ty =>
+ | Csyntax.Eparen r1 ty =>
error (msg "SimplExpr.transl_expr: paren")
end
with transl_exprlist (rl: exprlist) : mon (list statement * list expr) :=
match rl with
- | C.Enil =>
+ | Csyntax.Enil =>
ret (nil, nil)
- | C.Econs r1 rl2 =>
+ | Csyntax.Econs r1 rl2 =>
do (sl1, a1) <- transl_expr For_val r1;
do (sl2, al2) <- transl_exprlist rl2;
ret (sl1 ++ sl2, a1 :: al2)
end.
-Definition transl_expression (r: C.expr) : mon (statement * expr) :=
+Definition transl_expression (r: Csyntax.expr) : mon (statement * expr) :=
do (sl, a) <- transl_expr For_val r; ret (makeseq sl, a).
-Definition transl_expr_stmt (r: C.expr) : mon statement :=
+Definition transl_expr_stmt (r: Csyntax.expr) : mon statement :=
do (sl, a) <- transl_expr For_effects r; ret (makeseq sl).
(*
-Definition transl_if (r: C.expr) (s1 s2: statement) : mon statement :=
+Definition transl_if (r: Csyntax.expr) (s1 s2: statement) : mon statement :=
do (sl, a) <- transl_expr For_val r;
ret (makeseq (sl ++ makeif a s1 s2 :: nil)).
*)
-Definition transl_if (r: C.expr) (s1 s2: statement) : mon statement :=
+Definition transl_if (r: Csyntax.expr) (s1 s2: statement) : mon statement :=
do (sl, a) <- transl_expr For_val r;
ret (makeseq (sl ++ makeif a s1 s2 :: nil)).
@@ -410,33 +408,33 @@ Definition transl_if (r: C.expr) (s1 s2: statement) : mon statement :=
Definition expr_true := Econst_int Int.one type_int32s.
Definition is_Sskip:
- forall s, {s = C.Sskip} + {s <> C.Sskip}.
+ forall s, {s = Csyntax.Sskip} + {s <> Csyntax.Sskip}.
Proof.
destruct s; ((left; reflexivity) || (right; congruence)).
Defined.
-Fixpoint transl_stmt (s: C.statement) : mon statement :=
+Fixpoint transl_stmt (s: Csyntax.statement) : mon statement :=
match s with
- | C.Sskip => ret Sskip
- | C.Sdo e => transl_expr_stmt e
- | C.Ssequence s1 s2 =>
+ | Csyntax.Sskip => ret Sskip
+ | Csyntax.Sdo e => transl_expr_stmt e
+ | Csyntax.Ssequence s1 s2 =>
do ts1 <- transl_stmt s1;
do ts2 <- transl_stmt s2;
ret (Ssequence ts1 ts2)
- | C.Sifthenelse e s1 s2 =>
+ | Csyntax.Sifthenelse e s1 s2 =>
do ts1 <- transl_stmt s1;
do ts2 <- transl_stmt s2;
do (s', a) <- transl_expression e;
ret (Ssequence s' (Sifthenelse a ts1 ts2))
- | C.Swhile e s1 =>
+ | Csyntax.Swhile e s1 =>
do s' <- transl_if e Sskip Sbreak;
do ts1 <- transl_stmt s1;
ret (Sloop (Ssequence s' ts1) Sskip)
- | C.Sdowhile e s1 =>
+ | Csyntax.Sdowhile e s1 =>
do s' <- transl_if e Sskip Sbreak;
do ts1 <- transl_stmt s1;
ret (Sloop ts1 s')
- | C.Sfor s1 e2 s3 s4 =>
+ | Csyntax.Sfor s1 e2 s3 s4 =>
do ts1 <- transl_stmt s1;
do s' <- transl_if e2 Sskip Sbreak;
do ts3 <- transl_stmt s3;
@@ -445,32 +443,32 @@ Fixpoint transl_stmt (s: C.statement) : mon statement :=
ret (Sloop (Ssequence s' ts4) ts3)
else
ret (Ssequence ts1 (Sloop (Ssequence s' ts4) ts3))
- | C.Sbreak =>
+ | Csyntax.Sbreak =>
ret Sbreak
- | C.Scontinue =>
+ | Csyntax.Scontinue =>
ret Scontinue
- | C.Sreturn None =>
+ | Csyntax.Sreturn None =>
ret (Sreturn None)
- | C.Sreturn (Some e) =>
+ | Csyntax.Sreturn (Some e) =>
do (s', a) <- transl_expression e;
ret (Ssequence s' (Sreturn (Some a)))
- | C.Sswitch e ls =>
+ | Csyntax.Sswitch e ls =>
do (s', a) <- transl_expression e;
do tls <- transl_lblstmt ls;
ret (Ssequence s' (Sswitch a tls))
- | C.Slabel lbl s1 =>
+ | Csyntax.Slabel lbl s1 =>
do ts1 <- transl_stmt s1;
ret (Slabel lbl ts1)
- | C.Sgoto lbl =>
+ | Csyntax.Sgoto lbl =>
ret (Sgoto lbl)
end
-with transl_lblstmt (ls: C.labeled_statements) : mon labeled_statements :=
+with transl_lblstmt (ls: Csyntax.labeled_statements) : mon labeled_statements :=
match ls with
- | C.LSdefault s =>
+ | Csyntax.LSdefault s =>
do ts <- transl_stmt s;
ret (LSdefault ts)
- | C.LScase n s ls1 =>
+ | Csyntax.LScase n s ls1 =>
do ts <- transl_stmt s;
do tls1 <- transl_lblstmt ls1;
ret (LScase n ts tls1)
@@ -478,30 +476,30 @@ with transl_lblstmt (ls: C.labeled_statements) : mon labeled_statements :=
(** Translation of a function *)
-Definition transl_function (f: C.function) : res function :=
- match transl_stmt f.(C.fn_body) (initial_generator tt) with
+Definition transl_function (f: Csyntax.function) : res function :=
+ match transl_stmt f.(Csyntax.fn_body) (initial_generator tt) with
| Err msg =>
Error msg
| Res tbody g i =>
OK (mkfunction
- f.(C.fn_return)
- f.(C.fn_params)
- f.(C.fn_vars)
+ f.(Csyntax.fn_return)
+ f.(Csyntax.fn_params)
+ f.(Csyntax.fn_vars)
g.(gen_trail)
tbody)
end.
Local Open Scope error_monad_scope.
-Definition transl_fundef (fd: C.fundef) : res fundef :=
+Definition transl_fundef (fd: Csyntax.fundef) : res fundef :=
match fd with
- | C.Internal f =>
+ | Csyntax.Internal f =>
do tf <- transl_function f; OK (Internal tf)
- | C.External ef targs tres =>
+ | Csyntax.External ef targs tres =>
OK (External ef targs tres)
end.
-Definition transl_program (p: C.program) : res program :=
+Definition transl_program (p: Csyntax.program) : res program :=
transform_partial_program transl_fundef p.
diff --git a/cfrontend/SimplExprproof.v b/cfrontend/SimplExprproof.v
index 59fc9bc..150ed76 100644
--- a/cfrontend/SimplExprproof.v
+++ b/cfrontend/SimplExprproof.v
@@ -33,7 +33,7 @@ Require Import SimplExprspec.
Section PRESERVATION.
-Variable prog: C.program.
+Variable prog: Csyntax.program.
Variable tprog: Clight.program.
Hypothesis TRANSL: transl_program prog = OK tprog.
@@ -76,20 +76,20 @@ Qed.
Lemma type_of_fundef_preserved:
forall f tf, transl_fundef f = OK tf ->
- type_of_fundef tf = C.type_of_fundef f.
+ type_of_fundef tf = Csyntax.type_of_fundef f.
Proof.
intros. destruct f; monadInv H.
exploit transl_function_spec; eauto. intros [A [B [C D]]].
- simpl. unfold type_of_function, C.type_of_function. congruence.
+ simpl. unfold type_of_function, Csyntax.type_of_function. congruence.
auto.
Qed.
Lemma function_return_preserved:
forall f tf, transl_function f = OK tf ->
- fn_return tf = C.fn_return f.
+ fn_return tf = Csyntax.fn_return f.
Proof.
intros. unfold transl_function in H.
- destruct (transl_stmt (C.fn_body f) (initial_generator tt)); inv H.
+ destruct (transl_stmt (Csyntax.fn_body f) (initial_generator tt)); inv H.
auto.
Qed.
@@ -190,11 +190,11 @@ Lemma tr_simple:
forall le dst sl a tmps,
tr_expr le dst r sl a tmps ->
match dst with
- | For_val => sl = nil /\ C.typeof r = typeof a /\ eval_expr tge e le m a v
+ | For_val => sl = nil /\ Csyntax.typeof r = typeof a /\ eval_expr tge e le m a v
| For_effects => sl = nil
| For_set tyl t =>
exists b, sl = do_set t tyl b
- /\ C.typeof r = typeof b
+ /\ Csyntax.typeof r = typeof b
/\ eval_expr tge e le m b v
end)
/\
@@ -202,7 +202,7 @@ Lemma tr_simple:
eval_simple_lvalue ge e m l b ofs ->
forall le sl a tmps,
tr_expr le For_val l sl a tmps ->
- sl = nil /\ C.typeof l = typeof a /\ eval_lvalue tge e le m a b ofs).
+ sl = nil /\ Csyntax.typeof l = typeof a /\ eval_lvalue tge e le m a b ofs).
Proof.
Opaque makeif.
intros e m.
@@ -275,11 +275,11 @@ Lemma tr_simple_rvalue:
forall le dst sl a tmps,
tr_expr le dst r sl a tmps ->
match dst with
- | For_val => sl = nil /\ C.typeof r = typeof a /\ eval_expr tge e le m a v
+ | For_val => sl = nil /\ Csyntax.typeof r = typeof a /\ eval_expr tge e le m a v
| For_effects => sl = nil
| For_set tyl t =>
exists b, sl = do_set t tyl b
- /\ C.typeof r = typeof b
+ /\ Csyntax.typeof r = typeof b
/\ eval_expr tge e le m b v
end.
Proof.
@@ -291,7 +291,7 @@ Lemma tr_simple_lvalue:
eval_simple_lvalue ge e m l b ofs ->
forall le sl a tmps,
tr_expr le For_val l sl a tmps ->
- sl = nil /\ C.typeof l = typeof a /\ eval_lvalue tge e le m a b ofs.
+ sl = nil /\ Csyntax.typeof l = typeof a /\ eval_lvalue tge e le m a b ofs.
Proof.
intros e m. exact (proj2 (tr_simple e m)).
Qed.
@@ -315,8 +315,8 @@ Qed.
Lemma typeof_context:
forall k1 k2 C, leftcontext k1 k2 C ->
- forall e1 e2, C.typeof e1 = C.typeof e2 ->
- C.typeof (C e1) = C.typeof (C e2).
+ forall e1 e2, Csyntax.typeof e1 = Csyntax.typeof e2 ->
+ Csyntax.typeof (C e1) = Csyntax.typeof (C e2).
Proof.
induction 1; intros; auto.
Qed.
@@ -337,7 +337,7 @@ Lemma tr_expr_leftcontext_rec:
/\ (forall le' e' sl3,
tr_expr le' dst' e' sl3 a' tmp' ->
(forall id, ~In id tmp' -> le'!id = le!id) ->
- C.typeof e' = C.typeof e ->
+ Csyntax.typeof e' = Csyntax.typeof e ->
tr_expr le' dst (C e') (sl3 ++ sl2) a tmps)
) /\ (
forall from C, leftcontextlist from C ->
@@ -350,7 +350,7 @@ Lemma tr_expr_leftcontext_rec:
/\ (forall le' e' sl3,
tr_expr le' dst' e' sl3 a' tmp' ->
(forall id, ~In id tmp' -> le'!id = le!id) ->
- C.typeof e' = C.typeof e ->
+ Csyntax.typeof e' = Csyntax.typeof e ->
tr_exprlist le' (C e') (sl3 ++ sl2) a tmps)
).
Proof.
@@ -695,7 +695,7 @@ Theorem tr_expr_leftcontext:
/\ (forall le' r' sl3,
tr_expr le' dst' r' sl3 a' tmp' ->
(forall id, ~In id tmp' -> le'!id = le!id) ->
- C.typeof r' = C.typeof r ->
+ Csyntax.typeof r' = Csyntax.typeof r ->
tr_expr le' dst (C r') (sl3 ++ sl2) a tmps).
Proof.
intros. eapply (proj1 tr_expr_leftcontext_rec); eauto.
@@ -714,7 +714,7 @@ Theorem tr_top_leftcontext:
/\ (forall le' m' r' sl3,
tr_expr le' dst' r' sl3 a' tmp' ->
(forall id, ~In id tmp' -> le'!id = le!id) ->
- C.typeof r' = C.typeof r ->
+ Csyntax.typeof r' = Csyntax.typeof r ->
tr_top tge e le' m' dst (C r') (sl3 ++ sl2) a tmps).
Proof.
induction 1; intros.
@@ -895,7 +895,7 @@ Inductive match_cont : Csem.cont -> cont -> Prop :=
| match_Kcall: forall f e C ty k optid tf le sl tk a dest tmps,
transl_function f = Errors.OK tf ->
leftcontext RV RV C ->
- (forall v m, tr_top tge e (set_opttemp optid v le) m dest (C (C.Eval v ty)) sl a tmps) ->
+ (forall v m, tr_top tge e (set_opttemp optid v le) m dest (C (Csyntax.Eval v ty)) sl a tmps) ->
match_cont_exp dest a k tk ->
match_cont (Csem.Kcall f e C ty k)
(Kcall optid tf e le (Kseqlist sl tk))
@@ -1220,10 +1220,10 @@ Proof.
(* for not skip *)
rename s' into sr.
rewrite (tr_find_label_if _ _ H3); auto.
- exploit (IHs1 (Csem.Kseq (C.Sfor C.Sskip e s2 s3) k)); eauto.
+ exploit (IHs1 (Csem.Kseq (Csyntax.Sfor Csyntax.Sskip e s2 s3) k)); eauto.
econstructor; eauto. econstructor; eauto.
destruct (Csem.find_label lbl s1
- (Csem.Kseq (C.Sfor C.Sskip e s2 s3) k)) as [[s' k'] | ].
+ (Csem.Kseq (Csyntax.Sfor Csyntax.Sskip e s2 s3) k)) as [[s' k'] | ].
intros [ts' [tk' [A [B C]]]]. rewrite A. exists ts'; exists tk'; intuition.
intro EQ; rewrite EQ.
exploit (IHs3 (Csem.Kfor3 e s2 s3 k)); eauto. econstructor; eauto.
@@ -1265,49 +1265,49 @@ End FIND_LABEL.
Sdo a, k ---> a, Kdo k ---> rval v, Kdo k ---> Sskip, k
>>
but the translation, which is [Sskip], makes no transitions.
-- The reduction [C.Ecomma (C.Eval v) r2 --> r2].
-- The reduction [C.Eparen (C.Eval v) --> C.Eval v] in a [For_effects] context.
+- The reduction [Ecomma (Eval v) r2 --> r2].
+- The reduction [Eparen (Eval v) --> Eval v] in a [For_effects] context.
The following measure decreases for these stuttering steps. *)
-Fixpoint esize (a: C.expr) : nat :=
+Fixpoint esize (a: Csyntax.expr) : nat :=
match a with
- | C.Eloc _ _ _ => 1%nat
- | C.Evar _ _ => 1%nat
- | C.Ederef r1 _ => S(esize r1)
- | C.Efield l1 _ _ => S(esize l1)
- | C.Eval _ _ => O
- | C.Evalof l1 _ => S(esize l1)
- | C.Eaddrof l1 _ => S(esize l1)
- | C.Eunop _ r1 _ => S(esize r1)
- | C.Ebinop _ r1 r2 _ => S(esize r1 + esize r2)%nat
- | C.Ecast r1 _ => S(esize r1)
- | C.Eseqand r1 _ _ => S(esize r1)
- | C.Eseqor r1 _ _ => S(esize r1)
- | C.Econdition r1 _ _ _ => S(esize r1)
- | C.Esizeof _ _ => 1%nat
- | C.Ealignof _ _ => 1%nat
- | C.Eassign l1 r2 _ => S(esize l1 + esize r2)%nat
- | C.Eassignop _ l1 r2 _ _ => S(esize l1 + esize r2)%nat
- | C.Epostincr _ l1 _ => S(esize l1)
- | C.Ecomma r1 r2 _ => S(esize r1 + esize r2)%nat
- | C.Ecall r1 rl2 _ => S(esize r1 + esizelist rl2)%nat
- | C.Ebuiltin ef _ rl _ => S(esizelist rl)%nat
- | C.Eparen r1 _ => S(esize r1)
+ | Csyntax.Eloc _ _ _ => 1%nat
+ | Csyntax.Evar _ _ => 1%nat
+ | Csyntax.Ederef r1 _ => S(esize r1)
+ | Csyntax.Efield l1 _ _ => S(esize l1)
+ | Csyntax.Eval _ _ => O
+ | Csyntax.Evalof l1 _ => S(esize l1)
+ | Csyntax.Eaddrof l1 _ => S(esize l1)
+ | Csyntax.Eunop _ r1 _ => S(esize r1)
+ | Csyntax.Ebinop _ r1 r2 _ => S(esize r1 + esize r2)%nat
+ | Csyntax.Ecast r1 _ => S(esize r1)
+ | Csyntax.Eseqand r1 _ _ => S(esize r1)
+ | Csyntax.Eseqor r1 _ _ => S(esize r1)
+ | Csyntax.Econdition r1 _ _ _ => S(esize r1)
+ | Csyntax.Esizeof _ _ => 1%nat
+ | Csyntax.Ealignof _ _ => 1%nat
+ | Csyntax.Eassign l1 r2 _ => S(esize l1 + esize r2)%nat
+ | Csyntax.Eassignop _ l1 r2 _ _ => S(esize l1 + esize r2)%nat
+ | Csyntax.Epostincr _ l1 _ => S(esize l1)
+ | Csyntax.Ecomma r1 r2 _ => S(esize r1 + esize r2)%nat
+ | Csyntax.Ecall r1 rl2 _ => S(esize r1 + esizelist rl2)%nat
+ | Csyntax.Ebuiltin ef _ rl _ => S(esizelist rl)%nat
+ | Csyntax.Eparen r1 _ => S(esize r1)
end
-with esizelist (el: C.exprlist) : nat :=
+with esizelist (el: Csyntax.exprlist) : nat :=
match el with
- | C.Enil => O
- | C.Econs r1 rl2 => (esize r1 + esizelist rl2)%nat
+ | Csyntax.Enil => O
+ | Csyntax.Econs r1 rl2 => (esize r1 + esizelist rl2)%nat
end.
Definition measure (st: Csem.state) : nat :=
match st with
| Csem.ExprState _ r _ _ _ => (esize r + 1)%nat
- | Csem.State _ C.Sskip _ _ _ => 0%nat
- | Csem.State _ (C.Sdo r) _ _ _ => (esize r + 2)%nat
- | Csem.State _ (C.Sifthenelse r _ _) _ _ _ => (esize r + 2)%nat
+ | Csem.State _ Csyntax.Sskip _ _ _ => 0%nat
+ | Csem.State _ (Csyntax.Sdo r) _ _ _ => (esize r + 2)%nat
+ | Csem.State _ (Csyntax.Sifthenelse r _ _) _ _ _ => (esize r + 2)%nat
| _ => 0%nat
end.
@@ -1338,7 +1338,7 @@ Lemma tr_val_gen:
(forall tge e le' m,
(forall id, In id tmp -> le'!id = le!id) ->
eval_expr tge e le' m a v) ->
- tr_expr le dst (C.Eval v ty) (final dst a) a tmp.
+ tr_expr le dst (Csyntax.Eval v ty) (final dst a) a tmp.
Proof.
intros. destruct dst; simpl; econstructor; auto.
Qed.
@@ -1378,7 +1378,7 @@ Proof.
econstructor; split.
left. eapply plus_two. constructor. eapply step_make_set; eauto. traceEq.
econstructor; eauto.
- change (final dst' (Etempvar t0 (C.typeof l)) ++ sl2) with (nil ++ (final dst' (Etempvar t0 (C.typeof l)) ++ sl2)).
+ change (final dst' (Etempvar t0 (Csyntax.typeof l)) ++ sl2) with (nil ++ (final dst' (Etempvar t0 (Csyntax.typeof l)) ++ sl2)).
apply S. apply tr_val_gen. auto.
intros. constructor. rewrite H5; auto. apply PTree.gss.
intros. apply PTree.gso. red; intros; subst; elim H5; auto.
@@ -1784,7 +1784,7 @@ Proof.
left. eapply plus_left. constructor. apply star_one.
econstructor. econstructor; eauto. rewrite <- TY1; eauto. traceEq.
econstructor; eauto.
- change sl2 with (final For_val (Etempvar t (C.typeof r)) ++ sl2). apply S.
+ change sl2 with (final For_val (Etempvar t (Csyntax.typeof r)) ++ sl2). apply S.
constructor. auto. intros. constructor. rewrite H2; auto. apply PTree.gss.
intros. apply PTree.gso. intuition congruence.
auto.
@@ -1877,7 +1877,7 @@ Qed.
Lemma tr_top_val_for_val_inv:
forall e le m v ty sl a tmps,
- tr_top tge e le m For_val (C.Eval v ty) sl a tmps ->
+ tr_top tge e le m For_val (Csyntax.Eval v ty) sl a tmps ->
sl = nil /\ typeof a = ty /\ eval_expr tge e le m a v.
Proof.
intros. inv H. auto. inv H0. auto.
@@ -2087,7 +2087,7 @@ Proof.
inv H9. exploit tr_top_val_for_val_inv; eauto. intros [A [B C]]. subst.
econstructor; split.
left. eapply plus_two. constructor. econstructor. eauto.
- replace (fn_return tf) with (C.fn_return f). eauto.
+ replace (fn_return tf) with (Csyntax.fn_return f). eauto.
exploit transl_function_spec; eauto. intuition congruence.
eauto. traceEq.
constructor. apply match_cont_call; auto.
diff --git a/cfrontend/SimplExprspec.v b/cfrontend/SimplExprspec.v
index 571a937..5cb0f18 100644
--- a/cfrontend/SimplExprspec.v
+++ b/cfrontend/SimplExprspec.v
@@ -35,9 +35,9 @@ Local Open Scope gensym_monad_scope.
(** This specification covers:
- all cases of [transl_lvalue] and [transl_rvalue];
-- two additional cases for [C.Eparen], so that reductions of [C.Econdition]
+- two additional cases for [Csyntax.Eparen], so that reductions of [Csyntax.Econdition]
expressions are properly tracked;
-- three additional cases allowing [C.Eval v] C expressions to match
+- three additional cases allowing [Csyntax.Eval v] C expressions to match
any Clight expression [a] that evaluates to [v] in any environment
matching the given temporary environment [le].
*)
@@ -57,69 +57,69 @@ Inductive tr_rvalof: type -> expr -> list statement -> expr -> list ident -> Pro
type_is_volatile ty = true -> In t tmp ->
tr_rvalof ty a (make_set t a :: nil) (Etempvar t ty) tmp.
-Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -> list ident -> Prop :=
+Inductive tr_expr: temp_env -> destination -> Csyntax.expr -> list statement -> expr -> list ident -> Prop :=
| tr_var: forall le dst id ty tmp,
- tr_expr le dst (C.Evar id ty)
+ tr_expr le dst (Csyntax.Evar id ty)
(final dst (Evar id ty)) (Evar id ty) tmp
| tr_deref: forall le dst e1 ty sl1 a1 tmp,
tr_expr le For_val e1 sl1 a1 tmp ->
- tr_expr le dst (C.Ederef e1 ty)
+ tr_expr le dst (Csyntax.Ederef e1 ty)
(sl1 ++ final dst (Ederef a1 ty)) (Ederef a1 ty) tmp
| tr_field: forall le dst e1 f ty sl1 a1 tmp,
tr_expr le For_val e1 sl1 a1 tmp ->
- tr_expr le dst (C.Efield e1 f ty)
+ tr_expr le dst (Csyntax.Efield e1 f ty)
(sl1 ++ final dst (Efield a1 f ty)) (Efield a1 f ty) tmp
| tr_val_effect: forall le v ty any tmp,
- tr_expr le For_effects (C.Eval v ty) nil any tmp
+ tr_expr le For_effects (Csyntax.Eval v ty) nil any tmp
| tr_val_value: forall le v ty a tmp,
typeof a = ty ->
(forall tge e le' m,
(forall id, In id tmp -> le'!id = le!id) ->
eval_expr tge e le' m a v) ->
- tr_expr le For_val (C.Eval v ty)
+ tr_expr le For_val (Csyntax.Eval v ty)
nil a tmp
| tr_val_set: forall le tyl t v ty a any tmp,
typeof a = ty ->
(forall tge e le' m,
(forall id, In id tmp -> le'!id = le!id) ->
eval_expr tge e le' m a v) ->
- tr_expr le (For_set tyl t) (C.Eval v ty)
+ tr_expr le (For_set tyl t) (Csyntax.Eval v ty)
(do_set t tyl a) any tmp
| tr_sizeof: forall le dst ty' ty tmp,
- tr_expr le dst (C.Esizeof ty' ty)
+ tr_expr le dst (Csyntax.Esizeof ty' ty)
(final dst (Esizeof ty' ty))
(Esizeof ty' ty) tmp
| tr_alignof: forall le dst ty' ty tmp,
- tr_expr le dst (C.Ealignof ty' ty)
+ tr_expr le dst (Csyntax.Ealignof ty' ty)
(final dst (Ealignof ty' ty))
(Ealignof ty' ty) tmp
| tr_valof: forall le dst e1 ty tmp sl1 a1 tmp1 sl2 a2 tmp2,
tr_expr le For_val e1 sl1 a1 tmp1 ->
- tr_rvalof (C.typeof e1) a1 sl2 a2 tmp2 ->
+ tr_rvalof (Csyntax.typeof e1) a1 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 -> incl tmp1 tmp -> incl tmp2 tmp ->
- tr_expr le dst (C.Evalof e1 ty)
+ tr_expr le dst (Csyntax.Evalof e1 ty)
(sl1 ++ sl2 ++ final dst a2)
a2 tmp
| tr_addrof: forall le dst e1 ty tmp sl1 a1,
tr_expr le For_val e1 sl1 a1 tmp ->
- tr_expr le dst (C.Eaddrof e1 ty)
+ tr_expr le dst (Csyntax.Eaddrof e1 ty)
(sl1 ++ final dst (Eaddrof a1 ty))
(Eaddrof a1 ty) tmp
| tr_unop: forall le dst op e1 ty tmp sl1 a1,
tr_expr le For_val e1 sl1 a1 tmp ->
- tr_expr le dst (C.Eunop op e1 ty)
+ tr_expr le dst (Csyntax.Eunop op e1 ty)
(sl1 ++ final dst (Eunop op a1 ty))
(Eunop op a1 ty) tmp
| tr_binop: forall le dst op e1 e2 ty sl1 a1 tmp1 sl2 a2 tmp2 tmp,
tr_expr le For_val e1 sl1 a1 tmp1 ->
tr_expr le For_val e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 -> incl tmp1 tmp -> incl tmp2 tmp ->
- tr_expr le dst (C.Ebinop op e1 e2 ty)
+ tr_expr le dst (Csyntax.Ebinop op e1 e2 ty)
(sl1 ++ sl2 ++ final dst (Ebinop op a1 a2 ty))
(Ebinop op a1 a2 ty) tmp
| tr_cast: forall le dst e1 ty sl1 a1 tmp,
tr_expr le For_val e1 sl1 a1 tmp ->
- tr_expr le dst (C.Ecast e1 ty)
+ tr_expr le dst (Csyntax.Ecast e1 ty)
(sl1 ++ final dst (Ecast a1 ty))
(Ecast a1 ty) tmp
| tr_seqand_val: forall le e1 e2 ty sl1 a1 tmp1 t sl2 a2 tmp2 tmp,
@@ -127,7 +127,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_expr le (For_set (type_bool :: ty :: nil) t) e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp -> In t tmp ->
- tr_expr le For_val (C.Eseqand e1 e2 ty)
+ tr_expr le For_val (Csyntax.Eseqand e1 e2 ty)
(sl1 ++ makeif a1 (makeseq sl2)
(Sset t (Econst_int Int.zero ty)) :: nil)
(Etempvar t ty) tmp
@@ -136,7 +136,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_expr le For_effects e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp ->
- tr_expr le For_effects (C.Eseqand e1 e2 ty)
+ tr_expr le For_effects (Csyntax.Eseqand e1 e2 ty)
(sl1 ++ makeif a1 (makeseq sl2) Sskip :: nil)
any tmp
| tr_seqand_set: forall le tyl t e1 e2 ty sl1 a1 tmp1 sl2 a2 tmp2 any tmp,
@@ -144,7 +144,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_expr le (For_set (type_bool :: ty :: tyl) t) e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp -> In t tmp ->
- tr_expr le (For_set tyl t) (C.Eseqand e1 e2 ty)
+ tr_expr le (For_set tyl t) (Csyntax.Eseqand e1 e2 ty)
(sl1 ++ makeif a1 (makeseq sl2)
(makeseq (do_set t tyl (Econst_int Int.zero ty))) :: nil)
any tmp
@@ -153,7 +153,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_expr le (For_set (type_bool :: ty :: nil) t) e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp -> In t tmp ->
- tr_expr le For_val (C.Eseqor e1 e2 ty)
+ tr_expr le For_val (Csyntax.Eseqor e1 e2 ty)
(sl1 ++ makeif a1 (Sset t (Econst_int Int.one ty))
(makeseq sl2) :: nil)
(Etempvar t ty) tmp
@@ -162,7 +162,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_expr le For_effects e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp ->
- tr_expr le For_effects (C.Eseqor e1 e2 ty)
+ tr_expr le For_effects (Csyntax.Eseqor e1 e2 ty)
(sl1 ++ makeif a1 Sskip (makeseq sl2) :: nil)
any tmp
| tr_seqor_set: forall le tyl t e1 e2 ty sl1 a1 tmp1 sl2 a2 tmp2 any tmp,
@@ -170,7 +170,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_expr le (For_set (type_bool :: ty :: tyl) t) e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp -> In t tmp ->
- tr_expr le (For_set tyl t) (C.Eseqor e1 e2 ty)
+ tr_expr le (For_set tyl t) (Csyntax.Eseqor e1 e2 ty)
(sl1 ++ makeif a1 (makeseq (do_set t tyl (Econst_int Int.one ty)))
(makeseq sl2) :: nil)
any tmp
@@ -181,7 +181,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
list_disjoint tmp1 tmp2 ->
list_disjoint tmp1 tmp3 ->
incl tmp1 tmp -> incl tmp2 tmp -> incl tmp3 tmp -> In t tmp ->
- tr_expr le For_val (C.Econdition e1 e2 e3 ty)
+ tr_expr le For_val (Csyntax.Econdition e1 e2 e3 ty)
(sl1 ++ makeif a1 (makeseq sl2) (makeseq sl3) :: nil)
(Etempvar t ty) tmp
| tr_condition_effects: forall le e1 e2 e3 ty sl1 a1 tmp1 sl2 a2 tmp2 sl3 a3 tmp3 any tmp,
@@ -191,7 +191,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
list_disjoint tmp1 tmp2 ->
list_disjoint tmp1 tmp3 ->
incl tmp1 tmp -> incl tmp2 tmp -> incl tmp3 tmp ->
- tr_expr le For_effects (C.Econdition e1 e2 e3 ty)
+ tr_expr le For_effects (Csyntax.Econdition e1 e2 e3 ty)
(sl1 ++ makeif a1 (makeseq sl2) (makeseq sl3) :: nil)
any tmp
| tr_condition_set: forall le tyl t e1 e2 e3 ty sl1 a1 tmp1 sl2 a2 tmp2 sl3 a3 tmp3 any tmp,
@@ -201,7 +201,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
list_disjoint tmp1 tmp2 ->
list_disjoint tmp1 tmp3 ->
incl tmp1 tmp -> incl tmp2 tmp -> incl tmp3 tmp -> In t tmp ->
- tr_expr le (For_set tyl t) (C.Econdition e1 e2 e3 ty)
+ tr_expr le (For_set tyl t) (Csyntax.Econdition e1 e2 e3 ty)
(sl1 ++ makeif a1 (makeseq sl2) (makeseq sl3) :: nil)
any tmp
| tr_assign_effects: forall le e1 e2 ty sl1 a1 tmp1 sl2 a2 tmp2 any tmp,
@@ -209,7 +209,7 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_expr le For_val e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp ->
- tr_expr le For_effects (C.Eassign e1 e2 ty)
+ tr_expr le For_effects (Csyntax.Eassign e1 e2 ty)
(sl1 ++ sl2 ++ make_assign a1 a2 :: nil)
any tmp
| tr_assign_val: forall le dst e1 e2 ty sl1 a1 tmp1 sl2 a2 tmp2 t tmp ty1 ty2,
@@ -218,9 +218,9 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
incl tmp1 tmp -> incl tmp2 tmp ->
list_disjoint tmp1 tmp2 ->
In t tmp -> ~In t tmp1 -> ~In t tmp2 ->
- ty1 = C.typeof e1 ->
- ty2 = C.typeof e2 ->
- tr_expr le dst (C.Eassign e1 e2 ty)
+ ty1 = Csyntax.typeof e1 ->
+ ty2 = Csyntax.typeof e2 ->
+ tr_expr le dst (Csyntax.Eassign e1 e2 ty)
(sl1 ++ sl2 ++
Sset t a2 ::
make_assign a1 (Etempvar t ty2) ::
@@ -229,11 +229,11 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
| tr_assignop_effects: forall le op e1 e2 tyres ty ty1 sl1 a1 tmp1 sl2 a2 tmp2 sl3 a3 tmp3 any tmp,
tr_expr le For_val e1 sl1 a1 tmp1 ->
tr_expr le For_val e2 sl2 a2 tmp2 ->
- ty1 = C.typeof e1 ->
+ ty1 = Csyntax.typeof e1 ->
tr_rvalof ty1 a1 sl3 a3 tmp3 ->
list_disjoint tmp1 tmp2 -> list_disjoint tmp1 tmp3 -> list_disjoint tmp2 tmp3 ->
incl tmp1 tmp -> incl tmp2 tmp -> incl tmp3 tmp ->
- tr_expr le For_effects (C.Eassignop op e1 e2 tyres ty)
+ tr_expr le For_effects (Csyntax.Eassignop op e1 e2 tyres ty)
(sl1 ++ sl2 ++ sl3 ++ make_assign a1 (Ebinop op a3 a2 tyres) :: nil)
any tmp
| tr_assignop_val: forall le dst op e1 e2 tyres ty sl1 a1 tmp1 sl2 a2 tmp2 sl3 a3 tmp3 t tmp ty1,
@@ -243,8 +243,8 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
list_disjoint tmp1 tmp2 -> list_disjoint tmp1 tmp3 -> list_disjoint tmp2 tmp3 ->
incl tmp1 tmp -> incl tmp2 tmp -> incl tmp3 tmp ->
In t tmp -> ~In t tmp1 -> ~In t tmp2 -> ~In t tmp3 ->
- ty1 = C.typeof e1 ->
- tr_expr le dst (C.Eassignop op e1 e2 tyres ty)
+ ty1 = Csyntax.typeof e1 ->
+ tr_expr le dst (Csyntax.Eassignop op e1 e2 tyres ty)
(sl1 ++ sl2 ++ sl3 ++
Sset t (Ebinop op a3 a2 tyres) ::
make_assign a1 (Etempvar t tyres) ::
@@ -253,17 +253,17 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
| tr_postincr_effects: forall le id e1 ty ty1 sl1 a1 tmp1 sl2 a2 tmp2 any tmp,
tr_expr le For_val e1 sl1 a1 tmp1 ->
tr_rvalof ty1 a1 sl2 a2 tmp2 ->
- ty1 = C.typeof e1 ->
+ ty1 = Csyntax.typeof e1 ->
incl tmp1 tmp -> incl tmp2 tmp ->
list_disjoint tmp1 tmp2 ->
- tr_expr le For_effects (C.Epostincr id e1 ty)
+ tr_expr le For_effects (Csyntax.Epostincr id e1 ty)
(sl1 ++ sl2 ++ make_assign a1 (transl_incrdecr id a2 ty1) :: nil)
any tmp
| tr_postincr_val: forall le dst id e1 ty sl1 a1 tmp1 t ty1 tmp,
tr_expr le For_val e1 sl1 a1 tmp1 ->
incl tmp1 tmp -> In t tmp -> ~In t tmp1 ->
- ty1 = C.typeof e1 ->
- tr_expr le dst (C.Epostincr id e1 ty)
+ ty1 = Csyntax.typeof e1 ->
+ tr_expr le dst (Csyntax.Epostincr id e1 ty)
(sl1 ++ make_set t a1 ::
make_assign a1 (transl_incrdecr id (Etempvar t ty1) ty1) ::
final dst (Etempvar t ty1))
@@ -273,13 +273,13 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_expr le dst e2 sl2 a2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp ->
- tr_expr le dst (C.Ecomma e1 e2 ty) (sl1 ++ sl2) a2 tmp
+ tr_expr le dst (Csyntax.Ecomma e1 e2 ty) (sl1 ++ sl2) a2 tmp
| tr_call_effects: forall le e1 el2 ty sl1 a1 tmp1 sl2 al2 tmp2 any tmp,
tr_expr le For_val e1 sl1 a1 tmp1 ->
tr_exprlist le el2 sl2 al2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp ->
- tr_expr le For_effects (C.Ecall e1 el2 ty)
+ tr_expr le For_effects (Csyntax.Ecall e1 el2 ty)
(sl1 ++ sl2 ++ Scall None a1 al2 :: nil)
any tmp
| tr_call_val: forall le dst e1 el2 ty sl1 a1 tmp1 sl2 al2 tmp2 t tmp,
@@ -288,45 +288,45 @@ Inductive tr_expr: temp_env -> destination -> C.expr -> list statement -> expr -
tr_exprlist le el2 sl2 al2 tmp2 ->
list_disjoint tmp1 tmp2 -> In t tmp ->
incl tmp1 tmp -> incl tmp2 tmp ->
- tr_expr le dst (C.Ecall e1 el2 ty)
+ tr_expr le dst (Csyntax.Ecall e1 el2 ty)
(sl1 ++ sl2 ++ Scall (Some t) a1 al2 :: final dst (Etempvar t ty))
(Etempvar t ty) tmp
| tr_builtin_effects: forall le ef tyargs el ty sl al tmp1 any tmp,
tr_exprlist le el sl al tmp1 ->
incl tmp1 tmp ->
- tr_expr le For_effects (C.Ebuiltin ef tyargs el ty)
+ tr_expr le For_effects (Csyntax.Ebuiltin ef tyargs el ty)
(sl ++ Sbuiltin None ef tyargs al :: nil)
any tmp
| tr_builtin_val: forall le dst ef tyargs el ty sl al tmp1 t tmp,
dst <> For_effects ->
tr_exprlist le el sl al tmp1 ->
In t tmp -> incl tmp1 tmp ->
- tr_expr le dst (C.Ebuiltin ef tyargs el ty)
+ tr_expr le dst (Csyntax.Ebuiltin ef tyargs el ty)
(sl ++ Sbuiltin (Some t) ef tyargs al :: final dst (Etempvar t ty))
(Etempvar t ty) tmp
| tr_paren_val: forall le e1 ty sl1 a1 t tmp,
tr_expr le (For_set (ty :: nil) t) e1 sl1 a1 tmp ->
In t tmp ->
- tr_expr le For_val (C.Eparen e1 ty)
+ tr_expr le For_val (Csyntax.Eparen e1 ty)
sl1
(Etempvar t ty) tmp
| tr_paren_effects: forall le e1 ty sl1 a1 tmp any,
tr_expr le For_effects e1 sl1 a1 tmp ->
- tr_expr le For_effects (C.Eparen e1 ty) sl1 any tmp
+ tr_expr le For_effects (Csyntax.Eparen e1 ty) sl1 any tmp
| tr_paren_set: forall le tyl t e1 ty sl1 a1 tmp any,
tr_expr le (For_set (ty::tyl) t) e1 sl1 a1 tmp ->
In t tmp ->
- tr_expr le (For_set tyl t) (C.Eparen e1 ty) sl1 any tmp
+ tr_expr le (For_set tyl t) (Csyntax.Eparen e1 ty) sl1 any tmp
-with tr_exprlist: temp_env -> C.exprlist -> list statement -> list expr -> list ident -> Prop :=
+with tr_exprlist: temp_env -> Csyntax.exprlist -> list statement -> list expr -> list ident -> Prop :=
| tr_nil: forall le tmp,
- tr_exprlist le C.Enil nil nil tmp
+ tr_exprlist le Csyntax.Enil nil nil tmp
| tr_cons: forall le e1 el2 sl1 a1 tmp1 sl2 al2 tmp2 tmp,
tr_expr le For_val e1 sl1 a1 tmp1 ->
tr_exprlist le el2 sl2 al2 tmp2 ->
list_disjoint tmp1 tmp2 ->
incl tmp1 tmp -> incl tmp2 tmp ->
- tr_exprlist le (C.Econs e1 el2) (sl1 ++ sl2) (a1 :: al2) tmp.
+ tr_exprlist le (Csyntax.Econs e1 el2) (sl1 ++ sl2) (a1 :: al2) tmp.
Scheme tr_expr_ind2 := Minimality for tr_expr Sort Prop
with tr_exprlist_ind2 := Minimality for tr_exprlist Sort Prop.
@@ -372,11 +372,11 @@ Qed.
(** The "top-level" translation is equivalent to [tr_expr] above
for source terms. It brings additional flexibility in the matching
- between C values and Cminor expressions: in the case of
+ between Csyntax values and Cminor expressions: in the case of
[tr_expr], the Cminor expression must not depend on memory,
while in the case of [tr_top] it can depend on the current memory
state. This special case is extended to values occurring under
- one or several [C.Eparen]. *)
+ one or several [Csyntax.Eparen]. *)
Section TR_TOP.
@@ -385,14 +385,14 @@ Variable e: env.
Variable le: temp_env.
Variable m: mem.
-Inductive tr_top: destination -> C.expr -> list statement -> expr -> list ident -> Prop :=
+Inductive tr_top: destination -> Csyntax.expr -> list statement -> expr -> list ident -> Prop :=
| tr_top_val_val: forall v ty a tmp,
typeof a = ty -> eval_expr ge e le m a v ->
- tr_top For_val (C.Eval v ty) nil a tmp
+ tr_top For_val (Csyntax.Eval v ty) nil a tmp
(*
| tr_top_val_set: forall t tyl v ty a any tmp,
typeof a = ty -> eval_expr ge e le m a v ->
- tr_top (For_set tyl t) (C.Eval v ty) (Sset t (fold_left Ecast tyl a) :: nil) any tmp
+ tr_top (For_set tyl t) (Csyntax.Eval v ty) (Sset t (fold_left Ecast tyl a) :: nil) any tmp
*)
| tr_top_base: forall dst r sl a tmp,
tr_expr le dst r sl a tmp ->
@@ -400,92 +400,92 @@ Inductive tr_top: destination -> C.expr -> list statement -> expr -> list ident
(*
| tr_top_paren_test: forall tyl t r ty sl a tmp,
tr_top (For_set (ty :: tyl) t) r sl a tmp ->
- tr_top (For_set tyl t) (C.Eparen r ty) sl a tmp.
+ tr_top (For_set tyl t) (Csyntax.Eparen r ty) sl a tmp.
*)
End TR_TOP.
(** ** Translation of statements *)
-Inductive tr_expression: C.expr -> statement -> expr -> Prop :=
+Inductive tr_expression: Csyntax.expr -> statement -> expr -> Prop :=
| tr_expression_intro: forall r sl a tmps,
(forall ge e le m, tr_top ge e le m For_val r sl a tmps) ->
tr_expression r (makeseq sl) a.
-Inductive tr_expr_stmt: C.expr -> statement -> Prop :=
+Inductive tr_expr_stmt: Csyntax.expr -> statement -> Prop :=
| tr_expr_stmt_intro: forall r sl a tmps,
(forall ge e le m, tr_top ge e le m For_effects r sl a tmps) ->
tr_expr_stmt r (makeseq sl).
-Inductive tr_if: C.expr -> statement -> statement -> statement -> Prop :=
+Inductive tr_if: Csyntax.expr -> statement -> statement -> statement -> Prop :=
| tr_if_intro: forall r s1 s2 sl a tmps,
(forall ge e le m, tr_top ge e le m For_val r sl a tmps) ->
tr_if r s1 s2 (makeseq (sl ++ makeif a s1 s2 :: nil)).
-Inductive tr_stmt: C.statement -> statement -> Prop :=
+Inductive tr_stmt: Csyntax.statement -> statement -> Prop :=
| tr_skip:
- tr_stmt C.Sskip Sskip
+ tr_stmt Csyntax.Sskip Sskip
| tr_do: forall r s,
tr_expr_stmt r s ->
- tr_stmt (C.Sdo r) s
+ tr_stmt (Csyntax.Sdo r) s
| tr_seq: forall s1 s2 ts1 ts2,
tr_stmt s1 ts1 -> tr_stmt s2 ts2 ->
- tr_stmt (C.Ssequence s1 s2) (Ssequence ts1 ts2)
+ tr_stmt (Csyntax.Ssequence s1 s2) (Ssequence ts1 ts2)
| tr_ifthenelse: forall r s1 s2 s' a ts1 ts2,
tr_expression r s' a ->
tr_stmt s1 ts1 -> tr_stmt s2 ts2 ->
- tr_stmt (C.Sifthenelse r s1 s2) (Ssequence s' (Sifthenelse a ts1 ts2))
+ tr_stmt (Csyntax.Sifthenelse r s1 s2) (Ssequence s' (Sifthenelse a ts1 ts2))
| tr_while: forall r s1 s' ts1,
tr_if r Sskip Sbreak s' ->
tr_stmt s1 ts1 ->
- tr_stmt (C.Swhile r s1)
+ tr_stmt (Csyntax.Swhile r s1)
(Sloop (Ssequence s' ts1) Sskip)
| tr_dowhile: forall r s1 s' ts1,
tr_if r Sskip Sbreak s' ->
tr_stmt s1 ts1 ->
- tr_stmt (C.Sdowhile r s1)
+ tr_stmt (Csyntax.Sdowhile r s1)
(Sloop ts1 s')
| tr_for_1: forall r s3 s4 s' ts3 ts4,
tr_if r Sskip Sbreak s' ->
tr_stmt s3 ts3 ->
tr_stmt s4 ts4 ->
- tr_stmt (C.Sfor C.Sskip r s3 s4)
+ tr_stmt (Csyntax.Sfor Csyntax.Sskip r s3 s4)
(Sloop (Ssequence s' ts4) ts3)
| tr_for_2: forall s1 r s3 s4 s' ts1 ts3 ts4,
tr_if r Sskip Sbreak s' ->
- s1 <> C.Sskip ->
+ s1 <> Csyntax.Sskip ->
tr_stmt s1 ts1 ->
tr_stmt s3 ts3 ->
tr_stmt s4 ts4 ->
- tr_stmt (C.Sfor s1 r s3 s4)
+ tr_stmt (Csyntax.Sfor s1 r s3 s4)
(Ssequence ts1 (Sloop (Ssequence s' ts4) ts3))
| tr_break:
- tr_stmt C.Sbreak Sbreak
+ tr_stmt Csyntax.Sbreak Sbreak
| tr_continue:
- tr_stmt C.Scontinue Scontinue
+ tr_stmt Csyntax.Scontinue Scontinue
| tr_return_none:
- tr_stmt (C.Sreturn None) (Sreturn None)
+ tr_stmt (Csyntax.Sreturn None) (Sreturn None)
| tr_return_some: forall r s' a,
tr_expression r s' a ->
- tr_stmt (C.Sreturn (Some r)) (Ssequence s' (Sreturn (Some a)))
+ tr_stmt (Csyntax.Sreturn (Some r)) (Ssequence s' (Sreturn (Some a)))
| tr_switch: forall r ls s' a tls,
tr_expression r s' a ->
tr_lblstmts ls tls ->
- tr_stmt (C.Sswitch r ls) (Ssequence s' (Sswitch a tls))
+ tr_stmt (Csyntax.Sswitch r ls) (Ssequence s' (Sswitch a tls))
| tr_label: forall lbl s ts,
tr_stmt s ts ->
- tr_stmt (C.Slabel lbl s) (Slabel lbl ts)
+ tr_stmt (Csyntax.Slabel lbl s) (Slabel lbl ts)
| tr_goto: forall lbl,
- tr_stmt (C.Sgoto lbl) (Sgoto lbl)
+ tr_stmt (Csyntax.Sgoto lbl) (Sgoto lbl)
-with tr_lblstmts: C.labeled_statements -> labeled_statements -> Prop :=
+with tr_lblstmts: Csyntax.labeled_statements -> labeled_statements -> Prop :=
| tr_default: forall s ts,
tr_stmt s ts ->
- tr_lblstmts (C.LSdefault s) (LSdefault ts)
+ tr_lblstmts (Csyntax.LSdefault s) (LSdefault ts)
| tr_case: forall n s ls ts tls,
tr_stmt s ts ->
tr_lblstmts ls tls ->
- tr_lblstmts (C.LScase n s ls) (LScase n ts tls).
+ tr_lblstmts (Csyntax.LScase n s ls) (LScase n ts tls).
(** * Correctness proof with respect to the specification. *)
@@ -504,7 +504,7 @@ Proof.
Qed.
Remark bind2_inversion:
- forall (A B C: Type) (f: mon (A*B)) (g: A -> B -> mon C) (y: C) (z1 z3: generator) I,
+ forall (A B Csyntax: Type) (f: mon (A*B)) (g: A -> B -> mon Csyntax) (y: Csyntax) (z1 z3: generator) I,
bind2 f g z1 = Res y z3 I ->
exists x1, exists x2, exists z2, exists I1, exists I2,
f z1 = Res (x1,x2) z2 I1 /\ g x1 x2 z2 = Res y z3 I2.
@@ -632,7 +632,7 @@ Lemma contained_disjoint:
contained l1 g1 g2 -> contained l2 g2 g3 -> list_disjoint l1 l2.
Proof.
intros; red; intros. red; intro; subst y.
- exploit H; eauto. intros [A B]. exploit H0; eauto. intros [C D].
+ exploit H; eauto. intros [A B]. exploit H0; eauto. intros [Csyntax D].
elim (Plt_strict x). apply Plt_Ple_trans with (gen_next g2); auto.
Qed.
@@ -640,7 +640,7 @@ Lemma contained_notin:
forall g1 l g2 id g3,
contained l g1 g2 -> within id g2 g3 -> ~In id l.
Proof.
- intros; red; intros. exploit H; eauto. intros [C D]. destruct H0 as [A B].
+ intros; red; intros. exploit H; eauto. intros [Csyntax D]. destruct H0 as [A B].
elim (Plt_strict id). apply Plt_Ple_trans with (gen_next g2); auto.
Qed.
@@ -737,13 +737,13 @@ Lemma transl_valof_meets_spec:
exists tmps, tr_rvalof ty a sl b tmps /\ contained tmps g g'.
Proof.
unfold transl_valof; intros.
- destruct (type_is_volatile ty) as []_eqn; monadInv H.
+ destruct (type_is_volatile ty) eqn:?; monadInv H.
exists (x :: nil); split; eauto with gensym. econstructor; eauto with coqlib.
exists (@nil ident); split; eauto with gensym. constructor; auto.
Qed.
-Scheme expr_ind2 := Induction for C.expr Sort Prop
- with exprlist_ind2 := Induction for C.exprlist Sort Prop.
+Scheme expr_ind2 := Induction for Csyntax.expr Sort Prop
+ with exprlist_ind2 := Induction for Csyntax.exprlist Sort Prop.
Combined Scheme expr_exprlist_ind from expr_ind2, exprlist_ind2.
Lemma transl_meets_spec:
@@ -775,7 +775,7 @@ Opaque makeif.
econstructor; split; eauto. intros; apply tr_expr_add_dest. constructor; auto.
(* valof *)
monadInv H0. exploit H; eauto. intros [tmp1 [A B]].
- exploit transl_valof_meets_spec; eauto. intros [tmp2 [C D]]. UseFinish.
+ exploit transl_valof_meets_spec; eauto. intros [tmp2 [Csyntax D]]. UseFinish.
exists (tmp1 ++ tmp2); split.
intros; apply tr_expr_add_dest. econstructor; eauto with gensym.
eauto with gensym.
@@ -790,7 +790,7 @@ Opaque makeif.
econstructor; split; eauto. intros; apply tr_expr_add_dest. constructor; auto.
(* binop *)
monadInv H1. exploit H; eauto. intros [tmp1 [A B]].
- exploit H0; eauto. intros [tmp2 [C D]]. UseFinish.
+ exploit H0; eauto. intros [tmp2 [Csyntax D]]. UseFinish.
exists (tmp1 ++ tmp2); split.
intros; apply tr_expr_add_dest. econstructor; eauto with gensym.
eauto with gensym.
@@ -801,7 +801,7 @@ Opaque makeif.
monadInv H1. exploit H; eauto. intros [tmp1 [A B]].
destruct dst; monadInv EQ0.
(* for value *)
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
simpl add_dest in *.
exists (x0 :: tmp1 ++ tmp2); split.
intros; eapply tr_seqand_val; eauto with gensym.
@@ -809,13 +809,13 @@ Opaque makeif.
apply contained_cons. eauto with gensym.
apply contained_app; eauto with gensym.
(* for effects *)
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
simpl add_dest in *.
exists (tmp1 ++ tmp2); split.
intros; eapply tr_seqand_effects; eauto with gensym.
apply contained_app; eauto with gensym.
(* for set *)
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
simpl add_dest in *.
exists (tmp1 ++ tmp2); split.
intros; eapply tr_seqand_set; eauto with gensym.
@@ -825,7 +825,7 @@ Opaque makeif.
monadInv H1. exploit H; eauto. intros [tmp1 [A B]].
destruct dst; monadInv EQ0.
(* for value *)
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
simpl add_dest in *.
exists (x0 :: tmp1 ++ tmp2); split.
intros; eapply tr_seqor_val; eauto with gensym.
@@ -833,13 +833,13 @@ Opaque makeif.
apply contained_cons. eauto with gensym.
apply contained_app; eauto with gensym.
(* for effects *)
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
simpl add_dest in *.
exists (tmp1 ++ tmp2); split.
intros; eapply tr_seqor_effects; eauto with gensym.
apply contained_app; eauto with gensym.
(* for set *)
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
simpl add_dest in *.
exists (tmp1 ++ tmp2); split.
intros; eapply tr_seqor_set; eauto with gensym.
@@ -849,7 +849,7 @@ Opaque makeif.
monadInv H2. exploit H; eauto. intros [tmp1 [A B]].
destruct dst; monadInv EQ0.
(* for value *)
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
exploit H1; eauto with gensym. intros [tmp3 [E F]].
simpl add_dest in *.
exists (x0 :: tmp1 ++ tmp2 ++ tmp3); split.
@@ -860,14 +860,14 @@ Opaque makeif.
apply contained_app. eauto with gensym.
apply contained_app; eauto with gensym.
(* for effects *)
- exploit H0; eauto. intros [tmp2 [C D]].
+ exploit H0; eauto. intros [tmp2 [Csyntax D]].
exploit H1; eauto. intros [tmp3 [E F]].
simpl add_dest in *.
exists (tmp1 ++ tmp2 ++ tmp3); split.
intros; eapply tr_condition_effects; eauto with gensym.
apply contained_app; eauto with gensym.
(* for test *)
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
exploit H1; eauto with gensym. intros [tmp3 [E F]].
simpl add_dest in *.
exists (tmp1 ++ tmp2 ++ tmp3); split.
@@ -883,7 +883,7 @@ Opaque makeif.
exists (@nil ident); split; auto with gensym. constructor.
(* assign *)
monadInv H1. exploit H; eauto. intros [tmp1 [A B]].
- exploit H0; eauto. intros [tmp2 [C D]].
+ exploit H0; eauto. intros [tmp2 [Csyntax D]].
destruct dst; monadInv EQ2; simpl add_dest in *.
(* for value *)
exists (x1 :: tmp1 ++ tmp2); split.
@@ -902,7 +902,7 @@ Opaque makeif.
apply contained_app; eauto with gensym.
(* assignop *)
monadInv H1. exploit H; eauto. intros [tmp1 [A B]].
- exploit H0; eauto. intros [tmp2 [C D]].
+ exploit H0; eauto. intros [tmp2 [Csyntax D]].
exploit transl_valof_meets_spec; eauto. intros [tmp3 [E F]].
destruct dst; monadInv EQ3; simpl add_dest in *.
(* for value *)
@@ -928,7 +928,7 @@ Opaque makeif.
econstructor; eauto with gensym.
apply contained_cons; eauto with gensym.
(* for effects *)
- exploit transl_valof_meets_spec; eauto. intros [tmp2 [C D]].
+ exploit transl_valof_meets_spec; eauto. intros [tmp2 [Csyntax D]].
exists (tmp1 ++ tmp2); split.
econstructor; eauto with gensym.
eauto with gensym.
@@ -939,7 +939,7 @@ Opaque makeif.
apply contained_cons; eauto with gensym.
(* comma *)
monadInv H1. exploit H; eauto. intros [tmp1 [A B]].
- exploit H0; eauto with gensym. intros [tmp2 [C D]].
+ exploit H0; eauto with gensym. intros [tmp2 [Csyntax D]].
exists (tmp1 ++ tmp2); split.
econstructor; eauto with gensym.
destruct dst; simpl; eauto with gensym.
@@ -949,7 +949,7 @@ Opaque makeif.
apply contained_app; eauto with gensym.
(* call *)
monadInv H1. exploit H; eauto. intros [tmp1 [A B]].
- exploit H0; eauto. intros [tmp2 [C D]].
+ exploit H0; eauto. intros [tmp2 [Csyntax D]].
destruct dst; monadInv EQ2; simpl add_dest in *.
(* for value *)
exists (x1 :: tmp1 ++ tmp2); split.
@@ -988,7 +988,7 @@ Opaque makeif.
monadInv H; exists (@nil ident); split; auto with gensym. constructor.
(* cons *)
monadInv H1. exploit H; eauto. intros [tmp1 [A B]].
- exploit H0; eauto. intros [tmp2 [C D]].
+ exploit H0; eauto. intros [tmp2 [Csyntax D]].
exists (tmp1 ++ tmp2); split.
econstructor; eauto with gensym.
eauto with gensym.
@@ -1054,13 +1054,13 @@ Qed.
Theorem transl_function_spec:
forall f tf,
transl_function f = OK tf ->
- tr_stmt f.(C.fn_body) tf.(fn_body)
- /\ fn_return tf = C.fn_return f
- /\ fn_params tf = C.fn_params f
- /\ fn_vars tf = C.fn_vars f.
+ tr_stmt f.(Csyntax.fn_body) tf.(fn_body)
+ /\ fn_return tf = Csyntax.fn_return f
+ /\ fn_params tf = Csyntax.fn_params f
+ /\ fn_vars tf = Csyntax.fn_vars f.
Proof.
intros until tf. unfold transl_function.
- case_eq (transl_stmt (C.fn_body f) (initial_generator tt)); intros; inv H0.
+ case_eq (transl_stmt (Csyntax.fn_body f) (initial_generator tt)); intros; inv H0.
simpl. intuition. eapply transl_stmt_meets_spec; eauto.
Qed.
diff --git a/cfrontend/SimplLocalsproof.v b/cfrontend/SimplLocalsproof.v
index f58a213..8df7b6e 100644
--- a/cfrontend/SimplLocalsproof.v
+++ b/cfrontend/SimplLocalsproof.v
@@ -83,7 +83,7 @@ Lemma type_of_global_preserved:
Proof.
unfold type_of_global; intros.
rewrite varinfo_preserved. destruct (Genv.find_var_info ge id). auto.
- destruct (Genv.find_funct_ptr ge id) as [fd|]_eqn; inv H.
+ destruct (Genv.find_funct_ptr ge id) as [fd|] eqn:?; inv H.
exploit function_ptr_translated; eauto. intros [tf [A B]]. rewrite A.
decEq. apply type_of_fundef_preserved; auto.
Qed.
@@ -183,12 +183,12 @@ Lemma match_envs_extcall:
Proof.
intros. eapply match_envs_invariant; eauto.
intros. destruct H0. eapply H8. intros; red. auto. auto.
- red in H2. intros. destruct (f b) as [[b' delta]|]_eqn.
+ red in H2. intros. destruct (f b) as [[b' delta]|] eqn:?.
eapply H1; eauto.
- destruct (f' b) as [[b' delta]|]_eqn; auto.
+ destruct (f' b) as [[b' delta]|] eqn:?; auto.
exploit H2; eauto. unfold Mem.valid_block. intros [A B].
omegaContradiction.
- intros. destruct (f b) as [[b'' delta']|]_eqn. eauto.
+ intros. destruct (f b) as [[b'' delta']|] eqn:?. eauto.
exploit H2; eauto. unfold Mem.valid_block. intros [A B].
omegaContradiction.
Qed.
@@ -405,7 +405,7 @@ Lemma match_envs_set_temp:
match_envs f cenv e (PTree.set id v le) m lo hi te (PTree.set id tv tle) tlo thi.
Proof.
intros. unfold check_temp in H1.
- destruct (VSet.mem id cenv) as []_eqn; monadInv H1.
+ destruct (VSet.mem id cenv) eqn:?; monadInv H1.
destruct H. constructor; eauto; intros.
(* vars *)
generalize (me_vars0 id0); intros MV; inv MV.
@@ -477,8 +477,8 @@ Remark add_local_variable_charact:
VSet.In id1 cenv \/ exists chunk, access_mode ty = By_value chunk /\ id = id1 /\ VSet.mem id atk = false.
Proof.
intros. unfold add_local_variable. split; intros.
- destruct (access_mode ty) as []_eqn; auto.
- destruct (VSet.mem id atk) as []_eqn; auto.
+ destruct (access_mode ty) eqn:?; auto.
+ destruct (VSet.mem id atk) eqn:?; auto.
rewrite VSF.add_iff in H. destruct H; auto. right; exists m; auto.
destruct H as [A | [chunk [A [B C]]]].
destruct (access_mode ty); auto. destruct (VSet.mem id atk); auto. rewrite VSF.add_iff; auto.
@@ -639,7 +639,7 @@ Proof.
(* inductive case *)
simpl in H1. inv H1. simpl.
- destruct (VSet.mem id cenv) as []_eqn. simpl.
+ destruct (VSet.mem id cenv) eqn:?. simpl.
(* variable is lifted out of memory *)
exploit Mem.alloc_left_unmapped_inject; eauto.
intros [j1 [A [B [C D]]]].
@@ -782,7 +782,7 @@ Proof.
assert (forall id l1 l2,
(In id (var_names l1) -> In id (var_names l2)) ->
(create_undef_temps l1)!id = None \/ (create_undef_temps l1)!id = (create_undef_temps l2)!id).
- intros. destruct ((create_undef_temps l1)!id) as [v1|]_eqn; auto.
+ intros. destruct ((create_undef_temps l1)!id) as [v1|] eqn:?; auto.
exploit create_undef_temps_inv; eauto. intros [A B]. subst v1.
exploit list_in_map_inv. unfold var_names in H. apply H. eexact B.
intros [[id1 ty1] [P Q]]. simpl in P; subst id1.
@@ -813,7 +813,7 @@ Remark filter_charact:
In x (List.filter f l) <-> In x l /\ f x = true.
Proof.
induction l; simpl. tauto.
- destruct (f a) as []_eqn.
+ destruct (f a) eqn:?.
simpl. rewrite IHl. intuition congruence.
intuition congruence.
Qed.
@@ -902,7 +902,7 @@ Proof.
unfold var_names in i. exploit list_in_map_inv; eauto.
intros [[id' ty] [EQ IN]]; simpl in EQ; subst id'.
exploit F; eauto. intros [b [P R]].
- destruct (VSet.mem id cenv) as []_eqn.
+ destruct (VSet.mem id cenv) eqn:?.
(* local var, lifted *)
destruct R as [U V]. exploit H2; eauto. intros [chunk X].
eapply match_var_lifted with (v := Vundef) (tv := Vundef); eauto.
@@ -918,7 +918,7 @@ Proof.
(* non-local var *)
exploit G; eauto. unfold empty_env. rewrite PTree.gempty. intros [U V].
eapply match_var_not_local; eauto.
- destruct (VSet.mem id cenv) as []_eqn; auto.
+ destruct (VSet.mem id cenv) eqn:?; auto.
elim n; eauto.
(* temps *)
@@ -1072,7 +1072,7 @@ Proof.
(* inductive case *)
inv NOREPET. inv CASTED. inv VINJ.
exploit me_vars; eauto. instantiate (1 := id); intros MV.
- destruct (VSet.mem id cenv) as []_eqn.
+ destruct (VSet.mem id cenv) eqn:?.
(* lifted to temp *)
eapply IHbind_parameters with (tle1 := PTree.set id v' tle1); eauto.
eapply match_envs_assign_lifted; eauto.
@@ -1164,7 +1164,7 @@ Proof.
induction l; simpl; intros.
contradiction.
destruct a as [[b1 lo1] hi1].
- destruct (Mem.free m b1 lo1 hi1) as [m1|]_eqn; try discriminate.
+ destruct (Mem.free m b1 lo1 hi1) as [m1|] eqn:?; try discriminate.
destruct H0. inv H0. eapply Mem.free_range_perm; eauto.
red; intros. eapply Mem.perm_free_3; eauto. eapply IHl; eauto.
Qed.
@@ -1209,7 +1209,7 @@ Lemma free_list_right_inject:
Proof.
induction l; simpl; intros.
congruence.
- destruct a as [[b lo] hi]. destruct (Mem.free m2 b lo hi) as [m21|]_eqn; try discriminate.
+ destruct a as [[b lo] hi]. destruct (Mem.free m2 b lo hi) as [m21|] eqn:?; try discriminate.
eapply IHl with (m2 := m21); eauto.
eapply Mem.free_right_inject; eauto.
Qed.
@@ -1380,8 +1380,8 @@ Proof.
destruct (classify_cmp ty1 ty2); try destruct s; inv H0; try discriminate; inv H1; inv H; TrivialInject.
destruct (Int.eq i Int.zero); try discriminate; auto.
destruct (Int.eq i Int.zero); try discriminate; auto.
- destruct (Mem.valid_pointer m b1 (Int.unsigned ofs1)) as []_eqn; try discriminate.
- destruct (Mem.valid_pointer m b0 (Int.unsigned ofs0)) as []_eqn; try discriminate.
+ destruct (Mem.valid_pointer m b1 (Int.unsigned ofs1)) eqn:?; try discriminate.
+ destruct (Mem.valid_pointer m b0 (Int.unsigned ofs0)) eqn:?; try discriminate.
simpl in H3.
rewrite (Mem.valid_pointer_inject_val _ _ _ _ _ _ _ MEMINJ Heqb).
rewrite (Mem.valid_pointer_inject_val _ _ _ _ _ _ _ MEMINJ Heqb0).
@@ -1509,7 +1509,7 @@ Proof.
(* addrof *)
exploit eval_simpl_lvalue; eauto.
destruct a; auto with compat.
- destruct a; auto. destruct (VSet.mem i cenv) as []_eqn; auto.
+ destruct a; auto. destruct (VSet.mem i cenv) eqn:?; auto.
elim (H0 i). apply VSet.singleton_2. auto. apply VSet.mem_2. auto.
intros [b' [ofs' [A B]]].
exists (Vptr b' ofs'); split; auto. constructor; auto.
@@ -1529,7 +1529,7 @@ Proof.
(* rval *)
assert (EITHER: (exists id, exists ty, a = Evar id ty /\ VSet.mem id cenv = true)
\/ (match a with Evar id _ => VSet.mem id cenv = false | _ => True end)).
- destruct a; auto. destruct (VSet.mem i cenv) as []_eqn; auto. left; exists i; exists t; auto.
+ destruct a; auto. destruct (VSet.mem i cenv) eqn:?; auto. left; exists i; exists t; auto.
destruct EITHER as [ [id [ty [EQ OPT]]] | NONOPT ].
(* a variable pulled out of memory *)
subst a. simpl. rewrite OPT.
@@ -1696,10 +1696,10 @@ Lemma match_cont_extcall:
Proof.
intros. eapply match_cont_invariant; eauto.
destruct H0. intros. eapply H5; eauto.
- red in H2. intros. destruct (f b) as [[b' delta] | ]_eqn. auto.
- destruct (f' b) as [[b' delta] | ]_eqn; auto.
+ red in H2. intros. destruct (f b) as [[b' delta] | ] eqn:?. auto.
+ destruct (f' b) as [[b' delta] | ] eqn:?; auto.
exploit H2; eauto. unfold Mem.valid_block. intros [A B]. omegaContradiction.
- red in H2. intros. destruct (f b) as [[b'' delta''] | ]_eqn. auto.
+ red in H2. intros. destruct (f b) as [[b'' delta''] | ] eqn:?. auto.
exploit H2; eauto. unfold Mem.valid_block. intros [A B]. omegaContradiction.
Qed.
@@ -1752,7 +1752,7 @@ Remark free_list_nextblock:
Proof.
induction l; simpl; intros.
congruence.
- destruct a. destruct p. destruct (Mem.free m b z0 z) as [m1|]_eqn; try discriminate.
+ destruct a. destruct p. destruct (Mem.free m b z0 z) as [m1|] eqn:?; try discriminate.
transitivity (Mem.nextblock m1). eauto. eapply Mem.nextblock_free; eauto.
Qed.
@@ -1764,7 +1764,7 @@ Remark free_list_load:
Proof.
induction l; simpl; intros.
inv H; auto.
- destruct a. destruct p. destruct (Mem.free m b z0 z) as [m1|]_eqn; try discriminate.
+ destruct a. destruct p. destruct (Mem.free m b z0 z) as [m1|] eqn:?; try discriminate.
transitivity (Mem.load chunk m1 b' 0). eauto.
eapply Mem.load_free. eauto. left. assert (b' < b) by eauto. unfold block; omega.
Qed.
@@ -1860,7 +1860,7 @@ Remark is_liftable_var_charact:
end.
Proof.
intros. destruct a; simpl; auto.
- destruct (VSet.mem i cenv) as []_eqn.
+ destruct (VSet.mem i cenv) eqn:?.
exists t; auto.
auto.
Qed.
@@ -2202,7 +2202,7 @@ Proof.
apply val_list_inject_incr with j'; eauto.
eexact B. eexact C.
intros. apply (create_undef_temps_lifted id f). auto.
- intros. destruct (create_undef_temps (fn_temps f))!id as [v|]_eqn; auto.
+ intros. destruct (create_undef_temps (fn_temps f))!id as [v|] eqn:?; auto.
exploit create_undef_temps_inv; eauto. intros [P Q]. elim (H3 id id); auto.
intros [tel [tm1 [P [Q [R [S T]]]]]].
change (cenv_for_gen (addr_taken_stmt (fn_body f)) (fn_params f ++ fn_vars f))
diff --git a/checklink/Asm_printers.ml b/checklink/Asm_printers.ml
index 094d51d..aeb4b3f 100644
--- a/checklink/Asm_printers.ml
+++ b/checklink/Asm_printers.ml
@@ -1,21 +1,10 @@
+open Camlcoq
open Asm
open AST
-open BinInt
-open BinPos
open Library
-let rec int_of_pos = function
- | Coq_xH -> 1
- | Coq_xO q -> 2 * int_of_pos q
- | Coq_xI q -> 2 * int_of_pos q + 1
-
-let string_of_pos p = string_of_int (int_of_pos p)
-
-let string_of_coq_Z = function
- | Z0 -> "0"
- | Zpos p -> string_of_pos p
- | Zneg p -> "-" ^ string_of_pos p
-
+let string_of_pos p = Z.to_string (Z.Zpos p)
+let string_of_coq_Z = Z.to_string
let string_of_ident = string_of_pos
let string_of_label = string_of_pos
let string_of_iint = string_of_coq_Z
diff --git a/checklink/Check.ml b/checklink/Check.ml
index a1cc004..9d668fa 100644
--- a/checklink/Check.ml
+++ b/checklink/Check.ml
@@ -1,8 +1,7 @@
+open Camlcoq
open Asm
open Asm_printers
open AST
-open BinInt
-open BinPos
open Bitstring_utils
open C2C
open Camlcoq
@@ -204,7 +203,7 @@ let re_variadic_stub: Str.regexp = Str.regexp "\\(.*\\)\\$[if]*$"
address, unless the symbol is a stub from CompCert. Otherwise, it filters
out all symbols whose virtual address does not match [vaddr].
*)
-let idmap_unify (k: positive) (vaddr: int32) (sfw: s_framework)
+let idmap_unify (k: P.t) (vaddr: int32) (sfw: s_framework)
: s_framework or_err =
try (
(* get the list of possible symbols for ident [k] *)
@@ -438,13 +437,13 @@ let match_csts (cc: constant) (ec: int32): checker = fun ffw ->
(* sda should be handled separately in places it occurs *)
fatal "Unhandled Csymbol_sda, please report."
-let match_z_int32 (cz: coq_Z) (ei: int32) =
+let match_z_int32 (cz: Z.t) (ei: int32) =
let cz = z_int32 cz in
check_eq (
Printf.sprintf "match_z_int32 %s %s" (string_of_int32 cz) (string_of_int32 ei)
) cz ei
-let match_z_int (cz: coq_Z) (ei: int) =
+let match_z_int (cz: Z.t) (ei: int) =
let cz = z_int32 cz in
let ei = Safe32.of_int ei in
check_eq (
@@ -452,7 +451,7 @@ let match_z_int (cz: coq_Z) (ei: int) =
) cz ei
(* [m] is interpreted as a bitmask, and checked against [ei]. *)
-let match_mask (m: coq_Z) (ei: int32) =
+let match_mask (m: Z.t) (ei: int32) =
let m = z_int32_lax m in
check_eq (
Printf.sprintf "match_mask %s %s"
diff --git a/checklink/Frameworks.ml b/checklink/Frameworks.ml
index 074a432..35144dc 100644
--- a/checklink/Frameworks.ml
+++ b/checklink/Frameworks.ml
@@ -1,6 +1,6 @@
+open Camlcoq
open Asm
open AST
-open BinPos
open ELF_types
open Lens
open Library
@@ -62,7 +62,7 @@ type e_framework = {
}
module PosOT = struct
- type t = positive
+ type t = P.t
let compare = Pervasives.compare
end
diff --git a/checklink/Library.ml b/checklink/Library.ml
index c38c1f1..acea80a 100644
--- a/checklink/Library.ml
+++ b/checklink/Library.ml
@@ -1,5 +1,3 @@
-open BinInt
-open BinPos
open Camlcoq
type bitstring = Bitstring.bitstring
@@ -75,9 +73,9 @@ exception Int32Overflow
(* Can only return positive numbers 0 <= res < 2^31 *)
let positive_int32 p =
let rec positive_int32_unsafe = function
- | Coq_xI(p) -> Int32.(add (shift_left (positive_int32_unsafe p) 1) 1l)
- | Coq_xO(p) -> Int32.(shift_left (positive_int32_unsafe p) 1)
- | Coq_xH -> 1l
+ | P.Coq_xI(p) -> Int32.(add (shift_left (positive_int32_unsafe p) 1) 1l)
+ | P.Coq_xO(p) -> Int32.(shift_left (positive_int32_unsafe p) 1)
+ | P.Coq_xH -> 1l
in
let res = positive_int32_unsafe p in
if res >= 0l
@@ -86,27 +84,27 @@ let positive_int32 p =
(* This allows for 1 bit of overflow, effectively returning a negative *)
let rec positive_int32_lax = function
-| Coq_xI(p) ->
+| P.Coq_xI(p) ->
let acc = positive_int32_lax p in
if acc < 0l
then raise Int32Overflow
else Int32.(add (shift_left acc 1) 1l)
-| Coq_xO(p) ->
+| P.Coq_xO(p) ->
let acc = positive_int32_lax p in
if acc < 0l
then raise Int32Overflow
else Int32.shift_left acc 1
-| Coq_xH -> 1l
+| P.Coq_xH -> 1l
let z_int32 = function
-| Z0 -> 0l
-| Zpos(p) -> positive_int32 p
-| Zneg(p) -> Int32.neg (positive_int32 p)
+| Z.Z0 -> 0l
+| Z.Zpos(p) -> positive_int32 p
+| Z.Zneg(p) -> Int32.neg (positive_int32 p)
let z_int32_lax = function
-| Z0 -> 0l
-| Zpos(p) -> positive_int32_lax p
-| Zneg(_) -> raise Int32Overflow
+| Z.Z0 -> 0l
+| Z.Zpos(p) -> positive_int32_lax p
+| Z.Zneg(_) -> raise Int32Overflow
let z_int z = Safe32.to_int (z_int32 z)
diff --git a/common/AST.v b/common/AST.v
index 40da732..d2065d6 100644
--- a/common/AST.v
+++ b/common/AST.v
@@ -225,10 +225,10 @@ Proof.
revert x EQ H0. induction (prog_defs p); simpl; intros.
inv EQ. contradiction.
destruct a as [id [f|v]].
- destruct (transf_fun f) as [tf1|msg]_eqn; monadInv EQ.
+ destruct (transf_fun f) as [tf1|msg] eqn:?; monadInv EQ.
simpl in H0; destruct H0. inv H. exists f; auto.
exploit IHl; eauto. intros [f' [P Q]]; exists f'; auto.
- destruct (transf_globvar v) as [tv1|msg]_eqn; monadInv EQ.
+ destruct (transf_globvar v) as [tv1|msg] eqn:?; monadInv EQ.
simpl in H0; destruct H0. inv H.
exploit IHl; eauto. intros [f' [P Q]]; exists f'; auto.
Qed.
@@ -245,10 +245,10 @@ Proof.
revert x EQ H0. induction (prog_defs p); simpl; intros.
inv EQ. contradiction.
destruct a as [id [f|v]].
- destruct (transf_fun f) as [tf1|msg]_eqn; monadInv EQ.
+ destruct (transf_fun f) as [tf1|msg] eqn:?; monadInv EQ.
simpl in H0; destruct H0. inv H.
exploit IHl; eauto. intros [v' [P Q]]; exists v'; auto.
- destruct (transf_globvar v) as [tv1|msg]_eqn; monadInv EQ.
+ destruct (transf_globvar v) as [tv1|msg] eqn:?; monadInv EQ.
simpl in H0; destruct H0. inv H.
monadInv Heqr. simpl. exists (gvar_info v). split. left. destruct v; auto. auto.
exploit IHl; eauto. intros [v' [P Q]]; exists v'; auto.
@@ -394,11 +394,11 @@ Proof.
monadInv EQ. constructor.
destruct a as [id [f|v]].
(* function *)
- destruct (transf_fun f) as [tf|?]_eqn; monadInv EQ.
+ destruct (transf_fun f) as [tf|?] eqn:?; monadInv EQ.
constructor; auto. constructor; auto.
(* variable *)
unfold transf_globvar in EQ.
- destruct (transf_var (gvar_info v)) as [tinfo|?]_eqn; simpl in EQ; monadInv EQ.
+ destruct (transf_var (gvar_info v)) as [tinfo|?] eqn:?; simpl in EQ; monadInv EQ.
constructor; auto. destruct v; simpl in *. constructor; auto.
Qed.
diff --git a/common/Globalenvs.v b/common/Globalenvs.v
index 100cab8..d426440 100644
--- a/common/Globalenvs.v
+++ b/common/Globalenvs.v
@@ -607,14 +607,14 @@ Proof.
unfold alloc_global. intros.
destruct g as [id [f|v]].
(* function *)
- destruct (Mem.alloc m 0 1) as [m1 b]_eqn.
+ destruct (Mem.alloc m 0 1) as [m1 b] eqn:?.
erewrite Mem.nextblock_drop; eauto. erewrite Mem.nextblock_alloc; eauto.
(* variable *)
set (init := gvar_init v) in *.
set (sz := init_data_list_size init) in *.
- destruct (Mem.alloc m 0 sz) as [m1 b]_eqn.
- destruct (store_zeros m1 b 0 sz) as [m2|]_eqn; try discriminate.
- destruct (store_init_data_list m2 b 0 init) as [m3|]_eqn; try discriminate.
+ destruct (Mem.alloc m 0 sz) as [m1 b] eqn:?.
+ destruct (store_zeros m1 b 0 sz) as [m2|] eqn:?; try discriminate.
+ destruct (store_init_data_list m2 b 0 init) as [m3|] eqn:?; try discriminate.
erewrite Mem.nextblock_drop; eauto.
erewrite store_init_data_list_nextblock; eauto.
erewrite store_zeros_nextblock; eauto.
@@ -629,7 +629,7 @@ Proof.
induction gl.
simpl; intros. inv H; unfold block; omega.
simpl length; rewrite inj_S; simpl; intros.
- destruct (alloc_global m a) as [m1|]_eqn; try discriminate.
+ destruct (alloc_global m a) as [m1|] eqn:?; try discriminate.
erewrite IHgl; eauto. erewrite alloc_global_nextblock; eauto. unfold block; omega.
Qed.
@@ -672,7 +672,7 @@ Remark alloc_global_perm:
Proof.
intros. destruct idg as [id [f|v]]; simpl in H.
(* function *)
- destruct (Mem.alloc m 0 1) as [m1 b]_eqn.
+ destruct (Mem.alloc m 0 1) as [m1 b] eqn:?.
assert (b' <> b). apply Mem.valid_not_valid_diff with m; eauto with mem.
split; intros.
eapply Mem.perm_drop_3; eauto. eapply Mem.perm_alloc_1; eauto.
@@ -680,9 +680,9 @@ Proof.
(* variable *)
set (init := gvar_init v) in *.
set (sz := init_data_list_size init) in *.
- destruct (Mem.alloc m 0 sz) as [m1 b]_eqn.
- destruct (store_zeros m1 b 0 sz) as [m2|]_eqn; try discriminate.
- destruct (store_init_data_list m2 b 0 init) as [m3|]_eqn; try discriminate.
+ destruct (Mem.alloc m 0 sz) as [m1 b] eqn:?.
+ destruct (store_zeros m1 b 0 sz) as [m2|] eqn:?; try discriminate.
+ destruct (store_init_data_list m2 b 0 init) as [m3|] eqn:?; try discriminate.
assert (b' <> b). apply Mem.valid_not_valid_diff with m; eauto with mem.
split; intros.
eapply Mem.perm_drop_3; eauto.
@@ -703,7 +703,7 @@ Remark alloc_globals_perm:
Proof.
induction gl.
simpl; intros. inv H. tauto.
- simpl; intros. destruct (alloc_global m a) as [m1|]_eqn; try discriminate.
+ simpl; intros. destruct (alloc_global m a) as [m1|] eqn:?; try discriminate.
erewrite alloc_global_perm; eauto. eapply IHgl; eauto.
unfold Mem.valid_block in *. erewrite alloc_global_nextblock; eauto. omega.
Qed.
@@ -734,7 +734,7 @@ Remark store_init_data_list_outside:
Proof.
induction il; simpl.
intros; congruence.
- intros. destruct (store_init_data m b p a) as [m1|]_eqn; try congruence.
+ intros. destruct (store_init_data m b p a) as [m1|] eqn:?; try congruence.
transitivity (Mem.load chunk m1 b' q).
eapply IHil; eauto. generalize (init_data_size_pos a). intuition omega.
destruct a; simpl in Heqo;
@@ -784,7 +784,7 @@ Proof.
induction il; simpl.
auto.
- intros. destruct (store_init_data m b p a) as [m1|]_eqn; try congruence.
+ intros. destruct (store_init_data m b p a) as [m1|] eqn:?; try congruence.
exploit IHil; eauto. intro D.
destruct a; simpl in Heqo; intuition.
eapply (A Mint8unsigned (Vint i)); eauto.
@@ -804,7 +804,7 @@ Remark load_alloc_global:
Proof.
intros. destruct g as [f|v]; simpl in H.
(* function *)
- destruct (Mem.alloc m 0 1) as [m1 b']_eqn.
+ destruct (Mem.alloc m 0 1) as [m1 b'] eqn:?.
assert (b <> b'). apply Mem.valid_not_valid_diff with m; eauto with mem.
transitivity (Mem.load chunk m1 b p).
eapply Mem.load_drop; eauto.
@@ -812,9 +812,9 @@ Proof.
(* variable *)
set (init := gvar_init v) in *.
set (sz := init_data_list_size init) in *.
- destruct (Mem.alloc m 0 sz) as [m1 b']_eqn.
- destruct (store_zeros m1 b' 0 sz) as [m2|]_eqn; try discriminate.
- destruct (store_init_data_list m2 b' 0 init) as [m3|]_eqn; try discriminate.
+ destruct (Mem.alloc m 0 sz) as [m1 b'] eqn:?.
+ destruct (store_zeros m1 b' 0 sz) as [m2|] eqn:?; try discriminate.
+ destruct (store_init_data_list m2 b' 0 init) as [m3|] eqn:?; try discriminate.
assert (b <> b'). apply Mem.valid_not_valid_diff with m; eauto with mem.
transitivity (Mem.load chunk m3 b p).
eapply Mem.load_drop; eauto.
@@ -833,7 +833,7 @@ Remark load_alloc_globals:
Proof.
induction gl; simpl; intros.
congruence.
- destruct (alloc_global m a) as [m''|]_eqn; try discriminate.
+ destruct (alloc_global m a) as [m''|] eqn:?; try discriminate.
transitivity (Mem.load chunk m'' b p).
apply IHgl; auto. unfold Mem.valid_block in *.
erewrite alloc_global_nextblock; eauto. omega.
@@ -895,9 +895,9 @@ Proof.
inv H3. simpl in H0.
set (init := gvar_init gv) in *.
set (sz := init_data_list_size init) in *.
- destruct (Mem.alloc m 0 sz) as [m1 b']_eqn.
- destruct (store_zeros m1 b' 0 sz) as [m2|]_eqn; try discriminate.
- destruct (store_init_data_list m2 b' 0 init) as [m3|]_eqn; try discriminate.
+ destruct (Mem.alloc m 0 sz) as [m1 b'] eqn:?.
+ destruct (store_zeros m1 b' 0 sz) as [m2|] eqn:?; try discriminate.
+ destruct (store_init_data_list m2 b' 0 init) as [m3|] eqn:?; try discriminate.
exploit Mem.alloc_result; eauto. intro RES.
replace (genv_next ge0) with b' by congruence.
split. red; intros. eapply Mem.perm_drop_1; eauto.
@@ -928,7 +928,7 @@ Proof.
destruct (ZIndexed.eq b (genv_next ge0)).
(* same *)
inv H3. simpl in H0.
- destruct (Mem.alloc m 0 1) as [m1 b']_eqn.
+ destruct (Mem.alloc m 0 1) as [m1 b'] eqn:?.
exploit Mem.alloc_result; eauto. intro RES.
replace (genv_next ge0) with b' by congruence.
split. eapply Mem.perm_drop_1; eauto. omega.
@@ -964,7 +964,7 @@ Lemma alloc_globals_initialized:
Proof.
induction gl; simpl; intros.
inv H0; auto.
- destruct a as [id g]. destruct (alloc_global m (id, g)) as [m1|]_eqn; try discriminate.
+ destruct a as [id g]. destruct (alloc_global m (id, g)) as [m1|] eqn:?; try discriminate.
exploit alloc_global_initialized; eauto. intros [P [Q R]].
eapply IHgl; eauto.
Qed.
@@ -1099,16 +1099,16 @@ Lemma alloc_global_neutral:
Proof.
intros. destruct idg as [id [f|v]]; simpl in H.
(* function *)
- destruct (Mem.alloc m 0 1) as [m1 b]_eqn.
+ destruct (Mem.alloc m 0 1) as [m1 b] eqn:?.
assert (b < thr). rewrite (Mem.alloc_result _ _ _ _ _ Heqp). auto.
eapply Mem.drop_inject_neutral; eauto.
eapply Mem.alloc_inject_neutral; eauto.
(* variable *)
set (init := gvar_init v) in *.
set (sz := init_data_list_size init) in *.
- destruct (Mem.alloc m 0 sz) as [m1 b]_eqn.
- destruct (store_zeros m1 b 0 sz) as [m2|]_eqn; try discriminate.
- destruct (store_init_data_list ge m2 b 0 init) as [m3|]_eqn; try discriminate.
+ destruct (Mem.alloc m 0 sz) as [m1 b] eqn:?.
+ destruct (store_zeros m1 b 0 sz) as [m2|] eqn:?; try discriminate.
+ destruct (store_init_data_list ge m2 b 0 init) as [m3|] eqn:?; try discriminate.
assert (b < thr). rewrite (Mem.alloc_result _ _ _ _ _ Heqp). auto.
eapply Mem.drop_inject_neutral; eauto.
eapply store_init_data_list_neutral with (m := m2) (b := b); eauto.
@@ -1210,7 +1210,7 @@ Lemma alloc_global_augment:
Proof.
intros. destruct idg as [id [f|v]]; simpl in H.
(* function *)
- destruct (Mem.alloc m2 0 1) as [m3 b]_eqn.
+ destruct (Mem.alloc m2 0 1) as [m3 b] eqn:?.
assert (b >= thr). rewrite (Mem.alloc_result _ _ _ _ _ Heqp). auto.
eapply Mem.drop_outside_inject. 2: eauto.
eapply Mem.alloc_right_inject; eauto.
@@ -1219,9 +1219,9 @@ Proof.
(* variable *)
set (init := gvar_init v) in *.
set (sz := init_data_list_size init) in *.
- destruct (Mem.alloc m2 0 sz) as [m3 b]_eqn.
- destruct (store_zeros m3 b 0 sz) as [m4|]_eqn; try discriminate.
- destruct (store_init_data_list ge m4 b 0 init) as [m5|]_eqn; try discriminate.
+ destruct (Mem.alloc m2 0 sz) as [m3 b] eqn:?.
+ destruct (store_zeros m3 b 0 sz) as [m4|] eqn:?; try discriminate.
+ destruct (store_init_data_list ge m4 b 0 init) as [m5|] eqn:?; try discriminate.
assert (b >= thr). rewrite (Mem.alloc_result _ _ _ _ _ Heqp). auto.
eapply Mem.drop_outside_inject. 2: eauto.
eapply store_init_data_list_augment. 3: eauto. 2: eauto.
@@ -1497,7 +1497,7 @@ Proof.
assert (forall m', store_init_data (globalenv p) m b ofs a = Some m' ->
store_init_data (globalenv p') m b ofs a = Some m').
destruct a; simpl; auto. rewrite find_symbol_match. auto.
- simpl in H. destruct (find_symbol (globalenv p) i) as [b'|]_eqn; try discriminate.
+ simpl in H. destruct (find_symbol (globalenv p) i) as [b'|] eqn:?; try discriminate.
apply new_ids_fresh. congruence.
case_eq (store_init_data (globalenv p) m b ofs a); intros.
rewrite H1 in H.
@@ -1513,14 +1513,14 @@ Lemma alloc_globals_match:
Proof.
induction 1; simpl; intros.
auto.
- destruct (alloc_global (globalenv p) m a1) as [m1|]_eqn; try discriminate.
+ destruct (alloc_global (globalenv p) m a1) as [m1|] eqn:?; try discriminate.
assert (alloc_global (globalenv p') m b1 = Some m1).
inv H; simpl in *.
auto.
set (sz := init_data_list_size init) in *.
- destruct (Mem.alloc m 0 sz) as [m2 b]_eqn.
- destruct (store_zeros m2 b 0 sz) as [m3|]_eqn; try discriminate.
- destruct (store_init_data_list (globalenv p) m3 b 0 init) as [m4|]_eqn; try discriminate.
+ destruct (Mem.alloc m 0 sz) as [m2 b] eqn:?.
+ destruct (store_zeros m2 b 0 sz) as [m3|] eqn:?; try discriminate.
+ destruct (store_init_data_list (globalenv p) m3 b 0 init) as [m4|] eqn:?; try discriminate.
erewrite store_init_data_list_match; eauto.
rewrite H2. eauto.
Qed.
@@ -1718,7 +1718,7 @@ Hypothesis transf_OK:
Remark transf_augment_OK:
transform_partial_augment_program transf_fun transf_var nil p.(prog_main) p = OK p'.
Proof.
- rewrite <- transf_OK. apply symmetry. apply transform_partial_program2_augment.
+ rewrite <- transf_OK. symmetry. apply transform_partial_program2_augment.
Qed.
Theorem find_funct_ptr_transf_partial2:
diff --git a/common/Memory.v b/common/Memory.v
index 37f21d7..514e1e0 100644
--- a/common/Memory.v
+++ b/common/Memory.v
@@ -1023,7 +1023,7 @@ Proof.
decEq. rewrite store_mem_contents; simpl.
rewrite ZMap.gsspec. destruct (ZIndexed.eq b' b). subst b'.
destruct H. congruence.
- destruct (zle n 0).
+ destruct (zle n 0) as [z | n0].
rewrite (nat_of_Z_neg _ z). auto.
destruct H. omegaContradiction.
apply getN_setN_outside. rewrite encode_val_length. rewrite <- size_chunk_conv.
@@ -1108,7 +1108,7 @@ Proof.
assert (length mvl = sz).
generalize (encode_val_length chunk v). rewrite <- H1. rewrite SZ.
simpl; congruence.
- rewrite H4. rewrite size_chunk_conv in z0. omega.
+ rewrite H4. rewrite size_chunk_conv in *. omega.
contradiction.
(* 3. ofs > ofs':
@@ -1126,8 +1126,8 @@ Proof.
rewrite setN_outside. rewrite ZMap.gss. auto. omega.
assert (~memval_valid_first (c'#ofs)).
rewrite SZ' in PSHAPE. simpl in PSHAPE. inv PSHAPE.
- apply H4. apply getN_in. rewrite size_chunk_conv in z.
- rewrite SZ' in z. rewrite inj_S in z. omega.
+ apply H4. apply getN_in. rewrite size_chunk_conv in *.
+ rewrite SZ' in *. rewrite inj_S in *. omega.
contradiction.
Qed.
@@ -3632,18 +3632,18 @@ Lemma mem_inj_compose:
Proof.
intros. unfold compose_meminj. inv H; inv H0; constructor; intros.
(* perm *)
- destruct (f b1) as [[b' delta'] |]_eqn; try discriminate.
- destruct (f' b') as [[b'' delta''] |]_eqn; inv H.
+ destruct (f b1) as [[b' delta'] |] eqn:?; try discriminate.
+ destruct (f' b') as [[b'' delta''] |] eqn:?; inv H.
replace (ofs + (delta' + delta'')) with ((ofs + delta') + delta'') by omega.
eauto.
(* valid access *)
- destruct (f b1) as [[b' delta'] |]_eqn; try discriminate.
- destruct (f' b') as [[b'' delta''] |]_eqn; inv H.
+ destruct (f b1) as [[b' delta'] |] eqn:?; try discriminate.
+ destruct (f' b') as [[b'' delta''] |] eqn:?; inv H.
replace (ofs + (delta' + delta'')) with ((ofs + delta') + delta'') by omega.
eauto.
(* memval *)
- destruct (f b1) as [[b' delta'] |]_eqn; try discriminate.
- destruct (f' b') as [[b'' delta''] |]_eqn; inv H.
+ destruct (f b1) as [[b' delta'] |] eqn:?; try discriminate.
+ destruct (f' b') as [[b'' delta''] |] eqn:?; inv H.
replace (ofs + (delta' + delta'')) with ((ofs + delta') + delta'') by omega.
eapply memval_inject_compose; eauto.
Qed.
@@ -3661,15 +3661,15 @@ Proof.
intros. erewrite mi_freeblocks0; eauto.
(* mapped *)
intros.
- destruct (f b) as [[b1 delta1] |]_eqn; try discriminate.
- destruct (f' b1) as [[b2 delta2] |]_eqn; inv H.
+ destruct (f b) as [[b1 delta1] |] eqn:?; try discriminate.
+ destruct (f' b1) as [[b2 delta2] |] eqn:?; inv H.
eauto.
(* no overlap *)
red; intros.
- destruct (f b1) as [[b1x delta1x] |]_eqn; try discriminate.
- destruct (f' b1x) as [[b1y delta1y] |]_eqn; inv H0.
- destruct (f b2) as [[b2x delta2x] |]_eqn; try discriminate.
- destruct (f' b2x) as [[b2y delta2y] |]_eqn; inv H1.
+ destruct (f b1) as [[b1x delta1x] |] eqn:?; try discriminate.
+ destruct (f' b1x) as [[b1y delta1y] |] eqn:?; inv H0.
+ destruct (f b2) as [[b2x delta2x] |] eqn:?; try discriminate.
+ destruct (f' b2x) as [[b2y delta2y] |] eqn:?; inv H1.
exploit mi_no_overlap0; eauto. intros A.
destruct (eq_block b1x b2x).
subst b1x. destruct A. congruence.
@@ -3680,8 +3680,8 @@ Proof.
unfold block; omega.
(* representable *)
intros.
- destruct (f b) as [[b1 delta1] |]_eqn; try discriminate.
- destruct (f' b1) as [[b2 delta2] |]_eqn; inv H.
+ destruct (f b) as [[b1 delta1] |] eqn:?; try discriminate.
+ destruct (f' b1) as [[b2 delta2] |] eqn:?; inv H.
exploit mi_representable0; eauto. intros [A B].
set (ofs' := Int.repr (Int.unsigned ofs + delta1)).
assert (Int.unsigned ofs' = Int.unsigned ofs + delta1).
diff --git a/common/PrintAST.ml b/common/PrintAST.ml
index 53741d5..7f2ed3f 100644
--- a/common/PrintAST.ml
+++ b/common/PrintAST.ml
@@ -42,7 +42,7 @@ let name_of_external = function
| EF_malloc -> "malloc"
| EF_free -> "free"
| EF_memcpy(sz, al) ->
- sprintf "memcpy size %ld align %ld " (camlint_of_z sz) (camlint_of_z al)
+ sprintf "memcpy size %s align %s " (Z.to_string sz) (Z.to_string al)
| EF_annot(text, targs) -> sprintf "annot %S" (extern_atom text)
| EF_annot_val(text, targ) -> sprintf "annot_val %S" (extern_atom text)
| EF_inline_asm text -> sprintf "inline_asm %S" (extern_atom text)
diff --git a/common/Values.v b/common/Values.v
index 1c03789..177cd93 100644
--- a/common/Values.v
+++ b/common/Values.v
@@ -620,7 +620,7 @@ Theorem modu_divu:
modu x y = Some z -> exists v, divu x y = Some v /\ z = sub x (mul v y).
Proof.
intros. destruct x; destruct y; simpl in *; try discriminate.
- destruct (Int.eq i0 Int.zero) as []_eqn; inv H.
+ destruct (Int.eq i0 Int.zero) eqn:?; inv H.
exists (Vint (Int.divu i i0)); split; auto.
simpl. rewrite Int.modu_divu. auto.
generalize (Int.eq_spec i0 Int.zero). rewrite Heqb; auto.
@@ -731,7 +731,7 @@ Theorem shrx_carry:
add (shr x y) (shr_carry x y) = z.
Proof.
intros. destruct x; destruct y; simpl in H; inv H.
- destruct (Int.ltu i0 (Int.repr 31)) as []_eqn; inv H1.
+ destruct (Int.ltu i0 (Int.repr 31)) eqn:?; inv H1.
exploit Int.ltu_inv; eauto. change (Int.unsigned (Int.repr 31)) with 31. intros.
assert (Int.ltu i0 Int.iwordsize = true).
unfold Int.ltu. apply zlt_true. change (Int.unsigned Int.iwordsize) with 32. omega.
@@ -746,7 +746,7 @@ Theorem shrx_shr:
z = shr (if Int.lt p Int.zero then add x (Vint (Int.sub (Int.shl Int.one q) Int.one)) else x) (Vint q).
Proof.
intros. destruct x; destruct y; simpl in H; inv H.
- destruct (Int.ltu i0 (Int.repr 31)) as []_eqn; inv H1.
+ destruct (Int.ltu i0 (Int.repr 31)) eqn:?; inv H1.
exploit Int.ltu_inv; eauto. change (Int.unsigned (Int.repr 31)) with 31. intros.
assert (Int.ltu i0 Int.iwordsize = true).
unfold Int.ltu. apply zlt_true. change (Int.unsigned Int.iwordsize) with 32. omega.
@@ -1030,8 +1030,8 @@ Proof.
destruct v1; simpl in H2; try discriminate;
destruct v2; simpl in H2; try discriminate;
inv H0; inv H1; simpl; auto.
- destruct (valid_ptr b0 (Int.unsigned i)) as []_eqn; try discriminate.
- destruct (valid_ptr b1 (Int.unsigned i0)) as []_eqn; try discriminate.
+ destruct (valid_ptr b0 (Int.unsigned i)) eqn:?; try discriminate.
+ destruct (valid_ptr b1 (Int.unsigned i0)) eqn:?; try discriminate.
rewrite (H _ _ Heqb2). rewrite (H _ _ Heqb0). auto.
Qed.
diff --git a/driver/Compiler.v b/driver/Compiler.v
index ed27f38..9db7f42 100644
--- a/driver/Compiler.v
+++ b/driver/Compiler.v
@@ -217,18 +217,18 @@ Proof.
repeat rewrite compose_print_identity in H.
simpl in H.
set (p1 := Tailcall.transf_program p) in *.
- destruct (Inlining.transf_program p1) as [p11|]_eqn; simpl in H; try discriminate.
+ destruct (Inlining.transf_program p1) as [p11|] eqn:?; simpl in H; try discriminate.
set (p12 := Renumber.transf_program p11) in *.
set (p2 := Constprop.transf_program p12) in *.
set (p21 := Renumber.transf_program p2) in *.
- destruct (CSE.transf_program p21) as [p3|]_eqn; simpl in H; try discriminate.
- destruct (Allocation.transf_program p3) as [p4|]_eqn; simpl in H; try discriminate.
+ destruct (CSE.transf_program p21) as [p3|] eqn:?; simpl in H; try discriminate.
+ destruct (Allocation.transf_program p3) as [p4|] eqn:?; simpl in H; try discriminate.
set (p5 := Tunneling.tunnel_program p4) in *.
- destruct (Linearize.transf_program p5) as [p6|]_eqn; simpl in H; try discriminate.
+ destruct (Linearize.transf_program p5) as [p6|] eqn:?; simpl in H; try discriminate.
set (p7 := CleanupLabels.transf_program p6) in *.
set (p8 := Reload.transf_program p7) in *.
set (p9 := RRE.transf_program p8) in *.
- destruct (Stacking.transf_program p9) as [p10|]_eqn; simpl in H; try discriminate.
+ destruct (Stacking.transf_program p9) as [p10|] eqn:?; simpl in H; try discriminate.
assert(TY1: LTLtyping.wt_program p5).
eapply Tunnelingtyping.program_typing_preserved.
@@ -274,7 +274,7 @@ Proof.
repeat rewrite compose_print_identity in H.
simpl in H.
set (p1 := Selection.sel_program p) in *.
- destruct (RTLgen.transl_program p1) as [p2|]_eqn; simpl in H; try discriminate.
+ destruct (RTLgen.transl_program p1) as [p2|] eqn:?; simpl in H; try discriminate.
eapply compose_forward_simulation. apply Selectionproof.transf_program_correct.
eapply compose_forward_simulation. apply RTLgenproof.transf_program_correct. eassumption.
exact (fst (transf_rtl_program_correct _ _ H)).
diff --git a/driver/Driver.ml b/driver/Driver.ml
index 85f6079..6c00cb7 100644
--- a/driver/Driver.ml
+++ b/driver/Driver.ml
@@ -11,6 +11,7 @@
(* *********************************************************************)
open Printf
+open Camlcoq
open Clflags
(* Location of the compatibility library *)
@@ -37,9 +38,9 @@ let safe_remove file =
let print_error oc msg =
let print_one_error = function
- | Errors.MSG s -> output_string oc (Camlcoq.camlstring_of_coqstring s)
- | Errors.CTX i -> output_string oc (Camlcoq.extern_atom i)
- | Errors.POS i -> fprintf oc "%ld" (Camlcoq.camlint_of_positive i)
+ | Errors.MSG s -> output_string oc (camlstring_of_coqstring s)
+ | Errors.CTX i -> output_string oc (extern_atom i)
+ | Errors.POS i -> fprintf oc "%ld" (P.to_int32 i)
in
List.iter print_one_error msg;
output_char oc '\n'
diff --git a/driver/Interp.ml b/driver/Interp.ml
index f3d75ea..9ea9d0c 100644
--- a/driver/Interp.ml
+++ b/driver/Interp.ml
@@ -17,8 +17,6 @@ type caml_float = float
open Format
open Camlcoq
open Datatypes
-open BinPos
-open BinInt
open AST
open Integers
open Floats
@@ -148,7 +146,7 @@ let compare_mem m1 m2 = (* should permissions be taken into account? *)
(* Comparing continuations *)
-let some_expr = Evar(Coq_xH, Tvoid)
+let some_expr = Evar(P.one, Tvoid)
let rank_cont = function
| Kstop -> 0
@@ -258,7 +256,7 @@ let extract_string ge m id ofs =
Some(Buffer.contents b)
end else begin
Buffer.add_char b c;
- extract blk (coq_Zsucc ofs)
+ extract blk (Z.succ ofs)
end
| _ ->
None in
diff --git a/extraction/extraction.v b/extraction/extraction.v
index 26cdb6d..89c708b 100644
--- a/extraction/extraction.v
+++ b/extraction/extraction.v
@@ -99,6 +99,15 @@ Extract Inlined Constant Fappli_IEEE.B2R => "fun _ -> assert false".
Extract Inlined Constant Fappli_IEEE.round_mode => "fun _ -> assert false".
Extract Inlined Constant Fcalc_bracket.inbetween_loc => "fun _ -> assert false".
+(* Needed in Coq 4.00 to avoid problems with Function definitions. *)
+Set Extraction AccessOpaque.
+
(* Go! *)
Cd "extraction".
-Recursive Extraction Library Compiler.
+(* Recursive Extraction Library Compiler. *)
+Separate Extraction
+ Compiler.transf_c_program Compiler.transf_cminor_program
+ Cexec.do_initial_state Cexec.do_step Cexec.at_final_state
+ Initializers.transl_init Initializers.constval
+ Csyntax.Eindex Csyntax.Epreincr.
+
diff --git a/ia32/Asmgenproof.v b/ia32/Asmgenproof.v
index 3d0c57f..d618d44 100644
--- a/ia32/Asmgenproof.v
+++ b/ia32/Asmgenproof.v
@@ -1122,7 +1122,8 @@ Proof.
intros. simpl in H2.
destruct (transl_cond_correct tge tf cond args _ _ rs m' H2)
as [rs' [A [B C]]].
- unfold PregEq.t in B; rewrite EC in B.
+ rewrite EC in B (* 8.4 *)
+ || (unfold PregEq.t in B; rewrite EC in B) (* 8.3 *).
destruct (testcond_for_condition cond); simpl in *.
(* simple jcc *)
exists (Pjcc c1 lbl); exists k; exists rs'.
@@ -1130,8 +1131,8 @@ Proof.
split. eapply agree_exten_temps; eauto.
simpl. rewrite B. auto.
(* jcc; jcc *)
- destruct (eval_testcond c1 rs') as [b1|]_eqn;
- destruct (eval_testcond c2 rs') as [b2|]_eqn; inv B.
+ destruct (eval_testcond c1 rs') as [b1|] eqn:?;
+ destruct (eval_testcond c2 rs') as [b2|] eqn:?; inv B.
destruct b1.
(* first jcc jumps *)
exists (Pjcc c1 lbl); exists (Pjcc c2 lbl :: k); exists rs'.
@@ -1147,8 +1148,8 @@ Proof.
simpl. rewrite eval_testcond_nextinstr. rewrite Heqo0.
destruct b2; auto || discriminate.
(* jcc2 *)
- destruct (eval_testcond c1 rs') as [b1|]_eqn;
- destruct (eval_testcond c2 rs') as [b2|]_eqn; inv B.
+ destruct (eval_testcond c1 rs') as [b1|] eqn:?;
+ destruct (eval_testcond c2 rs') as [b2|] eqn:?; inv B.
destruct (andb_prop _ _ H4). subst.
exists (Pjcc2 c1 c2 lbl); exists k; exists rs'.
split. eexact A.
@@ -1169,7 +1170,8 @@ Proof.
left; eapply exec_straight_steps; eauto. intros. simpl in H0.
destruct (transl_cond_correct tge tf cond args _ _ rs m' H0)
as [rs' [A [B C]]].
- unfold PregEq.t in B; rewrite EC in B.
+ rewrite EC in B (* 8.4 *)
+ || (unfold PregEq.t in B; rewrite EC in B) (* 8.3 *).
destruct (testcond_for_condition cond); simpl in *.
(* simple jcc *)
econstructor; split.
@@ -1178,8 +1180,8 @@ Proof.
split. apply agree_nextinstr. eapply agree_exten_temps; eauto.
simpl; congruence.
(* jcc ; jcc *)
- destruct (eval_testcond c1 rs') as [b1|]_eqn;
- destruct (eval_testcond c2 rs') as [b2|]_eqn; inv B.
+ destruct (eval_testcond c1 rs') as [b1|] eqn:?;
+ destruct (eval_testcond c2 rs') as [b2|] eqn:?; inv B.
destruct (orb_false_elim _ _ H2); subst.
econstructor; split.
eapply exec_straight_trans. eexact A.
@@ -1188,8 +1190,8 @@ Proof.
split. apply agree_nextinstr. apply agree_nextinstr. eapply agree_exten_temps; eauto.
simpl; congruence.
(* jcc2 *)
- destruct (eval_testcond c1 rs') as [b1|]_eqn;
- destruct (eval_testcond c2 rs') as [b2|]_eqn; inv B.
+ destruct (eval_testcond c1 rs') as [b1|] eqn:?;
+ destruct (eval_testcond c2 rs') as [b2|] eqn:?; inv B.
exists (nextinstr rs'); split.
eapply exec_straight_trans. eexact A.
apply exec_straight_one. simpl.
diff --git a/ia32/Asmgenproof1.v b/ia32/Asmgenproof1.v
index 0a46677..7a4348b 100644
--- a/ia32/Asmgenproof1.v
+++ b/ia32/Asmgenproof1.v
@@ -1099,12 +1099,12 @@ Proof.
rewrite (int_ltu_not i i0). destruct (Int.ltu i i0); destruct (Int.eq i i0); reflexivity.
destruct (Int.ltu i i0); reflexivity.
(* int ptr *)
- destruct (Int.eq i Int.zero) as []_eqn; try discriminate.
+ destruct (Int.eq i Int.zero) eqn:?; try discriminate.
destruct c; simpl in *; inv H1.
rewrite Heqb1; reflexivity.
rewrite Heqb1; reflexivity.
(* ptr int *)
- destruct (Int.eq i0 Int.zero) as []_eqn; try discriminate.
+ destruct (Int.eq i0 Int.zero) eqn:?; try discriminate.
destruct c; simpl in *; inv H1.
rewrite Heqb1; reflexivity.
rewrite Heqb1; reflexivity.
@@ -1396,13 +1396,13 @@ Proof.
(* comp *)
simpl. rewrite (ireg_of_eq _ _ EQ). rewrite (ireg_of_eq _ _ EQ1).
econstructor. split. apply exec_straight_one. simpl. eauto. auto.
- split. destruct (Val.cmp_bool c0 (rs x) (rs x0)) as []_eqn; auto.
+ split. destruct (Val.cmp_bool c0 (rs x) (rs x0)) eqn:?; auto.
eapply testcond_for_signed_comparison_correct; eauto.
intros. unfold compare_ints. repeat SOther.
(* compu *)
simpl. rewrite (ireg_of_eq _ _ EQ). rewrite (ireg_of_eq _ _ EQ1).
econstructor. split. apply exec_straight_one. simpl. eauto. auto.
- split. destruct (Val.cmpu_bool (Mem.valid_pointer m) c0 (rs x) (rs x0)) as []_eqn; auto.
+ split. destruct (Val.cmpu_bool (Mem.valid_pointer m) c0 (rs x) (rs x0)) eqn:?; auto.
eapply testcond_for_unsigned_comparison_correct; eauto.
intros. unfold compare_ints. repeat SOther.
(* compimm *)
@@ -1412,13 +1412,13 @@ Proof.
eapply testcond_for_signed_comparison_correct; eauto.
intros. unfold compare_ints. repeat SOther.
econstructor; split. apply exec_straight_one. simpl; eauto. auto.
- split. destruct (Val.cmp_bool c0 (rs x) (Vint i)) as []_eqn; auto.
+ split. destruct (Val.cmp_bool c0 (rs x) (Vint i)) eqn:?; auto.
eapply testcond_for_signed_comparison_correct; eauto.
intros. unfold compare_ints. repeat SOther.
(* compuimm *)
simpl. rewrite (ireg_of_eq _ _ EQ).
econstructor. split. apply exec_straight_one. simpl. eauto. auto.
- split. destruct (Val.cmpu_bool (Mem.valid_pointer m) c0 (rs x) (Vint i)) as []_eqn; auto.
+ split. destruct (Val.cmpu_bool (Mem.valid_pointer m) c0 (rs x) (Vint i)) eqn:?; auto.
eapply testcond_for_unsigned_comparison_correct; eauto.
intros. unfold compare_ints. repeat SOther.
(* compf *)
@@ -1613,22 +1613,22 @@ Proof.
(* div *)
apply SAME.
specialize (divs_mods_exist (rs x0) (rs x1)). rewrite H0.
- destruct (Val.mods (rs x0) (rs x1)) as [vr|]_eqn; intros; try contradiction.
+ destruct (Val.mods (rs x0) (rs x1)) as [vr|] eqn:?; intros; try contradiction.
eapply mk_div_correct with (dsem := Val.divs) (msem := Val.mods); eauto.
(* divu *)
apply SAME.
specialize (divu_modu_exist (rs x0) (rs x1)). rewrite H0.
- destruct (Val.modu (rs x0) (rs x1)) as [vr|]_eqn; intros; try contradiction.
+ destruct (Val.modu (rs x0) (rs x1)) as [vr|] eqn:?; intros; try contradiction.
eapply mk_div_correct with (dsem := Val.divu) (msem := Val.modu); eauto.
(* mod *)
apply SAME.
specialize (divs_mods_exist (rs x0) (rs x1)). rewrite H0.
- destruct (Val.divs (rs x0) (rs x1)) as [vq|]_eqn; intros; try contradiction.
+ destruct (Val.divs (rs x0) (rs x1)) as [vq|] eqn:?; intros; try contradiction.
eapply mk_mod_correct with (dsem := Val.divs) (msem := Val.mods); eauto.
(* modu *)
apply SAME.
specialize (divu_modu_exist (rs x0) (rs x1)). rewrite H0.
- destruct (Val.divu (rs x0) (rs x1)) as [vq|]_eqn; intros; try contradiction.
+ destruct (Val.divu (rs x0) (rs x1)) as [vq|] eqn:?; intros; try contradiction.
eapply mk_mod_correct with (dsem := Val.divu) (msem := Val.modu); eauto.
(* shl *)
apply SAME. eapply mk_shift_correct; eauto.
diff --git a/ia32/ConstpropOpproof.v b/ia32/ConstpropOpproof.v
index 1a0508c..9003743 100644
--- a/ia32/ConstpropOpproof.v
+++ b/ia32/ConstpropOpproof.v
@@ -158,10 +158,10 @@ Proof.
destruct (Int.ltu n Int.iwordsize); simpl; auto.
eapply eval_static_addressing_correct; eauto.
unfold eval_static_intoffloat.
- destruct (Float.intoffloat n1) as []_eqn; simpl in H0; inv H0.
+ destruct (Float.intoffloat n1) eqn:?; simpl in H0; inv H0.
simpl; auto.
destruct (propagate_float_constants tt); simpl; auto.
- unfold eval_static_condition_val. destruct (eval_static_condition c vl0) as [b|]_eqn.
+ unfold eval_static_condition_val. destruct (eval_static_condition c vl0) as [b|] eqn:?.
rewrite (eval_static_condition_correct _ _ _ m _ H Heqo).
destruct b; simpl; auto.
simpl; auto.
@@ -290,7 +290,7 @@ Proof.
exists (Vint Int.zero); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.mul_zero; auto.
predSpec Int.eq Int.eq_spec n Int.one; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.mul_one; auto.
- destruct (Int.is_power2 n) as []_eqn; intros.
+ destruct (Int.is_power2 n) eqn:?; intros.
rewrite (Val.mul_pow2 rs#r1 _ _ Heqo). apply make_shlimm_correct; auto.
econstructor; split; eauto. auto.
Qed.
@@ -303,8 +303,8 @@ Lemma make_divimm_correct:
exists w, eval_operation ge sp op rs##args m = Some w /\ Val.lessdef v w.
Proof.
intros; unfold make_divimm.
- destruct (Int.is_power2 n) as []_eqn.
- destruct (Int.ltu i (Int.repr 31)) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
+ destruct (Int.ltu i (Int.repr 31)) eqn:?.
exists v; split; auto. simpl. eapply Val.divs_pow2; eauto. congruence.
exists v; auto.
exists v; auto.
@@ -318,7 +318,7 @@ Lemma make_divuimm_correct:
exists w, eval_operation ge sp op rs##args m = Some w /\ Val.lessdef v w.
Proof.
intros; unfold make_divuimm.
- destruct (Int.is_power2 n) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
replace v with (Val.shru rs#r1 (Vint i)).
eapply make_shruimm_correct; eauto.
eapply Val.divu_pow2; eauto. congruence.
@@ -333,7 +333,7 @@ Lemma make_moduimm_correct:
exists w, eval_operation ge sp op rs##args m = Some w /\ Val.lessdef v w.
Proof.
intros; unfold make_moduimm.
- destruct (Int.is_power2 n) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
exists v; split; auto. simpl. decEq. eapply Val.modu_pow2; eauto. congruence.
exists v; auto.
Qed.
@@ -430,10 +430,10 @@ Lemma builtin_strength_reduction_correct:
Proof.
intros until m'. unfold builtin_strength_reduction.
destruct (builtin_strength_reduction_match ef args vl); simpl; intros; InvApproxRegs; SimplVMA.
- unfold symbol_address in H. destruct (Genv.find_symbol ge symb) as [b|]_eqn; rewrite H in H0.
+ unfold symbol_address in H. destruct (Genv.find_symbol ge symb) as [b|] eqn:?; rewrite H in H0.
rewrite volatile_load_global_charact. exists b; auto.
inv H0.
- unfold symbol_address in H1. destruct (Genv.find_symbol ge symb) as [b|]_eqn; rewrite H1 in H0.
+ unfold symbol_address in H1. destruct (Genv.find_symbol ge symb) as [b|] eqn:?; rewrite H1 in H0.
rewrite volatile_store_global_charact. exists b; auto.
inv H0.
auto.
diff --git a/ia32/Op.v b/ia32/Op.v
index 8169594..93a867a 100644
--- a/ia32/Op.v
+++ b/ia32/Op.v
@@ -642,8 +642,8 @@ Proof.
right. apply Int.no_overlap_sound; auto.
(* Aglobal *)
unfold symbol_address in *.
- destruct (Genv.find_symbol ge i1) as []_eqn; inv H2.
- destruct (Genv.find_symbol ge i) as []_eqn; inv H1.
+ destruct (Genv.find_symbol ge i1) eqn:?; inv H2.
+ destruct (Genv.find_symbol ge i) eqn:?; inv H1.
destruct (ident_eq i i1). subst.
replace (Int.unsigned n1) with (Int.unsigned (Int.add Int.zero n1)).
replace (Int.unsigned n2) with (Int.unsigned (Int.add Int.zero n2)).
@@ -653,9 +653,9 @@ Proof.
left. red; intros; elim n. subst. eapply Genv.genv_vars_inj; eauto.
(* Abased *)
unfold symbol_address in *.
- destruct (Genv.find_symbol ge i1) as []_eqn; simpl in *; try discriminate.
+ destruct (Genv.find_symbol ge i1) eqn:?; simpl in *; try discriminate.
destruct v; inv H2.
- destruct (Genv.find_symbol ge i) as []_eqn; inv H1.
+ destruct (Genv.find_symbol ge i) eqn:?; inv H1.
destruct (ident_eq i i1). subst.
rewrite (Int.add_commut i0 i3). rewrite (Int.add_commut i2 i3).
right. apply Int.no_overlap_sound; auto.
@@ -776,8 +776,8 @@ Opaque Int.add.
Val.cmpu_bool (Mem.valid_pointer m1) c v1 v2 = Some b ->
Val.cmpu_bool (Mem.valid_pointer m2) c v1' v2' = Some b).
intros. inv H; simpl in H1; try discriminate; inv H0; simpl in H1; try discriminate; simpl; auto.
- destruct (Mem.valid_pointer m1 b1 (Int.unsigned ofs1)) as []_eqn; try discriminate.
- destruct (Mem.valid_pointer m1 b0 (Int.unsigned ofs0)) as []_eqn; try discriminate.
+ destruct (Mem.valid_pointer m1 b1 (Int.unsigned ofs1)) eqn:?; try discriminate.
+ destruct (Mem.valid_pointer m1 b0 (Int.unsigned ofs0)) eqn:?; try discriminate.
rewrite (valid_pointer_inj _ H2 Heqb4).
rewrite (valid_pointer_inj _ H Heqb0). simpl.
destruct (zeq b1 b0); simpl in H1.
@@ -878,7 +878,7 @@ Proof.
inv H4; simpl in H1; inv H1. simpl. destruct (Float.intoffloat f0); simpl in H2; inv H2.
exists (Vint i); auto.
inv H4; simpl in H1; inv H1. simpl. TrivialExists.
- subst v1. destruct (eval_condition c vl1 m1) as []_eqn.
+ subst v1. destruct (eval_condition c vl1 m1) eqn:?.
exploit eval_condition_inj; eauto. intros EQ; rewrite EQ.
destruct b; simpl; constructor.
simpl; constructor.
@@ -995,7 +995,7 @@ Hypothesis sp_inj: f sp1 = Some(sp2, delta).
Remark symbol_address_inject:
forall id ofs, val_inject f (symbol_address genv id ofs) (symbol_address genv id ofs).
Proof.
- intros. unfold symbol_address. destruct (Genv.find_symbol genv id) as []_eqn; auto.
+ intros. unfold symbol_address. destruct (Genv.find_symbol genv id) eqn:?; auto.
exploit (proj1 globals); eauto. intros.
econstructor; eauto. rewrite Int.add_zero; auto.
Qed.
diff --git a/ia32/PrintAsm.ml b/ia32/PrintAsm.ml
index da08de8..601869b 100644
--- a/ia32/PrintAsm.ml
+++ b/ia32/PrintAsm.ml
@@ -787,7 +787,7 @@ let print_init oc = function
(camlint64_of_coqint (Floats.Float.bits_of_double n))
comment (camlfloat_of_coqfloat n)
| Init_space n ->
- let n = camlint_of_z n in
+ let n = Z.to_int32 n in
if n > 0l then fprintf oc " .space %ld\n" n
| Init_addrof(symb, ofs) ->
fprintf oc " .long %a\n"
diff --git a/ia32/SelectOpproof.v b/ia32/SelectOpproof.v
index 136a765..18deca6 100644
--- a/ia32/SelectOpproof.v
+++ b/ia32/SelectOpproof.v
@@ -228,12 +228,12 @@ Proof.
destruct (shlimm_match a); intros; InvEval.
exists (Vint (Int.shl n1 n)); split. EvalOp.
simpl. destruct (Int.ltu n Int.iwordsize); auto.
- destruct (Int.ltu (Int.add n n1) Int.iwordsize) as []_eqn.
+ destruct (Int.ltu (Int.add n n1) Int.iwordsize) eqn:?.
exists (Val.shl v1 (Vint (Int.add n n1))); split. EvalOp.
subst. destruct v1; simpl; auto.
rewrite Heqb.
- destruct (Int.ltu n1 Int.iwordsize) as []_eqn; simpl; auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; simpl; auto.
+ destruct (Int.ltu n1 Int.iwordsize) eqn:?; simpl; auto.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; simpl; auto.
rewrite Int.add_commut. rewrite Int.shl_shl; auto. rewrite Int.add_commut; auto.
subst. TrivialExists. econstructor. EvalOp. simpl; eauto. constructor.
simpl. auto.
@@ -259,12 +259,12 @@ Proof.
destruct (shruimm_match a); intros; InvEval.
exists (Vint (Int.shru n1 n)); split. EvalOp.
simpl. destruct (Int.ltu n Int.iwordsize); auto.
- destruct (Int.ltu (Int.add n n1) Int.iwordsize) as []_eqn.
+ destruct (Int.ltu (Int.add n n1) Int.iwordsize) eqn:?.
exists (Val.shru v1 (Vint (Int.add n n1))); split. EvalOp.
subst. destruct v1; simpl; auto.
rewrite Heqb.
- destruct (Int.ltu n1 Int.iwordsize) as []_eqn; simpl; auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; simpl; auto.
+ destruct (Int.ltu n1 Int.iwordsize) eqn:?; simpl; auto.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; simpl; auto.
rewrite Int.add_commut. rewrite Int.shru_shru; auto. rewrite Int.add_commut; auto.
subst. TrivialExists. econstructor. EvalOp. simpl; eauto. constructor.
simpl. auto.
@@ -281,12 +281,12 @@ Proof.
destruct (shrimm_match a); intros; InvEval.
exists (Vint (Int.shr n1 n)); split. EvalOp.
simpl. destruct (Int.ltu n Int.iwordsize); auto.
- destruct (Int.ltu (Int.add n n1) Int.iwordsize) as []_eqn.
+ destruct (Int.ltu (Int.add n n1) Int.iwordsize) eqn:?.
exists (Val.shr v1 (Vint (Int.add n n1))); split. EvalOp.
subst. destruct v1; simpl; auto.
rewrite Heqb.
- destruct (Int.ltu n1 Int.iwordsize) as []_eqn; simpl; auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; simpl; auto.
+ destruct (Int.ltu n1 Int.iwordsize) eqn:?; simpl; auto.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; simpl; auto.
rewrite Int.add_commut. rewrite Int.shr_shr; auto. rewrite Int.add_commut; auto.
subst. TrivialExists. econstructor. EvalOp. simpl; eauto. constructor.
simpl. auto.
@@ -417,25 +417,25 @@ Proof.
InvEval. rewrite Val.or_commut. apply eval_orimm; auto.
InvEval. apply eval_orimm; auto.
(* shlimm - shruimm *)
- destruct (Int.eq (Int.add n1 n2) Int.iwordsize && same_expr_pure t1 t2) as []_eqn.
+ destruct (Int.eq (Int.add n1 n2) Int.iwordsize && same_expr_pure t1 t2) eqn:?.
destruct (andb_prop _ _ Heqb0).
generalize (Int.eq_spec (Int.add n1 n2) Int.iwordsize); rewrite H1; intros EQ.
InvEval. exploit eval_same_expr; eauto. intros [EQ1 EQ2]; subst.
exists (Val.ror v0 (Vint n2)); split. EvalOp.
destruct v0; simpl; auto.
- destruct (Int.ltu n1 Int.iwordsize) as []_eqn; auto.
- destruct (Int.ltu n2 Int.iwordsize) as []_eqn; auto.
+ destruct (Int.ltu n1 Int.iwordsize) eqn:?; auto.
+ destruct (Int.ltu n2 Int.iwordsize) eqn:?; auto.
simpl. rewrite <- Int.or_ror; auto.
TrivialExists.
(* shruimm - shlimm *)
- destruct (Int.eq (Int.add n1 n2) Int.iwordsize && same_expr_pure t1 t2) as []_eqn.
+ destruct (Int.eq (Int.add n1 n2) Int.iwordsize && same_expr_pure t1 t2) eqn:?.
destruct (andb_prop _ _ Heqb0).
generalize (Int.eq_spec (Int.add n1 n2) Int.iwordsize); rewrite H1; intros EQ.
InvEval. exploit eval_same_expr; eauto. intros [EQ1 EQ2]; subst.
exists (Val.ror v1 (Vint n2)); split. EvalOp.
destruct v1; simpl; auto.
- destruct (Int.ltu n2 Int.iwordsize) as []_eqn; auto.
- destruct (Int.ltu n1 Int.iwordsize) as []_eqn; auto.
+ destruct (Int.ltu n2 Int.iwordsize) eqn:?; auto.
+ destruct (Int.ltu n1 Int.iwordsize) eqn:?; auto.
simpl. rewrite Int.or_commut. rewrite <- Int.or_ror; auto.
TrivialExists.
(* default *)
@@ -717,7 +717,7 @@ Theorem eval_intuoffloat:
exists v, eval_expr ge sp e m le (intuoffloat a) v /\ Val.lessdef y v.
Proof.
intros. destruct x; simpl in H0; try discriminate.
- destruct (Float.intuoffloat f) as [n|]_eqn; simpl in H0; inv H0.
+ destruct (Float.intuoffloat f) as [n|] eqn:?; simpl in H0; inv H0.
exists (Vint n); split; auto. unfold intuoffloat.
set (im := Int.repr Int.half_modulus).
set (fm := Float.floatofintu im).
@@ -729,7 +729,7 @@ Proof.
econstructor. instantiate (1 := Vfloat fm). EvalOp.
eapply eval_Econdition with (vb := Float.cmp Clt f fm).
eauto with evalexpr. auto.
- destruct (Float.cmp Clt f fm) as []_eqn.
+ destruct (Float.cmp Clt f fm) eqn:?.
exploit Float.intuoffloat_intoffloat_1; eauto. intro EQ.
EvalOp. simpl. rewrite EQ; auto.
exploit Float.intuoffloat_intoffloat_2; eauto.
@@ -763,7 +763,7 @@ Proof.
eapply eval_Econdition with (vb := Int.ltu i Float.ox8000_0000).
constructor. eauto. constructor.
simpl. auto.
- destruct (Int.ltu i Float.ox8000_0000) as []_eqn.
+ destruct (Int.ltu i Float.ox8000_0000) eqn:?.
rewrite Float.floatofintu_floatofint_1; auto.
unfold floatofint. EvalOp.
exploit (eval_addimm (Int.neg Float.ox8000_0000) (Vint i :: le) (Eletvar 0)); eauto.
diff --git a/lib/Camlcoq.ml b/lib/Camlcoq.ml
index 00c2103..442766d 100644
--- a/lib/Camlcoq.ml
+++ b/lib/Camlcoq.ml
@@ -16,75 +16,206 @@
(* Library of useful Caml <-> Coq conversions *)
open Datatypes
-open BinPos
+open BinNums
open BinInt
+open BinPos
open Floats
-(* Integers *)
+(* Coq's [nat] type and some of its operations *)
-let rec camlint_of_positive = function
- | Coq_xI p -> Int32.add (Int32.shift_left (camlint_of_positive p) 1) 1l
- | Coq_xO p -> Int32.shift_left (camlint_of_positive p) 1
- | Coq_xH -> 1l
+module Nat = struct
-let camlint_of_z = function
- | Z0 -> 0l
- | Zpos p -> camlint_of_positive p
- | Zneg p -> Int32.neg (camlint_of_positive p)
+ type t = nat = O | S of t
+
+ let rec to_int = function
+ | O -> 0
+ | S n -> succ (to_int n)
+
+ let rec to_int32 = function
+ | O -> 0l
+ | S n -> Int32.succ(to_int32 n)
+
+ let rec of_int n =
+ assert (n >= 0);
+ if n = 0 then O else S (of_int (pred n))
+
+ let rec of_int32 n =
+ assert (n >= 0l);
+ if n = 0l then O else S (of_int32 (Int32.pred n))
+
+end
+
+
+(* Coq's [positive] type and some of its operations *)
-let camlint_of_coqint : Integers.Int.int -> int32 = camlint_of_z
+module P = struct
-let rec camlint64_of_positive = function
- | Coq_xI p -> Int64.add (Int64.shift_left (camlint64_of_positive p) 1) 1L
- | Coq_xO p -> Int64.shift_left (camlint64_of_positive p) 1
+ type t = positive = Coq_xI of t | Coq_xO of t | Coq_xH
+
+ let one = Coq_xH
+ let succ = Pos.succ
+ let pred = Pos.pred
+ let add = Pos.add
+ let sub = Pos.sub
+ let eq x y = (Pos.compare x y = Eq)
+ let lt x y = (Pos.compare x y = Lt)
+ let gt x y = (Pos.compare x y = Gt)
+ let le x y = (Pos.compare x y <> Gt)
+ let ge x y = (Pos.compare x y <> Lt)
+
+ let rec to_int = function
+ | Coq_xI p -> (to_int p lsl 1) + 1
+ | Coq_xO p -> to_int p lsl 1
+ | Coq_xH -> 1
+
+ let rec of_int n =
+ if n = 0 then assert false else
+ if n = 1 then Coq_xH else
+ if n land 1 = 0
+ then Coq_xO (of_int (n lsr 1))
+ else Coq_xI (of_int (n lsr 1))
+
+ let rec to_int32 = function
+ | Coq_xI p -> Int32.add (Int32.shift_left (to_int32 p) 1) 1l
+ | Coq_xO p -> Int32.shift_left (to_int32 p) 1
+ | Coq_xH -> 1l
+
+ let rec of_int32 n =
+ if n = 0l then assert false else
+ if n = 1l then Coq_xH else
+ if Int32.logand n 1l = 0l
+ then Coq_xO (of_int32 (Int32.shift_right_logical n 1))
+ else Coq_xI (of_int32 (Int32.shift_right_logical n 1))
+
+ let rec to_int64 = function
+ | Coq_xI p -> Int64.add (Int64.shift_left (to_int64 p) 1) 1L
+ | Coq_xO p -> Int64.shift_left (to_int64 p) 1
| Coq_xH -> 1L
-let camlint64_of_z = function
- | Z0 -> 0L
- | Zpos p -> camlint64_of_positive p
- | Zneg p -> Int64.neg (camlint64_of_positive p)
+ let rec of_int64 n =
+ if n = 0L then assert false else
+ if n = 1L then Coq_xH else
+ if Int64.logand n 1L = 0L
+ then Coq_xO (of_int64 (Int64.shift_right_logical n 1))
+ else Coq_xI (of_int64 (Int64.shift_right_logical n 1))
+
+ let (+) = add
+ let (-) = sub
+ let (=) = eq
+ let (<) = lt
+ let (<=) = le
+ let (>) = gt
+ let (>=) = ge
+
+end
+
+(* Coq's [Z] type and some of its operations *)
+
+module Z = struct
+
+ type t = coq_Z = Z0 | Zpos of positive | Zneg of positive
+
+ let zero = Z0
+ let one = Zpos Coq_xH
+ let mone = Zneg Coq_xH
+ let succ = Z.succ
+ let pred = Z.pred
+ let neg = Z.opp
+ let add = Z.add
+ let sub = Z.sub
+ let mul = Z.mul
+ let eq x y = (Z.compare x y = Eq)
+ let lt x y = (Z.compare x y = Lt)
+ let gt x y = (Z.compare x y = Gt)
+ let le x y = (Z.compare x y <> Gt)
+ let ge x y = (Z.compare x y <> Lt)
+
+ let to_int = function
+ | Z0 -> 0
+ | Zpos p -> P.to_int p
+ | Zneg p -> - (P.to_int p)
+
+ let of_sint n =
+ if n = 0 then Z0 else
+ if n > 0 then Zpos (P.of_int n)
+ else Zneg (P.of_int (-n))
+
+ let of_uint n =
+ if n = 0 then Z0 else Zpos (P.of_int n)
+
+ let to_int32 = function
+ | Z0 -> 0l
+ | Zpos p -> P.to_int32 p
+ | Zneg p -> Int32.neg (P.to_int32 p)
-let camlint64_of_coqint : Integers.Int64.int -> int64 = camlint64_of_z
+ let of_sint32 n =
+ if n = 0l then Z0 else
+ if n > 0l then Zpos (P.of_int32 n)
+ else Zneg (P.of_int32 (Int32.neg n))
-let rec camlint_of_nat = function
- | O -> 0
- | S n -> camlint_of_nat n + 1
-
-let rec nat_of_camlint n =
- assert (n >= 0l);
- if n = 0l then O else S (nat_of_camlint (Int32.sub n 1l))
-
-let rec positive_of_camlint n =
- if n = 0l then assert false else
- if n = 1l then Coq_xH else
- if Int32.logand n 1l = 0l
- then Coq_xO (positive_of_camlint (Int32.shift_right_logical n 1))
- else Coq_xI (positive_of_camlint (Int32.shift_right_logical n 1))
-
-let z_of_camlint n =
- if n = 0l then Z0 else
- if n > 0l then Zpos (positive_of_camlint n)
- else Zneg (positive_of_camlint (Int32.neg n))
-
-let coqint_of_camlint (n: int32) : Integers.Int.int =
- (* Interpret n as unsigned so that resulting Z is in range *)
- if n = 0l then Z0 else Zpos (positive_of_camlint n)
-
-let rec positive_of_camlint64 n =
- if n = 0L then assert false else
- if n = 1L then Coq_xH else
- if Int64.logand n 1L = 0L
- then Coq_xO (positive_of_camlint64 (Int64.shift_right_logical n 1))
- else Coq_xI (positive_of_camlint64 (Int64.shift_right_logical n 1))
-
-let z_of_camlint64 n =
- if n = 0L then Z0 else
- if n > 0L then Zpos (positive_of_camlint64 n)
- else Zneg (positive_of_camlint64 (Int64.neg n))
-
-let coqint_of_camlint64 (n: int64) : Integers.Int64.int =
- (* Interpret n as unsigned so that resulting Z is in range *)
- if n = 0L then Z0 else Zpos (positive_of_camlint64 n)
+ let of_uint32 n =
+ if n = 0l then Z0 else Zpos (P.of_int32 n)
+
+ let to_int64 = function
+ | Z0 -> 0L
+ | Zpos p -> P.to_int64 p
+ | Zneg p -> Int64.neg (P.to_int64 p)
+
+ let of_sint64 n =
+ if n = 0L then Z0 else
+ if n > 0L then Zpos (P.of_int64 n)
+ else Zneg (P.of_int64 (Int64.neg n))
+
+ let of_uint64 n =
+ if n = 0L then Z0 else Zpos (P.of_int64 n)
+
+ let rec to_string_rec base buff x =
+ if x = Z0 then () else begin
+ let (q, r) = Z.div_eucl x base in
+ to_string_rec base buff q;
+ let q' = to_int q in
+ Buffer.add_char buff (Char.chr
+ (if q' < 10 then Char.code '0' + q'
+ else Char.code 'A' + q' - 10))
+ end
+
+ let to_string_aux base x =
+ match x with
+ | Z0 -> "0"
+ | Zpos _ ->
+ let buff = Buffer.create 10 in
+ to_string_rec base buff x;
+ Buffer.contents buff
+ | Zneg p ->
+ let buff = Buffer.create 10 in
+ Buffer.add_char buff '-';
+ to_string_rec base buff (Zpos p);
+ Buffer.contents buff
+
+ let dec = to_string_aux (of_uint 10)
+
+ let hex = to_string_aux (of_uint 16)
+
+ let to_string = dec
+
+ let (+) = add
+ let (-) = sub
+ let ( * ) = mul
+ let (=) = eq
+ let (<) = lt
+ let (<=) = le
+ let (>) = gt
+ let (>=) = ge
+end
+
+(* Alternate names *)
+
+let camlint_of_coqint : Integers.Int.int -> int32 = Z.to_int32
+let coqint_of_camlint : int32 -> Integers.Int.int = Z.of_uint32
+ (* interpret the int32 as unsigned so that result Z is in range for int *)
+let camlint64_of_coqint : Integers.Int64.int -> int64 = Z.to_int64
+let coqint_of_camlint64 : int64 -> Integers.Int64.int = Z.of_uint64
+ (* interpret the int64 as unsigned so that result Z is in range for int *)
(* Atoms (positive integers representing strings) *)
@@ -97,7 +228,7 @@ let intern_string s =
Hashtbl.find atom_of_string s
with Not_found ->
let a = !next_atom in
- next_atom := coq_Psucc !next_atom;
+ next_atom := Pos.succ !next_atom;
Hashtbl.add atom_of_string s a;
Hashtbl.add string_of_atom a s;
a
@@ -106,7 +237,7 @@ let extern_atom a =
try
Hashtbl.find string_of_atom a
with Not_found ->
- Printf.sprintf "$%ld" (camlint_of_positive a)
+ Printf.sprintf "$%d" (P.to_int a)
let first_unused_ident () = !next_atom
diff --git a/lib/Coqlib.v b/lib/Coqlib.v
index 3d5df25..676aa0a 100644
--- a/lib/Coqlib.v
+++ b/lib/Coqlib.v
@@ -33,7 +33,7 @@ Ltac caseEq name :=
generalize (refl_equal name); pattern name at -1 in |- *; case name.
Ltac destructEq name :=
- destruct name as []_eqn.
+ destruct name eqn:?.
Ltac decEq :=
match goal with
@@ -393,7 +393,7 @@ Qed.
Lemma Zmin_spec:
forall x y, Zmin x y = if zlt x y then x else y.
Proof.
- intros. case (zlt x y); unfold Zlt, Zge; intros.
+ intros. case (zlt x y); unfold Zlt, Zge; intro z.
unfold Zmin. rewrite z. auto.
unfold Zmin. caseEq (x ?= y); intro.
apply Zcompare_Eq_eq. auto.
@@ -404,7 +404,7 @@ Qed.
Lemma Zmax_spec:
forall x y, Zmax x y = if zlt y x then x else y.
Proof.
- intros. case (zlt y x); unfold Zlt, Zge; intros.
+ intros. case (zlt y x); unfold Zlt, Zge; intro z.
unfold Zmax. rewrite <- (Zcompare_antisym y x).
rewrite z. simpl. auto.
unfold Zmax. rewrite <- (Zcompare_antisym y x).
@@ -565,7 +565,7 @@ Qed.
Lemma Zdivides_trans:
forall x y z, (x | y) -> (y | z) -> (x | z).
Proof.
- intros. inv H. inv H0. exists (q0 * q). ring.
+ intros x y z [a A] [b B]; subst. exists (a*b); ring.
Qed.
Definition Zdivide_dec:
diff --git a/lib/Floats.v b/lib/Floats.v
index aae2646..711fd61 100644
--- a/lib/Floats.v
+++ b/lib/Floats.v
@@ -362,7 +362,7 @@ Proof.
destruct c, x, y; simpl; try destruct b; try destruct b0; try reflexivity;
rewrite <- (Zcompare_antisym e e1); destruct (e ?= e1); try reflexivity;
change Eq with (CompOpp Eq); rewrite <- (Pcompare_antisym m m0 Eq);
- simpl; destruct ((m ?= m0)%positive Eq); try reflexivity.
+ simpl; destruct (Pcompare m m0 Eq); reflexivity.
Qed.
Theorem cmp_ne_eq:
@@ -524,6 +524,7 @@ Proof.
destruct (binary_normalize64_exact (Int.unsigned x)); [now smart_omega|].
match goal with [|- _ _ _ ?f = _] => destruct f end; intuition.
exfalso; simpl in H2; change 0%R with (Z2R 0) in H2; apply eq_Z2R in H2; omega.
+ try (change (53 ?= 1024) with Lt in H1). (* for Coq 8.4 *)
simpl Zcompare in *.
match goal with [|- _ _ _ ?f = _] => destruct f end; intuition.
exfalso; simpl in H0; change 0%R with (Z2R 0) in H0; apply eq_Z2R in H0; omega.
@@ -718,6 +719,8 @@ Proof.
rewrite (Ztrunc_floor (B2R _ _ x)), <- Zfloor_minus, <- Ztrunc_floor;
[f_equal; assumption|apply Rle_0_minus; left; assumption|].
left; eapply Rlt_trans; [|now apply H2]; apply (Z2R_lt 0); reflexivity.
+ try (change (0 ?= 53) with Lt in H6,H8). (* for Coq 8.4 *)
+ try (change (53 ?= 1024) with Lt in H6,H8). (* for Coq 8.4 *)
exfalso; simpl Zcompare in H6, H8; rewrite H6, H8 in H9.
destruct H9 as [|[]]; [discriminate|..].
eapply Rle_trans in H9; [|apply Rle_0_minus; left; assumption]; apply (le_Z2R 0) in H9; apply H9; reflexivity.
@@ -761,7 +764,7 @@ unfold Int64.or, Int64.bitwise_binop in H0.
rewrite Int64.unsigned_repr, Int64.bits_of_Z_of_bits in H0.
rewrite orb_false_intro in H0; [discriminate|reflexivity|].
rewrite Int64.sign_bit_of_Z.
-match goal with [|- ((if ?c then _ else _) = _)] => destruct c end.
+match goal with [|- ((if ?c then _ else _) = _)] => destruct c as [z0|z0] end.
reflexivity.
rewrite Int64.unsigned_repr in z0; [exfalso|]; now smart_omega.
vm_compute; split; congruence.
@@ -793,7 +796,7 @@ Proof.
intros; unfold from_words, double_of_bits, b64_of_bits, binary_float_of_bits.
rewrite B2R_FF2B; unfold is_finite; rewrite match_FF2B;
unfold binary_float_of_bits_aux; rewrite split_bits_or; simpl; pose proof (Int.unsigned_range x).
- destruct (Int.unsigned x + Zpower_pos 2 52) as []_eqn.
+ destruct (Int.unsigned x + Zpower_pos 2 52) eqn:?.
exfalso; now smart_omega.
simpl; rewrite <- Heqz; unfold F2R; simpl.
rewrite <- (Z2R_plus 4503599627370496), Rmult_1_r.
@@ -822,6 +825,7 @@ Proof.
rewrite round_exact in H3 by smart_omega.
match goal with [H3:if Rlt_bool ?x ?y then _ else _ |- _] =>
pose proof (Rlt_bool_spec x y); destruct (Rlt_bool x y) end; destruct H3.
+ try (change (53 ?= 1024) with Lt in H3,H5). (* for Coq 8.4 *)
simpl Zcompare in *; apply B2R_inj;
try match goal with [H':B2R _ _ ?f = _ , H'':is_finite _ _ ?f = true |- is_finite_strict _ _ ?f = true] =>
destruct f; [
@@ -869,6 +873,8 @@ Proof.
rewrite round_exact in H3 by smart_omega.
match goal with [H3:if Rlt_bool ?x ?y then _ else _ |- _] =>
pose proof (Rlt_bool_spec x y); destruct (Rlt_bool x y) end; destruct H3.
+ try (change (0 ?= 53) with Lt in H3,H5). (* for Coq 8.4 *)
+ try (change (53 ?= 1024) with Lt in H3,H5). (* for Coq 8.4 *)
simpl Zcompare in *; apply B2R_inj;
try match goal with [H':B2R _ _ ?f = _ , H'':is_finite _ _ ?f = true |- is_finite_strict _ _ ?f = true] =>
destruct f; [
diff --git a/lib/Integers.v b/lib/Integers.v
index 7d5f016..9844ed1 100644
--- a/lib/Integers.v
+++ b/lib/Integers.v
@@ -168,7 +168,7 @@ Lemma Z_mod_two_p_range:
Proof.
induction n; simpl; intros.
rewrite two_power_nat_O. omega.
- rewrite two_power_nat_S. destruct (Z_bin_decomp x) as [b y]_eqn.
+ rewrite two_power_nat_S. destruct (Z_bin_decomp x) as [b y] eqn:?.
rewrite Z_bin_comp_eq. generalize (IHn y). destruct b; omega.
Qed.
@@ -179,7 +179,7 @@ Proof.
induction n; simpl; intros.
rewrite two_power_nat_O. exists x. ring.
rewrite two_power_nat_S.
- destruct (Z_bin_decomp x) as [b y]_eqn.
+ destruct (Z_bin_decomp x) as [b y] eqn:?.
destruct (IHn y) as [z EQ].
exists z. rewrite (Z_bin_comp_decomp2 _ _ _ Heqp).
repeat rewrite Z_bin_comp_eq. rewrite EQ at 1. ring.
@@ -1171,7 +1171,7 @@ Proof.
Z_of_bits n (bits_of_Z n x) 0 = k * two_power_nat n + x).
induction n; intros; simpl.
rewrite two_power_nat_O. exists (-x). omega.
- rewrite two_power_nat_S. destruct (Z_bin_decomp x) as [b y]_eqn.
+ rewrite two_power_nat_S. destruct (Z_bin_decomp x) as [b y] eqn:?.
rewrite zeq_true. destruct (IHn y) as [k EQ].
replace (Z_of_bits n (fun i => if zeq i 0 then b else bits_of_Z n y (i - 1)) 1)
with (Z_of_bits n (bits_of_Z n y) 0).
@@ -1302,7 +1302,7 @@ Proof.
auto.
destruct (zlt i 0). apply bits_of_Z_below. auto.
simpl.
- destruct (Z_bin_decomp x) as [b x1]_eqn.
+ destruct (Z_bin_decomp x) as [b x1] eqn:?.
destruct (zeq i 0).
subst i. simpl in H. assert (x = 0) by omega. subst x. simpl in Heqp. congruence.
apply IHn.
@@ -2199,7 +2199,7 @@ Proof.
simpl. rewrite two_power_nat_O in H0.
assert (x = 0). omega. subst x. omega.
rewrite two_power_nat_S in H0. simpl Z_one_bits.
- destruct (Z_bin_decomp x) as [b y]_eqn.
+ destruct (Z_bin_decomp x) as [b y] eqn:?.
rewrite (Z_bin_comp_decomp2 _ _ _ Heqp).
assert (EQ: y * two_p (i + 1) = powerserie (Z_one_bits n y (i + 1))).
apply IHn. omega.
diff --git a/lib/Iteration.v b/lib/Iteration.v
index 235b650..1c3c9cc 100644
--- a/lib/Iteration.v
+++ b/lib/Iteration.v
@@ -171,7 +171,7 @@ Proof.
intros. unfold iter in H1. rewrite unroll_Fix in H1. unfold iter_step in H1.
destruct (peq x 1). discriminate.
specialize (step_prop a H0).
- destruct (step a) as [b'|a']_eqn.
+ destruct (step a) as [b'|a'] eqn:?.
inv H1. auto.
apply H with (Ppred x) a'. apply Ppred_Plt; auto. auto. auto.
Qed.
diff --git a/lib/Postorder.v b/lib/Postorder.v
index 3a76b0d..4a83ea5 100644
--- a/lib/Postorder.v
+++ b/lib/Postorder.v
@@ -148,8 +148,8 @@ Proof.
constructor; intros.
eauto.
caseEq (s.(map)!root); intros. congruence. exploit GREY; eauto. intros [? ?]; contradiction.
- destruct (s.(map)!x) as []_eqn; try congruence.
- destruct (s.(map)!y) as []_eqn; try congruence.
+ destruct (s.(map)!x) eqn:?; try congruence.
+ destruct (s.(map)!y) eqn:?; try congruence.
exploit COLOR; eauto. intros. exploit GREY; eauto. intros [? ?]; contradiction.
(* not finished *)
destruct succ_x as [ | y succ_x ].
@@ -189,7 +189,7 @@ Proof.
exists l'; auto.
(* children y needs traversing *)
- destruct ((gr s)!y) as [ succs_y | ]_eqn.
+ destruct ((gr s)!y) as [ succs_y | ] eqn:?.
(* y has children *)
constructor; simpl; intros.
(* sub *)
@@ -241,7 +241,7 @@ Qed.
Lemma initial_state_spec:
invariant (init_state ginit root).
Proof.
- unfold init_state. destruct (ginit!root) as [succs|]_eqn.
+ unfold init_state. destruct (ginit!root) as [succs|] eqn:?.
(* root has succs *)
constructor; simpl; intros.
(* sub *)
@@ -315,7 +315,7 @@ Proof.
discriminate.
destruct succs as [ | y succs ].
inv H. simpl. apply lex_ord_right. omega.
- destruct ((gr s)!y) as [succs'|]_eqn.
+ destruct ((gr s)!y) as [succs'|] eqn:?.
inv H. simpl. apply lex_ord_left. eapply PTree_Properties.cardinal_remove; eauto.
inv H. simpl. apply lex_ord_right. omega.
Qed.
diff --git a/powerpc/Asmgenproof1.v b/powerpc/Asmgenproof1.v
index 2af4f70..f1c206e 100644
--- a/powerpc/Asmgenproof1.v
+++ b/powerpc/Asmgenproof1.v
@@ -1516,6 +1516,7 @@ Lemma transl_load_correct:
Proof.
intros.
exploit eval_addressing_lessdef. eapply preg_vals; eauto. eauto.
+ unfold PregEq.t.
intros [a' [A B]].
exploit Mem.loadv_extends; eauto. intros [v' [C D]].
apply transl_load_store_correct with ms; auto.
@@ -1570,6 +1571,7 @@ Lemma transl_store_correct:
Proof.
intros.
exploit eval_addressing_lessdef. eapply preg_vals; eauto. eauto.
+ unfold PregEq.t.
intros [a' [A B]].
assert (Z: Val.lessdef (ms src) (rs (preg_of src))). eapply preg_val; eauto.
exploit Mem.storev_extends; eauto. intros [m1' [C D]].
diff --git a/powerpc/ConstpropOpproof.v b/powerpc/ConstpropOpproof.v
index eef3944..7d557c6 100644
--- a/powerpc/ConstpropOpproof.v
+++ b/powerpc/ConstpropOpproof.v
@@ -155,7 +155,7 @@ Proof.
destruct (propagate_float_constants tt); simpl; auto.
unfold eval_static_condition_val, Val.of_optbool.
- destruct (eval_static_condition c vl0) as []_eqn.
+ destruct (eval_static_condition c vl0) eqn:?.
rewrite (eval_static_condition_correct _ _ _ m _ H Heqo).
destruct b; simpl; auto.
simpl; auto.
@@ -240,7 +240,7 @@ Proof.
intros; unfold make_shlimm.
predSpec Int.eq Int.eq_spec n Int.zero; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.shl_zero. auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; intros.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; intros.
rewrite Val.shl_rolm; auto. econstructor; split; eauto. auto.
econstructor; split; eauto. simpl. congruence.
Qed.
@@ -254,7 +254,7 @@ Proof.
intros; unfold make_shrimm.
predSpec Int.eq Int.eq_spec n Int.zero; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.shr_zero. auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn.
+ destruct (Int.ltu n Int.iwordsize) eqn:?.
econstructor; split; eauto. simpl. auto.
econstructor; split; eauto. simpl. congruence.
Qed.
@@ -268,7 +268,7 @@ Proof.
intros; unfold make_shruimm.
predSpec Int.eq Int.eq_spec n Int.zero; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.shru_zero. auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn; intros.
+ destruct (Int.ltu n Int.iwordsize) eqn:?; intros.
rewrite Val.shru_rolm; auto. econstructor; split; eauto. auto.
econstructor; split; eauto. simpl. congruence.
Qed.
@@ -284,7 +284,7 @@ Proof.
exists (Vint Int.zero); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.mul_zero; auto.
predSpec Int.eq Int.eq_spec n Int.one; intros. subst.
exists (rs#r1); split; auto. destruct (rs#r1); simpl; auto. rewrite Int.mul_one; auto.
- destruct (Int.is_power2 n) as []_eqn; intros.
+ destruct (Int.is_power2 n) eqn:?; intros.
rewrite (Val.mul_pow2 rs#r1 _ _ Heqo). rewrite Val.shl_rolm.
econstructor; split; eauto. auto.
eapply Int.is_power2_range; eauto.
@@ -299,8 +299,8 @@ Lemma make_divimm_correct:
exists w, eval_operation ge sp op rs##args m = Some w /\ Val.lessdef v w.
Proof.
intros; unfold make_divimm.
- destruct (Int.is_power2 n) as []_eqn.
- destruct (Int.ltu i (Int.repr 31)) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
+ destruct (Int.ltu i (Int.repr 31)) eqn:?.
exists v; split; auto. simpl. eapply Val.divs_pow2; eauto. congruence.
exists v; auto.
exists v; auto.
@@ -314,7 +314,7 @@ Lemma make_divuimm_correct:
exists w, eval_operation ge sp op rs##args m = Some w /\ Val.lessdef v w.
Proof.
intros; unfold make_divuimm.
- destruct (Int.is_power2 n) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
econstructor; split. simpl; eauto.
exploit Int.is_power2_range; eauto. intros RANGE.
rewrite <- Val.shru_rolm; auto. rewrite H0 in H.
@@ -439,10 +439,10 @@ Lemma builtin_strength_reduction_correct:
Proof.
intros until m'. unfold builtin_strength_reduction.
destruct (builtin_strength_reduction_match ef args vl); simpl; intros; InvApproxRegs; SimplVMA.
- unfold symbol_address in H. destruct (Genv.find_symbol ge symb) as [b|]_eqn; rewrite H in H0.
+ unfold symbol_address in H. destruct (Genv.find_symbol ge symb) as [b|] eqn:?; rewrite H in H0.
rewrite volatile_load_global_charact. exists b; auto.
inv H0.
- unfold symbol_address in H1. destruct (Genv.find_symbol ge symb) as [b|]_eqn; rewrite H1 in H0.
+ unfold symbol_address in H1. destruct (Genv.find_symbol ge symb) as [b|] eqn:?; rewrite H1 in H0.
rewrite volatile_store_global_charact. exists b; auto.
inv H0.
auto.
diff --git a/powerpc/Op.v b/powerpc/Op.v
index e59e15f..58bcb2c 100644
--- a/powerpc/Op.v
+++ b/powerpc/Op.v
@@ -576,8 +576,8 @@ Proof.
right. apply Int.no_overlap_sound; auto.
(* Aglobal *)
unfold symbol_address in *.
- destruct (Genv.find_symbol ge i1) as []_eqn; inv H2.
- destruct (Genv.find_symbol ge i) as []_eqn; inv H1.
+ destruct (Genv.find_symbol ge i1) eqn:?; inv H2.
+ destruct (Genv.find_symbol ge i) eqn:?; inv H1.
destruct (ident_eq i i1). subst.
replace (Int.unsigned n1) with (Int.unsigned (Int.add Int.zero n1)).
replace (Int.unsigned n2) with (Int.unsigned (Int.add Int.zero n2)).
@@ -587,9 +587,9 @@ Proof.
left. red; intros; elim n. subst. eapply Genv.genv_vars_inj; eauto.
(* Abased *)
unfold symbol_address in *.
- destruct (Genv.find_symbol ge i1) as []_eqn; simpl in *; try discriminate.
+ destruct (Genv.find_symbol ge i1) eqn:?; simpl in *; try discriminate.
destruct v; inv H2.
- destruct (Genv.find_symbol ge i) as []_eqn; inv H1.
+ destruct (Genv.find_symbol ge i) eqn:?; inv H1.
destruct (ident_eq i i1). subst.
rewrite (Int.add_commut i0 i3). rewrite (Int.add_commut i2 i3).
right. apply Int.no_overlap_sound; auto.
@@ -706,8 +706,8 @@ Opaque Int.add.
Val.cmpu_bool (Mem.valid_pointer m1) c v1 v2 = Some b ->
Val.cmpu_bool (Mem.valid_pointer m2) c v1' v2' = Some b).
intros. inv H; simpl in H1; try discriminate; inv H0; simpl in H1; try discriminate; simpl; auto.
- destruct (Mem.valid_pointer m1 b1 (Int.unsigned ofs1)) as []_eqn; try discriminate.
- destruct (Mem.valid_pointer m1 b0 (Int.unsigned ofs0)) as []_eqn; try discriminate.
+ destruct (Mem.valid_pointer m1 b1 (Int.unsigned ofs1)) eqn:?; try discriminate.
+ destruct (Mem.valid_pointer m1 b0 (Int.unsigned ofs0)) eqn:?; try discriminate.
rewrite (valid_pointer_inj _ H2 Heqb4).
rewrite (valid_pointer_inj _ H Heqb0). simpl.
destruct (zeq b1 b0); simpl in H1.
@@ -792,7 +792,7 @@ Proof.
inv H4; simpl in H1; inv H1. simpl. destruct (Float.intoffloat f0); simpl in H2; inv H2.
exists (Vint i); auto.
inv H4; inv H2; simpl; auto.
- subst v1. destruct (eval_condition c vl1 m1) as []_eqn.
+ subst v1. destruct (eval_condition c vl1 m1) eqn:?.
exploit eval_condition_inj; eauto. intros EQ; rewrite EQ.
destruct b; simpl; constructor.
simpl; constructor.
@@ -923,7 +923,7 @@ Hypothesis sp_inj: f sp1 = Some(sp2, delta).
Remark symbol_address_inject:
forall id ofs, val_inject f (symbol_address genv id ofs) (symbol_address genv id ofs).
Proof.
- intros. unfold symbol_address. destruct (Genv.find_symbol genv id) as []_eqn; auto.
+ intros. unfold symbol_address. destruct (Genv.find_symbol genv id) eqn:?; auto.
exploit (proj1 globals); eauto. intros.
econstructor; eauto. rewrite Int.add_zero; auto.
Qed.
diff --git a/powerpc/PrintAsm.ml b/powerpc/PrintAsm.ml
index a20448c..f56c3f2 100644
--- a/powerpc/PrintAsm.ml
+++ b/powerpc/PrintAsm.ml
@@ -924,7 +924,7 @@ let print_init oc = function
(Int64.logand b 0xFFFFFFFFL)
comment (camlfloat_of_coqfloat n)
| Init_space n ->
- let n = camlint_of_z n in
+ let n = Z.to_int32 n in
if n > 0l then fprintf oc " .space %ld\n" n
| Init_addrof(symb, ofs) ->
fprintf oc " .long %a\n"
diff --git a/powerpc/SelectOpproof.v b/powerpc/SelectOpproof.v
index 5e49366..7be8858 100644
--- a/powerpc/SelectOpproof.v
+++ b/powerpc/SelectOpproof.v
@@ -232,7 +232,7 @@ Proof.
red; intros. unfold shlimm.
predSpec Int.eq Int.eq_spec n Int.zero.
subst. exists x; split; auto. destruct x; simpl; auto. rewrite Int.shl_zero; auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn.
+ destruct (Int.ltu n Int.iwordsize) eqn:?.
rewrite Val.shl_rolm; auto. apply eval_rolm; auto.
TrivialExists. econstructor. eauto. econstructor. EvalOp. simpl; eauto. constructor. auto.
Qed.
@@ -244,7 +244,7 @@ Proof.
red; intros. unfold shruimm.
predSpec Int.eq Int.eq_spec n Int.zero.
subst. exists x; split; auto. destruct x; simpl; auto. rewrite Int.shru_zero; auto.
- destruct (Int.ltu n Int.iwordsize) as []_eqn.
+ destruct (Int.ltu n Int.iwordsize) eqn:?.
rewrite Val.shru_rolm; auto. apply eval_rolm; auto.
TrivialExists. econstructor. eauto. econstructor. EvalOp. simpl; eauto. constructor. auto.
Qed.
@@ -257,7 +257,7 @@ Proof.
predSpec Int.eq Int.eq_spec n Int.zero.
intros. subst. exists x; split; auto. destruct x; simpl; auto. rewrite Int.shr_zero; auto.
case (shrimm_match a); intros.
- destruct (Int.lt mask1 Int.zero) as []_eqn.
+ destruct (Int.lt mask1 Int.zero) eqn:?.
TrivialExists.
replace (Val.shr x (Vint n)) with (Val.shru x (Vint n)).
apply eval_shruimm; auto.
@@ -331,7 +331,7 @@ Proof.
InvEval. TrivialExists. simpl. rewrite Int.and_commut; auto.
set (n' := Int.and n n2).
destruct (Int.eq (Int.shru (Int.shl n' amount) amount) n' &&
- Int.ltu amount Int.iwordsize) as []_eqn.
+ Int.ltu amount Int.iwordsize) eqn:?.
InvEval. destruct (andb_prop _ _ Heqb).
generalize (Int.eq_spec (Int.shru (Int.shl n' amount) amount) n'). rewrite H1; intros.
replace (Val.and x (Vint n))
@@ -349,7 +349,7 @@ Proof.
destruct v1; auto. simpl. unfold Int.rolm. rewrite Int.and_assoc.
decEq. decEq. decEq. apply Int.and_commut.
destruct (Int.eq (Int.shru (Int.shl n amount) amount) n &&
- Int.ltu amount Int.iwordsize) as []_eqn.
+ Int.ltu amount Int.iwordsize) eqn:?.
InvEval. destruct (andb_prop _ _ Heqb).
generalize (Int.eq_spec (Int.shru (Int.shl n amount) amount) n). rewrite H0; intros.
replace (Val.and x (Vint n))
@@ -402,20 +402,20 @@ Theorem eval_or: binary_constructor_sound or Val.or.
Proof.
red; intros until y; unfold or; case (or_match a b); intros.
(* rolm - rolm *)
- destruct (Int.eq amount1 amount2 && same_expr_pure t1 t2) as []_eqn.
+ destruct (Int.eq amount1 amount2 && same_expr_pure t1 t2) eqn:?.
destruct (andb_prop _ _ Heqb0).
generalize (Int.eq_spec amount1 amount2). rewrite H1. intro. subst amount2.
InvEval. exploit eval_same_expr; eauto. intros [EQ1 EQ2]. subst.
rewrite Val.or_rolm. TrivialExists.
TrivialExists.
(* andimm - rolm *)
- destruct (Int.eq mask1 (Int.not mask2) && is_rlw_mask mask2) as []_eqn.
+ destruct (Int.eq mask1 (Int.not mask2) && is_rlw_mask mask2) eqn:?.
destruct (andb_prop _ _ Heqb0).
generalize (Int.eq_spec mask1 (Int.not mask2)); rewrite H1; intros.
InvEval. subst. TrivialExists.
TrivialExists.
(* rolm - andimm *)
- destruct (Int.eq mask2 (Int.not mask1) && is_rlw_mask mask1) as []_eqn.
+ destruct (Int.eq mask2 (Int.not mask1) && is_rlw_mask mask1) eqn:?.
destruct (andb_prop _ _ Heqb0).
generalize (Int.eq_spec mask2 (Int.not mask1)); rewrite H1; intros.
InvEval. subst. rewrite Val.or_commut. TrivialExists.
@@ -507,7 +507,7 @@ Theorem eval_divuimm:
exists v, eval_expr ge sp e m le (divuimm a n) v /\ Val.lessdef z v.
Proof.
intros; unfold divuimm.
- destruct (Int.is_power2 n) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
replace z with (Val.shru x (Vint i)). apply eval_shruimm; auto.
eapply Val.divu_pow2; eauto.
TrivialExists.
@@ -533,7 +533,7 @@ Theorem eval_moduimm:
exists v, eval_expr ge sp e m le (moduimm a n) v /\ Val.lessdef z v.
Proof.
intros; unfold moduimm.
- destruct (Int.is_power2 n) as []_eqn.
+ destruct (Int.is_power2 n) eqn:?.
replace z with (Val.and x (Vint (Int.sub n Int.one))). apply eval_andimm; auto.
eapply Val.modu_pow2; eauto.
exploit Val.modu_divu; eauto. intros [v [A B]].
@@ -758,7 +758,7 @@ Theorem eval_intuoffloat:
exists v, eval_expr ge sp e m le (intuoffloat a) v /\ Val.lessdef y v.
Proof.
intros. destruct x; simpl in H0; try discriminate.
- destruct (Float.intuoffloat f) as [n|]_eqn; simpl in H0; inv H0.
+ destruct (Float.intuoffloat f) as [n|] eqn:?; simpl in H0; inv H0.
exists (Vint n); split; auto. unfold intuoffloat.
set (im := Int.repr Int.half_modulus).
set (fm := Float.floatofintu im).
@@ -770,7 +770,7 @@ Proof.
econstructor. instantiate (1 := Vfloat fm). EvalOp.
eapply eval_Econdition with (vb := Float.cmp Clt f fm).
eauto with evalexpr. auto.
- destruct (Float.cmp Clt f fm) as []_eqn.
+ destruct (Float.cmp Clt f fm) eqn:?.
exploit Float.intuoffloat_intoffloat_1; eauto. intro EQ.
EvalOp. simpl. rewrite EQ; auto.
exploit Float.intuoffloat_intoffloat_2; eauto.