diff options
author | willchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-19 19:09:30 +0000 |
---|---|---|
committer | willchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-19 19:09:30 +0000 |
commit | 63dc378eac88be2da11255b61d7af140bb89ba55 (patch) | |
tree | e5ae5e3659b8a9bafa3d93f09072901e20338f59 /base/profiler.h | |
parent | 7e96b7ac9c98f54506da88a4d69e9012b164761f (diff) | |
download | chromium_src-63dc378eac88be2da11255b61d7af140bb89ba55.zip chromium_src-63dc378eac88be2da11255b61d7af140bb89ba55.tar.gz chromium_src-63dc378eac88be2da11255b61d7af140bb89ba55.tar.bz2 |
Drop allocator dependency from base library.
This will fix libnpapi_test_plugin from loading TCMalloc.
This undoes the bad dependency from base to allocator added in http://src.chromium.org/viewvc/chrome/trunk/src/base/base.gyp?revision=43477&view=markup, which was required to fix the linux shared build, due to http://src.chromium.org/viewvc/chrome?view=rev&revision=41218 which added the base/profiler.cc compile-time dependency on TCMalloc (rather than a link-time dependency injection, relying on something like weak symbols)
The purify/quantify dependency is indeed compile-time, and is appropriately done in profiler.cc. But, to simply this change, I've killed profiler.cc and only used it in the profiler extension. We can add it back if needed, but it's only been used in that one place for a long time anyway.
BUG=59317,40467
TEST=make -j15 npapi_test_plugin && nm out/Debug/libnpapi_test_plugin.so | grep TCMalloc. Should be empty.
Review URL: http://codereview.chromium.org/3783009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63082 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/profiler.h')
-rw-r--r-- | base/profiler.h | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/base/profiler.h b/base/profiler.h deleted file mode 100644 index ea8867a..0000000 --- a/base/profiler.h +++ /dev/null @@ -1,42 +0,0 @@ -// Copyright (c) 2009 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// An abstraction for functions used to control execution time profiling. -// All methods are effectively no-ops unless this program is being run through -// a supported tool (currently only Quantify, a companion tool to Purify) - -#ifndef BASE_PROFILER_H__ -#define BASE_PROFILER_H__ -#pragma once - -#include "base/basictypes.h" - -namespace base { - -class Profiler { - public: - // Starts or resumes recording. - static void StartRecording(); - - // Stops recording until StartRecording is called or the program exits. - static void StopRecording(); - - // Throw away data collected so far. This can be useful to call before - // your first call to StartRecording, for instance to avoid counting any - // time in application startup. - static void ClearData(); - - // Flushes all recorded data to disk. No-op until recording is started. - static void Flush(); - - // Sets the name of the current thread for display in the profiler's UI. - static void SetThreadName(const char *name); - - private: - DISALLOW_IMPLICIT_CONSTRUCTORS(Profiler); -}; - -} // namespace base - -#endif // BASE_PROFILER_H__ |