1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
5 An audio time-stretching and pitch-shifting library.
6 Copyright 2007-2008 Chris Cannam.
8 This program is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License as
10 published by the Free Software Foundation; either version 2 of the
11 License, or (at your option) any later version. See the file
12 COPYING included with this distribution for more information.
20 //#define WANT_TIMING 1
21 //#define PROFILE_CLOCKS 1
42 namespace RubberBand
{
49 Profiler(const char *name
);
52 void end(); // same action as dtor
61 struct timeval m_start
;
63 bool m_showOnDestruct
;
66 typedef std::pair
<int, float> TimePair
;
67 typedef std::map
<const char *, TimePair
> ProfileMap
;
68 typedef std::map
<const char *, float> WorstCallMap
;
69 static ProfileMap m_profiles
;
70 static WorstCallMap m_worstCalls
;
71 static void add(const char *, float);
79 Profiler(const char *) { }
82 void update() const { }
84 static void dump() { }