Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1273)

Issue 6946054: Replacing alloca call in SkTileGrid with SkAutoSMalloc (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 6 months ago by junov1
Modified:
11 years, 6 months ago
Reviewers:
reed1
CC:
skia-review_googlegroups.com, robertphillips
Base URL:
http://skia.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Replacing alloca call in SkTileGrid with SkAutoSMalloc Committed: https://code.google.com/p/skia/source/detail?r=6824

Patch Set 1 #

Patch Set 2 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+2 lines, -6 lines) Patch
M src/core/SkTileGrid.cpp View 1 2 chunks +2 lines, -6 lines 0 comments Download

Messages

Total messages: 9
junov1
PTAL
11 years, 6 months ago (2012-12-14 19:50:45 UTC) #1
reed1
SkAutoSTMalloc might be clearer. SkAutoSTMalloc<1024, SkTDArray*> storage(count); SkTDArray** array = storage.get();
11 years, 6 months ago (2012-12-14 19:54:45 UTC) #2
reed1
or SkAutoSTArray, which is equivalent (in behavior) to SkAutoSTMalloc if T is a POD (which ...
11 years, 6 months ago (2012-12-14 19:56:35 UTC) #3
junov1
On 2012/12/14 19:56:35, reed1 wrote: > or SkAutoSTArray, which is equivalent (in behavior) to SkAutoSTMalloc ...
11 years, 6 months ago (2012-12-14 19:59:56 UTC) #4
reed1
lgtm might add a comment above the 1024, describing why that seems like a good ...
11 years, 6 months ago (2012-12-14 20:02:04 UTC) #5
junov1
I totally pulled that number out of my rear, which does not seam like an ...
11 years, 6 months ago (2012-12-14 20:08:02 UTC) #6
reed1
Then (perhaps), we should not use it. Can you run this on some pictures, and ...
11 years, 6 months ago (2012-12-14 20:19:56 UTC) #7
junov1
A typical big page, say 2k x 16k would have 512 tiles. On Fri, Dec ...
11 years, 6 months ago (2012-12-14 20:24:22 UTC) #8
reed1
11 years, 6 months ago (2012-12-14 20:27:44 UTC) #9
That sounds like a great thing for a comment!

On Fri, Dec 14, 2012 at 3:24 PM, Justin Novosad <junov@chromium.org> wrote:
> A typical big page, say  2k x 16k would have 512 tiles.
>
>
> On Fri, Dec 14, 2012 at 3:19 PM, Mike Reed <reed@google.com> wrote:
>>
>> Then (perhaps), we should not use it. Can you run this on some
>> pictures, and get a feel for what value might be appropriate? Perhaps
>> we can just use the heap all the time, rather than complicate it with
>> stack-based allocations, unless we feel this is performance critical.
>>
>> On Fri, Dec 14, 2012 at 3:08 PM,  <junov@chromium.org> wrote:
>> > I totally pulled that number out of my rear, which does not seam like an
>> > appropriate comment.
>> >
>> >
>> > On 2012/12/14 20:02:04, reed1 wrote:
>> >>
>> >> lgtm
>> >
>> >
>> >> might add a comment above the 1024, describing why that seems like a
>> >
>> > good guess
>> >>
>> >> (not sure of your reasoning).
>> >
>> >
>> >
>> >
>> > https://codereview.appspot.com/6946054/
>
>
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b