Open Bug 1108711 Opened 10 years ago Updated 2 years ago

Add bytecode disassembler to the debugger

Categories

(DevTools :: Debugger, enhancement, P5)

x86_64
Linux
enhancement

Tracking

(Not tracked)

People

(Reporter: tromey, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

I've occasionally wished that the debugger had a built-in javascript disassembler. This would make debugging firefox itself a bit simpler sometimes.
Summary: add disassembler to the debugger → add bytecode disassembler to the debugger
We actually *just* talked about this at Mozlandia. Personally, I would really love to have multiple levels of disassembly: (1) Byte code w/ source note annotations inline. (2) MIR converted back to its "equivalent" JS code, but includes special forms for all the checks and stuff (h4writer has this implemented somewhere...) (3) The native code that Ion generates for the function.
(In reply to Nick Fitzgerald [:fitzgen] from comment #1) > We actually *just* talked about this at Mozlandia. > > Personally, I would really love to have multiple levels of disassembly: > > (1) Byte code w/ source note annotations inline. > > (2) MIR converted back to its "equivalent" JS code, but includes special > forms for all the checks and stuff (h4writer has this implemented > somewhere...) > > (3) The native code that Ion generates for the function. I would think (2) is by far the most niche. An optimized code decompiler has been hard to comprehend for me, from personal experience.
I would love to see this. This would be very helpful in debugging some of the breakpoint issues we have. Another feature I would particularly like to have is that selecting a line in a source highlights those bytecode offsets that the debugger thinks are entry points for those line.
Summary: add bytecode disassembler to the debugger → Add bytecode disassembler to the debugger
(In reply to Nick Fitzgerald [:fitzgen] from comment #1) > (2) MIR converted back to its "equivalent" JS code, but includes special > forms for all the checks and stuff (h4writer has this implemented > somewhere...) This is a raw prototype version of this: https://github.com/h4writer/ssa-to-js
See also bug 915267
This would still be nice-to-have; but low priority. Maybe just bug 915267 would probably be enough.
Priority: -- → P3
Product: Firefox → DevTools
Blocks: dbg-inspect
Priority: P3 → P5
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: