Profiler.cc revision 10919
16145Snate@binkert.org/* 210012Snilay@cs.wisc.edu * Copyright (c) 1999-2013 Mark D. Hill and David A. Wood 36145Snate@binkert.org * All rights reserved. 46145Snate@binkert.org * 56145Snate@binkert.org * Redistribution and use in source and binary forms, with or without 66145Snate@binkert.org * modification, are permitted provided that the following conditions are 76145Snate@binkert.org * met: redistributions of source code must retain the above copyright 86145Snate@binkert.org * notice, this list of conditions and the following disclaimer; 96145Snate@binkert.org * redistributions in binary form must reproduce the above copyright 106145Snate@binkert.org * notice, this list of conditions and the following disclaimer in the 116145Snate@binkert.org * documentation and/or other materials provided with the distribution; 126145Snate@binkert.org * neither the name of the copyright holders nor the names of its 136145Snate@binkert.org * contributors may be used to endorse or promote products derived from 146145Snate@binkert.org * this software without specific prior written permission. 156145Snate@binkert.org * 166145Snate@binkert.org * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 176145Snate@binkert.org * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 186145Snate@binkert.org * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 196145Snate@binkert.org * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 206145Snate@binkert.org * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 216145Snate@binkert.org * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 226145Snate@binkert.org * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 236145Snate@binkert.org * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 246145Snate@binkert.org * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 256145Snate@binkert.org * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 266145Snate@binkert.org * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 276145Snate@binkert.org */ 286145Snate@binkert.org 296145Snate@binkert.org/* 306145Snate@binkert.org This file has been modified by Kevin Moore and Dan Nussbaum of the 316145Snate@binkert.org Scalable Systems Research Group at Sun Microsystems Laboratories 326145Snate@binkert.org (http://research.sun.com/scalable/) to support the Adaptive 336145Snate@binkert.org Transactional Memory Test Platform (ATMTP). 346145Snate@binkert.org 356145Snate@binkert.org Please send email to atmtp-interest@sun.com with feedback, questions, or 366145Snate@binkert.org to request future announcements about ATMTP. 376145Snate@binkert.org 386145Snate@binkert.org ---------------------------------------------------------------------- 396145Snate@binkert.org 406145Snate@binkert.org File modification date: 2008-02-23 416145Snate@binkert.org 426145Snate@binkert.org ---------------------------------------------------------------------- 436145Snate@binkert.org*/ 446145Snate@binkert.org 458946Sandreas.hansson@arm.com#include <sys/types.h> 468946Sandreas.hansson@arm.com#include <unistd.h> 477002Snate@binkert.org 487454Snate@binkert.org#include <algorithm> 497832Snate@binkert.org#include <fstream> 507454Snate@binkert.org 517454Snate@binkert.org#include "base/stl_helpers.hh" 527056Snate@binkert.org#include "base/str.hh" 537048Snate@binkert.org#include "mem/protocol/MachineType.hh" 548229Snate@binkert.org#include "mem/protocol/RubyRequest.hh" 557048Snate@binkert.org#include "mem/ruby/network/Network.hh" 567048Snate@binkert.org#include "mem/ruby/profiler/AddressProfiler.hh" 576154Snate@binkert.org#include "mem/ruby/profiler/Profiler.hh" 589598Snilay@cs.wisc.edu#include "mem/ruby/system/Sequencer.hh" 596876Ssteve.reinhardt@amd.com 607055Snate@binkert.orgusing namespace std; 617454Snate@binkert.orgusing m5::stl_helpers::operator<<; 627055Snate@binkert.org 6310012Snilay@cs.wisc.eduProfiler::Profiler(const RubySystemParams *p) 646145Snate@binkert.org{ 657048Snate@binkert.org m_hot_lines = p->hot_lines; 667048Snate@binkert.org m_all_instructions = p->all_instructions; 676876Ssteve.reinhardt@amd.com 6810919Sbrandon.potter@amd.com m_address_profiler_ptr = new AddressProfiler(p->num_of_sequencers, this); 697048Snate@binkert.org m_address_profiler_ptr->setHotLines(m_hot_lines); 707048Snate@binkert.org m_address_profiler_ptr->setAllInstructions(m_all_instructions); 716285Snate@binkert.org 727048Snate@binkert.org if (m_all_instructions) { 7310919Sbrandon.potter@amd.com m_inst_profiler_ptr = new AddressProfiler(p->num_of_sequencers, this); 747048Snate@binkert.org m_inst_profiler_ptr->setHotLines(m_hot_lines); 757048Snate@binkert.org m_inst_profiler_ptr->setAllInstructions(m_all_instructions); 767048Snate@binkert.org } 776285Snate@binkert.org} 786285Snate@binkert.org 796889SBrad.Beckmann@amd.comProfiler::~Profiler() 806889SBrad.Beckmann@amd.com{ 817048Snate@binkert.org} 827048Snate@binkert.org 837048Snate@binkert.orgvoid 8410012Snilay@cs.wisc.eduProfiler::regStats(const std::string &pName) 857048Snate@binkert.org{ 8610012Snilay@cs.wisc.edu if (!m_all_instructions) { 8710012Snilay@cs.wisc.edu m_address_profiler_ptr->regStats(pName); 8810012Snilay@cs.wisc.edu } 8910012Snilay@cs.wisc.edu 9010012Snilay@cs.wisc.edu if (m_all_instructions) { 9110012Snilay@cs.wisc.edu m_inst_profiler_ptr->regStats(pName); 9210012Snilay@cs.wisc.edu } 9310012Snilay@cs.wisc.edu 9410012Snilay@cs.wisc.edu delayHistogram 9510012Snilay@cs.wisc.edu .init(10) 9610012Snilay@cs.wisc.edu .name(pName + ".delayHist") 9710012Snilay@cs.wisc.edu .desc("delay histogram for all message") 9810012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 9910012Snilay@cs.wisc.edu 10010012Snilay@cs.wisc.edu uint32_t numVNets = Network::getNumberOfVirtualNetworks(); 10110012Snilay@cs.wisc.edu for (int i = 0; i < numVNets; i++) { 10210012Snilay@cs.wisc.edu delayVCHistogram.push_back(new Stats::Histogram()); 10310012Snilay@cs.wisc.edu delayVCHistogram[i] 10410012Snilay@cs.wisc.edu ->init(10) 10510012Snilay@cs.wisc.edu .name(pName + csprintf(".delayVCHist.vnet_%i", i)) 10610012Snilay@cs.wisc.edu .desc(csprintf("delay histogram for vnet_%i", i)) 10710012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 10810012Snilay@cs.wisc.edu } 10910012Snilay@cs.wisc.edu 11010012Snilay@cs.wisc.edu m_outstandReqHist 11110012Snilay@cs.wisc.edu .init(10) 11210012Snilay@cs.wisc.edu .name(pName + ".outstanding_req_hist") 11310012Snilay@cs.wisc.edu .desc("") 11410012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 11510012Snilay@cs.wisc.edu 11610012Snilay@cs.wisc.edu m_latencyHist 11710012Snilay@cs.wisc.edu .init(10) 11810012Snilay@cs.wisc.edu .name(pName + ".latency_hist") 11910012Snilay@cs.wisc.edu .desc("") 12010012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 12110012Snilay@cs.wisc.edu 12210012Snilay@cs.wisc.edu m_hitLatencyHist 12310012Snilay@cs.wisc.edu .init(10) 12410012Snilay@cs.wisc.edu .name(pName + ".hit_latency_hist") 12510012Snilay@cs.wisc.edu .desc("") 12610012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 12710012Snilay@cs.wisc.edu 12810012Snilay@cs.wisc.edu m_missLatencyHist 12910012Snilay@cs.wisc.edu .init(10) 13010012Snilay@cs.wisc.edu .name(pName + ".miss_latency_hist") 13110012Snilay@cs.wisc.edu .desc("") 13210012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 13310012Snilay@cs.wisc.edu 13410012Snilay@cs.wisc.edu for (int i = 0; i < RubyRequestType_NUM; i++) { 13510012Snilay@cs.wisc.edu m_typeLatencyHist.push_back(new Stats::Histogram()); 13610012Snilay@cs.wisc.edu m_typeLatencyHist[i] 13710012Snilay@cs.wisc.edu ->init(10) 13810012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.latency_hist", 13910012Snilay@cs.wisc.edu RubyRequestType(i))) 14010012Snilay@cs.wisc.edu .desc("") 14110012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 14210012Snilay@cs.wisc.edu 14310012Snilay@cs.wisc.edu m_hitTypeLatencyHist.push_back(new Stats::Histogram()); 14410012Snilay@cs.wisc.edu m_hitTypeLatencyHist[i] 14510012Snilay@cs.wisc.edu ->init(10) 14610012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.hit_latency_hist", 14710012Snilay@cs.wisc.edu RubyRequestType(i))) 14810012Snilay@cs.wisc.edu .desc("") 14910012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 15010012Snilay@cs.wisc.edu 15110012Snilay@cs.wisc.edu m_missTypeLatencyHist.push_back(new Stats::Histogram()); 15210012Snilay@cs.wisc.edu m_missTypeLatencyHist[i] 15310012Snilay@cs.wisc.edu ->init(10) 15410012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.miss_latency_hist", 15510012Snilay@cs.wisc.edu RubyRequestType(i))) 15610012Snilay@cs.wisc.edu .desc("") 15710012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 15810012Snilay@cs.wisc.edu } 15910012Snilay@cs.wisc.edu 16010012Snilay@cs.wisc.edu for (int i = 0; i < MachineType_NUM; i++) { 16110012Snilay@cs.wisc.edu m_hitMachLatencyHist.push_back(new Stats::Histogram()); 16210012Snilay@cs.wisc.edu m_hitMachLatencyHist[i] 16310012Snilay@cs.wisc.edu ->init(10) 16410012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.hit_mach_latency_hist", 16510012Snilay@cs.wisc.edu MachineType(i))) 16610012Snilay@cs.wisc.edu .desc("") 16710012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 16810012Snilay@cs.wisc.edu 16910012Snilay@cs.wisc.edu m_missMachLatencyHist.push_back(new Stats::Histogram()); 17010012Snilay@cs.wisc.edu m_missMachLatencyHist[i] 17110012Snilay@cs.wisc.edu ->init(10) 17210012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.miss_mach_latency_hist", 17310012Snilay@cs.wisc.edu MachineType(i))) 17410012Snilay@cs.wisc.edu .desc("") 17510012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 17610012Snilay@cs.wisc.edu 17710012Snilay@cs.wisc.edu m_IssueToInitialDelayHist.push_back(new Stats::Histogram()); 17810012Snilay@cs.wisc.edu m_IssueToInitialDelayHist[i] 17910012Snilay@cs.wisc.edu ->init(10) 18010012Snilay@cs.wisc.edu .name(pName + csprintf( 18110012Snilay@cs.wisc.edu ".%s.miss_latency_hist.issue_to_initial_request", 18210012Snilay@cs.wisc.edu MachineType(i))) 18310012Snilay@cs.wisc.edu .desc("") 18410012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 18510012Snilay@cs.wisc.edu 18610012Snilay@cs.wisc.edu m_InitialToForwardDelayHist.push_back(new Stats::Histogram()); 18710012Snilay@cs.wisc.edu m_InitialToForwardDelayHist[i] 18810012Snilay@cs.wisc.edu ->init(10) 18910012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.miss_latency_hist.initial_to_forward", 19010012Snilay@cs.wisc.edu MachineType(i))) 19110012Snilay@cs.wisc.edu .desc("") 19210012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 19310012Snilay@cs.wisc.edu 19410012Snilay@cs.wisc.edu m_ForwardToFirstResponseDelayHist.push_back(new Stats::Histogram()); 19510012Snilay@cs.wisc.edu m_ForwardToFirstResponseDelayHist[i] 19610012Snilay@cs.wisc.edu ->init(10) 19710012Snilay@cs.wisc.edu .name(pName + csprintf( 19810012Snilay@cs.wisc.edu ".%s.miss_latency_hist.forward_to_first_response", 19910012Snilay@cs.wisc.edu MachineType(i))) 20010012Snilay@cs.wisc.edu .desc("") 20110012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 20210012Snilay@cs.wisc.edu 20310012Snilay@cs.wisc.edu m_FirstResponseToCompletionDelayHist.push_back(new Stats::Histogram()); 20410012Snilay@cs.wisc.edu m_FirstResponseToCompletionDelayHist[i] 20510012Snilay@cs.wisc.edu ->init(10) 20610012Snilay@cs.wisc.edu .name(pName + csprintf( 20710012Snilay@cs.wisc.edu ".%s.miss_latency_hist.first_response_to_completion", 20810012Snilay@cs.wisc.edu MachineType(i))) 20910012Snilay@cs.wisc.edu .desc("") 21010012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 21110012Snilay@cs.wisc.edu 21210012Snilay@cs.wisc.edu m_IncompleteTimes[i] 21310012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.incomplete_times", MachineType(i))) 21410012Snilay@cs.wisc.edu .desc("") 21510012Snilay@cs.wisc.edu .flags(Stats::nozero); 21610012Snilay@cs.wisc.edu } 21710012Snilay@cs.wisc.edu 21810012Snilay@cs.wisc.edu for (int i = 0; i < RubyRequestType_NUM; i++) { 21910012Snilay@cs.wisc.edu m_hitTypeMachLatencyHist.push_back(std::vector<Stats::Histogram *>()); 22010012Snilay@cs.wisc.edu m_missTypeMachLatencyHist.push_back(std::vector<Stats::Histogram *>()); 22110012Snilay@cs.wisc.edu 22210012Snilay@cs.wisc.edu for (int j = 0; j < MachineType_NUM; j++) { 22310012Snilay@cs.wisc.edu m_hitTypeMachLatencyHist[i].push_back(new Stats::Histogram()); 22410012Snilay@cs.wisc.edu m_hitTypeMachLatencyHist[i][j] 22510012Snilay@cs.wisc.edu ->init(10) 22610012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.%s.hit_type_mach_latency_hist", 22710012Snilay@cs.wisc.edu RubyRequestType(i), MachineType(j))) 22810012Snilay@cs.wisc.edu .desc("") 22910012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 23010012Snilay@cs.wisc.edu 23110012Snilay@cs.wisc.edu m_missTypeMachLatencyHist[i].push_back(new Stats::Histogram()); 23210012Snilay@cs.wisc.edu m_missTypeMachLatencyHist[i][j] 23310012Snilay@cs.wisc.edu ->init(10) 23410012Snilay@cs.wisc.edu .name(pName + csprintf(".%s.%s.miss_type_mach_latency_hist", 23510012Snilay@cs.wisc.edu RubyRequestType(i), MachineType(j))) 23610012Snilay@cs.wisc.edu .desc("") 23710012Snilay@cs.wisc.edu .flags(Stats::nozero | Stats::pdf | Stats::oneline); 23810012Snilay@cs.wisc.edu } 23910012Snilay@cs.wisc.edu } 2407048Snate@binkert.org} 2417048Snate@binkert.org 2427048Snate@binkert.orgvoid 24310012Snilay@cs.wisc.eduProfiler::collateStats() 2449496Snilay@cs.wisc.edu{ 24510012Snilay@cs.wisc.edu if (!m_all_instructions) { 24610012Snilay@cs.wisc.edu m_address_profiler_ptr->collateStats(); 2479496Snilay@cs.wisc.edu } 2489496Snilay@cs.wisc.edu 24910012Snilay@cs.wisc.edu if (m_all_instructions) { 25010012Snilay@cs.wisc.edu m_inst_profiler_ptr->collateStats(); 2519496Snilay@cs.wisc.edu } 2529497Snilay@cs.wisc.edu 2539497Snilay@cs.wisc.edu uint32_t numVNets = Network::getNumberOfVirtualNetworks(); 2549497Snilay@cs.wisc.edu for (uint32_t i = 0; i < MachineType_NUM; i++) { 2559497Snilay@cs.wisc.edu for (map<uint32_t, AbstractController*>::iterator it = 2569497Snilay@cs.wisc.edu g_abs_controls[i].begin(); 2579497Snilay@cs.wisc.edu it != g_abs_controls[i].end(); ++it) { 2589497Snilay@cs.wisc.edu 2599497Snilay@cs.wisc.edu AbstractController *ctr = (*it).second; 2609497Snilay@cs.wisc.edu delayHistogram.add(ctr->getDelayHist()); 2619497Snilay@cs.wisc.edu 2629497Snilay@cs.wisc.edu for (uint32_t i = 0; i < numVNets; i++) { 26310012Snilay@cs.wisc.edu delayVCHistogram[i]->add(ctr->getDelayVCHist(i)); 2649497Snilay@cs.wisc.edu } 2659497Snilay@cs.wisc.edu } 2669497Snilay@cs.wisc.edu } 2679497Snilay@cs.wisc.edu 2689598Snilay@cs.wisc.edu for (uint32_t i = 0; i < MachineType_NUM; i++) { 2699598Snilay@cs.wisc.edu for (map<uint32_t, AbstractController*>::iterator it = 27010012Snilay@cs.wisc.edu g_abs_controls[i].begin(); 27110012Snilay@cs.wisc.edu it != g_abs_controls[i].end(); ++it) { 2729598Snilay@cs.wisc.edu 2739598Snilay@cs.wisc.edu AbstractController *ctr = (*it).second; 2749598Snilay@cs.wisc.edu Sequencer *seq = ctr->getSequencer(); 2759598Snilay@cs.wisc.edu if (seq != NULL) { 27610012Snilay@cs.wisc.edu m_outstandReqHist.add(seq->getOutstandReqHist()); 2779598Snilay@cs.wisc.edu } 2789598Snilay@cs.wisc.edu } 2799598Snilay@cs.wisc.edu } 2809598Snilay@cs.wisc.edu 2819773Snilay@cs.wisc.edu for (uint32_t i = 0; i < MachineType_NUM; i++) { 2829773Snilay@cs.wisc.edu for (map<uint32_t, AbstractController*>::iterator it = 28310012Snilay@cs.wisc.edu g_abs_controls[i].begin(); 28410012Snilay@cs.wisc.edu it != g_abs_controls[i].end(); ++it) { 2859773Snilay@cs.wisc.edu 2869773Snilay@cs.wisc.edu AbstractController *ctr = (*it).second; 2879773Snilay@cs.wisc.edu Sequencer *seq = ctr->getSequencer(); 2889773Snilay@cs.wisc.edu if (seq != NULL) { 2899773Snilay@cs.wisc.edu // add all the latencies 29010012Snilay@cs.wisc.edu m_latencyHist.add(seq->getLatencyHist()); 29110012Snilay@cs.wisc.edu m_hitLatencyHist.add(seq->getHitLatencyHist()); 29210012Snilay@cs.wisc.edu m_missLatencyHist.add(seq->getMissLatencyHist()); 2939773Snilay@cs.wisc.edu 2949773Snilay@cs.wisc.edu // add the per request type latencies 2959773Snilay@cs.wisc.edu for (uint32_t j = 0; j < RubyRequestType_NUM; ++j) { 29610012Snilay@cs.wisc.edu m_typeLatencyHist[j] 29710012Snilay@cs.wisc.edu ->add(seq->getTypeLatencyHist(j)); 29810012Snilay@cs.wisc.edu m_hitTypeLatencyHist[j] 29910012Snilay@cs.wisc.edu ->add(seq->getHitTypeLatencyHist(j)); 30010012Snilay@cs.wisc.edu m_missTypeLatencyHist[j] 30110012Snilay@cs.wisc.edu ->add(seq->getMissTypeLatencyHist(j)); 3029773Snilay@cs.wisc.edu } 3039773Snilay@cs.wisc.edu 3049773Snilay@cs.wisc.edu // add the per machine type miss latencies 3059773Snilay@cs.wisc.edu for (uint32_t j = 0; j < MachineType_NUM; ++j) { 30610012Snilay@cs.wisc.edu m_hitMachLatencyHist[j] 30710012Snilay@cs.wisc.edu ->add(seq->getHitMachLatencyHist(j)); 30810012Snilay@cs.wisc.edu m_missMachLatencyHist[j] 30910012Snilay@cs.wisc.edu ->add(seq->getMissMachLatencyHist(j)); 3109773Snilay@cs.wisc.edu 31110012Snilay@cs.wisc.edu m_IssueToInitialDelayHist[j]->add( 3129773Snilay@cs.wisc.edu seq->getIssueToInitialDelayHist(MachineType(j))); 3139773Snilay@cs.wisc.edu 31410012Snilay@cs.wisc.edu m_InitialToForwardDelayHist[j]->add( 3159773Snilay@cs.wisc.edu seq->getInitialToForwardDelayHist(MachineType(j))); 31610012Snilay@cs.wisc.edu m_ForwardToFirstResponseDelayHist[j]->add(seq-> 3179773Snilay@cs.wisc.edu getForwardRequestToFirstResponseHist(MachineType(j))); 3189773Snilay@cs.wisc.edu 31910012Snilay@cs.wisc.edu m_FirstResponseToCompletionDelayHist[j]->add(seq-> 32010012Snilay@cs.wisc.edu getFirstResponseToCompletionDelayHist( 32110012Snilay@cs.wisc.edu MachineType(j))); 32210012Snilay@cs.wisc.edu m_IncompleteTimes[j] += 3239773Snilay@cs.wisc.edu seq->getIncompleteTimes(MachineType(j)); 3249773Snilay@cs.wisc.edu } 3259773Snilay@cs.wisc.edu 3269773Snilay@cs.wisc.edu // add the per (request, machine) type miss latencies 3279773Snilay@cs.wisc.edu for (uint32_t j = 0; j < RubyRequestType_NUM; j++) { 3289773Snilay@cs.wisc.edu for (uint32_t k = 0; k < MachineType_NUM; k++) { 32910012Snilay@cs.wisc.edu m_hitTypeMachLatencyHist[j][k]->add( 33010012Snilay@cs.wisc.edu seq->getHitTypeMachLatencyHist(j,k)); 33110012Snilay@cs.wisc.edu m_missTypeMachLatencyHist[j][k]->add( 33210012Snilay@cs.wisc.edu seq->getMissTypeMachLatencyHist(j,k)); 3339773Snilay@cs.wisc.edu } 3349773Snilay@cs.wisc.edu } 3359773Snilay@cs.wisc.edu } 3369773Snilay@cs.wisc.edu } 3379773Snilay@cs.wisc.edu } 3386145Snate@binkert.org} 3396145Snate@binkert.org 3407048Snate@binkert.orgvoid 3418174Snilay@cs.wisc.eduProfiler::addAddressTraceSample(const RubyRequest& msg, NodeID id) 3426145Snate@binkert.org{ 3438165Snilay@cs.wisc.edu if (msg.getType() != RubyRequestType_IFETCH) { 3447048Snate@binkert.org // Note: The following line should be commented out if you 3457048Snate@binkert.org // want to use the special profiling that is part of the GS320 3467048Snate@binkert.org // protocol 3476145Snate@binkert.org 3487048Snate@binkert.org // NOTE: Unless PROFILE_HOT_LINES is enabled, nothing will be 3497048Snate@binkert.org // profiled by the AddressProfiler 3507048Snate@binkert.org m_address_profiler_ptr-> 3517048Snate@binkert.org addTraceSample(msg.getLineAddress(), msg.getProgramCounter(), 3527048Snate@binkert.org msg.getType(), msg.getAccessMode(), id, false); 3537048Snate@binkert.org } 3546145Snate@binkert.org} 355