Closed Bug 643565 Opened 13 years ago Closed 11 years ago

Analyze v8-crypto performance

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: dmandelin, Assigned: dmandelin)

References

Details

Attachments

(1 file)

We do fairly well with tracing, but v8/nocs is 2x faster than our mjit. Why?
Attached file Profiler output
The 2x difference given in comment 0 is for 64-bit, which means that it actually compares SM/x64 with v8/nocs/x86. What it means is that the code we generate for 64-bit is not as good as 32-bit, but we already knew that.

On 32-bit Linux both ways, we are only 12% slower than v8/nocs here. I suspect most of that difference is captured by this microbenchmark:

    function f() {
        for (var i = 0; i < 6600000; ++i) {
            var n = 12;
            while (--n) {
            }
        }
    }

    var t0 = new Date;
    f();
    print(new Date - t0);

v8/nocs is 4x faster than js -a -m on this. If I take out the inner loop and instead run the outer loop 12x as many iterations, they are 2x faster. So, we have problems with our basic loop performance, which seem to get worse with nested loops. We know that |i++| and such are deoptimized; it might be just that, and maybe the problem bites us harder with nested loops.
We're pretty much on par with v8 for the microbenchmark here, and more recent analysis is happening in bug 768572.

Filter on jm-cleanup.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: