Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@hrydgard
Copy link
Owner

@hrydgard hrydgard commented Jun 7, 2024

Mainly just experimenting so far. There are some better wins to be had, but these are easy. These Opt* instructions will only be generated in the very last pass, and only for the IR interpreter - the IR Jits can do similar things themselves when generating native code and we don't want to have them handle more instructions.

part of #19143

Additionally, moves Downcount to the start of each block, saving us from one switch-dispatch per block execution.

Also adds a new optimization pass to take out some unnecessary loads after stores, seen in some games (likely some bad compiler..).

Overall, this seems to be a 5-7% speed boost. Possibly mostly due to the Downcount change...

@hrydgard hrydgard added the IRInterpreter Occurs with IR Interpreter but not with another CPU backend. label Jun 7, 2024
@hrydgard hrydgard added this to the v1.18.0 milestone Jun 7, 2024
@hrydgard hrydgard marked this pull request as ready for review June 7, 2024 21:11
@hrydgard hrydgard merged commit 27815c7 into master Jun 7, 2024
@hrydgard hrydgard deleted the ir-specialization branch June 7, 2024 21:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

IRInterpreter Occurs with IR Interpreter but not with another CPU backend.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant