From 86a93fe7b9576045b5e085965ec85692379823e7 Mon Sep 17 00:00:00 2001 From: Nathan Binkert Date: Tue, 15 Jun 2010 01:18:36 -0700 Subject: stats: only consider a formula initialized if there is a formula --- src/arch/arm/tlb.cc | 5 ---- src/arch/arm/tlb.hh | 1 - src/arch/mips/tlb.cc | 5 ---- src/arch/mips/tlb.hh | 1 - src/arch/power/tlb.cc | 5 ---- src/arch/power/tlb.hh | 1 - src/base/statistics.cc | 8 +++++-- src/dev/etherdevice.cc | 3 ++- src/dev/ide_disk.hh | 4 ---- src/mem/cache/base.hh | 2 ++ .../linux/twosys-tsunami-simple-atomic/config.ini | 28 +++++++++++----------- .../linux/twosys-tsunami-simple-atomic/simout | 14 +++++------ .../linux/twosys-tsunami-simple-atomic/stats.txt | 16 +++++++------ 13 files changed, 40 insertions(+), 53 deletions(-) diff --git a/src/arch/arm/tlb.cc b/src/arch/arm/tlb.cc index f0e40f690..9cc00a89e 100644 --- a/src/arch/arm/tlb.cc +++ b/src/arch/arm/tlb.cc @@ -282,11 +282,6 @@ TLB::regStats() .desc("DTB misses") ; - invalids - .name(name() + ".invalids") - .desc("DTB access violations") - ; - accesses .name(name() + ".accesses") .desc("DTB accesses") diff --git a/src/arch/arm/tlb.hh b/src/arch/arm/tlb.hh index a779a492d..1bddd8497 100644 --- a/src/arch/arm/tlb.hh +++ b/src/arch/arm/tlb.hh @@ -108,7 +108,6 @@ class TLB : public BaseTLB mutable Stats::Scalar write_accesses; Stats::Formula hits; Stats::Formula misses; - Stats::Formula invalids; Stats::Formula accesses; diff --git a/src/arch/mips/tlb.cc b/src/arch/mips/tlb.cc index e01c06ae5..cf1230745 100644 --- a/src/arch/mips/tlb.cc +++ b/src/arch/mips/tlb.cc @@ -281,11 +281,6 @@ TLB::regStats() .desc("DTB misses") ; - invalids - .name(name() + ".invalids") - .desc("DTB access violations") - ; - accesses .name(name() + ".accesses") .desc("DTB accesses") diff --git a/src/arch/mips/tlb.hh b/src/arch/mips/tlb.hh index 68b1c0c75..e301cf666 100644 --- a/src/arch/mips/tlb.hh +++ b/src/arch/mips/tlb.hh @@ -105,7 +105,6 @@ class TLB : public BaseTLB mutable Stats::Scalar write_accesses; Stats::Formula hits; Stats::Formula misses; - Stats::Formula invalids; Stats::Formula accesses; public: diff --git a/src/arch/power/tlb.cc b/src/arch/power/tlb.cc index 292f13078..a0ff69391 100644 --- a/src/arch/power/tlb.cc +++ b/src/arch/power/tlb.cc @@ -265,11 +265,6 @@ TLB::regStats() .desc("DTB misses") ; - invalids - .name(name() + ".invalids") - .desc("DTB access violations") - ; - accesses .name(name() + ".accesses") .desc("DTB accesses") diff --git a/src/arch/power/tlb.hh b/src/arch/power/tlb.hh index 1794de626..4445995fc 100644 --- a/src/arch/power/tlb.hh +++ b/src/arch/power/tlb.hh @@ -123,7 +123,6 @@ class TLB : public BaseTLB mutable Stats::Scalar write_accesses; Stats::Formula hits; Stats::Formula misses; - Stats::Formula invalids; Stats::Formula accesses; public: diff --git a/src/base/statistics.cc b/src/base/statistics.cc index 59013ed34..ab351567c 100644 --- a/src/base/statistics.cc +++ b/src/base/statistics.cc @@ -238,12 +238,12 @@ Vector2dInfo::enable() Formula::Formula() { - setInit(); } Formula::Formula(Temp r) { root = r; + setInit(); assert(size()); } @@ -252,6 +252,7 @@ Formula::operator=(Temp r) { assert(!root && "Can't change formulas"); root = r; + setInit(); assert(size()); return *this; } @@ -261,8 +262,11 @@ Formula::operator+=(Temp r) { if (root) root = NodePtr(new BinaryNode >(root, r)); - else + else { root = r; + setInit(); + } + assert(size()); return *this; } diff --git a/src/dev/etherdevice.cc b/src/dev/etherdevice.cc index 5341c02c4..59febcdc5 100644 --- a/src/dev/etherdevice.cc +++ b/src/dev/etherdevice.cc @@ -119,7 +119,7 @@ EtherDevice::regStats() .precision(0) ; - descDmaWrBytes + descDmaWrBytes .name(name() + ".descDmaWriteBytes") .desc("number of descriptor bytes write w/ DMA") .precision(0) @@ -364,4 +364,5 @@ EtherDevice::regStats() txPacketRate = txPackets / simSeconds; rxPacketRate = rxPackets / simSeconds; + totPacketRate = totPackets / simSeconds; } diff --git a/src/dev/ide_disk.hh b/src/dev/ide_disk.hh index 1b455e8ad..78a9e1fe7 100644 --- a/src/dev/ide_disk.hh +++ b/src/dev/ide_disk.hh @@ -244,10 +244,6 @@ class IdeDisk : public SimObject Stats::Scalar dmaWriteFullPages; Stats::Scalar dmaWriteBytes; Stats::Scalar dmaWriteTxs; - Stats::Formula rdBandwidth; - Stats::Formula wrBandwidth; - Stats::Formula totBandwidth; - Stats::Formula totBytes; public: typedef IdeDiskParams Params; diff --git a/src/mem/cache/base.hh b/src/mem/cache/base.hh index 62e8ae126..2f1088609 100644 --- a/src/mem/cache/base.hh +++ b/src/mem/cache/base.hh @@ -324,12 +324,14 @@ class BaseCache : public MemObject /** Total cycle latency of overall MSHR misses. */ Stats::Formula overallMshrUncacheableLatency; +#if 0 /** The total number of MSHR accesses per command and thread. */ Stats::Formula mshrAccesses[MemCmd::NUM_MEM_CMDS]; /** The total number of demand MSHR accesses. */ Stats::Formula demandMshrAccesses; /** The total number of MSHR accesses. */ Stats::Formula overallMshrAccesses; +#endif /** The miss rate in the MSHRs pre command and thread. */ Stats::Formula mshrMissRate[MemCmd::NUM_MEM_CMDS]; diff --git a/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/config.ini b/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/config.ini index 83f000f15..f9d319b05 100644 --- a/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/config.ini +++ b/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/config.ini @@ -8,13 +8,13 @@ type=LinuxAlphaSystem children=bridge cpu disk0 disk2 intrctrl iobus membus physmem simple_disk terminal tsunami boot_cpu_frequency=1 boot_osflags=root=/dev/hda1 console=ttyS0 -console=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/binaries/console +console=/dist/m5/system/binaries/console init_param=0 -kernel=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/binaries/vmlinux +kernel=/dist/m5/system/binaries/vmlinux mem_mode=atomic -pal=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/binaries/ts_osfpal +pal=/dist/m5/system/binaries/ts_osfpal physmem=drivesys.physmem -readfile=/proj/aatl_perfmod_arch/users/lihsu/m5/m5/configs/boot/netperf-server.rcS +readfile=/n/blue/z/binkert/work/m5/work/configs/boot/netperf-server.rcS symbolfile= system_rev=1024 system_type=34 @@ -95,7 +95,7 @@ table_size=65536 [drivesys.disk0.image.child] type=RawDiskImage -image_file=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/disks/linux-latest.img +image_file=/dist/m5/system/disks/linux-latest.img read_only=true [drivesys.disk2] @@ -115,7 +115,7 @@ table_size=65536 [drivesys.disk2.image.child] type=RawDiskImage -image_file=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/disks/linux-bigswap2.img +image_file=/dist/m5/system/disks/linux-bigswap2.img read_only=true [drivesys.intrctrl] @@ -179,7 +179,7 @@ system=drivesys [drivesys.simple_disk.disk] type=RawDiskImage -image_file=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/disks/linux-latest.img +image_file=/dist/m5/system/disks/linux-latest.img read_only=true [drivesys.terminal] @@ -712,13 +712,13 @@ type=LinuxAlphaSystem children=bridge cpu disk0 disk2 intrctrl iobus membus physmem simple_disk terminal tsunami boot_cpu_frequency=1 boot_osflags=root=/dev/hda1 console=ttyS0 -console=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/binaries/console +console=/dist/m5/system/binaries/console init_param=0 -kernel=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/binaries/vmlinux +kernel=/dist/m5/system/binaries/vmlinux mem_mode=atomic -pal=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/binaries/ts_osfpal +pal=/dist/m5/system/binaries/ts_osfpal physmem=testsys.physmem -readfile=/proj/aatl_perfmod_arch/users/lihsu/m5/m5/configs/boot/netperf-stream-client.rcS +readfile=/n/blue/z/binkert/work/m5/work/configs/boot/netperf-stream-client.rcS symbolfile= system_rev=1024 system_type=34 @@ -799,7 +799,7 @@ table_size=65536 [testsys.disk0.image.child] type=RawDiskImage -image_file=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/disks/linux-latest.img +image_file=/dist/m5/system/disks/linux-latest.img read_only=true [testsys.disk2] @@ -819,7 +819,7 @@ table_size=65536 [testsys.disk2.image.child] type=RawDiskImage -image_file=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/disks/linux-bigswap2.img +image_file=/dist/m5/system/disks/linux-bigswap2.img read_only=true [testsys.intrctrl] @@ -883,7 +883,7 @@ system=testsys [testsys.simple_disk.disk] type=RawDiskImage -image_file=/proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/disks/linux-latest.img +image_file=/dist/m5/system/disks/linux-latest.img read_only=true [testsys.terminal] diff --git a/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/simout b/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/simout index 3d53e8197..749055d7f 100755 --- a/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/simout +++ b/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/simout @@ -5,13 +5,13 @@ The Regents of The University of Michigan All Rights Reserved -M5 compiled Feb 24 2010 23:13:04 -M5 revision 1a33ca29ec29 6980 default share-aware-test-update.patch tip qtip -M5 started Feb 24 2010 23:13:12 -M5 executing on SC2B0619 -command line: build/ALPHA_FS/m5.fast -d build/ALPHA_FS/tests/fast/quick/80.netperf-stream/alpha/linux/twosys-tsunami-simple-atomic -re tests/run.py build/ALPHA_FS/tests/fast/quick/80.netperf-stream/alpha/linux/twosys-tsunami-simple-atomic +M5 compiled Jun 14 2010 18:16:48 +M5 revision 22c414a5ff89+ 7455+ default stats_funcinit.diff qtip tip +M5 started Jun 14 2010 18:19:53 +M5 executing on maize +command line: /n/blue/z/binkert/build/work/build/ALPHA_FS/m5.fast -d /n/blue/z/binkert/build/work/build/ALPHA_FS/tests/fast/quick/80.netperf-stream/alpha/linux/twosys-tsunami-simple-atomic -re tests/run.py /n/blue/z/binkert/build/work/build/ALPHA_FS/tests/fast/quick/80.netperf-stream/alpha/linux/twosys-tsunami-simple-atomic Global frequency set at 1000000000000 ticks per second -info: kernel located at: /proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/binaries/vmlinux -info: kernel located at: /proj/aatl_perfmod_arch/m5_system_files/m5_system_2.0b3/binaries/vmlinux +info: kernel located at: /dist/m5/system/binaries/vmlinux +info: kernel located at: /dist/m5/system/binaries/vmlinux info: Entering event queue @ 0. Starting simulation... Exiting @ tick 4300236804024 because checkpoint diff --git a/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/stats.txt b/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/stats.txt index 72190af46..f998eb975 100644 --- a/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/stats.txt +++ b/tests/quick/80.netperf-stream/ref/alpha/linux/twosys-tsunami-simple-atomic/stats.txt @@ -139,6 +139,7 @@ drivesys.tsunami.ethernet.rxTcpChecksums 8 # Nu drivesys.tsunami.ethernet.rxUdpChecksums 0 # Number of rx UDP Checksums done by device drivesys.tsunami.ethernet.totBandwidth 70320 # Total Bandwidth (bits/s) drivesys.tsunami.ethernet.totBytes 1758 # Total Bytes +drivesys.tsunami.ethernet.totPPS 65 # Total Tranmission Rate (packets/s) drivesys.tsunami.ethernet.totPackets 13 # Total Packets drivesys.tsunami.ethernet.totalRxDesc 8 # total number of RxDesc written to ISR drivesys.tsunami.ethernet.totalRxIdle 0 # total number of RxIdle written to ISR @@ -155,10 +156,10 @@ drivesys.tsunami.ethernet.txPPS 25 # Pa drivesys.tsunami.ethernet.txPackets 5 # Number of Packets Transmitted drivesys.tsunami.ethernet.txTcpChecksums 2 # Number of tx TCP Checksums done by device drivesys.tsunami.ethernet.txUdpChecksums 0 # Number of tx UDP Checksums done by device -host_inst_rate 70382622 # Simulator instruction rate (inst/s) -host_mem_usage 464660 # Number of bytes of host memory used -host_seconds 3.88 # Real time elapsed on the host -host_tick_rate 51489346502 # Simulator tick rate (ticks/s) +host_inst_rate 296969022 # Simulator instruction rate (inst/s) +host_mem_usage 463340 # Number of bytes of host memory used +host_seconds 0.92 # Real time elapsed on the host +host_tick_rate 217224993666 # Simulator tick rate (ticks/s) sim_freq 1000000000000 # Frequency of simulated ticks sim_insts 273374833 # Number of instructions simulated sim_seconds 0.200001 # Number of seconds simulated @@ -312,6 +313,7 @@ testsys.tsunami.ethernet.rxTcpChecksums 5 # Nu testsys.tsunami.ethernet.rxUdpChecksums 0 # Number of rx UDP Checksums done by device testsys.tsunami.ethernet.totBandwidth 70320 # Total Bandwidth (bits/s) testsys.tsunami.ethernet.totBytes 1758 # Total Bytes +testsys.tsunami.ethernet.totPPS 65 # Total Tranmission Rate (packets/s) testsys.tsunami.ethernet.totPackets 13 # Total Packets testsys.tsunami.ethernet.totalRxDesc 5 # total number of RxDesc written to ISR testsys.tsunami.ethernet.totalRxIdle 0 # total number of RxIdle written to ISR @@ -429,10 +431,10 @@ drivesys.tsunami.ethernet.totalSwi 0 # to drivesys.tsunami.ethernet.totalTxDesc 0 # total number of TxDesc written to ISR drivesys.tsunami.ethernet.totalTxIdle 0 # total number of TxIdle written to ISR drivesys.tsunami.ethernet.totalTxOk 0 # total number of TxOk written to ISR -host_inst_rate 166997454490 # Simulator instruction rate (inst/s) -host_mem_usage 464660 # Number of bytes of host memory used +host_inst_rate 197240139250 # Simulator instruction rate (inst/s) +host_mem_usage 463340 # Number of bytes of host memory used host_seconds 0.00 # Real time elapsed on the host -host_tick_rate 453274510 # Simulator tick rate (ticks/s) +host_tick_rate 532144888 # Simulator tick rate (ticks/s) sim_freq 1000000000000 # Frequency of simulated ticks sim_insts 273374833 # Number of instructions simulated sim_seconds 0.000001 # Number of seconds simulated -- cgit v1.2.3