Closed Bug 1724119 Opened 3 years ago Closed 2 years ago

Avoid using pinned atoms in JS debugger

Categories

(Core :: JavaScript Engine, task, P2)

task

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: tcampbell, Unassigned, Mentored)

References

(Blocks 1 open bug)

Details

(Keywords: good-first-bug)

There are still a few places in the JS debugger that use PinAtom when we should consider it deprecated.

This is not ideal because a "pinned" atom string is kept alive forever and requires deprecated GC machinery to do so. Instead, if there is a finite set we pin here, they should be made "well-known" atoms built into spidermonkey. These still live forever, but with less complexity.

  1. Make sure you can build spidermonkey using this guide: https://firefox-source-docs.mozilla.org/js/build.html
  2. Ensure the few strings we need are in the CommonPropertyNames.h list.
  3. Update DebuggerEnvironment::CallData::typeGetter to use cx->names().... similar to here
  4. Make sure ./mach jit-tests debug passes on your computer after these fixes.

Additionally, DebuggerEnvironment::CallData::scopeKindGetter could be fixed in a similar way too.

Severity: -- → S3
Priority: -- → P2

Hey there! 👋 Grabbing this issue. I work on the desktop front-end, and I'd like to get a little bit of experience working with JS engine C++. Feel free to steal this back if it gets prioritized up, or if someone's already working on it.

Assignee: nobody → jhirsch

This good-first-bug hasn't had any activity for 2 months, it is automatically unassigned.
For more information, please visit auto_nag documentation.

Assignee: jhirsch → nobody

This has been fixed in other bugs.

Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.