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

Mask GetPointer Differently on GameCube #4303

Closed
wants to merge 1 commit into from

Conversation

@JMC47
Copy link
Contributor

commented Oct 5, 2016

GameCube can't access EXRAM I'm guessing, so we need to wrap it different. Number was verified by LibOGC or something by someone who wasn't me.

Fixes Starfox Assault crash better this time.


This change is Reviewable

@@ -391,7 +391,10 @@ u8* GetPointer(u32 address)
{
// TODO: Should we be masking off more bits here? Can all devices access

This comment has been minimized.

Copy link
@RisingFog

RisingFog Oct 5, 2016

Member

Does this comment apply anymore?

This comment has been minimized.

Copy link
@phire

phire Oct 6, 2016

Member

Yes. Testing is still needed. Though I'm pretty sure the answer is "All devices can access EXRAM"

@BhaaLseN

This comment has been minimized.

Copy link
Member

commented Oct 5, 2016

That comment was what got me the idea of doing this in here; and the mask 0x01ffffff is the next-best thing for the amount of physically available RAM on a GameCube.
I suppose it still applies though, since we don't exactly know if that covers all cases; and we still have games/cases where it doesn't affect enough to fix things. Somewhere else in that file, it mentions that the whole function is just a guesstimation of what could be.

Should probably be "mask", not "wrap" tho ;)

@JMC47 JMC47 changed the title Wrap GetPointer Differently on GameCube Mask GetPointer Differently on GameCube Oct 5, 2016

@shuffle2

This comment has been minimized.

Copy link
Contributor

commented Oct 6, 2016

These masks should probably be derived from Memory::REALRAM_SIZE or something (or else MP3 beta will break 😛 )

@JMC47

This comment has been minimized.

Copy link
Contributor Author

commented Oct 6, 2016

Right. If I could modify this to work with Metroid Prime 3's Beta, that'd be even better. Is there a way to do that?

@JMC47

This comment has been minimized.

Copy link
Contributor Author

commented Oct 6, 2016

Note: Metroid Prime 3's beta doesn't run right now without modifying Dolphin, so if I can kill two birds with one stone, I definitely will. It'd make a good video.

@shuffle2

This comment has been minimized.

Copy link
Contributor

commented Jun 6, 2017

converting the enum values into variables should be possible without too much trouble, but I'd be willing to bet there will be some perf impact, since the values are used in a bunch of pretty hot code paths.

Someone should try it, I guess ;)

@JMC47

This comment has been minimized.

Copy link
Contributor Author

commented Mar 23, 2018

This PR is wrong, 24/32 MB is open bus.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
5 participants
You can’t perform that action at this time.