diff options
author | Richard Linden <none@none> | 2010-08-26 12:49:00 -0700 |
---|---|---|
committer | Richard Linden <none@none> | 2010-08-26 12:49:00 -0700 |
commit | 093e83386d5a132cc8947095f93ea6405aab6e3f (patch) | |
tree | 043184fa92c8a6a9f8e747eb13056616bb27ba20 /indra/newview/llappviewer.cpp | |
parent | 2667c77a1cfb230ade472a047f46fd2bde7883c0 (diff) | |
parent | ce1a0c6bafad092f9687e3b5a6b4865569d96863 (diff) |
merge
Diffstat (limited to 'indra/newview/llappviewer.cpp')
-rw-r--r-- | indra/newview/llappviewer.cpp | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 8e448d53ee..8989a5a2e5 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -1125,7 +1125,6 @@ bool LLAppViewer::mainLoop() { LLMemType mt_sleep(LLMemType::MTYPE_SLEEP); LLFastTimer t2(FTM_SLEEP); - bool run_multiple_threads = gSavedSettings.getBOOL("RunMultipleThreads"); // yield some time to the os based on command line option if(mYieldTime >= 0) @@ -1164,9 +1163,7 @@ bool LLAppViewer::mainLoop() } static const F64 FRAME_SLOW_THRESHOLD = 0.5; //2 frames per seconds - const F64 min_frame_time = 0.0; //(.0333 - .0010); // max video frame rate = 30 fps - const F64 min_idle_time = 0.0; //(.0010); // min idle time = 1 ms - const F64 max_idle_time = run_multiple_threads ? min_idle_time : llmin(.005*10.0*gFrameTimeSeconds, 0.005); // 5 ms a second + const F64 max_idle_time = llmin(.005*10.0*gFrameTimeSeconds, 0.005); // 5 ms a second idleTimer.reset(); bool is_slow = (frameTimer.getElapsedTimeF64() > FRAME_SLOW_THRESHOLD) ; S32 total_work_pending = 0; @@ -1204,22 +1201,13 @@ bool LLAppViewer::mainLoop() total_work_pending += work_pending ; total_io_pending += io_pending ; - F64 frame_time = frameTimer.getElapsedTimeF64(); - F64 idle_time = idleTimer.getElapsedTimeF64(); - if (frame_time >= min_frame_time && - idle_time >= min_idle_time && - (!work_pending || idle_time >= max_idle_time)) + + if (!work_pending || idleTimer.getElapsedTimeF64() >= max_idle_time) { break; } } - // Prevent the worker threads from running while rendering. - // if (LLThread::processorCount()==1) //pause() should only be required when on a single processor client... - if (run_multiple_threads == FALSE) - { - //LLFastTimer ftm(FTM_PAUSE_THREADS); //not necessary. - if(!total_work_pending) //pause texture fetching threads if nothing to process. { LLAppViewer::getTextureCache()->pause(); @@ -1231,7 +1219,6 @@ bool LLAppViewer::mainLoop() LLVFSThread::sLocal->pause(); LLLFSThread::sLocal->pause(); } - } if ((LLStartUp::getStartupState() >= STATE_CLEANUP) && (frameTimer.getElapsedTimeF64() > FRAME_STALL_THRESHOLD)) |