[webkit-dev] size_t vs unsigned in WTF::Vector API ?
Filip Pizlo
fpizlo at apple.com
Thu Nov 20 14:10:05 PST 2014
> On Nov 20, 2014, at 2:06 PM, Alexey Proskuryakov <ap at webkit.org> wrote:
>
>
> SmallVector and Vector seem reasonable to me. I think that this is the right nomenclature - using limited size vectors should be a conscious choice.
>
> Even SmallVector should probably have a size_t API, so that we could centralize magnitude checks. What do you think?
Agreed.
This avoids any risk of someone computing a size_t quantity and flowing it into the SmallVector API in a way that would result in truncation that SmallVector cannot internally catch.
-Filip
>
> - Alexey
>
>
> 20 нояб. 2014 г., в 11:40, Filip Pizlo <fpizlo at apple.com <mailto:fpizlo at apple.com>> написал(а):
>
>> That looks like a pretty good performance win.
>>
>> I'd advocate for SmallVector and Vector, then.
>>
>> -Filip
>>
>>
>>> On Nov 20, 2014, at 11:38 AM, Chris Dumez <cdumez at apple.com <mailto:cdumez at apple.com>> wrote:
>>>
>>> The corresponding Blink bug did contain some performance data:
>>> CrBug#229226 <https://code.google.com/p/chromium/issues/detail?id=229226>
>>>
>>> Kr,
>>> --
>>> Chris Dumez - Apple Inc.
>>> Cupertino, CA
>>>
>>>
>>>
>>>
>>>> On Nov 20, 2014, at 11:32 AM, Geoffrey Garen <ggaren at apple.com <mailto:ggaren at apple.com>> wrote:
>>>>
>>>>> I wonder what the downsides are to this approach. Footprint of Vector?
>>>>
>>>> It looks like the original change was motivated by shrinking Vector:
>>>>
>>>> https://bugs.webkit.org/show_bug.cgi?id=97268 <https://bugs.webkit.org/show_bug.cgi?id=97268>
>>>>
>>>> Sadly, it didn’t include any data on the observed benefit :(.
>>>>
>>>> Geoff
>>>> _______________________________________________
>>>> webkit-dev mailing list
>>>> webkit-dev at lists.webkit.org <mailto:webkit-dev at lists.webkit.org>
>>>> https://lists.webkit.org/mailman/listinfo/webkit-dev <https://lists.webkit.org/mailman/listinfo/webkit-dev>
>>>
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-dev/attachments/20141120/4a419a51/attachment.html>
More information about the webkit-dev
mailing list