LoopUnrollRuntime: Check for overflow in the trip count calculation.

Fixes PR19823.