update optimisations in implementation