Unreviewed, rolling out r144726.
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 7 Mar 2013 05:49:15 +0000 (05:49 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 7 Mar 2013 05:49:15 +0000 (05:49 +0000)
http://trac.webkit.org/changeset/144726
https://bugs.webkit.org/show_bug.cgi?id=111681

caused performance regression for Dromaeo attribute tests.
(Requested by arpitab on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2013-03-06

Source/WebCore:

* dom/Element.h:
(WebCore::ElementData::getAttributeItemIndex):

LayoutTests:

* fast/dom/Element/getAttribute-case-insensitivity-expected.txt: Removed.
* fast/dom/Element/getAttribute-case-insensitivity.html: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@145036 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/fast/dom/Element/getAttribute-case-insensitivity-expected.txt [deleted file]
LayoutTests/fast/dom/Element/getAttribute-case-insensitivity.html [deleted file]
Source/WebCore/ChangeLog
Source/WebCore/dom/Element.h

index c5f5a13..ec7e920 100644 (file)
@@ -1,3 +1,15 @@
+2013-03-06  Sheriff Bot  <webkit.review.bot@gmail.com>
+
+        Unreviewed, rolling out r144726.
+        http://trac.webkit.org/changeset/144726
+        https://bugs.webkit.org/show_bug.cgi?id=111681
+
+        caused performance regression for Dromaeo attribute tests.
+        (Requested by arpitab on #webkit).
+
+        * fast/dom/Element/getAttribute-case-insensitivity-expected.txt: Removed.
+        * fast/dom/Element/getAttribute-case-insensitivity.html: Removed.
+
 2013-03-05  Kinuko Yasuda  <kinuko@chromium.org>
 
         File.lastModifiedDate() should return the current date/time if the file date/time is not available
diff --git a/LayoutTests/fast/dom/Element/getAttribute-case-insensitivity-expected.txt b/LayoutTests/fast/dom/Element/getAttribute-case-insensitivity-expected.txt
deleted file mode 100644 (file)
index dccbb4e..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-Test for Bugzilla bug: 105713: getAttribute does not behave correctly for mixed-case attributes on HTML testements.
-This test verifies that the getAttribute() and the getAttributeNode() APIs convert the passed attribute name to lowercase before comparing against existing attributes.
-
-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-
-PASS test.getAttribute('NEWATTR') is 'PASS'
-PASS test.getAttributeNode('NEWATTR').value is 'PASS'
-PASS test.getAttributeNS(null, 'NEWATTR') is 'FAIL'
-PASS test.getAttribute('newattr') is 'PASS'
-PASS test.getAttributeNode('newattr').value is 'PASS'
-PASS test.getAttributeNS(null, 'newattr') is 'PASS'
-PASS successfullyParsed is true
-
-TEST COMPLETE
-
diff --git a/LayoutTests/fast/dom/Element/getAttribute-case-insensitivity.html b/LayoutTests/fast/dom/Element/getAttribute-case-insensitivity.html
deleted file mode 100644 (file)
index 728b3d4..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-<html>
-<head>
-<script src="../../js/resources/js-test-pre.js"></script>
-<script>
-function runTest()
-{
-    description("This test verifies that the getAttribute() and the getAttributeNode() APIs convert the passed attribute name to lowercase before comparing against existing attributes.");
-    
-    var test = document.getElementById("test");
-    test.setAttributeNS(null, "NEWATTR", "FAIL");
-    test.setAttributeNS(null, "newattr", "PASS");
-    
-    if (window.testRunner) {
-        shouldBe("test.getAttribute('NEWATTR')", "'PASS'");
-        shouldBe("test.getAttributeNode('NEWATTR').value", "'PASS'");
-        shouldBe("test.getAttributeNS(null, 'NEWATTR')", "'FAIL'");
-        shouldBe("test.getAttribute('newattr')", "'PASS'");
-        shouldBe("test.getAttributeNode('newattr').value", "'PASS'");
-        shouldBe("test.getAttributeNS(null, 'newattr')", "'PASS'");
-    
-        isSuccessfullyParsed();
-    }
-}
-</script>
-</head>
-<body onload="runTest()">
-<div>Test for Bugzilla bug:<a href="https://bugs.webkit.org/show_bug.cgi?id=105713"> 105713:</a>  getAttribute does not behave correctly for mixed-case attributes on HTML testements.</div>
-<div id="test"></div>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
\ No newline at end of file
index fce878b..f09c4db 100644 (file)
@@ -1,3 +1,15 @@
+2013-03-06  Sheriff Bot  <webkit.review.bot@gmail.com>
+
+        Unreviewed, rolling out r144726.
+        http://trac.webkit.org/changeset/144726
+        https://bugs.webkit.org/show_bug.cgi?id=111681
+
+        caused performance regression for Dromaeo attribute tests.
+        (Requested by arpitab on #webkit).
+
+        * dom/Element.h:
+        (WebCore::ElementData::getAttributeItemIndex):
+
 2013-03-04  Kinuko Yasuda  <kinuko@chromium.org>
 
         File.lastModifiedDate() should return the current date/time if the file date/time is not available
index c3046fb..4988b1d 100644 (file)
@@ -941,7 +941,7 @@ inline size_t ElementData::getAttributeItemIndex(const AtomicString& name, bool
     for (unsigned i = 0; i < len; ++i) {
         const Attribute* attribute = attributeItem(i);
         if (!attribute->name().hasPrefix()) {
-            if ((shouldIgnoreAttributeCase ? name.lower() : name) == attribute->localName())
+            if (name == attribute->localName())
                 return i;
         } else
             doSlowCheck = true;