Skip to content

Commit c6026a3

Browse files
ncrucesalehander92
authored andcommitted
Fix typo in memory fill. (wazero#2396)
Signed-off-by: Nuno Cruces <[email protected]>
1 parent 64d55c9 commit c6026a3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/engine/wazevo/frontend/lower.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -770,7 +770,7 @@ func (c *Compiler) lowerCurrentOpcode() {
770770
dstAddr := builder.AllocateInstruction().AsIadd(addr, loopVar).Insert(builder).Return()
771771

772772
// chunk := ((i - 1) & 8191) + 1
773-
mask := builder.AllocateInstruction().AsIconst64(16383).Insert(builder).Return()
773+
mask := builder.AllocateInstruction().AsIconst64(8191).Insert(builder).Return()
774774
tmp1 := builder.AllocateInstruction().AsIsub(loopVar, one).Insert(builder).Return()
775775
tmp2 := builder.AllocateInstruction().AsBand(tmp1, mask).Insert(builder).Return()
776776
chunk := builder.AllocateInstruction().AsIadd(tmp2, one).Insert(builder).Return()

0 commit comments

Comments
 (0)