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

VertexLoader: cache NativeVertexFormat #809

Merged
merged 1 commit into from Aug 16, 2014
Merged

Conversation

degasus
Copy link
Member

@degasus degasus commented Aug 15, 2014

This fix a performance regression of PR #672.

static NativeVertexLoaderMap s_native_vertex_map;
// TODO - change into array of pointers. Keep a map of all seen so far.

void Init()
{
MarkAllDirty();
for (VertexLoader*& vertexLoader : g_VertexLoaders)
vertexLoader = nullptr;
for (auto& vertexLoader : s_VertexLoaders)

This comment was marked as off-topic.

This comment was marked as off-topic.

@delroth
Copy link
Member

delroth commented Aug 15, 2014

LGTM. @JMC47 any noticeable performance improvement here?

@JMC47
Copy link
Contributor

JMC47 commented Aug 16, 2014

Increases Super Mario Galaxy's intro from 167 fps to 224 fps on my computer. Umm. If this looks good to people, it should probably be merged.

20 FPS increase in both SMG1 and SMG2 at pretty much all times. But the weird thing is that when I tested the build that this was supposed to fix a performance regression in, I couldn't find a performance regression. As such it's just... faster. I don't know, but, if it fixes a performance regression, that's good enough for me.

This fix a performance regression of PR dolphin-emu#672.
@degasus
Copy link
Member Author

degasus commented Aug 16, 2014

@delroth updated

@JMC47 Sorry, I took the wrong PR to let you test the regression. The one linked in the commit message is the right one #672.

@delroth
Copy link
Member

delroth commented Aug 16, 2014

Thanks, sorry again for the regression. Didn't notice the additional map lookup.

delroth added a commit that referenced this pull request Aug 16, 2014
VertexLoader: cache NativeVertexFormat
@delroth delroth merged commit b9404f9 into dolphin-emu:master Aug 16, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants