Update build.gradle - initial JVM args. Minor fixies and speedups in code