Skip to Content.
Sympa Menu

coq-club - Re: [Coq-Club] (Computationally) Efficient Finite Maps

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

Re: [Coq-Club] (Computationally) Efficient Finite Maps


Chronological Thread 
  • From: Pierre Courtieu <Pierre.Courtieu AT cnam.fr>
  • To: Andrew Appel <appel AT princeton.edu>, coq-club AT inria.fr
  • Subject: Re: [Coq-Club] (Computationally) Efficient Finite Maps
  • Date: Thu, 14 May 2020 21:13:53 +0200
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=Pierre.Courtieu AT cnam.fr; spf=Pass smtp.mailfrom=pierre.courtieu AT gmail.com; spf=None smtp.helo=postmaster AT mail-il1-f173.google.com
  • Ironport-phdr: 9a23:bKWswRfBpL992nox/LoHDkMilGMj4u6mDksu8pMizoh2WeGdxcW+Zh7h7PlgxGXEQZ/co6odzbaP7uaxBydZu8rJmUtBWaQEbwUCh8QSkl5oK+++Imq/EsTXaTcnFt9JTl5v8iLzG0FUHMHjew+a+SXqvnYdFRrlKAV6OPn+FJLMgMSrzeCy/IDYbxlViDanbr5+MRW7oR/Vu8QXjoduN7g9xxTUqXZUZupawn9lK0iOlBjm/Mew+5Bj8yVUu/0/8sNLTLv3caclQ7FGFToqK2866tHluhnFVguP+2ATUn4KnRpSAgjK9w/1U5HsuSbnrOV92S2aPcrrTbAoXDmp8qlmRAP0hCoBKjU063/chNBug61HoRKhvx1/zJDSYIGJL/p1Y6fRccoHSWZdQspdUipMCZ6+YYQSFeoMJelXr4f/qFUOoxWwBhSiCv3zxTJTnHD6wbc33v49HQ3a3gEtGc8FvnTOrNXyMacfSfq7zKjWwjXZdfNZxyr25ZbPchA8u/GMQbNwftTMyUIyEA7LlFSQppL/PzOPyOsBqXaW7+19VeK1l24nqh9+oiW0y8gwjInGnIcVxkrK9SVj2Ys4I8CzR0Fnb9C+CpRQqz2aOJVsQsMkW2xmtzg3x6MbtJO0YiQExpAqyh3QZvKHcYWF4hLuWPiMLTp2mn5pZK6yihKu/UauyuPyWNW53VdEoCdHnNTBtnAD2hrO4caJTft9+12u2TeJ1w3L5eFEIFw0larGK5E62LI/ip0TsUHFEyTrm0v2lLebels49uWs8ejqYbXrqoWBO4J1iwzyKLkil86xDOk+LwMARXKU+f6m273m5UD5QKtFjvkxkqTBtZDVP8UbpqqgDw9U1oYv9g+zDzm73Nkak3QLNl1FeBWAj4jmP1HBPur0Auu4g1SpiDtrxvbGMaP9ApjVMHTPjLPscax+5kNc0gY/0NFS6pNOBr0cIv/+VFf9tNnCAR84Nwy0zfznCNJ41o4GQWKPA7GWMLnIsVCW/O4gP+6MZJIPuDbhKvgq+ePugGQ2mV8YZ6ap3J8XZGqkEfRhJkWVeWDsjcsZEWcWogo+S/Tnh0GFUT5Kfnq9Q6Y85iwgB4+9FofCRoWtgKSb0yuhH51WYHpGClGWHnvyeYWEQaREVCXHC8ltiDEbHZG5U4IlnUWnrBf3z5J/NOvS8SAEspSl2dRosambnhYrsDdwEs610meXTmgykHlbaSUx2fVHoEFn0FrL+q9lmeBZGMEbs8tIXx0gONj3yPFgF9H/RyrKeN6MDli8FIb1SQotR848loddK312HM+v21Wah3LzUu0l0oeTDZlxyZrymn34JsJz0XHDjfBzgFwvQ88JPmqj1PcmqlrjQrXRmkDcrJ6EMKQR2CmXqjWGxGuK+UBcCUt+CPqeG38YYUTSoJLy4UaQF+byW4RiCRNIzIu5EoUPcsfg3AdNQv7mftrEMTq8

What about another kind of trade-off? You can use different (But provably equivalent) implementations of the same data structure. 
While proving take an lightweight inefficient version. When extracting take the heavyweight-but-squashed-at-extctraction version.
You need a way to switch from one implementation to another. Either with modules (MSet and co are extremely versatile in this aspect) or maybe use the parametricity plugin?
Best 
P

Le jeu. 14 mai 2020 à 19:55, Hugo Herbelin <Hugo.Herbelin AT inria.fr> a écrit :
For the record, Pierre Letouzey (main author of the FSets/FMaps
library with Jean-Christophe Filliātre) has precisely updated last
week his "M" version of FMaps (https://github.com/letouzey/coq-mmaps),
with the plan to release it soon as an opam package.

Best,

Hugo

On Thu, May 14, 2020 at 12:46:38PM -0400, Andrew Appel wrote:
> The MSets interface of the Coq standard library factors the program from the
> proof, and may solve the problem that's being discussed here.
> It was intended as a replacement for FSets and FMaps.
> There had been a plan to make MMaps also (finite maps instead of sets), but
> unfortunately I don't think that was ever done.
>
> There are efficient implementations of MSets for AVL trees and Red-Black trees
> in the standard library.
>



Archive powered by MHonArc 2.6.18.

Top of Page