Closed Bug 1820605 Opened 2 years ago Closed 2 years ago

Add --enable-ic-frame-pointers

Categories

(Core :: JavaScript Engine: JIT, enhancement, P1)

enhancement

Tracking

()

RESOLVED FIXED
113 Branch
Tracking Status
firefox113 --- fixed

People

(Reporter: jrmuizel, Assigned: iain)

References

(Blocks 2 open bugs)

Details

(Whiteboard: [sp3] )

Attachments

(4 files)

This means we'll attribute time spent in them to the caller's caller instead of the caller when looking at a JS only profile.

There's an example here: https://share.firefox.dev/3KXgZkz.

  • a bunch of IC's have IC: TrialInline as their caller when it should likely be Baseline: filter or Baseline: map

jandem suggests that we could have a mode to add frame pointer epilogue/prologue code to baseline ICs

and iain says:
If it's just a mode for profiling, maybe we could make it 64-bit only and dedicate a separate register for the baseline frame pointer
So rbp would point to the stub frame, and (say) r14 would point to the baseline frame
It's hard to make it work on 32 bit x86 because we're already so short on registers

Whiteboard: [sp3]
Blocks: 1820627

The severity field is not set for this bug.
:willyelm, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(wmedina)
Assignee: nobody → iireland
Severity: -- → N/A
Type: defect → enhancement
Flags: needinfo?(wmedina)
Priority: -- → P1
Summary: IC are missing frame pointers → Add --enable-ic-frame-pointers
Duplicate of this bug: 1823415

This interferes with frame pointers and is only being used for a single op. Given the overhead of a VM call, doing a tail call here doesn't seem worthwhile.

Depends on D173386

These two encodings are equivalent, but the perf team's patches to perf are built around the one that LLVM uses. We can simplify things by changing our encoding.

Unfortunately we have some tests that hardcode specific encodings that have to be updated. Tested on try for both Linux and Windows.

Depends on D173388

Attachment #9324597 - Attachment description: Bug 1820605: Remove BaselineCacheIRCompiler::tailCallVM r=jandem → Bug 1820605: Remove BaselineCacheIRCompiler::tailCallVM r=jandem!
Attachment #9324598 - Attachment description: Bug 1820605: Add --enable-ic-frame-pointers r=jandem → Bug 1820605: Add --enable-ic-frame-pointers r=jandem!
Attachment #9324599 - Attachment description: Bug 1820605: Optionally emit frame pointers in baseline ICs r=jandem → Bug 1820605: Optionally emit frame pointers in baseline ICs r=jandem!
Attachment #9324600 - Attachment description: Bug 1820605: Adjust encoding to match LLVM r=jandem → Bug 1820605: Adjust encoding to match LLVM r=jandem!
Pushed by iireland@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/32227614c7f1 Remove BaselineCacheIRCompiler::tailCallVM r=jandem https://hg.mozilla.org/integration/autoland/rev/d5c403a4e05f Add --enable-ic-frame-pointers r=jandem https://hg.mozilla.org/integration/autoland/rev/4ae02092a204 Optionally emit frame pointers in baseline ICs r=jandem https://hg.mozilla.org/integration/autoland/rev/6d97efe0c291 Adjust encoding to match LLVM r=jandem
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: