added option to set amount of mem used by the packer