diff options
Diffstat (limited to 'indra/newview/llappviewer.cpp')
-rw-r--r-- | indra/newview/llappviewer.cpp | 44 |
1 files changed, 18 insertions, 26 deletions
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 30f82926f1..1000c0e1e8 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -731,10 +731,6 @@ bool LLAppViewer::init() mAlloc.setProfilingEnabled(gSavedSettings.getBOOL("MemProfiling")); -#if LL_RECORD_VIEWER_STATS - LLViewerStatsRecorder::initClass(); -#endif - // Initialize the non-LLCurl libcurl library. Should be called // before consumers (LLTextureFetch). mAppCoreHttp.init(); @@ -808,9 +804,6 @@ bool LLAppViewer::init() ////////////////////////////////////////////////////////////////////////////// // *FIX: The following code isn't grouped into functions yet. - // Statistics / debug timer initialization - init_statistics(); - // // Various introspection concerning the libs we're using - particularly // the libs involved in getting to a full login screen. @@ -1037,11 +1030,20 @@ bool LLAppViewer::init() } #if LL_WINDOWS - if (gGLManager.mIsIntel && - LLFeatureManager::getInstance()->getGPUClass() > 0 && - gGLManager.mGLVersion <= 3.f) + if (gGLManager.mGLVersion < LLFeatureManager::getInstance()->getExpectedGLVersion()) { - LLNotificationsUtil::add("IntelOldDriver"); + if (gGLManager.mIsIntel) + { + LLNotificationsUtil::add("IntelOldDriver"); + } + else if (gGLManager.mIsNVIDIA) + { + LLNotificationsUtil::add("NVIDIAOldDriver"); + } + else if (gGLManager.mIsATI) + { + LLNotificationsUtil::add("AMDOldDriver"); + } } #endif @@ -1196,9 +1198,10 @@ static LLFastTimer::DeclareTimer FTM_SERVICE_CALLBACK("Callback"); static LLFastTimer::DeclareTimer FTM_AGENT_AUTOPILOT("Autopilot"); static LLFastTimer::DeclareTimer FTM_AGENT_UPDATE("Update"); +LLFastTimer::DeclareTimer FTM_FRAME("Frame", true); + bool LLAppViewer::mainLoop() { - LLMemType mt1(LLMemType::MTYPE_MAIN); mMainloopTimeout = new LLWatchdogTimeout(); //------------------------------------------- @@ -1234,7 +1237,8 @@ bool LLAppViewer::mainLoop() // Handle messages while (!LLApp::isExiting()) { - LLFastTimer::nextFrame(); // Should be outside of any timer instances + LLFastTimer _(FTM_FRAME); + LLFastTimer::nextFrame(); //clear call stack records llclearcallstacks; @@ -1298,7 +1302,6 @@ bool LLAppViewer::mainLoop() && (gHeadlessClient || !gViewerWindow->getShowProgress()) && !gFocusMgr.focusLocked()) { - LLMemType mjk(LLMemType::MTYPE_JOY_KEY); joystick->scanJoystick(); gKeyboard->scanKeyboard(); } @@ -1312,7 +1315,6 @@ bool LLAppViewer::mainLoop() if (gAres != NULL && gAres->isInitialized()) { - LLMemType mt_ip(LLMemType::MTYPE_IDLE_PUMP); pingMainloopTimeout("Main:ServicePump"); LLFastTimer t4(FTM_PUMP); { @@ -1362,7 +1364,6 @@ bool LLAppViewer::mainLoop() // Sleep and run background threads { - LLMemType mt_sleep(LLMemType::MTYPE_SLEEP); LLFastTimer t2(FTM_SLEEP); // yield some time to the os based on command line option @@ -1939,10 +1940,6 @@ bool LLAppViewer::cleanup() LLMetricPerformanceTesterBasic::cleanClass() ; -#if LL_RECORD_VIEWER_STATS - LLViewerStatsRecorder::cleanupClass(); -#endif - llinfos << "Cleaning up Media and Textures" << llendflush; //Note: @@ -3222,8 +3219,6 @@ void LLAppViewer::writeSystemInfo() LL_INFOS("SystemInfo") << "OS: " << getOSInfo().getOSStringSimple() << LL_ENDL; LL_INFOS("SystemInfo") << "OS info: " << getOSInfo() << LL_ENDL; - LL_INFOS("SystemInfo") << "Timers: " << LLFastTimer::sClockType << LL_ENDL; - writeDebugInfo(); // Save out debug_info.log early, in case of crash. } @@ -4207,7 +4202,6 @@ static LLFastTimer::DeclareTimer FTM_VLMANAGER("VL Manager"); /////////////////////////////////////////////////////// void LLAppViewer::idle() { - LLMemType mt_idle(LLMemType::MTYPE_IDLE); pingMainloopTimeout("Main:Idle"); // Update frame timers @@ -4320,7 +4314,6 @@ void LLAppViewer::idle() // of SEND_STATS_PERIOD so that the initial stats report will // be sent immediately. static LLFrameStatsTimer viewer_stats_timer(SEND_STATS_PERIOD); - reset_statistics(); // Update session stats every large chunk of time // *FIX: (???) SAMANTHA @@ -4380,7 +4373,7 @@ void LLAppViewer::idle() idle_afk_check(); // Update statistics for this frame - update_statistics(gFrameCount); + update_statistics(); } //////////////////////////////////////// @@ -4806,7 +4799,6 @@ static LLFastTimer::DeclareTimer FTM_CHECK_REGION_CIRCUIT("Check Region Circuit" void LLAppViewer::idleNetwork() { - LLMemType mt_in(LLMemType::MTYPE_IDLE_NETWORK); pingMainloopTimeout("idleNetwork"); gObjectList.mNumNewObjects = 0; |