Skip to content

Conversation

@Amanieu
Copy link
Contributor

@Amanieu Amanieu commented May 24, 2023

When a dedicated scratch register is provided by the environment, the redundant move eliminator needs to assume that this register can be clobbered by any instruction.

This register can't be specified as a clobber because it is also used by jump instructions which cannot have operands.

When a dedicated scratch register is provided by the environment, the
redundant move eliminator needs to assume that this register can be
clobbered by any instruction.

This register can't be specified as a clobber because it is also used by
jump instructions which cannot have operands.
@Amanieu
Copy link
Contributor Author

Amanieu commented May 24, 2023

This wasn't caught by the fuzzer because our fuzzing setup doesn't use a dedicated scratch register. I could change that but then we wouldn't be testing the case where regalloc2 needs to find a scratch register on its own.

Copy link
Member

@cfallin cfallin left a comment

Choose a reason for hiding this comment

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

Thanks! Do you need a point release for this?

@cfallin cfallin merged commit 64df42b into bytecodealliance:main May 25, 2023
@Amanieu
Copy link
Contributor Author

Amanieu commented May 25, 2023

Thanks! Do you need a point release for this?

That's not necessary since I'm currently using a fork that includes the changes from #131. Once that is resolved I'd like to switch back to using mainline regalloc2.

@elliottt elliottt mentioned this pull request May 31, 2023
@Amanieu Amanieu deleted the redundant-scratch branch November 24, 2023 08:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants