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

Running Blue Revolver on VF2 leads to OOM #763

Closed
ksco opened this issue May 5, 2023 · 17 comments
Closed

Running Blue Revolver on VF2 leads to OOM #763

ksco opened this issue May 5, 2023 · 17 comments

Comments

@ksco
Copy link
Collaborator

ksco commented May 5, 2023

Reproduce:

  1. Download [experimental] bluerevolver_v051_demo_linux.tar.gz from https://woofycakes.itch.io/blue-revolver-v05
  2. Uncompress it and run box64 bin/love64 bin/game.love (with gl4es and emulated SDL)

The game seems running fine, but memory usage will grow at a rate of 1GB/s until it gets killed. I already tried BOX64_DYNAREC=0, no help.

@xctan has run it on a native machine, and the memory usage is normal.

@ptitSeb
Copy link
Owner

ptitSeb commented May 5, 2023

interresting. I'll check, thanks for the details.

@xctan
Copy link
Contributor

xctan commented May 5, 2023

I tried this game with 0e14d42 in qemu, the game crashed after entering gameplay (always press z without selecting other options), and the memory footprint was kept below 1 GB.
image

@ksco
Copy link
Collaborator Author

ksco commented May 5, 2023

0e14d42 is two more commits away from the latest main, I've tried, also leads to OOM. So not the last two commits, but QEMU and SBC do behave inconsistently on this...

@ptitSeb
Copy link
Owner

ptitSeb commented May 5, 2023

Not sure on RV64 as I haven't tried yet, but I fixed all issues running this game on ARM64. It's a bit slowish when lots of action is occuring, but I haven't analysed what is happening yet.

@ksco
Copy link
Collaborator Author

ksco commented May 5, 2023

I'll check that later today.

@ksco
Copy link
Collaborator Author

ksco commented May 5, 2023

It works on VF2, and it's slow too. But after playing for a while, it reported an error.

image

@ksco
Copy link
Collaborator Author

ksco commented May 5, 2023

Seems it will report this error as soon as a bullet hits a target, looks like an opcode bug.

@ptitSeb
Copy link
Owner

ptitSeb commented May 5, 2023

Yeah, I don't have this on ARM64, it works fine. I played a couple of time and there was no errors.

@ksco
Copy link
Collaborator Author

ksco commented May 5, 2023

Ok, I'll try fix the opcode bug.

@xctan
Copy link
Contributor

xctan commented May 5, 2023

I found this bug after running the game half an hour under cosim. The rounding mode should apply to the raw value, not the absolute one.

@ksco
Copy link
Collaborator Author

ksco commented May 5, 2023

Cosim is awesome!

@ptitSeb
Copy link
Owner

ptitSeb commented May 5, 2023

That's strange, I think I saw that before, but it was ok because the sign bit was copied after the conversion.

@xctan
Copy link
Contributor

xctan commented May 5, 2023

BTW the gameplay is still slow at 1.8~7 fps, drastically dropped from above 30 fps in the menu.

@xctan
Copy link
Contributor

xctan commented May 5, 2023

And if the player is not shooting, the game runs at ~12 fps with much less danmaku.

@ptitSeb
Copy link
Owner

ptitSeb commented May 5, 2023

Yes, I noticed. I tried some analysis, but I'm still unsure what is going on. I think it's luajit that doesn't play nice with box64 Dynarec, but even that I'm unsure yet.

@ksco
Copy link
Collaborator Author

ksco commented May 5, 2023

Should I leave this ticket open? The OOM issue is fixed.

@ptitSeb
Copy link
Owner

ptitSeb commented May 5, 2023

No, it should be closed. The performance issue is something completly different.
It something that you can also see, more or less, with other JIT based engined, like Mono/Unity3D (with Terraria or Broforce for example).
The solution is not clear yet, nor is the root cause of the slowdown...

@ksco ksco closed this as completed May 5, 2023
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

No branches or pull requests

3 participants