mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 19:59:17 +00:00
LibJS/JIT: Annotate disassembly with bytecode information
This commit is contained in:
parent
9f78e56823
commit
112eadc863
Notes:
sideshowbarker
2024-07-17 07:35:03 +09:00
Author: https://github.com/skyrising
Commit: 112eadc863
Pull-request: https://github.com/SerenityOS/serenity/pull/21703
3 changed files with 86 additions and 4 deletions
|
@ -19,6 +19,7 @@ struct BytecodeMapping {
|
|||
|
||||
// Special block index for labels outside any blocks.
|
||||
static constexpr auto EXECUTABLE = NumericLimits<size_t>::max();
|
||||
static constexpr auto EXECUTABLE_LABELS = AK::Array { "entry"sv, "common_exit"sv };
|
||||
};
|
||||
|
||||
class NativeExecutable {
|
||||
|
@ -30,7 +31,10 @@ public:
|
|||
~NativeExecutable();
|
||||
|
||||
void run(VM&) const;
|
||||
void dump_disassembly() const;
|
||||
void dump_disassembly(Bytecode::Executable const& executable) const;
|
||||
BytecodeMapping const& find_mapping_entry(size_t native_offset) const;
|
||||
|
||||
ReadonlyBytes code_bytes() const { return { m_code, m_size }; }
|
||||
|
||||
private:
|
||||
void* m_code { nullptr };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue