Skip to content
This repository was archived by the owner on Jan 15, 2025. It is now read-only.

Comments

Restrict offsets to index type's range in validation#79

Merged
sbc100 merged 3 commits intoWebAssembly:mainfrom
bvisness:offset-limit
Sep 5, 2024
Merged

Restrict offsets to index type's range in validation#79
sbc100 merged 3 commits intoWebAssembly:mainfrom
bvisness:offset-limit

Conversation

@bvisness
Copy link
Collaborator

@bvisness bvisness commented Aug 20, 2024

This PR adds validation of memarg.offset to ensure that loads and stores for a 32-bit memory cannot have a 64-bit offset. Execution semantics are unaffected.

Resolves #76.

@bvisness
Copy link
Collaborator Author

Yet again I have no idea what is wrong with the PDF build.

@rossberg
Copy link
Member

rossberg commented Aug 20, 2024

Well, the error says it all: \lt is not a defined Latex macro. You want to spell it <.

Copy link
Member

@rossberg rossberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good modulo <

@backes
Copy link
Member

backes commented Aug 30, 2024

Can you please add tests for this? Otherwise it's easy for engine to overlook this restriction and be like "we pass all tests, hence we fully implement memory64".

@bvisness
Copy link
Collaborator Author

Yes, I have a personal todo item to add spec tests for all the recent spec changes. I'll create a GitHub issue today to make that more visible for others though. Thanks for the reminder.

@sbc100
Copy link
Member

sbc100 commented Sep 5, 2024

Is this ready to land?

@bvisness
Copy link
Collaborator Author

bvisness commented Sep 5, 2024

Should be, assuming you're comfortable with tests coming later.

@sbc100 sbc100 merged commit 940398c into WebAssembly:main Sep 5, 2024
@bvisness bvisness deleted the offset-limit branch September 5, 2024 16:13
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Restricting offsets to match the index type

4 participants