close
Skip to content

Bindings: Expect memory growth when lowering references - #2568

Merged
dcodeIO merged 1 commit into
mainfrom
issue-2553
Nov 16, 2022
Merged

Bindings: Expect memory growth when lowering references#2568
dcodeIO merged 1 commit into
mainfrom
issue-2553

Conversation

@dcodeIO

@dcodeIO dcodeIO commented Nov 16, 2022

Copy link
Copy Markdown
Member

Fixes #2553 by using a helper function when lowering (what's typically) another lowering to memory:

new Uint32Array(memory.buffer)[pointer >>> 2] = __lowerXY(...);
// ->
__store_ref(pointer, __lowerXY(...));

Changes evaluation order so the LHS view is not invalidated by memory growth in the RHS before the store is performed.

  • I've read the contributing guidelines
  • I've added my name and email to the NOTICE file

@dcodeIO
dcodeIO merged commit 8ae086d into main Nov 16, 2022
@HerrCai0907
HerrCai0907 deleted the issue-2553 branch October 17, 2023 09:00
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.

Uncaught Error: Element type must be nullable if array is holey in ~lib/array.ts:118:40

1 participant