• the

    E.getAddressOf(new Uint32Array([
                    this.idx,
                    this.next,
                    offset,
                    stepping
                ]),
    

    will not last long, the array is not referenced anywhere so will be freed soon, assign it to some variable. The E.getAddressOf just gives memory address, it does not care about allocation.

  • Fanoush probably has a point here, regarding the temporary array getting cleaned up in garbage collection.
    Instead I have used a global auxiliary Uint32Array large enough to be in a flat memory area for passing in additional parameters. Not very elegant but works...

About

Avatar for user113695 @user113695 started