Closed Bug 717208 Opened 13 years ago Closed 13 years ago

sometimes __noSuchMethod__ is not found out and throw Exception: func is not a function

Categories

(Core :: JavaScript Engine, defect)

12 Branch
x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla12

People

(Reporter: teramako, Assigned: bhackett1024)

References

Details

(Keywords: regression)

Attachments

(2 files)

User Agent: Mozilla/5.0 (Windows NT 5.1; rv:12.0a1) Gecko/20120110 Firefox/12.0a1
Build ID: 20120110031111

Steps to reproduce:

main code is here:

var a = {
    __noSuchMethod__: function () {c++;}
};
var e = [];
var c = 0;
for (var i = 0; i < 100; i++) {
    try {
        a.b();
    } catch (ex) {
        e.push([i, ex.message]);
    }
}

e.push(c);
Services.console.logStringMessage(JSON.stringify(e));


1. install the attempted xpi
2. disable and enable the extension (I don't know why the problem is not occured at the first installed)




Actual results:

following messages are shown in Error Console

Test: start
[[39,"a.b is not a function"],[80,"a.b is not a function"],[81,"a.b is not a function"],97]


Expected results:

messages should be shown any times:

Test: start
[100]
This problem is occured since Firefox 12.0a1 (2012-01-10)
Regression window(m-c)
Works:
http://hg.mozilla.org/mozilla-central/rev/9a230265bad5
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0a1) Gecko/20120108 Firefox/12.0a1 ID:20120108060523
Fails:
http://hg.mozilla.org/mozilla-central/rev/c713003d3226
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0a1) Gecko/20120110 Firefox/12.0a1 ID:20120110031111
Pushlog:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=9a230265bad5&tochange=c713003d3226



Regression window(m-i)
Works:
http://hg.mozilla.org/integration/mozilla-inbound/rev/b6c60a28454d
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0a1) Gecko/20120107 Firefox/12.0a1 ID:20120109062923
Fails:
http://hg.mozilla.org/integration/mozilla-inbound/rev/7ab4f1ebc7cc
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0a1) Gecko/20120109 Firefox/12.0a1 ID:20120109063028
Pushlog:
http://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=b6c60a28454d&tochange=7ab4f1ebc7cc

Triggered by:
7ab4f1ebc7cc	Brian Hackett — Backout 54cd89b0f1fa (bug 712714 backout). Talos will probably report fake regressions for this patch, do not back out for this reason.
Blocks: 712714
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: regression
Attached patch patchSplinter Review
I didn't confirm this fixes the example, but when generating an IC for the CALLPROP the access was treated as a generic property access and didn't go through the logic used for noSuchMethod.  The patch has a shell testcase which exhibited the bad behavior.
Assignee: general → bhackett1024
Attachment #587878 - Flags: review?(dvander)
Attachment #587878 - Flags: review?(dvander) → review+
Blocks: 717319
Is it at all plausible that this patch would have improved the Talos V8 numbers?  The regression bot claims it did...
(In reply to Boris Zbarsky (:bz) from comment #5)
> Is it at all plausible that this patch would have improved the Talos V8
> numbers?  The regression bot claims it did...

Not legitimately, in the same way that bug 712714 didn't actually regress V8 either.  At least things are back in balance I guess.
https://hg.mozilla.org/mozilla-central/rev/16f0d80b3137
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla12
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: