| Index: third_party/tcmalloc/chromium/src/gperftools/allocated_type_map.h
|
| diff --git a/third_party/tcmalloc/chromium/src/gperftools/allocated_type_map.h b/third_party/tcmalloc/chromium/src/gperftools/allocated_type_map.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..76d0d62b9752e36c9bbaeebcab8c4ce44f58988e
|
| --- /dev/null
|
| +++ b/third_party/tcmalloc/chromium/src/gperftools/allocated_type_map.h
|
| @@ -0,0 +1,32 @@
|
| +// Copyright 2012 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.
|
| +
|
| +#ifndef ALLOCATED_TYPE_MAP_H_
|
| +#define ALLOCATED_TYPE_MAP_H_
|
| +
|
| +#include <typeinfo>
|
| +
|
| +// We don't use PERFTOOLS_DLL_DECL since AllocatedTypeMap works only on Linux.
|
| +
|
| +struct AllocatedObject {
|
| + public:
|
| + AllocatedObject(): size(0), type(NULL) {}
|
| + AllocatedObject(unsigned int size_arg, const std::type_info* type_arg)
|
| + : size(size_arg),
|
| + type(type_arg) {
|
| + }
|
| +
|
| + unsigned int size;
|
| + const std::type_info* type;
|
| +};
|
| +
|
| +void InsertAllocatedType(void* address,
|
| + unsigned int size,
|
| + const std::type_info& type);
|
| +
|
| +void EraseAllocatedType(void* address);
|
| +
|
| +const std::type_info* LookupAllocatedType(const void* address);
|
| +
|
| +#endif // ALLOCATED_TYPE_MAP_H_
|
|
|