Hardware based optimisations of the fugue algorithm