optimisation fixes and configuration changes.