Currently we try to combine two GEPs even if the inner one has more than one use. However, this means we can end up duplicating the index arithmetic.
This patch restricts GEP merging to one-use or constant source. Constant offsets are allowed, because these are considered essentially free.
TBH I'm not really sure whether we should do this, as it's long-standing behavior, and I'm not aware of it causing active problems. This came up as a question during D138637.