Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected behavior on fast interpreter mode #3402

Closed
erxiaozhou opened this issue May 8, 2024 · 2 comments
Closed

Unexpected behavior on fast interpreter mode #3402

erxiaozhou opened this issue May 8, 2024 · 2 comments
Labels
bug Something isn't working fast interpreter fixed

Comments

@erxiaozhou
Copy link

Subject of the issue

WAMR on fast interpreter mode raises an unexpected exception.

Test case

tt_finterp_exceptionx.zip

Your environment

  • Host OS: Ubuntu 20.04
  • Commit Id: 1c2a8fc

Steps to reproduce

  1. build WAMR on fast interpreter mode
  2. execute the command
iwasm --heap-size=0 -f "to_test" <test_case>

Expected behavior

No exception

0x2d0:i64

Actual behavior

An exception

Exception: integer overflow
@wenyongh
Copy link
Contributor

@erxiaozhou thanks for reporting the issue, please try #3434.

@wenyongh wenyongh added bug Something isn't working fixed fast interpreter labels May 14, 2024
wenyongh added a commit that referenced this issue May 15, 2024
When copying two cells from src offsets to dst offsets in RECOVER_BR_INFO,
the offsets may be overlapped and the src data may be overwritten, use
GET_I64_FROM_ADDR and then SET_I64_FROM_ADDR instead to resolve it.

And handling VALUE_TYPE_FUNCREF/VALUE_TYPE_EXTERNREF for opcode
local.set and local.tee when reference types feature is enabled.

This PR fixes issue #3401 and #3402.
@wenyongh
Copy link
Contributor

Close the issue since it was fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fast interpreter fixed
Projects
None yet
Development

No branches or pull requests

2 participants