Also, you can try to lessen the amount of memory allocations. Make sure that for floating point calculations you're using the fl... operations and that you use the flonum and not safe declarations in those parts of the code; and/or instead of allocating temporary objects always freshly, reuse them and mutate their contents. Also if your allocations are mostly closures, play with the linining-limit, and avoid passing closures to other compilation units (instead put the called code into the same unit).