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

ARMeilleure: replace else-ifs with switch statements #124

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

LukeWarnut
Copy link
Contributor

This PR replaces several if/else if/else statements with switch statements across ARMeilleure. This should result in a very minor performance increase in some CPU/PPTC-related tasks.

I've tested several games with no issues, but further testing is welcome.

@github-actions github-actions bot added the cpu An issue with ARM emulation or the JIT label Oct 31, 2024
@Digote
Copy link
Contributor

Digote commented Nov 6, 2024

Great job! I’ll add some tests to check if there’s been any regression.

Setup

Ryzen 5 5600
32GB - 3200Mhz
RTX 4060ti - Driver 566.03


Pokémon Legends: Arceus(1.1.1.)

MAIN(1.2.72)

Main.1.mp4

PR-124

Pr.124.mp4

I will add more games later.

MAINTAINER EDIT: These videos are h.265 encoded and seemingly only viewable in Chromium-based browsers, or via downloading & watching with a program that can handle h.265.

EDIT 2: I uploaded it again with h.264

@Julienraptor01
Copy link

Julienraptor01 commented Nov 6, 2024

MAINTAINER EDIT: These videos are h.265 encoded and seemingly only viewable in Chromium-based browsers, or via downloading & watching with a program that can handle h.265.

Note

The problem is actually not the H.265, but the Microsoft Media Foundation (MF) CDM (Content Decryption Module) DRM
The video was likely recorded with a Microsoft tool instead of smth clean like OBS

@extherian
Copy link
Contributor

It would be great to see this merged, but we're still waiting on the sparse jit pr, which hasn't yet been tested to Greem's satisfaction, I imagine this will have to be tested just as thoroughly. I will do another reddit testing thread once the sparse jit has been merged.

@Digote
Copy link
Contributor

Digote commented Nov 6, 2024

MAINTAINER EDIT: These videos are h.265 encoded and seemingly only viewable in Chromium-based browsers, or via downloading & watching with a program that can handle h.265.

Note

The problem is actually not the H.265, but the Microsoft Media Foundation (MF) CDM (Content Decryption Module) DRM The video was likely recorded with a Microsoft tool instead of smth clean like OBS

Very strange, I used OBS Studio to record and Handbrake to convert it to h.265 and reduce the file size.

@sokennethwasall
Copy link

Tested Super Smash Bro's & Echos of Wisdom on M4 Max Macbook Pro. Both seemed to run well

@bangfire
Copy link

Have you profiled this to check that the JIT is not already performing any relevant optimizations or is this just something that is suggested by IDE? As most of these contain very few potential branches, I'm unsure if the runtime would not simply lower this into identical IL.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cpu An issue with ARM emulation or the JIT
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants