diff options
| author | Jedidiah Barber <contact@jedbarber.id.au> | 2026-01-22 16:41:39 +1300 |
|---|---|---|
| committer | Jedidiah Barber <contact@jedbarber.id.au> | 2026-01-22 16:41:39 +1300 |
| commit | 28d132c2823d7dfa21190bf746f9f39dd59a40d8 (patch) | |
| tree | b0d1e26b2fadffa43bca2300dc273d8991c77df4 /readme.md | |
| parent | 42e3c2fa30552a227e38f03b859f03ae51f9000d (diff) | |
States are now custom linked lists
Diffstat (limited to 'readme.md')
| -rw-r--r-- | readme.md | 14 |
1 files changed, 6 insertions, 8 deletions
@@ -18,11 +18,6 @@ Most commonly only the main Kompsos package and the Math and Pretty_Print child packages will be needed. Although Collector is also used internally for the basic reification. -Note that efficient culling of intermediate results is an ongoing concern, and -it is recommended to minimise branching when making use of the Math functions. -Do not attempt to run the `houses.adb` example program unless you have a large -amount of free memory, around two gigabytes. - #### Dependencies @@ -95,9 +90,12 @@ instead. All the Goal operations beyond the microKanren four take an array of Terms as input in order to allow for Conjunct to be reasonably implemented. -The State datatype and the cache in the Collector package both make use of -Vectors instead of Maps. This is done to reduce memory requirements, and the -difference is considerable. +The State datatype makes use of custom linked lists, and the bookkeeping data +in the Collector package uses a custom directed acyclic graph structure that +reflects the main Goal graph. This is done instead of using Vectors or Maps +from the standard library both to improve speed and reduce memory requirements. +The improvement due to tail sharing is considerable, despite the theoretically +expensive operations involved walking the list to reify a variable. |
