PERF: avoid warnings in IndexEngine.get_loc
Only reached for non-unique indexes.  Makes a big difference for small indexes.

Room for de-duplication in follow-ups.

```
import numpy as np
import pandas as pd

np.random.seed(90)
arr = np.random.randn(4).repeat(2)
idx = pd.Index(arr)
assert not idx.is_unique
key = arr[4]
engine = idx._engine

%timeit engine.get_loc(key)
6.6 µs ± 50.6 ns per loop (mean ± std. dev. of 7 runs, 100000 loops each)  # <- master
2.62 µs ± 127 ns per loop (mean ± std. dev. of 7 runs, 100000 loops each)  # <- PR
```