Commit 5d646fe8 authored by Morten Stenshorne's avatar Morten Stenshorne Committed by Commit Bot

[LayoutNG] Reduce vector inline capacities in fragment builder.

This saves 192 bytes [*] of stack space per in-flow layout recursion.

[*] Linux 64bit release.

Bug: 930637
Change-Id: Ib4531d031312d97023c5e14ef40b8f25684ae29c
Reviewed-on: https://chromium-review.googlesource.com/c/1489421Reviewed-by: default avatarIan Kilpatrick <ikilpatrick@chromium.org>
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Cr-Commit-Position: refs/heads/master@{#636625}
parent 2b3ea54e
...@@ -31,8 +31,8 @@ class CORE_EXPORT NGContainerFragmentBuilder : public NGFragmentBuilder { ...@@ -31,8 +31,8 @@ class CORE_EXPORT NGContainerFragmentBuilder : public NGFragmentBuilder {
STACK_ALLOCATED(); STACK_ALLOCATED();
public: public:
typedef Vector<scoped_refptr<const NGPhysicalFragment>, 16> ChildrenVector; typedef Vector<scoped_refptr<const NGPhysicalFragment>, 4> ChildrenVector;
typedef Vector<NGLogicalOffset, 16> OffsetVector; typedef Vector<NGLogicalOffset, 4> OffsetVector;
LayoutUnit BfcLineOffset() const { return bfc_line_offset_; } LayoutUnit BfcLineOffset() const { return bfc_line_offset_; }
NGContainerFragmentBuilder& SetBfcLineOffset(LayoutUnit bfc_line_offset) { NGContainerFragmentBuilder& SetBfcLineOffset(LayoutUnit bfc_line_offset) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment