psqueues
Pure priority search queues
The psqueues package provides
<http://en.wikipedia.org/wiki/Priority_queue Priority Search Queues> in
three different flavors.
* @OrdPSQ k p v@, which uses the @Ord k@ instance to provide fast insertion,
deletion and lookup. This implementation is based on Ralf Hinze's
<http://citeseer.ist.psu.edu/hinze01simple.html A Simple Implementation Technique for Priority Search Queues>.
Hence, it is similar to the
<http://hackage.haskell.org/package/PSQueue PSQueue> library, although it is
considerably faster and provides a slightly different API.
* @IntPSQ p v@ is a far more efficient implementation. It fixes the key type
to @Int@ and uses a <http://en.wikipedia.org/wiki/Radix_tree radix tree>
(like @IntMap@) with an additional min-heap property.
* @HashPSQ k p v@ is a fairly straightforward extension of @IntPSQ@: it
simply uses the keys' hashes as indices in the @IntPSQ@. If there are any
hash collisions, it uses an @OrdPSQ@ to resolve those. The performance of
this implementation is comparable to that of @IntPSQ@, but it is more widely
applicable since the keys are not restricted to @Int@, but rather to any
@Hashable@ datatype.
Each of the three implementations provides the same API, so they can be used
interchangeably. The benchmarks show how they perform relative to one
another, and also compared to the other Priority Search Queue
implementations on Hackage:
<http://hackage.haskell.org/package/PSQueue PSQueue>
and
<http://hackage.haskell.org/package/fingertree-psqueue fingertree-psqueue>.
<<http://i.imgur.com/KmbDKR6.png>>
<<http://i.imgur.com/ClT181D.png>>
Typical applications of Priority Search Queues include:
* Caches, and more specifically LRU Caches;
* Schedulers;
* Pathfinding algorithms, such as Dijkstra's and A*.
| version | uploaded | uploader | changes | |
|---|---|---|---|---|
| 0.2.8.3 | 2025-12-28 06:54 UTC | JasperVanDerJeugt | 2 revisions | +5/−2 lines, 3 filesdep ~QuickCheckPVP ok |
| 0.2.8.2 | 2025-08-08 13:56 UTC | JasperVanDerJeugt | +76/−26 lines, 4 filesdep −arraydep −containersdep −ghc-primPVP: major bump suggested | |
| 0.2.8.1 | 2025-01-28 00:07 UTC | JasperVanDerJeugt | +29/−9 lines, 3 filesPVP ok | |
| 0.2.8.0 | 2023-10-27 15:51 UTC | JasperVanDerJeugt | 2 revisions | +57/−95 lines, 7 filesdep −fingertree-psqueuedep ~QuickCheckdep ~deepseqdep ~hashablePVP ok |
| 0.2.7.3 | 2021-11-05 17:37 UTC | JasperVanDerJeugt | +25/−16 lines, 2 filesdep ~QuickCheckdep ~hashabledep ~tastyPVP ok | |
| 0.2.7.2 | 2019-06-07 14:32 UTC | JasperVanDerJeugt | 1 revisions | +56/−54 lines, 7 filesdep +tastydep +tasty-hunitdep +tasty-quickcheckdep −test-frameworkdep −test-framework-hunitdep −test-framework-quickcheck2dep ~QuickCheckdep ~hashablePVP ok |
| 0.2.7.1 | 2019-01-07 19:19 UTC | JasperVanDerJeugt | 1 revisions | +5/−2 lines, 2 filesdep ~QuickCheckPVP: major bump suggested |
| 0.2.7.0 | 2018-04-30 14:30 UTC | JasperVanDerJeugt | 1 revisions | +17/−4 lines, 5 filesPVP ok |
| 0.2.6.0 | 2018-03-14 13:52 UTC | JasperVanDerJeugt | 1 revisions | +11/−2 lines, 3 filesdep ~QuickCheckPVP ok |
| 0.2.5.0 | 2018-01-18 14:26 UTC | JasperVanDerJeugt | 1 revisions | +7/−5 lines, 3 filesdep ~basePVP ok |
| 0.2.4.0 | 2017-09-27 14:52 UTC | JasperVanDerJeugt | 2 revisions | +185/−94 lines, 10 filesdep ~hashablePVP ok |
| 0.2.3.0 | 2017-07-03 11:11 UTC | JasperVanDerJeugt | 2 revisions | +150/−33 lines, 11 filesdep ~HUnitdep ~QuickCheckPVP ok |
| 0.2.2.3 | 2016-11-28 10:36 UTC | JasperVanDerJeugt | 2 revisions | +5/−2 lines, 2 filesdep ~HUnitPVP ok |
| 0.2.2.2 | 2016-07-24 12:45 UTC | JasperVanDerJeugt | 2 revisions | +5/−2 lines, 2 filesdep ~QuickCheckPVP: major bump suggested |
| 0.2.2.1 | 2016-04-22 10:17 UTC | JasperVanDerJeugt | 2 revisions | +314/−1 lines, 8 filesPVP ok |
| 0.2.2.0 | 2016-02-06 10:43 UTC | JasperVanDerJeugt | 2 revisions | +8/−1 lines, 5 filesdep ~basePVP ok |
| 0.2.1.0 | 2016-02-03 10:27 UTC | JasperVanDerJeugt | 4 revisions | +40/−59 lines, 5 filesdep ~basePVP: major bump suggested |
| 0.2.0.3 | 2015-09-23 17:48 UTC | JasperVanDerJeugt | 2 revisions | +8/−2 lines, 2 filesdep ~HUnitPVP ok |
| 0.2.0.2 | 2015-05-11 09:38 UTC | JasperVanDerJeugt | 2 revisions | +2/−2 lines, 1 filesdep ~QuickCheckPVP ok |
| 0.2.0.1 | 2015-03-16 19:00 UTC | JasperVanDerJeugt | 2 revisions | +57/−52 lines, 5 filesPVP ok |
| 0.2.0.0 | 2015-01-19 17:16 UTC | JasperVanDerJeugt | 2 revisions | +65/−5 lines, 10 filesdep ~basedep ~deepseqPVP ok |
| 0.1.1.0 | 2014-07-02 14:22 UTC | JasperVanDerJeugt | 1 revisions | +6/−3 lines, 4 filesPVP: major bump suggested |
| 0.1.0.1 | 2014-06-24 14:34 UTC | JasperVanDerJeugt | 1 revisions | +44/−17 lines, 2 filesPVP ok |
| 0.1.0.0 | 2014-06-23 13:53 UTC | JasperVanDerJeugt | 1 revisions | +3279/−0 lines, 19 filesdep +HUnitdep +PSQueuedep +QuickChecksetup-changed |
Dependencies of psqueues-0.2.8.3
HUnit >=1.2 && <1.7 1.6.1.0 → 1.6.2.0
| 2021-01-19 18:27 UTC | 1.6.2.0 | +48/−42 lines, 5 filesdep ~call-stackPVP: major bump suggested |
| 2020-10-31 12:09 UTC | 1.6.1.0 | +35/−21 lines, 4 filesPVP ok |
| 2017-03-20 01:42 UTC | 1.6.0.0 | +9/−5 lines, 4 filesdep ~basePVP ok |
| 2016-10-16 03:35 UTC | 1.5.0.0 | +47/−27 lines, 5 filesPVP ok |
| 2016-10-07 03:13 UTC | 1.4.0.0 | +761/−778 lines, 12 filesdep +call-stackPVP ok |
showing 5 of 22 versions
PSQueue >=1.1 1.2.1 → 1.2.2
| 2025-08-24 18:16 UTC | 1.2.2 | +234/−23 lines, 4 filesdep +tasty-hunitdep ~basePVP ok |
| 2025-01-27 14:00 UTC | 1.2.1 | +28/−22 lines, 4 filesdep +tastydep +tasty-quickcheckPVP ok |
| 2023-05-17 09:16 UTC | 1.2.0 | +100/−65 lines, 4 filesdep ~QuickCheckdep ~basePVP ok |
| 2022-04-13 08:48 UTC | 1.1.1 | +779/−688 lines, 6 filesdep +PSQueuedep +QuickCheckdep ~basenew-uploaderPVP: major bump suggested |
| 2019-01-12 19:56 UTC | 1.1.0.1 | +118/−110 lines, 4 filesdep ~basesetup-changednew-uploaderPVP: major bump suggested |
showing 5 of 7 versions
QuickCheck >=2.7 && <2.19 2.18.0.0 → 2.19.0.0 newer than bounds
| 2026-09-16 11:18 UTC | 2.19.0.0 newer than bounds | +67/−41 lines, 10 filesdep +OneTuplePVP ok |
| 2026-02-26 12:42 UTC | 2.18.0.0 | +826/−542 lines, 23 filesPVP ok |
| 2025-10-13 12:40 UTC | 2.17.1.0 | +18/−8 lines, 4 filesdep ~randomPVP: major bump suggested |
| 2025-10-07 12:26 UTC | 2.17.0.0 | +667/−129 lines, 14 filesdep +data-array-bytedep +hintdep +splitdep −ghc-primdep −old-localedep −old-timedep ~basedep ~randomdep ~template-haskellPVP ok |
| 2025-06-17 07:53 UTC | 2.16.0.0 | +477/−86 lines, 15 filesdep ~basenew-uploaderPVP ok |
showing 5 of 66 versions
base >=4.2 && <5 4.22.0.0 → 4.22.1.0
| 2026-12-01 12:38 UTC | 4.22.1.0 | +388/−6 lines, 9 filesdep ~ghc-internalPVP: major bump suggested |
| 2025-12-19 11:52 UTC | 4.22.0.0 | +886/−215 lines, 28 filesdep ~ghc-internalPVP ok |
| 2026-03-27 12:26 UTC | 4.21.2.0 | +10/−3 lines, 4 filesdep ~ghc-internalPVP ok |
| 2025-12-27 10:31 UTC | 4.21.1.0 | +17/−5 lines, 4 filesdep ~ghc-internalPVP ok |
| 2024-12-16 09:24 UTC | 4.21.0.0 | +1170/−396 lines, 39 filesdep ~ghc-internalPVP ok |
showing 5 of 61 versions
criterion >=0.8 1.6.4.1 → 1.6.5.0
| 2026-04-02 13:34 UTC | 1.6.5.0 | +7650/−7639 lines, 41 filesdep −parsecdep −timedep −vector-algorithmsdep ~aesondep ~deepseqsetup-changedPVP ok |
| 2025-09-06 22:52 UTC | 1.6.4.1 | +7639/−4696 lines, 42 filesdep ~base-compat-batteriessetup-changedbinary-addedPVP: major bump suggested |
| 2024-10-27 00:12 UTC | 1.6.4.0 | +64/−143 lines, 15 filesdep −faildep −ghc-primdep −semigroupsdep ~aesondep ~basedep ~binaryPVP: major bump suggested |
| 2023-08-08 11:17 UTC | 1.6.3.0 | +13/−7 lines, 3 filesdep ~base-compat-batteriesPVP ok |
| 2023-05-23 23:07 UTC | 1.6.2.0 | +18/−62 lines, 4 filesdep +prettyprinterdep +prettyprinter-ansi-terminaldep ~aesondep ~optparse-applicativePVP ok |
showing 5 of 70 versions
deepseq >=1.2 && <1.6 1.5.2.0 → 1.6.0.0 newer than bounds
| 2024-09-08 16:18 UTC | 1.6.0.0 newer than bounds | +5/−14 lines, 3 filesdep ~basePVP ok |
| 2025-06-14 22:25 UTC | 1.5.2.0 | +13/−4 lines, 3 filesPVP: major bump suggested |
| 2024-09-09 12:48 UTC | 1.5.1.0 | +69/−14 lines, 3 filesdep −arraydep ~basePVP: major bump suggested |
| 2023-07-27 19:32 UTC | 1.5.0.0 | +619/−532 lines, 5 filesdep ~basePVP ok |
| 2022-12-18 00:14 UTC | 1.4.8.1 | +34/−9 lines, 3 filesdep ~basePVP: major bump suggested |
showing 5 of 26 versions
hashable >=1.1.2.3 && <1.6 1.5.0.0 → 1.5.1.0
| 2026-01-02 17:45 UTC | 1.5.1.0 | +7260/−6790 lines, 5 filesdep −HUnitdep −ghc-bignumdep −randomdep ~basedep ~containersPVP: major bump suggested |
| 2024-07-04 19:38 UTC | 1.5.0.0 | +50/−156 lines, 4 filesdep −base-orphansdep −ghc-bignum-orphansdep −integer-gmpdep ~QuickCheckdep ~basedep ~bytestringPVP ok |
| 2024-06-24 10:44 UTC | 1.4.7.0 | +8/−3 lines, 2 filesPVP ok |
| 2024-06-09 19:43 UTC | 1.4.6.0 | +60/−83 lines, 7 filesdep −test-frameworkdep −test-framework-hunitdep −test-framework-quickcheck2PVP ok |
| 2024-06-08 14:07 UTC | 1.4.5.0 | +7338/−256 lines, 15 filesdep +primitivedep +tastydep +tasty-hunitdep ~basedep ~bytestringdep ~containersPVP ok |
showing 5 of 52 versions
random >=1.0 1.3.0 → 1.3.1
| 2025-04-04 14:25 UTC | 1.3.1 | +15/−6 lines, 3 filesPVP ok |
| 2025-01-06 04:03 UTC | 1.3.0 | +2410/−538 lines, 16 filesdep +data-array-bytedep ~basedep ~transformersPVP ok |
| 2024-12-14 20:31 UTC | 1.2.1.3 | +22/−37 lines, 3 filesdep −doctestdep −mwc-randomdep −unliftiodep ~basedep ~containersdep ~primitivePVP ok |
| 2024-02-04 16:26 UTC | 1.2.1.2 | +17/−12 lines, 2 filesdep ~doctestdep ~tastyPVP: major bump suggested |
| 2022-05-09 02:32 UTC | 1.2.1.1 | +8/−9 lines, 3 filesdep −ghc-byteorderdep ~bytestringdep ~doctestdep ~mtlPVP ok |
showing 5 of 15 versions
tagged >=0 0.8.11 → 0.9
| 2026-09-28 11:22 UTC | 0.9 | +7/−104 lines, 3 filesdep −template-haskellPVP ok |
| 2026-09-28 11:16 UTC | 0.8.11 | +11/−15 lines, 3 filesPVP ok |
| 2025-12-08 00:55 UTC | 0.8.10 | +40/−16 lines, 4 filesdep −transformersdep ~template-haskellPVP: major bump suggested |
| 2024-12-03 12:15 UTC | 0.8.9 | +39/−439 lines, 5 filesdep −ghc-primdep −transformers-compatdep ~basedep ~template-haskelldep ~transformersPVP ok |
| 2023-08-08 10:32 UTC | 0.8.8 | +14/−10 lines, 3 filesdep ~deepseqdep ~template-haskellPVP ok |
showing 5 of 41 versions
tasty >=1.2 && <1.6 1.5.4 → 1.5.5
| 2026-10-20 23:13 UTC | 1.5.5 | +53/−26 lines, 7 filesdep +terminal-sizePVP ok |
| 2026-03-25 20:04 UTC | 1.5.4 | +332/−166 lines, 22 filesdep −semigroupsPVP ok |
| 2025-01-05 19:52 UTC | 1.5.3 | +36/−11 lines, 3 filesdep ~containersdep ~optparse-applicativePVP: major bump suggested |
| 2024-11-03 00:34 UTC | 1.5.2 | +22/−5 lines, 4 filesdep ~basePVP ok |
| 2024-06-22 10:14 UTC | 1.5.1 | +131/−63 lines, 10 filesdep ~basePVP: major bump suggested |
showing 5 of 76 versions
tasty-hunit >=0.9 && <0.11 0.10.1 → 0.10.2
| 2024-06-22 10:14 UTC | 0.10.2 | +15/−7 lines, 4 filesPVP ok |
| 2023-09-10 00:12 UTC | 0.10.1 | +30/−52 lines, 5 filesdep ~basedep ~call-stackdep ~tastynew-uploaderPVP ok |
| 2020-12-18 09:42 UTC | 0.10.0.3 | +55/−10 lines, 4 filesdep ~basePVP ok |
| 2019-05-15 05:50 UTC | 0.10.0.2 | +38/−8 lines, 3 filesdep ~tastyPVP: major bump suggested |
| 2017-12-01 19:24 UTC | 0.10.0.1 | +51/−29 lines, 4 filesPVP: major bump suggested |
showing 5 of 15 versions
tasty-quickcheck >=0.8 && <0.12 0.11 → 0.11.1
| 2025-01-05 19:53 UTC | 0.11.1 | +66/−33 lines, 4 filesdep +regex-tdfadep −pcre-lightdep ~QuickCheckdep ~basedep ~optparse-applicativePVP: major bump suggested |
| 2024-06-22 10:14 UTC | 0.11 | +132/−49 lines, 4 filesdep ~QuickCheckPVP ok |
| 2023-09-10 00:10 UTC | 0.10.3 | +52/−14 lines, 3 filesdep ~QuickCheckdep ~optparse-applicativedep ~randomnew-uploaderPVP ok |
| 2021-11-20 19:17 UTC | 0.10.2 | +21/−13 lines, 3 filesdep ~basePVP: major bump suggested |
| 2020-12-18 09:42 UTC | 0.10.1.2 | +27/−13 lines, 4 filesdep ~basePVP: major bump suggested |
showing 5 of 23 versions
Reverse dependencies
37 packages depend on psqueues; 1 have bounds that exclude 0.2.8.3