[M52] Cherry-pick
e6c515f3d34096426b6822ad90a757131e8baf31
Fix int32 overflow in LinearGradientContext::shade4_dx_clamp
The unconditional increment in shade4_dx_clamp can overflow int32
=> n == SK_MinS32
=> count ~= SK_MinS32
=> we skip the main shader loop 'cause count < 0
Also include trivial
0e59bb7aaad272ac42d6fba53e8439bd9fa1ff3d followup
to ensure we're not tripping ASAN.
TBR=reed@google.com,mtklein@google.com
BUG=chromium:599458
Review-Url: https://codereview.chromium.org/
2010843002
NOTREECHECKS=true
NOTRY=true
NOPRESUBMIT=true
Review-Url: https://codereview.chromium.org/
2021673002