Revert "SL-18721 Viewer shutdown order changes"
This reverts commit edf0874e06.
Reverted since it causes a significant uptick in shutdown freezes.
Can't repro those freezes, will seek an alternate solution.
meow-7.2.2
parent
eb7ab13000
commit
dc2fc3488d
|
|
@ -21,12 +21,11 @@
|
|||
#include "llevents.h"
|
||||
#include "stringize.h"
|
||||
|
||||
LL::ThreadPool::ThreadPool(const std::string& name, size_t threads, size_t capacity, bool auto_shutdown):
|
||||
LL::ThreadPool::ThreadPool(const std::string& name, size_t threads, size_t capacity):
|
||||
super(name),
|
||||
mQueue(name, capacity),
|
||||
mName("ThreadPool:" + name),
|
||||
mThreadCount(threads),
|
||||
mAutomaticShutdown(auto_shutdown)
|
||||
mThreadCount(threads)
|
||||
{}
|
||||
|
||||
void LL::ThreadPool::start()
|
||||
|
|
@ -40,13 +39,6 @@ void LL::ThreadPool::start()
|
|||
run(tname);
|
||||
});
|
||||
}
|
||||
|
||||
// Some threads might need to run longer than LLEventPumps
|
||||
if (!mAutomaticShutdown)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// Listen on "LLApp", and when the app is shutting down, close the queue
|
||||
// and join the workers.
|
||||
LLEventPumps::instance().obtain("LLApp").listen(
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ namespace LL
|
|||
* Pass ThreadPool a string name. This can be used to look up the
|
||||
* relevant WorkQueue.
|
||||
*/
|
||||
ThreadPool(const std::string& name, size_t threads=1, size_t capacity=1024, bool auto_shutdown = true);
|
||||
ThreadPool(const std::string& name, size_t threads=1, size_t capacity=1024);
|
||||
virtual ~ThreadPool();
|
||||
|
||||
/**
|
||||
|
|
@ -66,7 +66,6 @@ namespace LL
|
|||
std::string mName;
|
||||
size_t mThreadCount;
|
||||
std::vector<std::pair<std::string, std::thread>> mThreads;
|
||||
bool mAutomaticShutdown;
|
||||
};
|
||||
|
||||
} // namespace LL
|
||||
|
|
|
|||
|
|
@ -828,7 +828,6 @@ void LLWindowWin32::close()
|
|||
// Is window is already closed?
|
||||
if (!mWindowHandle)
|
||||
{
|
||||
mWindowThread->close();
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -4591,7 +4590,7 @@ std::vector<std::string> LLWindowWin32::getDynamicFallbackFontList()
|
|||
#endif // LL_WINDOWS
|
||||
|
||||
inline LLWindowWin32::LLWindowWin32Thread::LLWindowWin32Thread()
|
||||
: ThreadPool("Window Thread", 1, MAX_QUEUE_SIZE, false)
|
||||
: ThreadPool("Window Thread", 1, MAX_QUEUE_SIZE)
|
||||
{
|
||||
ThreadPool::start();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue