Minor performance optimisations