PERF: perf issue with indexing