[mercury-users] Memory consumption w/memoization

Zoltan Somogyi zs at cs.mu.OZ.AU
Fri Sep 23 13:33:33 AEST 2005


On 22-Sep-2005, Kral Stefan <skral at mips.complang.tuwien.ac.at> wrote:
> Is there a way to limit the amount of memory used for the 
> memoization of a predicate?

No, not at the moment. We have recognized the issue, and I know that some
other people have also implemented probabilistic memoization, where you memo
only e.g. 5% of answers. (On transitive closure of graphs, this gets most of
the available speedup, if I recall the relevant paper correctly.) I don't know
of any widely disseminated systems that have such facilities, but then again
I haven't looked lately.

This has always been on my list of ideas to try sometime later, the reason
I haven't taken it up being the lack of a representative application. If you
think you have one, I would be glad to work on it with you. There are several
design issues to consider, such as what method of controlling space consumption
is actually best for users, and how the time overhead of the extra checks
required and the extra recomputation required can be traded off against
the time required to actually memo answers as well as the space consumeed
by answers.

Zoltan.
--------------------------------------------------------------------------
mercury-users mailing list
post:  mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the users mailing list