Skip to content

Intern functions once in array-fill ops - #13524

Merged
alexcrichton merged 1 commit into
bytecodealliance:mainfrom
alexcrichton:intern-less
Jun 1, 2026
Merged

alexcrichton merged 1 commit into
bytecodealliance:mainfrom
alexcrichton:intern-less

Conversation

@alexcrichton

Copy link
Copy Markdown
Member

This commit updates the handling of the translate_entity_fill function within Cranelift translation to ensure that when a funcref is used to fill an array it's only intern'd once instead of O(size of fill). This can make all the variants of array.{fill,new,new_default} etc much faster for large arrays of functions.

Closes #13521

This commit updates the handling of the `translate_entity_fill` function
within Cranelift translation to ensure that when a `funcref` is used to
fill an array it's only intern'd once instead of O(size of fill). This
can make all the variants of `array.{fill,new,new_default}` etc much
faster for large arrays of functions.

Closes bytecodealliance#13521
@alexcrichton
alexcrichton requested a review from fitzgen June 1, 2026 16:31
@alexcrichton
alexcrichton requested review from a team as code owners June 1, 2026 16:31

@fitzgen fitzgen left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@alexcrichton
alexcrichton added this pull request to the merge queue Jun 1, 2026
Merged via the queue into bytecodealliance:main with commit 7e56e24 Jun 1, 2026
51 checks passed
@alexcrichton
alexcrichton deleted the intern-less branch June 1, 2026 17:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Computationally large element segments timing out during fuzzing

2 participants