profile.cc (2665:a124942bacb8) profile.cc (2680:246e7104f744)
1/*
2 * Copyright (c) 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;

--- 22 unchanged lines hidden (view full) ---

31#include <string>
32
33#include "base/bitfield.hh"
34#include "base/callback.hh"
35#include "base/statistics.hh"
36#include "base/trace.hh"
37#include "base/loader/symtab.hh"
38#include "cpu/base.hh"
1/*
2 * Copyright (c) 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;

--- 22 unchanged lines hidden (view full) ---

31#include <string>
32
33#include "base/bitfield.hh"
34#include "base/callback.hh"
35#include "base/statistics.hh"
36#include "base/trace.hh"
37#include "base/loader/symtab.hh"
38#include "cpu/base.hh"
39#include "cpu/exec_context.hh"
39#include "cpu/thread_context.hh"
40#include "cpu/profile.hh"
41
42using namespace std;
43
44ProfileNode::ProfileNode()
45 : count(0)
46{ }
47

--- 67 unchanged lines hidden (view full) ---

115void
116FunctionProfile::clear()
117{
118 top.clear();
119 pc_count.clear();
120}
121
122void
40#include "cpu/profile.hh"
41
42using namespace std;
43
44ProfileNode::ProfileNode()
45 : count(0)
46{ }
47

--- 67 unchanged lines hidden (view full) ---

115void
116FunctionProfile::clear()
117{
118 top.clear();
119 pc_count.clear();
120}
121
122void
123FunctionProfile::dump(ExecContext *xc, ostream &os) const
123FunctionProfile::dump(ThreadContext *tc, ostream &os) const
124{
125 ccprintf(os, ">>>PC data\n");
126 map<Addr, Counter>::const_iterator i, end = pc_count.end();
127 for (i = pc_count.begin(); i != end; ++i) {
128 Addr pc = i->first;
129 Counter count = i->second;
130
131 std::string symbol;

--- 26 unchanged lines hidden ---
124{
125 ccprintf(os, ">>>PC data\n");
126 map<Addr, Counter>::const_iterator i, end = pc_count.end();
127 for (i = pc_count.begin(); i != end; ++i) {
128 Addr pc = i->first;
129 Counter count = i->second;
130
131 std::string symbol;

--- 26 unchanged lines hidden ---