LibJS: Make async functions & generators faster with helper types

Instead of returning internal generator results as ordinary JS::Objects
with properties, we now use GeneratorResult and CompletionCell which
both inherit from Cell directly and allow efficient access to state.

1.59x speedup on JetStream3/lazy-collections.js :^)
This commit is contained in:
Andreas Kling 2025-03-31 09:32:39 +01:00 committed by Alexander Kalenik
commit a0bb31f7a0
Notes: github-actions[bot] 2025-04-01 00:31:35 +00:00
12 changed files with 259 additions and 93 deletions

View file

@ -57,6 +57,7 @@
O(GetByValue) \
O(GetByValueWithThis) \
O(GetCalleeAndThisFromEnvironment) \
O(GetCompletionFields) \
O(GetGlobal) \
O(GetImportMeta) \
O(GetIterator) \
@ -131,6 +132,7 @@
O(RightShift) \
O(ScheduleJump) \
O(SetArgument) \
O(SetCompletionType) \
O(SetLexicalBinding) \
O(SetVariableBinding) \
O(StrictlyEquals) \