Backed out changeset: 1f6f0608136f - prep for http merge

Wed, 12 Feb 2014 14:15:21 -0800

author
Tank_Master
date
Wed, 12 Feb 2014 14:15:21 -0800
changeset 40755
2d4b7013135a
parent 40754
45dd6102ba3b
child 40756
0da1db68a6e7

Backed out changeset: 1f6f0608136f - prep for http merge

indra/newview/app_settings/settings.xml file | annotate | diff | revisions
indra/newview/llmeshrepository.cpp file | annotate | diff | revisions
indra/newview/llmeshrepository.h file | annotate | diff | revisions
     1.1 --- a/indra/newview/app_settings/settings.xml	Wed Feb 12 13:55:07 2014 -0800
     1.2 +++ b/indra/newview/app_settings/settings.xml	Wed Feb 12 14:15:21 2014 -0800
     1.3 @@ -19605,17 +19605,6 @@
     1.4      <key>Value</key>
     1.5      <integer>100</integer>
     1.6    </map>
     1.7 -  <key>FSMeshRequestTimeout</key>
     1.8 -  <map>
     1.9 -    <key>Comment</key>
    1.10 -    <string>The timeout in seconds for a mesh header or LOD data request after that the request will be sent again.</string>
    1.11 -    <key>Persist</key>
    1.12 -    <integer>1</integer>
    1.13 -    <key>Type</key>
    1.14 -    <string>F32</string>
    1.15 -    <key>Value</key>
    1.16 -    <real>35.0</real>
    1.17 -  </map>
    1.18      <key>ExodusFlickrLastTags</key>
    1.19      <map>
    1.20        <key>Comment</key>
     2.1 --- a/indra/newview/llmeshrepository.cpp	Wed Feb 12 13:55:07 2014 -0800
     2.2 +++ b/indra/newview/llmeshrepository.cpp	Wed Feb 12 14:15:21 2014 -0800
     2.3 @@ -581,8 +581,6 @@
     2.4  
     2.5  	// <FS:Ansariel> Configurable request throttle
     2.6  	static LLCachedControl<U32> fsMaxMeshRequestsPerSecond(gSavedSettings, "FSMaxMeshRequestsPerSecond");
     2.7 -	// <FS:Ansariel> Mesh header/LOD retry functionality
     2.8 -	static LLCachedControl<F32> fsMeshRequestTimeout(gSavedSettings, "FSMeshRequestTimeout");
     2.9  
    2.10  	while (!LLApp::isQuitting())
    2.11  	{
    2.12 @@ -600,59 +598,6 @@
    2.13  			{ //a second has gone by, clear count
    2.14  				last_hundred = gFrameTimeSeconds;
    2.15  				count = 0;	
    2.16 -
    2.17 -				// <FS:Ansariel> Mesh header/LOD retry functionality
    2.18 -				F32 curl_timeout = (F32)fsMeshRequestTimeout;
    2.19 -
    2.20 -				if (mMutex)
    2.21 -				{
    2.22 -					mMutex->lock();
    2.23 -					// Handle header requests
    2.24 -					std::set<ActiveHeaderRequest>::iterator header_it = mActiveHeaderRequests.begin();
    2.25 -					std::list<ActiveHeaderRequest> active_header_clear_list;
    2.26 -
    2.27 -					for ( ; header_it != mActiveHeaderRequests.end(); header_it++)
    2.28 -					{
    2.29 -						ActiveHeaderRequest active_req = *header_it;
    2.30 -						if (gFrameTimeSeconds - active_req.mFrameTimeStart > curl_timeout)
    2.31 -						{
    2.32 -							LL_WARNS("MeshRequestTimeout") << "Mesh header request timed out for SculptID=" << active_req.mMeshParams.getSculptID() << LL_ENDL;
    2.33 -							HeaderRequest req(active_req.mMeshParams);
    2.34 -							mHeaderReqQ.push(req);
    2.35 -							active_header_clear_list.push_back(active_req);
    2.36 -						}
    2.37 -					}
    2.38 -
    2.39 -					for (std::list<ActiveHeaderRequest>::iterator it = active_header_clear_list.begin(); it != active_header_clear_list.end(); it++)
    2.40 -					{
    2.41 -						mActiveHeaderRequests.erase(*it);
    2.42 -					}
    2.43 -
    2.44 -					// Handle LOD requests
    2.45 -					std::set<ActiveLODRequest>::iterator lod_it = mActiveLODRequests.begin();
    2.46 -					std::list<ActiveLODRequest> active_lod_clear_list;
    2.47 -
    2.48 -					for ( ; lod_it != mActiveLODRequests.end(); lod_it++)
    2.49 -					{
    2.50 -						ActiveLODRequest active_req = *lod_it;
    2.51 -						if (gFrameTimeSeconds - active_req.mFrameTimeStart > curl_timeout)
    2.52 -						{
    2.53 -							LL_WARNS("MeshRequestTimeout") << "Mesh LOD request timed out for SculptID=" << active_req.mMeshParams.getSculptID() << " and LOD=" << active_req.mLOD << LL_ENDL;
    2.54 -							LODRequest req(active_req.mMeshParams, active_req.mLOD);
    2.55 -							LLMeshRepository::sLODProcessing++;
    2.56 -							mLODReqQ.push(req);
    2.57 -							active_lod_clear_list.push_back(active_req);
    2.58 -						}
    2.59 -					}
    2.60 -
    2.61 -					for (std::list<ActiveLODRequest>::iterator it = active_lod_clear_list.begin(); it != active_lod_clear_list.end(); it++)
    2.62 -					{
    2.63 -						mActiveLODRequests.erase(*it);
    2.64 -					}
    2.65 -
    2.66 -					mMutex->unlock();
    2.67 -				}
    2.68 -				// </FS:Ansariel> Mesh header/LOD retry functionality
    2.69  			}
    2.70  
    2.71  			// NOTE: throttling intentionally favors LOD requests over header requests
    2.72 @@ -1150,18 +1095,6 @@
    2.73  		if(retval)
    2.74  		{
    2.75  			LLMeshRepository::sHTTPRequestCount++;
    2.76 -
    2.77 -			// <FS:Ansariel> Mesh header/LOD retry functionality
    2.78 -			S32 frameTime = gFrameTimeSeconds;
    2.79 -			LL_DEBUGS("MeshRequestTimeout") << "Mesh header request: SculptID=" << mesh_params.getSculptID() << ", gFrameTimeSeconds=" << frameTime << LL_ENDL;
    2.80 -			if (mMutex)
    2.81 -			{
    2.82 -				mMutex->lock();
    2.83 -				mActiveHeaderRequests.insert(ActiveHeaderRequest(mesh_params, frameTime));
    2.84 -				LL_DEBUGS("MeshRequestTimeout") << "Active mesh header requests: " << mActiveHeaderRequests.size() << LL_ENDL;
    2.85 -				mMutex->unlock();
    2.86 -			}
    2.87 -			// </FS:Ansariel> Mesh header/LOD retry functionality
    2.88  		}
    2.89  		count++;
    2.90  	}
    2.91 @@ -1236,18 +1169,6 @@
    2.92  				if(retval)
    2.93  				{
    2.94  					LLMeshRepository::sHTTPRequestCount++;
    2.95 -
    2.96 -					// <FS:Ansariel> Mesh header/LOD retry functionality
    2.97 -					S32 frameTime = gFrameTimeSeconds;
    2.98 -					LL_DEBUGS("MeshRequestTimeout") << "Mesh LOD request: SculptID=" << mesh_params.getSculptID() << ", LOD=" << lod << ", gFrameTimeSeconds=" << frameTime << LL_ENDL;
    2.99 -					if (mMutex)
   2.100 -					{
   2.101 -						mMutex->lock();
   2.102 -						mActiveLODRequests.insert(ActiveLODRequest(mesh_params, lod, frameTime));
   2.103 -						LL_DEBUGS("MeshRequestTimeout") << "Active mesh LOD requests: " << mActiveLODRequests.size() << LL_ENDL;
   2.104 -						mMutex->unlock();
   2.105 -					}
   2.106 -					// </FS:Ansariel> Mesh header/LOD retry functionality
   2.107  				}
   2.108  				count++;
   2.109  			}
   2.110 @@ -2019,14 +1940,6 @@
   2.111  	{
   2.112  		return;
   2.113  	}
   2.114 -	// <FS:Ansariel> Mesh header/LOD retry functionality
   2.115 -	{
   2.116 -		LLMutexLock lock(gMeshRepo.mThread->mMutex);
   2.117 -		LLMeshRepoThread::ActiveLODRequest Req(mMeshParams, mLOD);
   2.118 -		gMeshRepo.mThread->mActiveLODRequests.erase(Req);
   2.119 -		LL_DEBUGS("MeshRequestTimeout") << "Cleared active mesh LOD request: SculptID=" << mMeshParams.getSculptID() << ", LOD=" << mLOD << LL_ENDL;
   2.120 -	}
   2.121 -	// </FS:Ansariel> Mesh header/LOD retry functionality
   2.122  	
   2.123  	S32 data_size = buffer->countAfter(channels.in(), NULL);
   2.124  
   2.125 @@ -2299,15 +2212,6 @@
   2.126  		return;
   2.127  	}
   2.128  
   2.129 -	// <FS:Ansariel> Mesh header/LOD retry functionality
   2.130 -	{
   2.131 -		LLMutexLock lock(gMeshRepo.mThread->mMutex);
   2.132 -		LLMeshRepoThread::ActiveHeaderRequest Req(mMeshParams);
   2.133 -		gMeshRepo.mThread->mActiveHeaderRequests.erase(Req);
   2.134 -		LL_DEBUGS("MeshRequestTimeout") << "Cleared active mesh header request: " << mMeshParams.getSculptID() << LL_ENDL;
   2.135 -	}
   2.136 -	// </FS:Ansariel> Mesh header/LOD retry functionality
   2.137 -
   2.138  	if (status < 200 || status > 400)
   2.139  	{
   2.140  		//llwarns
     3.1 --- a/indra/newview/llmeshrepository.h	Wed Feb 12 13:55:07 2014 -0800
     3.2 +++ b/indra/newview/llmeshrepository.h	Wed Feb 12 14:15:21 2014 -0800
     3.3 @@ -263,70 +263,6 @@
     3.4  		}
     3.5  	};
     3.6  
     3.7 -	// <FS:Ansariel> Mesh header/LOD retry functionality
     3.8 -	class ActiveHeaderRequest
     3.9 -	{
    3.10 -	public:
    3.11 -		LLVolumeParams	mMeshParams;
    3.12 -		F32				mFrameTimeStart;
    3.13 -
    3.14 -		ActiveHeaderRequest()
    3.15 -		{
    3.16 -			mMeshParams = LLVolumeParams();
    3.17 -		}
    3.18 -
    3.19 -		ActiveHeaderRequest(const LLVolumeParams& mesh_params, S32 frametime = 0)
    3.20 -			: mMeshParams(mesh_params), mFrameTimeStart(frametime)
    3.21 -		{
    3.22 -		}
    3.23 -
    3.24 -		bool operator==(const ActiveHeaderRequest& rhs) const
    3.25 -		{
    3.26 -			return (mMeshParams == rhs.mMeshParams);
    3.27 -		}
    3.28 -
    3.29 -		bool operator<(const ActiveHeaderRequest& rhs) const
    3.30 -		{
    3.31 -			return (mMeshParams < rhs.mMeshParams);
    3.32 -		}
    3.33 -	};
    3.34 -
    3.35 -	class ActiveLODRequest
    3.36 -	{
    3.37 -	public:
    3.38 -		LLVolumeParams	mMeshParams;
    3.39 -		S32				mLOD;
    3.40 -		F32				mFrameTimeStart;
    3.41 -
    3.42 -		ActiveLODRequest()
    3.43 -		{
    3.44 -			mMeshParams = LLVolumeParams();
    3.45 -			mLOD = 0;
    3.46 -		}
    3.47 -
    3.48 -		ActiveLODRequest(const LLVolumeParams& mesh_params, S32 lod, S32 frametime = 0)
    3.49 -			: mMeshParams(mesh_params), mLOD(lod), mFrameTimeStart(frametime)
    3.50 -		{
    3.51 -		}
    3.52 -
    3.53 -		bool operator==(const ActiveLODRequest& rhs) const
    3.54 -		{
    3.55 -			return (mMeshParams == rhs.mMeshParams &&
    3.56 -				mLOD == rhs.mLOD);
    3.57 -		}
    3.58 -
    3.59 -		bool operator<(const ActiveLODRequest& rhs) const
    3.60 -		{
    3.61 -			if (mMeshParams == rhs.mMeshParams)
    3.62 -			{
    3.63 -				return (mLOD < rhs.mLOD);
    3.64 -			}
    3.65 -			return (mMeshParams < rhs.mMeshParams);
    3.66 -		}
    3.67 -
    3.68 -	};
    3.69 -	// </FS:Ansariel> Mesh header/LOD retry functionality
    3.70 -
    3.71  	struct CompareScoreGreater
    3.72  	{
    3.73  		bool operator()(const LODRequest& lhs, const LODRequest& rhs)
    3.74 @@ -371,14 +307,6 @@
    3.75  	//queue of requested LODs
    3.76  	std::queue<LODRequest> mLODReqQ;
    3.77  
    3.78 -	// <FS:Ansariel> Mesh header/LOD retry functionality
    3.79 -	//map of currently running header requests via HTTP
    3.80 -	std::set<ActiveHeaderRequest> mActiveHeaderRequests;
    3.81 -
    3.82 -	//map of currently running LOD requests via HTTP
    3.83 -	std::set<ActiveLODRequest> mActiveLODRequests;
    3.84 -	// </FS:Ansariel> Mesh header/LOD retry functionality
    3.85 -
    3.86  	//queue of unavailable LODs (either asset doesn't exist or asset doesn't have desired LOD)
    3.87  	std::queue<LODRequest> mUnavailableQ;
    3.88  

mercurial