Java memory directives, tweaks from xnat_discussion on thread http://x90.es/7Zt