fukamachi / prove

Yet another unit testing framework for Common Lisp
218 stars 23 forks source link

deftest uses excessive dynamic memory causes heap exhaust on compile. #25

Open aarvid opened 8 years ago

aarvid commented 8 years ago

I have run into a problem where I can only define about 1000-1200 tests until the heap is exhausted. It appears that every time deftest is compiled, it is using up over 1MB of dynamic memory.

I made test code here: https://github.com/aarvid/prove-fail

The results are in repl.txt (copy of the slime repl) and inferior-lisp.txt, showing the buffer of inferior-lisp and the heap exhausted message.

Interesting that load-ing the file does not cause the problem. see repl-load.txt. Each deftest still uses over 1MB. However, the GC seems to recover a lot of the memory but when compiling, gc recovers very little.

I am using SBCL 1.3.2.

aarvid commented 8 years ago

Update: CCL 1.10 does not show this behaviour

aarvid commented 8 years ago

I have since created another repository to test sbcl without depending on prove. It is here: https://github.com/aarvid/comp-heap-exhaust. This emulates prove but does not depend on it. It shows the same behavior.

I have since created a bug report on SBCL: compile exhausts heap but load does not