mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-23 05:19:56 +00:00
Address feedback from previous PR
This commit is contained in:
parent
f88633b696
commit
1860a73d58
@ -111,8 +111,8 @@ void ParallelRangeLoop(ThreadManager *threadMan, const std::function<void(int, i
|
||||
|
||||
// NOTE: Supports a max of 2GB.
|
||||
void ParallelMemcpy(ThreadManager *threadMan, void *dst, const void *src, size_t bytes, TaskPriority priority) {
|
||||
// This threshold can probably be a lot bigger.
|
||||
if (bytes < 512) {
|
||||
// This threshold should be the same as the minimum split below, 128kb.
|
||||
if (bytes < 128 * 1024) {
|
||||
memcpy(dst, src, bytes);
|
||||
return;
|
||||
}
|
||||
@ -129,7 +129,7 @@ void ParallelMemcpy(ThreadManager *threadMan, void *dst, const void *src, size_t
|
||||
// NOTE: Supports a max of 2GB.
|
||||
void ParallelMemset(ThreadManager *threadMan, void *dst, uint8_t value, size_t bytes, TaskPriority priority) {
|
||||
// This threshold can probably be a lot bigger.
|
||||
if (bytes < 512) {
|
||||
if (bytes < 128 * 1024) {
|
||||
memset(dst, 0, bytes);
|
||||
return;
|
||||
}
|
||||
|
@ -561,8 +561,7 @@ bool ReplacedTexture::CopyLevelTo(int level, void *out, int rowPitch) {
|
||||
}
|
||||
} else {
|
||||
// TODO: Add sanity checks here for other formats?
|
||||
// Just gonna do a memcpy, slightly scared of the parallel ones.
|
||||
memcpy(out, data.data(), data.size());
|
||||
ParallelMemcpy(&g_threadManager, out, data.data(), data.size());
|
||||
}
|
||||
|
||||
return true;
|
||||
|
@ -455,9 +455,6 @@ void TextureCacheVulkan::BuildTexture(TexCacheEntry *const entry) {
|
||||
Draw::DataFormat fmt = plan.replaced->Format();
|
||||
bcFormat = Draw::DataFormatIsBlockCompressed(fmt, &bcAlign);
|
||||
actualFmt = ToVulkanFormat(fmt);
|
||||
if (actualFmt != VULKAN_8888_FORMAT) {
|
||||
actualFmt = actualFmt;
|
||||
}
|
||||
}
|
||||
|
||||
bool computeUpload = false;
|
||||
|
Loading…
Reference in New Issue
Block a user