Commit f2878347 by Alexis Hetu Committed by Alexis Hétu

Remove precacheDLL

Remove leftover variables not cleaned up in: https://swiftshader-review.googlesource.com/c/SwiftShader/+/7250 Change-Id: Ia2e66c15e5cadeed32f564c60d5105c17319e9d4 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/27028 Presubmit-Ready: Alexis Hétu <sugoi@google.com> Tested-by: 's avatarAlexis Hétu <sugoi@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by: 's avatarNicolas Capens <nicolascapens@google.com>
parent 6480d4e1
......@@ -352,7 +352,7 @@ namespace sw
void PixelProcessor::setRoutineCacheSize(int cacheSize)
{
delete routineCache;
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536), precachePixel ? "sw-pixel" : 0);
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536));
}
const PixelProcessor::State PixelProcessor::update() const
......
......@@ -24,28 +24,7 @@ namespace sw
using namespace rr;
template<class State>
class RoutineCache : public LRUCache<State, Routine>
{
public:
RoutineCache(int n, const char *precache = 0);
~RoutineCache();
private:
const char *precache;
#if defined(_WIN32)
HMODULE precacheDLL;
#endif
};
template<class State>
RoutineCache<State>::RoutineCache(int n, const char *precache) : LRUCache<State, Routine>(n), precache(precache)
{
}
template<class State>
RoutineCache<State>::~RoutineCache()
{
}
using RoutineCache = LRUCache<State, Routine>;
}
#endif // sw_RoutineCache_hpp
......@@ -120,6 +120,6 @@ namespace sw
void SetupProcessor::setRoutineCacheSize(int cacheSize)
{
delete routineCache;
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536), precacheSetup ? "sw-setup" : 0);
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536));
}
}
......@@ -94,7 +94,7 @@ namespace sw
void VertexProcessor::setRoutineCacheSize(int cacheSize)
{
delete routineCache;
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536), precacheVertex ? "sw-vertex" : 0);
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536));
}
const VertexProcessor::State VertexProcessor::update(DrawType drawType)
......
......@@ -933,7 +933,7 @@ namespace sw
void PixelProcessor::setRoutineCacheSize(int cacheSize)
{
delete routineCache;
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536), precachePixel ? "sw-pixel" : 0);
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536));
}
void PixelProcessor::setFogRanges(float start, float end)
......
......@@ -24,28 +24,7 @@ namespace sw
using namespace rr;
template<class State>
class RoutineCache : public LRUCache<State, Routine>
{
public:
RoutineCache(int n, const char *precache = nullptr);
~RoutineCache();
private:
const char *precache;
#if defined(_WIN32)
HMODULE precacheDLL;
#endif
};
template<class State>
RoutineCache<State>::RoutineCache(int n, const char *precache) : LRUCache<State, Routine>(n), precache(precache)
{
}
template<class State>
RoutineCache<State>::~RoutineCache()
{
}
using RoutineCache = LRUCache<State, Routine>;
}
#endif // sw_RoutineCache_hpp
......@@ -243,6 +243,6 @@ namespace sw
void SetupProcessor::setRoutineCacheSize(int cacheSize)
{
delete routineCache;
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536), precacheSetup ? "sw-setup" : 0);
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536));
}
}
......@@ -899,7 +899,7 @@ namespace sw
void VertexProcessor::setRoutineCacheSize(int cacheSize)
{
delete routineCache;
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536), precacheVertex ? "sw-vertex" : 0);
routineCache = new RoutineCache<State>(clamp(cacheSize, 1, 65536));
}
const VertexProcessor::State VertexProcessor::update(DrawType drawType)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment