Merge "Revert "Reduce stack usage for overflow checks"" into lmp-dev