diff options
author | 2016-02-02 16:01:39 -0800 | |
---|---|---|
committer | 2016-02-02 16:01:39 -0800 | |
commit | 67e8bd207261ed4a4b30c4e488a6a2b6baf04d7a (patch) | |
tree | 4914444176e82ce7473f3b0a7caf0fd0c678c1e7 /src/gpu/batches/GrDrawPathBatch.cpp | |
parent | 8870e94fe38dc2cd73e0603b5facc4af78b5be83 (diff) |
Revert of Move Google3-specific stack limitation logic to template classes. Remove #ifdefs in other files. (patchset #2 id:50001 of https://codereview.chromium.org/1656143003/ )
Reason for revert:
See https://codereview.chromium.org/1665603002
Original issue's description:
> Move Google3-specific stack limitation logic to template classes. Remove #ifdefs in other files.
>
> Does not change the public API.
>
> TBR=reed
> GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1656143003
>
> Committed: https://skia.googlesource.com/skia/+/c92159c8250c62cc47b7b63686538d61d54d2835
TBR=mtklein@google.com,reed@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.chromium.org/1666503002
Diffstat (limited to 'src/gpu/batches/GrDrawPathBatch.cpp')
-rw-r--r-- | src/gpu/batches/GrDrawPathBatch.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gpu/batches/GrDrawPathBatch.cpp b/src/gpu/batches/GrDrawPathBatch.cpp index a99f4ebf43..ff62539932 100644 --- a/src/gpu/batches/GrDrawPathBatch.cpp +++ b/src/gpu/batches/GrDrawPathBatch.cpp @@ -137,8 +137,14 @@ void GrDrawPathRangeBatch::onDraw(GrBatchFlushState* state) { instances.count()); } else { int floatsPerTransform = GrPathRendering::PathTransformSize(this->transformType()); +#if defined(GOOGLE3) + //Stack frame size is limited in GOOGLE3. + SkAutoSTMalloc<512, float> transformStorage(floatsPerTransform * fTotalPathCount); + SkAutoSTMalloc<256, uint16_t> indexStorage(fTotalPathCount); +#else SkAutoSTMalloc<4096, float> transformStorage(floatsPerTransform * fTotalPathCount); SkAutoSTMalloc<2048, uint16_t> indexStorage(fTotalPathCount); +#endif int idx = 0; for (DrawList::Iter iter(fDraws); iter.get(); iter.next()) { const Draw& draw = *iter.get(); |