base.cc (3125:febd811bccc6) | base.cc (3126:756092c6383c) |
---|---|
1/* 2 * Copyright (c) 2002-2005 The Regents of The University of Michigan 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 46 unchanged lines hidden (view full) --- 55 56vector<BaseCPU *> BaseCPU::cpuList; 57 58// This variable reflects the max number of threads in any CPU. Be 59// careful to only use it once all the CPUs that you care about have 60// been initialized 61int maxThreadsPerCPU = 1; 62 | 1/* 2 * Copyright (c) 2002-2005 The Regents of The University of Michigan 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 46 unchanged lines hidden (view full) --- 55 56vector<BaseCPU *> BaseCPU::cpuList; 57 58// This variable reflects the max number of threads in any CPU. Be 59// careful to only use it once all the CPUs that you care about have 60// been initialized 61int maxThreadsPerCPU = 1; 62 |
63CPUProgressEvent::CPUProgressEvent(EventQueue *q, Tick ival, 64 BaseCPU *_cpu) 65 : Event(q, Event::Stat_Event_Pri), interval(ival), 66 lastNumInst(0), cpu(_cpu) 67{ 68 if (interval) 69 schedule(curTick + interval); 70} 71 |
|
63void 64CPUProgressEvent::process() 65{ 66 Counter temp = cpu->totalInstructions(); 67#ifndef NDEBUG 68 double ipc = double(temp - lastNumInst) / (interval / cpu->cycles(1)); 69 70 DPRINTFN("%s progress event, instructions committed: %lli, IPC: %0.8d\n", --- 80 unchanged lines hidden (view full) --- 151 int *counter = new int; 152 *counter = number_of_threads; 153 for (int i = 0; i < number_of_threads; ++i) 154 new CountedExitEvent(comLoadEventQueue[i], 155 "all threads reached the max load count", 156 p->max_loads_all_threads, *counter); 157 } 158 | 72void 73CPUProgressEvent::process() 74{ 75 Counter temp = cpu->totalInstructions(); 76#ifndef NDEBUG 77 double ipc = double(temp - lastNumInst) / (interval / cpu->cycles(1)); 78 79 DPRINTFN("%s progress event, instructions committed: %lli, IPC: %0.8d\n", --- 80 unchanged lines hidden (view full) --- 160 int *counter = new int; 161 *counter = number_of_threads; 162 for (int i = 0; i < number_of_threads; ++i) 163 new CountedExitEvent(comLoadEventQueue[i], 164 "all threads reached the max load count", 165 p->max_loads_all_threads, *counter); 166 } 167 |
159 if (p->stats_reset_inst != 0) { 160 Stats::SetupEvent(Stats::Reset, p->stats_reset_inst, 0, comInstEventQueue[0]); 161 cprintf("Stats reset event scheduled for %lli insts\n", 162 p->stats_reset_inst); 163 } 164 | |
165#if FULL_SYSTEM 166 memset(interrupts, 0, sizeof(interrupts)); 167 intstatus = 0; 168#endif 169 170 functionTracingEnabled = false; 171 if (p->functionTrace) { 172 functionTraceStream = simout.find(csprintf("ftrace.%s", name())); --- 256 unchanged lines hidden --- | 168#if FULL_SYSTEM 169 memset(interrupts, 0, sizeof(interrupts)); 170 intstatus = 0; 171#endif 172 173 functionTracingEnabled = false; 174 if (p->functionTrace) { 175 functionTraceStream = simout.find(csprintf("ftrace.%s", name())); --- 256 unchanged lines hidden --- |