opennars / Narjure

A Clojure implementation of the Non-Axiomatic Reasoning System proposed by Pei Wang.
GNU General Public License v2.0
44 stars 11 forks source link

Potential sources of a memory leak #54

Closed rasom closed 8 years ago

rasom commented 8 years ago

https://github.com/opennars/opennars2/blob/2_0_3_simple_budget/src/nal/deriver.clj#L21 https://github.com/opennars/opennars2/blob/0a20811d218934fce5d7fc256b2f682d1c35eb88/src/nal/deriver.clj#L22 https://github.com/opennars/opennars2/blob/0a20811d218934fce5d7fc256b2f682d1c35eb88/src/nal/deriver/key_path.clj#L48 https://github.com/opennars/opennars2/blob/0a20811d218934fce5d7fc256b2f682d1c35eb88/src/nal/deriver/key_path.clj#L58 https://github.com/opennars/opennars2/blob/0a20811d218934fce5d7fc256b2f682d1c35eb88/src/nal/deriver/substitution.clj#L21

If you will find a problem here, there is core.memoize https://github.com/clojure/core.memoize/ library which provides different strategies for cache invalidation.

patham9 commented 8 years ago

thanks a lot! :)

patham9 commented 8 years ago

this was indeed the source of the memory leak as you thought, and since we resolved it: closed.