Changeset 116437 in webkit


Ignore:
Timestamp:
May 8, 2012 11:09:51 AM (12 years ago)
Author:
commit-queue@webkit.org
Message:

Unreviewed, rolling out r116402.
http://trac.webkit.org/changeset/116402
https://bugs.webkit.org/show_bug.cgi?id=85898

Caused a 3% regression on Chromium's bloat-http test on Linux
(Requested by ojan_gardening on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-05-08

  • WebCore.exp.in:
  • bindings/v8/RetainedDOMInfo.cpp:
  • dom/ContainerNode.h:
  • dom/Node.cpp:

(WebCore::Node::traverseNextNode):
(WebCore):
(WebCore::Node::traverseNextSibling):

  • dom/Node.h:

(Node):

Location:
trunk/Source/WebCore
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r116435 r116437  
     12012-05-08  Sheriff Bot  <webkit.review.bot@gmail.com>
     2
     3        Unreviewed, rolling out r116402.
     4        http://trac.webkit.org/changeset/116402
     5        https://bugs.webkit.org/show_bug.cgi?id=85898
     6
     7        Caused a 3% regression on Chromium's bloat-http test on Linux
     8        (Requested by ojan_gardening on #webkit).
     9
     10        * WebCore.exp.in:
     11        * bindings/v8/RetainedDOMInfo.cpp:
     12        * dom/ContainerNode.h:
     13        * dom/Node.cpp:
     14        (WebCore::Node::traverseNextNode):
     15        (WebCore):
     16        (WebCore::Node::traverseNextSibling):
     17        * dom/Node.h:
     18        (Node):
     19
    1202012-05-08  Hironori Bono  <hbono@chromium.org>
    221
  • trunk/Source/WebCore/WebCore.exp.in

    r116402 r116437  
    20972097__ZN7WebCore8Document22setAnimatingFullScreenEb
    20982098__ZNK7WebCore8Document9domWindowEv
     2099__ZNK7WebCore4Node16traverseNextNodeEPKS0_
    20992100#endif
    21002101
  • trunk/Source/WebCore/bindings/v8/RetainedDOMInfo.cpp

    r116402 r116437  
    3232#include "RetainedDOMInfo.h"
    3333
    34 #include "ContainerNode.h"
     34#include "Node.h"
    3535
    3636namespace WebCore {
  • trunk/Source/WebCore/dom/ContainerNode.h

    r116402 r116437  
    229229}
    230230
    231 inline Node* Node::traverseNextNode() const
    232 {
    233     if (firstChild())
    234         return firstChild();
    235     if (nextSibling())
    236         return nextSibling();
    237     const Node* node = this;
    238     while (node && !node->nextSibling())
    239         node = node->parentNode();
    240     if (UNLIKELY(!node))
    241         return 0;
    242     return node->nextSibling();
    243 }
    244 
    245 inline Node* Node::traverseNextNode(const Node* stayWithin) const
    246 {
    247     if (firstChild())
    248         return firstChild();
    249     if (UNLIKELY(this == stayWithin))
    250         return 0;
    251     if (nextSibling())
    252         return nextSibling();
    253     const Node* node = this;
    254     while (node && !node->nextSibling() && (!stayWithin || node->parentNode() != stayWithin))
    255         node = node->parentNode();
    256     if (UNLIKELY(!node))
    257         return 0;
    258     return node->nextSibling();
    259 }
    260 
    261 inline Node* Node::traverseNextSibling() const
    262 {
    263     if (nextSibling())
    264         return nextSibling();
    265     const Node* node = this;
    266     while (node && !node->nextSibling())
    267         node = node->parentNode();
    268     if (UNLIKELY(!node))
    269         return 0;
    270     return node->nextSibling();
    271 }
    272 
    273 inline Node* Node::traverseNextSibling(const Node* stayWithin) const
    274 {
    275     if (UNLIKELY(this == stayWithin))
    276         return 0;
    277     if (nextSibling())
    278         return nextSibling();
    279     const Node* node = this;
    280     while (node && !node->nextSibling() && (!stayWithin || node->parentNode() != stayWithin))
    281         node = node->parentNode();
    282     if (UNLIKELY(!node))
    283         return 0;
    284     return node->nextSibling();
    285 }
    286 
    287231typedef Vector<RefPtr<Node>, 11> NodeVector;
    288232
  • trunk/Source/WebCore/dom/Node.cpp

    r116402 r116437  
    10851085}
    10861086
     1087Node* Node::traverseNextNode(const Node* stayWithin) const
     1088{
     1089    if (firstChild())
     1090        return firstChild();
     1091    if (this == stayWithin)
     1092        return 0;
     1093    if (nextSibling())
     1094        return nextSibling();
     1095    const Node *n = this;
     1096    while (n && !n->nextSibling() && (!stayWithin || n->parentNode() != stayWithin))
     1097        n = n->parentNode();
     1098    if (n)
     1099        return n->nextSibling();
     1100    return 0;
     1101}
     1102
     1103Node* Node::traverseNextSibling(const Node* stayWithin) const
     1104{
     1105    if (this == stayWithin)
     1106        return 0;
     1107    if (nextSibling())
     1108        return nextSibling();
     1109    const Node *n = this;
     1110    while (n && !n->nextSibling() && (!stayWithin || n->parentNode() != stayWithin))
     1111        n = n->parentNode();
     1112    if (n)
     1113        return n->nextSibling();
     1114    return 0;
     1115}
     1116
    10871117Node* Node::traverseNextNodePostOrder() const
    10881118{
  • trunk/Source/WebCore/dom/Node.h

    r116419 r116437  
    432432    // argument is non-null, the traversal will stop once the specified node is reached.
    433433    // This can be used to restrict traversal to a particular sub-tree.
    434     Node* traverseNextNode() const;
    435     Node* traverseNextNode(const Node* stayWithin) const;
     434    Node* traverseNextNode(const Node* stayWithin = 0) const;
    436435
    437436    // Like traverseNextNode, but skips children and starts with the next sibling.
    438     Node* traverseNextSibling() const;
    439     Node* traverseNextSibling(const Node* stayWithin) const;
     437    Node* traverseNextSibling(const Node* stayWithin = 0) const;
    440438
    441439    // Does a reverse pre-order traversal to find the node that comes before the current one in document order
Note: See TracChangeset for help on using the changeset viewer.