Closed Bug 906284 Opened 7 years ago Closed 7 years ago

Differential Testing: Different output message involving "use strict"

Categories

(Core :: JavaScript Engine, defect, major)

x86_64
macOS
defect
Not set
major

Tracking

()

RESOLVED FIXED
mozilla26

People

(Reporter: gkw, Assigned: jandem)

References

(Blocks 2 open bugs)

Details

(Keywords: testcase)

Attachments

(2 files)

try {
    (function() {
        "use strict"
        print(new f)
        function f() {
            h = {}
        }
    })()
} catch (e) {}

shows nothing on a 64-bit debug deterministic threadsafe js shell on m-c rev 8ad1e4c838c8, but shows the following with --ion-eager:

[object Object]

Setting needinfo for jandem as previously requested. (Pass in the testcase as a CLI argument to reproduce)


function f() {
    "use strict"
    v = undefined
}
try {
    new f
} catch (e) {
    print('FOO')
}

is another similar testcase that shows "FOO" without any CLI arguments, but shows nothing with --ion-eager.
Flags: needinfo?(jdemooij)
Attached patch PatchSplinter Review
Thanks Gary, another nice find!

Bug 864218 changed SetProperty's last argument from "bool isSetName" to "int jsop", but didn't update the call in SetPropertyIC::update. I checked and this is the only place we have to fix.
Assignee: general → jdemooij
Status: NEW → ASSIGNED
Attachment #792151 - Flags: review?(bhackett1024)
Flags: needinfo?(jdemooij)
Attachment #792151 - Flags: review?(bhackett1024) → review+
Eric found the same bug and we decided it would be good to change the argument from int to JSOp or jsbytecode *. This patch does the latter. Applies on top of the previous patch.
Attachment #792692 - Flags: review?(efaustbmo)
Comment on attachment 792692 [details] [diff] [review]
Pass jsbytecode * instead of int

Review of attachment 792692 [details] [diff] [review]:
-----------------------------------------------------------------

r=me. Thanks for doing this.
Attachment #792692 - Flags: review?(efaustbmo) → review+
https://hg.mozilla.org/mozilla-central/rev/f620fcca5ff1
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla26
Good news: this patch seemed to have caused an 11% speedup on asmjs-ubench-life, 3% speedup on asmjs-ubench-fasta, and 10% on asmjs-ubench-memops.
You need to log in before you can comment on or make changes to this bug.