Modeling the dominance of the gradient drift or Kelvin–Helmholtz instability in sheared ionospheric E × B flows