-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
PM4 type 2 in acb #3047
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
PM4 type 2 in acb #3047
Conversation
This PR progresses updated versions of Call of Duty®: Advanced Warfare (CUSA00803) further, though they still crash before reaching ingame. |
shad_log.txt |
Last I remember, seeing errors for PM4 like this are usually other issues with processing the command buffer and not actually unimplemented packets. |
Type 0 case definitely feels like a hack, though I'm pretty sure type 2 is valid. |
Wrong command size, return as been in first commit, now error:
in knack, and all screen blink black. Something really broken. Battlefield still softlock on game start |
@StevenMiller123, do you think, something wrong with offsets, and PM4t2 - is part (data) of other command? |
Knack has a pretty bad race condition going on still. This PR won't fix it. |
There are a lot of reasons why games might be triggering the PM4 type 0 unreachable, and it will need to be looked into at some point. It's pretty clear in most games that the PM4 type 0 error is caused by some race condition. No amount of properly handling type 0 packets will fix these crashes in games like Knack or The Last of Us Remastered. |
ok maybe we can keep type 2 for this pr? |
i leave the possibility to skip Type0, for developers |
src/video_core/amdgpu/liverpool.cpp
Outdated
// comment "UNREACHABLE_MSG()" above ^^^ to skip "PM4 type 0" command | ||
dcb = NextPacket(dcb, header->type0.NumWords() + 1); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should have this kind of thing committed into the main branch source
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why? this code not really executed without editing code
and source code full of stubs, which cannot be reversed from fw ATM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because it’s clutter, and this isn’t even a stub, it’s an invalid packet. This is just hiding another issue. Hacks don’t belong in mainline.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this code is NOT executing in mainline at all, it crash early on UNREACHABLE_MSG()
it's just for devs, to see, how long a game goes on w/o this crash.
After fixing reasons, why games go to this case, the code probably never reach this point (but, as it depricated, may still be used)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, and I think even commented out we should not be committing incorrect hacks into mainline. There’s nothing stopping someone from making this change for debugging or having a branch but I won’t approve on this as-is.
this PR passes CUSA00625 - Battlefield™ Hardline through main menu