PERF: groupby.apply on a non-unique, unsorted index
- [x] closes #46527
- [x] [Tests added and passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#writing-tests) if fixing a bug or adding a new feature
- [x] All [code checks passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#pre-commit).
- [x] Added an entry in the latest `doc/source/whatsnew/v1.5.0.rst` 


Added the following asv to cover this case:

```
from asv_bench.benchmarks.groupby import ApplyNonUniqueUnsortedIndex

b = ApplyNonUniqueUnsortedIndex()
b.setup()

%timeit b.time_groupby_apply_non_unique_unsorted_index()
```

```
2.16 s ± 163 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)     <- main
7.1 ms ± 207 µs per loop (mean ± std. dev. of 7 runs, 100 loops each)  <- PR
```
thanks @lukemanley very nice!