[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373

oliver at apple.com oliver at apple.com
Thu Apr 8 01:57:55 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit 73c72f9611f4c18b3b88c76f69a5cf86e81fe1ec
Author: oliver at apple.com <oliver at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Wed Feb 24 04:27:46 2010 +0000

    2010-02-23  Oliver Hunt  <oliver at apple.com>
    
            Reviewed by Maciej Stachowiak.
    
            Web Inspector: Regression: r55027+: Inspector broken
            https://bugs.webkit.org/show_bug.cgi?id=35253
    
            op_get_by_id_getter_chain was not passing the correct this parameter.
            The bug was caused by incorrect use of baseCell instead of baseValue,
            baseValue contains the original object for the lookup (and hence the
            correct this object), baseCell is clobbered as part of walking the
            prototype chain.
    
            * interpreter/Interpreter.cpp:
            (JSC::Interpreter::privateExecute):
    2010-02-23  Oliver Hunt  <oliver at apple.com>
    
            Reviewed by Maciej Stachowiak.
    
            Web Inspector: Regression: r55027+: Inspector broken
            https://bugs.webkit.org/show_bug.cgi?id=35253
    
            Add thorough testing of getter access to hit the various
            possible caching scenarios.
    
            * fast/js/pic/cached-getter-setter-expected.txt:
            * fast/js/pic/cached-getter-setter.html:
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@55181 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog
index 75d228d..8226aaa 100644
--- a/JavaScriptCore/ChangeLog
+++ b/JavaScriptCore/ChangeLog
@@ -1,3 +1,19 @@
+2010-02-23  Oliver Hunt  <oliver at apple.com>
+
+        Reviewed by Maciej Stachowiak.
+
+        Web Inspector: Regression: r55027+: Inspector broken
+        https://bugs.webkit.org/show_bug.cgi?id=35253
+
+        op_get_by_id_getter_chain was not passing the correct this parameter.
+        The bug was caused by incorrect use of baseCell instead of baseValue,
+        baseValue contains the original object for the lookup (and hence the
+        correct this object), baseCell is clobbered as part of walking the
+        prototype chain.
+
+        * interpreter/Interpreter.cpp:
+        (JSC::Interpreter::privateExecute):
+
 2010-02-23  Gustavo Noronha Silva  <gns at gnome.org>
 
         Rubber-stamped by Dimitri Glazkov.
diff --git a/JavaScriptCore/interpreter/Interpreter.cpp b/JavaScriptCore/interpreter/Interpreter.cpp
index 6dbbcf9..8e05c12 100644
--- a/JavaScriptCore/interpreter/Interpreter.cpp
+++ b/JavaScriptCore/interpreter/Interpreter.cpp
@@ -2379,7 +2379,7 @@ JSValue Interpreter::privateExecute(ExecutionFlag flag, RegisterFile* registerFi
                             JSObject* getter = getterSetter->getter();
                             CallData callData;
                             CallType callType = getter->getCallData(callData);
-                            JSValue result = call(callFrame, getter, callType, callData, asObject(baseCell), ArgList());
+                            JSValue result = call(callFrame, getter, callType, callData, baseValue, ArgList());
                             CHECK_FOR_EXCEPTION();
                             callFrame->r(dst) = result;
                         } else
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 70a1738..f2d4bfe 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,16 @@
+2010-02-23  Oliver Hunt  <oliver at apple.com>
+
+        Reviewed by Maciej Stachowiak.
+
+        Web Inspector: Regression: r55027+: Inspector broken
+        https://bugs.webkit.org/show_bug.cgi?id=35253
+
+        Add thorough testing of getter access to hit the various
+        possible caching scenarios.
+
+        * fast/js/pic/cached-getter-setter-expected.txt:
+        * fast/js/pic/cached-getter-setter.html:
+
 2010-02-23  Enrica Casucci  <enrica at apple.com>
 
         Reviewed by Simon Fraser.
diff --git a/LayoutTests/fast/js/pic/cached-getter-setter-expected.txt b/LayoutTests/fast/js/pic/cached-getter-setter-expected.txt
index c0e092c..99c5019 100644
--- a/LayoutTests/fast/js/pic/cached-getter-setter-expected.txt
+++ b/LayoutTests/fast/js/pic/cached-getter-setter-expected.txt
@@ -6,6 +6,15 @@ PASS: o.x should be 2 and is.
 PASS: o.y should be 0 and is.
 PASS: o.y should be 1 and is.
 PASS: o.y should be 2 and is.
+PASS: testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0}) should be 10 and is.
+PASS: testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0, newProperty: 0}) should be 10 and is.
+PASS: testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0, newProperty2: 0}) should be 10 and is.
+PASS: testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0}) should be 10 and is.
+PASS: testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0, newProperty: 0}) should be 10 and is.
+PASS: testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0, newProperty2: 0}) should be 10 and is.
+PASS: testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0}) should be 10 and is.
+PASS: testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0, newProperty: 0}) should be 10 and is.
+PASS: testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0, newProperty2: 0}) should be 10 and is.
 PASS: getX(o) should be 3 and is.
 PASS: getX(o) should be 3 and is.
 
diff --git a/LayoutTests/fast/js/pic/cached-getter-setter.html b/LayoutTests/fast/js/pic/cached-getter-setter.html
index e50d9b1..f4494f1 100644
--- a/LayoutTests/fast/js/pic/cached-getter-setter.html
+++ b/LayoutTests/fast/js/pic/cached-getter-setter.html
@@ -52,6 +52,43 @@ you'll see a series of PASS messages below.
         }
     })();
 
+    function testGetter(o) {
+        var result;
+        for (var i = 0; i < 10; i++)
+            result = o.getter;
+        return result;
+    }
+    function testProtoGetter(o) {
+        var result;
+        for (var i = 0; i < 10; i++)
+            result = o.getter;
+        return result;
+    }
+    function testProtoChainGetter(o) {
+        var result;
+        for (var i = 0; i < 10; i++)
+            result = o.getter;
+        return result;
+    }
+    shouldBe(testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0}), 
+            "testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0})", 10);
+    shouldBe(testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0, newProperty: 0}), 
+            "testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0, newProperty: 0})", 10);
+    shouldBe(testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0, newProperty2: 0}), 
+            "testGetter({__proto__: {count: 'FAIL'}, get getter(){ return ++this.count; }, count: 0, newProperty2: 0})", 10);
+    shouldBe(testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0}), 
+            "testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0})", 10);
+    shouldBe(testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0, newProperty: 0}), 
+            "testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0, newProperty: 0})", 10);
+    shouldBe(testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0, newProperty2: 0}), 
+            "testProtoGetter({__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}, count: 0, newProperty2: 0})", 10);
+    shouldBe(testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0}), 
+            "testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0})", 10);
+    shouldBe(testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0, newProperty: 0}), 
+            "testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0, newProperty: 0})", 10);
+    shouldBe(testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0, newProperty2: 0}),
+            "testProtoChainGetter({__proto__: {__proto__: {count: 'FAIL', get getter(){ return ++this.count; }}}, count: 0, newProperty2: 0})", 10);
+
     (function() {
         var o = {
             x : 1,

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list