mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 01:35:08 +02:00
Teach the Rust bytecode generator to treat the synthetic entry GetLexicalEnvironment as a removable prologue load. We still model reg4 as the saved entry lexical environment during codegen, but assemble() now deletes that load when no emitted instruction refers to the saved environment register. This keeps the semantics of unwinding and environment restoration intact while letting empty functions and other simple bodies start at their first real instruction.
32 lines
695 B
Plaintext
32 lines
695 B
Plaintext
$e3bb9811 argument-variables.js:12:1
|
|
Registers: 8
|
|
Blocks: 1
|
|
Constants:
|
|
[0] = Undefined
|
|
[1] = Int32(1)
|
|
[2] = Int32(2)
|
|
|
|
block0:
|
|
[ 0] GetGlobal dst:reg6, `identity`
|
|
[ 18] Call dst:reg5, callee:reg6, this_value:Undefined, identity, arguments:[Int32(1)]
|
|
[ 40] GetGlobal dst:reg7, `swap`
|
|
[ 58] Call dst:reg6, callee:reg7, this_value:Undefined, swap, arguments:[Int32(1), Int32(2)]
|
|
[ 80] End value:reg6
|
|
|
|
|
|
identity$7176ad76 argument-variables.js:5:5
|
|
Registers: 5
|
|
Blocks: 1
|
|
|
|
block0:
|
|
[ 0] Return value:arg0
|
|
|
|
|
|
swap$0ff1f8d6 argument-variables.js:9:5
|
|
Registers: 6
|
|
Blocks: 1
|
|
|
|
block0:
|
|
[ 0] Add dst:reg5, lhs:arg1, rhs:arg0
|
|
[ 10] Return value:reg5
|