Added profiling files. More performance changes (keys vector pointer used rather than a copy of it).