summaryrefslogtreecommitdiffstats
path: root/src/perfglue
diff options
context:
space:
mode:
authorSage Weil <sage@inktank.com>2012-08-17 19:58:24 +0200
committerSage Weil <sage@inktank.com>2012-08-17 19:58:32 +0200
commit1daeb2dd5b9b413a70c6d65ac4d1998fd5c47b88 (patch)
treec91e04b1aa654f7afb162e6357549353eba86c24 /src/perfglue
parentdoc: small RST syntax fixes for eu.ceph.com mirror (diff)
downloadceph-1daeb2dd5b9b413a70c6d65ac4d1998fd5c47b88.tar.xz
ceph-1daeb2dd5b9b413a70c6d65ac4d1998fd5c47b88.zip
cpu_profiler: drop start, stop commands
These don't appear to work. Setting CPUPROFILE=path on startup does. Signed-off-by: Sage Weil <sage@inktank.com>
Diffstat (limited to 'src/perfglue')
-rw-r--r--src/perfglue/cpu_profiler.cc20
1 files changed, 2 insertions, 18 deletions
diff --git a/src/perfglue/cpu_profiler.cc b/src/perfglue/cpu_profiler.cc
index 756c220b5b9..8ba15b0af1a 100644
--- a/src/perfglue/cpu_profiler.cc
+++ b/src/perfglue/cpu_profiler.cc
@@ -20,18 +20,7 @@
void cpu_profiler_handle_command(const std::vector<std::string> &cmd,
ostream& out)
{
- if (cmd[1] == "start") {
- if (cmd.size() < 3) {
- out << "cpu_profiler: you must give an argument to start: a "
- << "file name to log to.";
- return;
- }
- const char *file = cmd[2].c_str();
- int r = ProfilerStart(file);
- out << "cpu_profiler: starting logging to " << file
- << ", r=" << r;
- }
- else if (cmd[1] == "status") {
+ if (cmd[1] == "status") {
ProfilerState st;
ProfilerGetCurrentState(&st);
out << "cpu_profiler " << (st.enabled ? "enabled":"not enabled")
@@ -43,13 +32,8 @@ void cpu_profiler_handle_command(const std::vector<std::string> &cmd,
ProfilerFlush();
out << "cpu_profiler: flushed";
}
- else if (cmd[1] == "stop") {
- ProfilerFlush();
- ProfilerStop();
- out << "cpu_profiler: flushed and stopped";
- }
else {
out << "cpu_profiler: unrecognized command " << cmd
- << "; expected one of start, status, flush, stop.";
+ << "; expected one of status, flush.";
}
}