SkPath: Avoid calls to reserve 0 points or verbs on SkPathRef.
SkPath: Avoid calls to reserve 0 points or verbs on SkPathRef.

When de-serializing paths, we have a pattern that causes extra re-allocations as in
the following example:

  For each path, reserve known size e.g. SkPath::incReserve(11)
    -> Reserves internal SkTArray verb & point space 11.
    -> Verb & Point SkTarray::fReserved is set to true.

  For each verb:
    SkPathRef::Editor::Editor() calls SkPathRef::incReserve(0, 0)
       -> SkTArray::reserve_back(0) sets fReserved to false.

    SkPathRef::growForVerb() pushes points & verbs
       -> SkTArray::checkRealloc() shrinks the allocation because fReserved == false.

  Eventually SkPathRef::growForVerb() needs to grow the array again.

This change avoids the SkTArray::reserve_back(0) calls.

Bug: skia:13817
Change-Id: I5ad3fa3ef79f4c0265b19e7459aafe3baace8700
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/592336
Reviewed-by: Herb Derby <9e12a3d2bbf73546e47cc9958f6ba8f3215b7eaf@google.com>
Commit-Queue: Herb Derby <9e12a3d2bbf73546e47cc9958f6ba8f3215b7eaf@google.com>

google/skia,google/skia,google/skia,google/skia,google/skia,google/skia,google/skia,google/skia,google/skia,google/skia