]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: use 32-bit function index on Wasm
authorCherry Mui <cherryyz@google.com>
Fri, 30 Aug 2024 21:24:27 +0000 (17:24 -0400)
committerCherry Mui <cherryyz@google.com>
Wed, 16 Jul 2025 14:15:29 +0000 (07:15 -0700)
Following CL 567896, this is one more place we used only 16 bits
for the function index. Change it to load 32 bits.

For #64856.

Change-Id: I66a78c086e67165604053313751c097a70c50ba9
Reviewed-on: https://go-review.googlesource.com/c/go/+/609118
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
src/runtime/asm_wasm.s

index 751bf0aec727d6d3ef3dd12c7ff0163e78d08c80..85aa52e0f793c328a0d4f5de677b3431d3f9b87b 100644 (file)
@@ -532,7 +532,7 @@ TEXT wasm_pc_f_loop(SB),NOSPLIT,$0
                        Get SP
                        I32Const $8
                        I32Sub
-                       I32Load16U $2 // PC_F
+                       I32Load $2 // PC_F
 
                        CallIndirect $0
                        Drop
@@ -568,7 +568,7 @@ outer:
                        Get SP
                        I32Const $8
                        I32Sub
-                       I32Load16U $2 // PC_F
+                       I32Load $2 // PC_F
                        Tee R2
 
                        Get R0