summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/lltexturefetch.cpp2
-rwxr-xr-xindra/newview/llviewermessage.cpp1
-rwxr-xr-xindra/newview/llviewerstats.cpp98
-rwxr-xr-xindra/newview/llviewerstats.h86
-rw-r--r--indra/newview/llviewertexturelist.cpp4
-rw-r--r--indra/newview/llworld.cpp6
6 files changed, 100 insertions, 97 deletions
diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp
index 2ce5f95b54..f2caa01644 100644
--- a/indra/newview/lltexturefetch.cpp
+++ b/indra/newview/lltexturefetch.cpp
@@ -2316,7 +2316,7 @@ S32 LLTextureFetch::update(F32 max_time_ms)
if(mCurlGetRequest)
{
- LLStatViewer::TEXTURE_KBIT.add<LLUnits::Bits<F32> >(mCurlGetRequest->getTotalReceivedBits());
+ LLStatViewer::TEXTURE_KBIT.add<LLUnits::Bits>(mCurlGetRequest->getTotalReceivedBits());
//gTextureList.sTextureBits += mCurlGetRequest->getTotalReceivedBits();
}
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 79ed093382..ec7d91ec4f 100755
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -4772,7 +4772,6 @@ void process_sim_stats(LLMessageSystem *msg, void **user_data)
//LLViewerStats::getInstance()->mSimAgentUPS.addValue(stat_value);
break;
case LL_SIM_STAT_FRAMEMS:
- //LLStatViewer::SIM_.sample(stat_value);
LLViewerStats::getInstance()->mSimFrameMsec.addValue(stat_value);
break;
case LL_SIM_STAT_NETMS:
diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp
index bed2dffb14..a3d04d655a 100755
--- a/indra/newview/llviewerstats.cpp
+++ b/indra/newview/llviewerstats.cpp
@@ -64,7 +64,7 @@
namespace LLStatViewer
{
-LLTrace::Rate<F32> FPS("fpsstat"),
+LLTrace::Count<> FPS("fpsstat"),
PACKETS_IN("packetsinstat"),
PACKETS_LOST("packetsloststat"),
PACKETS_OUT("packetsoutstat"),
@@ -90,7 +90,7 @@ LLTrace::Rate<F32> FPS("fpsstat"),
FRAMETIME_DOUBLED("frametimedoubled", "Ratio of frames 2x longer than previous"),
TEX_BAKES("texbakes"),
TEX_REBAKES("texrebakes");
-LLTrace::Rate<LLUnits::Bytes<F32> > KBIT("kbitstat"),
+LLTrace::Count<LLUnits::Kilobits> KBIT("kbitstat"),
LAYERS_KBIT("layerskbitstat"),
OBJECT_KBIT("objectkbitstat"),
ASSET_KBIT("assetkbitstat"),
@@ -98,17 +98,17 @@ LLTrace::Rate<LLUnits::Bytes<F32> > KBIT("kbitstat"),
ACTUAL_IN_KBIT("actualinkbit"),
ACTUAL_OUT_KBIT("actualoutkbit");
-LLTrace::Rate<LLUnits::Seconds<F32> > AVATAR_EDIT_TIME("avataredittime", "Seconds in Edit Appearence"),
- TOOLBOX_TIME("toolboxtime", "Seconds using Toolbox"),
- MOUSELOOK_TIME("mouselooktime", "Seconds in Mouselook"),
- FPS_10_TIME("fps10time", "Seconds below 10 FPS"),
- FPS_8_TIME("fps8time", "Seconds below 8 FPS"),
- FPS_2_TIME("fps2time", "Seconds below 2 FPS"),
- SIM_20_FPS_TIME("sim20fpstime", "Seconds with sim FPS below 20"),
- SIM_PHYSICS_20_FPS_TIME("simphysics20fpstime", "Seconds with physics FPS below 20"),
- LOSS_5_PERCENT_TIME("loss5percenttime", "Seconds with packet loss > 5%");
-
-LLTrace::Measurement<F32> SIM_TIME_DILATION("simtimedilation"),
+LLTrace::Count<LLUnits::Seconds> AVATAR_EDIT_TIME("avataredittime", "Seconds in Edit Appearence"),
+ TOOLBOX_TIME("toolboxtime", "Seconds using Toolbox"),
+ MOUSELOOK_TIME("mouselooktime", "Seconds in Mouselook"),
+ FPS_10_TIME("fps10time", "Seconds below 10 FPS"),
+ FPS_8_TIME("fps8time", "Seconds below 8 FPS"),
+ FPS_2_TIME("fps2time", "Seconds below 2 FPS"),
+ SIM_20_FPS_TIME("sim20fpstime", "Seconds with sim FPS below 20"),
+ SIM_PHYSICS_20_FPS_TIME("simphysics20fpstime", "Seconds with physics FPS below 20"),
+ LOSS_5_PERCENT_TIME("loss5percenttime", "Seconds with packet loss > 5%");
+
+LLTrace::Measurement<> SIM_TIME_DILATION("simtimedilation"),
SIM_FPS("simfps"),
SIM_PHYSICS_FPS("simphysicsfps"),
SIM_AGENT_UPS("simagentups"),
@@ -147,36 +147,36 @@ LLTrace::Measurement<F32> SIM_TIME_DILATION("simtimedilation"),
WINDOW_WIDTH("windowwidth", "Window width"),
WINDOW_HEIGHT("windowheight", "Window height");
-LLTrace::Measurement<LLUnits::Bytes<F32> > SIM_UNACKED_BYTES("simtotalunackedbytes"),
- SIM_PHYSICS_MEM("physicsmemoryallocated"),
- GL_TEX_MEM("gltexmemstat"),
- GL_BOUND_MEM("glboundmemstat"),
- RAW_MEM("rawmemstat"),
- FORMATTED_MEM("formattedmemstat");
-
-
-LLTrace::Measurement<LLUnits::Seconds<F32> > SIM_PHYSICS_TIME("simsimphysicsmsec"),
- SIM_PHYSICS_STEP_TIME("simsimphysicsstepmsec"),
- SIM_PHYSICS_SHAPE_UPDATE_TIME("simsimphysicsshapeupdatemsec"),
- SIM_PHYSICS_OTHER_TIME("simsimphysicsothermsec"),
- SIM_AI_TIME("simsimaistepmsec"),
- SIM_AGENTS_TIME("simagentmsec"),
- SIM_IMAGES_TIME("simimagesmsec"),
- SIM_SCRIPTS_TIME("simscriptmsec"),
- SIM_SPARE_TIME("simsparemsec"),
- SIM_SLEEP_TIME("simsleepmsec"),
- SIM_PUMP_IO_TIME("simpumpiomsec"),
- SIM_PING("simpingstat"),
- FRAMETIME_JITTER("frametimejitter", "Average delta between successive frame times"),
- FRAMETIME_SLEW("frametimeslew", "Average delta between frame time and mean"),
- LOGIN_SECONDS("loginseconds", "Time between LoginRequest and LoginReply"),
- REGION_CROSSING_TIME("regioncrossingtime", "CROSSING_AVG"),
- FRAME_STACKTIME("framestacktime", "FRAME_SECS"),
- UPDATE_STACKTIME("updatestacktime", "UPDATE_SECS"),
- NETWORK_STACKTIME("networkstacktime", "NETWORK_SECS"),
- IMAGE_STACKTIME("imagestacktime", "IMAGE_SECS"),
- REBUILD_STACKTIME("rebuildstacktime", "REBUILD_SECS"),
- RENDER_STACKTIME("renderstacktime", "RENDER_SECS");
+LLTrace::Measurement<LLUnits::Bytes> SIM_UNACKED_BYTES("simtotalunackedbytes"),
+ SIM_PHYSICS_MEM("physicsmemoryallocated"),
+ GL_TEX_MEM("gltexmemstat"),
+ GL_BOUND_MEM("glboundmemstat"),
+ RAW_MEM("rawmemstat"),
+ FORMATTED_MEM("formattedmemstat");
+
+
+LLTrace::Measurement<LLUnits::Seconds> SIM_PHYSICS_TIME("simsimphysicsmsec"),
+ SIM_PHYSICS_STEP_TIME("simsimphysicsstepmsec"),
+ SIM_PHYSICS_SHAPE_UPDATE_TIME("simsimphysicsshapeupdatemsec"),
+ SIM_PHYSICS_OTHER_TIME("simsimphysicsothermsec"),
+ SIM_AI_TIME("simsimaistepmsec"),
+ SIM_AGENTS_TIME("simagentmsec"),
+ SIM_IMAGES_TIME("simimagesmsec"),
+ SIM_SCRIPTS_TIME("simscriptmsec"),
+ SIM_SPARE_TIME("simsparemsec"),
+ SIM_SLEEP_TIME("simsleepmsec"),
+ SIM_PUMP_IO_TIME("simpumpiomsec"),
+ SIM_PING("simpingstat"),
+ FRAMETIME_JITTER("frametimejitter", "Average delta between successive frame times"),
+ FRAMETIME_SLEW("frametimeslew", "Average delta between frame time and mean"),
+ LOGIN_SECONDS("loginseconds", "Time between LoginRequest and LoginReply"),
+ REGION_CROSSING_TIME("regioncrossingtime", "CROSSING_AVG"),
+ FRAME_STACKTIME("framestacktime", "FRAME_SECS"),
+ UPDATE_STACKTIME("updatestacktime", "UPDATE_SECS"),
+ NETWORK_STACKTIME("networkstacktime", "NETWORK_SECS"),
+ IMAGE_STACKTIME("imagestacktime", "IMAGE_SECS"),
+ REBUILD_STACKTIME("rebuildstacktime", "REBUILD_SECS"),
+ RENDER_STACKTIME("renderstacktime", "RENDER_SECS");
}
class StatAttributes
@@ -266,6 +266,7 @@ LLViewerStats::LLViewerStats() :
mAgentPositionSnaps.reset();
mRecording.start();
+ LLTrace::get_frame_recording().start();
}
LLViewerStats::~LLViewerStats()
@@ -437,25 +438,28 @@ void update_statistics()
LLCircuitData *cdp = gMessageSystem->mCircuitInfo.findCircuit(gAgent.getRegion()->getHost());
if (cdp)
{
+ LLStatViewer::SIM_PING.sample<LLUnits::Seconds>(cdp->getPingDelay());
stats.mSimPingStat.addValue(cdp->getPingDelay());
gAvgSimPing = ((gAvgSimPing * (F32)gSimPingCount) + (F32)(cdp->getPingDelay())) / ((F32)gSimPingCount + 1);
gSimPingCount++;
}
else
{
+ LLUnits::Seconds i(10000);
+ LLStatViewer::SIM_PING.sample(i);//<LLUnits::Seconds<U32> >(10000);
stats.mSimPingStat.addValue(10000);
}
//stats.mFPSStat.addValue(1);
LLStatViewer::FPS.add(1);
F32 layer_bits = (F32)(gVLManager.getLandBits() + gVLManager.getWindBits() + gVLManager.getCloudBits());
- LLStatViewer::LAYERS_KBIT.add<LLUnits::Bits<F32> >(layer_bits);
+ LLStatViewer::LAYERS_KBIT.add<LLUnits::Bits>(layer_bits);
//stats.mLayersKBitStat.addValue(layer_bits/1024.f);
- LLStatViewer::OBJECT_KBIT.add<LLUnits::Bits<F32> >(gObjectBits);
+ LLStatViewer::OBJECT_KBIT.add<LLUnits::Bits>(gObjectBits);
//stats.mObjectKBitStat.addValue(gObjectBits/1024.f);
//stats.mVFSPendingOperations.addValue(LLVFile::getVFSThread()->getPending());
LLStatViewer::SIM_PENDING_VFS_OPERATIONS.sample(LLVFile::getVFSThread()->getPending());
- LLStatViewer::ASSET_KBIT.add<LLUnits::Bits<F32> >(gTransferManager.getTransferBitsIn(LLTCT_ASSET));
+ LLStatViewer::ASSET_KBIT.add<LLUnits::Bits>(gTransferManager.getTransferBitsIn(LLTCT_ASSET));
//stats.mAssetKBitStat.addValue(gTransferManager.getTransferBitsIn(LLTCT_ASSET)/1024.f);
gTransferManager.resetTransferBitsIn(LLTCT_ASSET);
@@ -493,7 +497,7 @@ void update_statistics()
static LLFrameTimer texture_stats_timer;
if (texture_stats_timer.getElapsedTimeF32() >= texture_stats_freq)
{
- gTotalTextureBytes = LLUnits::Bytes<F32>(LLViewerStats::instance().getRecording().getSum(LLStatViewer::TEXTURE_KBIT)).value();
+ gTotalTextureBytes = LLUnits::Bytes(LLViewerStats::instance().getRecording().getSum(LLStatViewer::TEXTURE_KBIT)).value();
texture_stats_timer.reset();
}
}
diff --git a/indra/newview/llviewerstats.h b/indra/newview/llviewerstats.h
index a164a28a59..5412294cf2 100755
--- a/indra/newview/llviewerstats.h
+++ b/indra/newview/llviewerstats.h
@@ -34,7 +34,7 @@
namespace LLStatViewer
{
-extern LLTrace::Rate<F32> FPS,
+extern LLTrace::Count<> FPS,
PACKETS_IN,
PACKETS_LOST,
PACKETS_OUT,
@@ -62,7 +62,7 @@ extern LLTrace::Rate<F32> FPS,
TEX_REBAKES;
-extern LLTrace::Rate<LLUnits::Bytes<F32> > KBIT,
+extern LLTrace::Count<LLUnits::Kilobits> KBIT,
LAYERS_KBIT,
OBJECT_KBIT,
ASSET_KBIT,
@@ -70,17 +70,17 @@ extern LLTrace::Rate<LLUnits::Bytes<F32> > KBIT,
ACTUAL_IN_KBIT,
ACTUAL_OUT_KBIT;
-extern LLTrace::Rate<LLUnits::Seconds<F32> > AVATAR_EDIT_TIME,
- TOOLBOX_TIME,
- MOUSELOOK_TIME,
- FPS_10_TIME,
- FPS_8_TIME,
- FPS_2_TIME,
- SIM_20_FPS_TIME,
- SIM_PHYSICS_20_FPS_TIME,
- LOSS_5_PERCENT_TIME;
-
-extern LLTrace::Measurement<F32> SIM_TIME_DILATION,
+extern LLTrace::Count<LLUnits::Seconds> AVATAR_EDIT_TIME,
+ TOOLBOX_TIME,
+ MOUSELOOK_TIME,
+ FPS_10_TIME,
+ FPS_8_TIME,
+ FPS_2_TIME,
+ SIM_20_FPS_TIME,
+ SIM_PHYSICS_20_FPS_TIME,
+ LOSS_5_PERCENT_TIME;
+
+extern LLTrace::Measurement<> SIM_TIME_DILATION,
SIM_FPS,
SIM_PHYSICS_FPS,
SIM_AGENT_UPS,
@@ -119,36 +119,36 @@ extern LLTrace::Measurement<F32> SIM_TIME_DILATION,
WINDOW_WIDTH,
WINDOW_HEIGHT;
-extern LLTrace::Measurement<LLUnits::Bytes<F32> > SIM_UNACKED_BYTES,
- SIM_PHYSICS_MEM,
- GL_TEX_MEM,
- GL_BOUND_MEM,
- RAW_MEM,
- FORMATTED_MEM;
-
-
-extern LLTrace::Measurement<LLUnits::Seconds<F32> > SIM_PHYSICS_TIME,
- SIM_PHYSICS_STEP_TIME,
- SIM_PHYSICS_SHAPE_UPDATE_TIME,
- SIM_PHYSICS_OTHER_TIME,
- SIM_AI_TIME,
- SIM_AGENTS_TIME,
- SIM_IMAGES_TIME,
- SIM_SCRIPTS_TIME,
- SIM_SPARE_TIME,
- SIM_SLEEP_TIME,
- SIM_PUMP_IO_TIME,
- SIM_PING,
- FRAMETIME_JITTER,
- FRAMETIME_SLEW,
- LOGIN_SECONDS,
- REGION_CROSSING_TIME,
- FRAME_STACKTIME,
- UPDATE_STACKTIME,
- NETWORK_STACKTIME,
- IMAGE_STACKTIME,
- REBUILD_STACKTIME,
- RENDER_STACKTIME;
+extern LLTrace::Measurement<LLUnits::Bytes> SIM_UNACKED_BYTES,
+ SIM_PHYSICS_MEM,
+ GL_TEX_MEM,
+ GL_BOUND_MEM,
+ RAW_MEM,
+ FORMATTED_MEM;
+
+
+extern LLTrace::Measurement<LLUnits::Seconds> SIM_PHYSICS_TIME,
+ SIM_PHYSICS_STEP_TIME,
+ SIM_PHYSICS_SHAPE_UPDATE_TIME,
+ SIM_PHYSICS_OTHER_TIME,
+ SIM_AI_TIME,
+ SIM_AGENTS_TIME,
+ SIM_IMAGES_TIME,
+ SIM_SCRIPTS_TIME,
+ SIM_SPARE_TIME,
+ SIM_SLEEP_TIME,
+ SIM_PUMP_IO_TIME,
+ SIM_PING,
+ FRAMETIME_JITTER,
+ FRAMETIME_SLEW,
+ LOGIN_SECONDS,
+ REGION_CROSSING_TIME,
+ FRAME_STACKTIME,
+ UPDATE_STACKTIME,
+ NETWORK_STACKTIME,
+ IMAGE_STACKTIME,
+ REBUILD_STACKTIME,
+ RENDER_STACKTIME;
}
class LLViewerStats : public LLSingleton<LLViewerStats>
diff --git a/indra/newview/llviewertexturelist.cpp b/indra/newview/llviewertexturelist.cpp
index af28ea36eb..ccfedd8881 100644
--- a/indra/newview/llviewertexturelist.cpp
+++ b/indra/newview/llviewertexturelist.cpp
@@ -1325,7 +1325,7 @@ void LLViewerTextureList::receiveImageHeader(LLMessageSystem *msg, void **user_d
{
received_size = msg->getReceiveSize() ;
}
- LLStatViewer::TEXTURE_KBIT.add<LLUnits::Bytes<F32> >(received_size);
+ LLStatViewer::TEXTURE_KBIT.add<LLUnits::Bytes>(received_size);
LLStatViewer::TEXTURE_PACKETS.add(1);
U8 codec;
@@ -1399,7 +1399,7 @@ void LLViewerTextureList::receiveImagePacket(LLMessageSystem *msg, void **user_d
received_size = msg->getReceiveSize() ;
}
- LLStatViewer::TEXTURE_KBIT.add<LLUnits::Bytes<F32> >(received_size);
+ LLStatViewer::TEXTURE_KBIT.add<LLUnits::Bytes>(received_size);
LLStatViewer::TEXTURE_PACKETS.add(1);
//llprintline("Start decode, image header...");
diff --git a/indra/newview/llworld.cpp b/indra/newview/llworld.cpp
index 056132c165..9e495c46b1 100644
--- a/indra/newview/llworld.cpp
+++ b/indra/newview/llworld.cpp
@@ -703,11 +703,11 @@ void LLWorld::updateNetStats()
S32 actual_in_bits = gMessageSystem->mPacketRing.getAndResetActualInBits();
S32 actual_out_bits = gMessageSystem->mPacketRing.getAndResetActualOutBits();
- LLStatViewer::ACTUAL_IN_KBIT.add<LLUnits::Bits<F32> >(actual_in_bits);
- LLStatViewer::ACTUAL_OUT_KBIT.add<LLUnits::Bits<F32> >(actual_out_bits);
+ LLStatViewer::ACTUAL_IN_KBIT.add<LLUnits::Bits>(actual_in_bits);
+ LLStatViewer::ACTUAL_OUT_KBIT.add<LLUnits::Bits>(actual_out_bits);
//LLViewerStats::getInstance()->mActualInKBitStat.addValue(actual_in_bits/1024.f);
//LLViewerStats::getInstance()->mActualOutKBitStat.addValue(actual_out_bits/1024.f);
- LLStatViewer::KBIT.add<LLUnits::Bits<F32> >(bits);
+ LLStatViewer::KBIT.add<LLUnits::Bits>(bits);
//LLViewerStats::getInstance()->mKBitStat.addValue(bits/1024.f);
LLStatViewer::PACKETS_IN.add(packets_in);
LLStatViewer::PACKETS_OUT.add(packets_out);