mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
samplerjit: Correct linear compile failure.
It was resetting to nullptr, because `nearest` was nullptr.
This commit is contained in:
parent
b2bb0be05d
commit
19998976c7
1 changed files with 5 additions and 1 deletions
|
@ -69,6 +69,7 @@ FetchFunc SamplerJitCache::CompileFetch(const SamplerID &id) {
|
|||
regCache_.Reset(false);
|
||||
EndWrite();
|
||||
ResetCodePtr(GetOffset(start));
|
||||
ERROR_LOG(G3D, "Failed to compile fetch %s", DescribeSamplerID(id).c_str());
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
@ -386,6 +387,7 @@ NearestFunc SamplerJitCache::CompileNearest(const SamplerID &id) {
|
|||
regCache_.Reset(false);
|
||||
EndWrite();
|
||||
ResetCodePtr(GetOffset(start));
|
||||
ERROR_LOG(G3D, "Failed to compile nearest %s", DescribeSamplerID(id).c_str());
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
@ -453,6 +455,7 @@ LinearFunc SamplerJitCache::CompileLinear(const SamplerID &id) {
|
|||
regCache_.Reset(false);
|
||||
EndWrite();
|
||||
ResetCodePtr(GetOffset(nearest));
|
||||
ERROR_LOG(G3D, "Failed to compile linear nearest %s", DescribeSamplerID(id).c_str());
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
@ -807,7 +810,8 @@ LinearFunc SamplerJitCache::CompileLinear(const SamplerID &id) {
|
|||
if (!success) {
|
||||
regCache_.Reset(false);
|
||||
EndWrite();
|
||||
ResetCodePtr(GetOffset(nearest));
|
||||
ResetCodePtr(GetOffset(nearest ? nearest : start));
|
||||
ERROR_LOG(G3D, "Failed to compile linear %s", DescribeSamplerID(id).c_str());
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue