BMH string algos with some performance tests