-
Notifications
You must be signed in to change notification settings - Fork 10
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
Fix LTCG Versioning Method #79
Comments
I've left some comments via Discord. But they didn't find their way into this issue: Instead of hacks like this 1xxx or 2xxx, just fix it properly, please. It could become
You could also always add 0x2000 as another flag (or fall-back to it, if 0x8000 is already used - I didn't check); 0x2000 either as boolean, or as extension for state number, giving you 8 options when combined with 0x4000 and 0x8000. It's basically the same as 1xxx / 2xxx (encoding multiple things in one field), except my suggestion is more readable and less error prone (avoids accidental match of last 3 digits). Obviously, you could also turn these flags into macros: If the codebase already uses bitmasks in the upper bits and has no room for more flags, the entire encoding could be changed to something like |
Adding the flags will not help. The symbol cache doesn't have any "flag" support and shouldn't provide support for it anyway. Also, generated symbol strings are output differently for LTCG. My second proposal is closely identical to your suggestion, @JayFoxRox. Except, it will break Cxbx-Reloaded. Meaning, Cxbx-Reloaded will need an update to match the symbol renames. |
We've discussed this on Discord again. My proposal wouldn't work, because the Lines 160 to 161 in c89ee86
Additionally, the version field might only be 13 bit (although the comment is apparently outdated): Line 152 in c89ee86
Since then, @RadWolfie has also clarified that the original post contains 2 different proposals. The second proposal doesn't cause these issues. My understanding is that it moves these markers into the symbol name (which is also a bit dirty, and might have some drawbacks / but also some benefits). It would essentially add the functions as a separate function handler. |
Convert above to below as like proposal 2
or something @JayFoxRox suggest to use the LTCG at the end of the symbol.
Plus he also advise to use double underlines, |
Just want to share my discovery when worked on D3D's render state variables pull request #177. I notice there are functions that are exactly the same except shifted by one to five offsets, sometimes more than five. Which is majority affecting LTCG titles. Due to current and future versioning' limitation, I think we should re-haul OOVPA design to something else*. Doing so will cut down redundant signatures that are only shifted one to five offsets into one simple signature. Then future versioning design could work better. * Something else could be like tuple design which could transform into custom instruction internally. How would it work is a mystery for me. However, this type of work will require backward compatibility removal, aka |
Similar to RadWolfie's first proposals, but adding a minor number. It also avoids conflicts between D3D and D3D8LTCG 1xxx. Such as
|
@jarupxx, I am not seeing how minor number will work with current implementation nor with group of symbols in the database list. |
Due to D3D8LTCG's OOVPA signatures using two separate versioning which is understandable. However, the signatures with version "1024" appear are not always in 3911's database. Which I had noticed and so are the other versions too.
I suggest a better versioning method to keep the LTCG's database sane and easier to find.
XbSymbolDatabase/OOVPADatabase/D3D8LTCG_OOVPA.inl
Lines 39 to 41 in 76146fa
My 2 proposals are:
OR
TASKS:
__LTCG
prefix and use actual versioning from existing version files.The text was updated successfully, but these errors were encountered: