Choose the heap size more carefully.

Fixes #20