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

rsx: tiny zcull optimizations #5117

Merged
merged 2 commits into from
Sep 13, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 1 addition & 2 deletions rpcs3/Emu/RSX/GL/GLGSRender.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1711,8 +1711,7 @@ work_item& GLGSRender::post_flush_request(u32 address, gl::texture_cache::thrash
{
std::lock_guard lock(queue_guard);

work_queue.emplace_back();
work_item &result = work_queue.back();
work_item &result = work_queue.emplace_back();
result.address_to_flush = address;
result.section_data = std::move(flush_data);
return result;
Expand Down
7 changes: 4 additions & 3 deletions rpcs3/Emu/RSX/RSXThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3201,11 +3201,12 @@ namespace rsx
const auto memory_end = memory_address + memory_range;
u32 sync_address = 0;

for (const auto &writer : m_pending_writes)
for (auto It = m_pending_writes.crbegin(); It != m_pending_writes.crend(); ++It)
{
if (writer.sink >= memory_address && writer.sink < memory_end)
if (It->sink >= memory_address && It->sink < memory_end)
{
sync_address = writer.sink;
sync_address = It->sink;
break;
}
}

Expand Down