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

Windows: Fill in per-core MIDR information #4031

Merged
merged 1 commit into from
Sep 3, 2024
Merged

Conversation

bylaws
Copy link
Collaborator

@bylaws bylaws commented Sep 3, 2024

No description provided.

@Sonicadvance1 Sonicadvance1 merged commit 7a9eb01 into FEX-Emu:main Sep 3, 2024
12 checks passed

auto HostFeatures = FEX::FetchHostFeatures(Features, !IsWine, CTR, MIDR);
FillMIDRInformation(&HostFeatures, MIDR);

for (uint32_t Idx = 0; Key; Key = OpenProcessorKey(++Idx)) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this intended to start at Idx==1 ? All documentation I could find (which wasn't a lot) suggests the first processor is at 0.

It's a bit of a weird way to express the iteration pattern either way; initializing to 1 and using post-increment would have been clearer.

Copy link
Collaborator Author

@bylaws bylaws Sep 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It starts at zero because the first iteration of the loop is for core zero which has its reg key already open from prior

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah... not the worst thing to do but rather subtle.

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

Successfully merging this pull request may close these issues.

3 participants