Chromium Code Reviews| Index: runtime/vm/malloc_hooks_unsupported.cc |
| diff --git a/runtime/vm/malloc_hooks_unsupported.cc b/runtime/vm/malloc_hooks_unsupported.cc |
| index 65edca7bff776d8d8c571b97c1e3e95c0e199a2c..8c479963d67f078d014dd01b6bb479facb440964 100644 |
| --- a/runtime/vm/malloc_hooks_unsupported.cc |
| +++ b/runtime/vm/malloc_hooks_unsupported.cc |
| @@ -2,16 +2,38 @@ |
| // for details. All rights reserved. Use of this source code is governed by a |
| // BSD-style license that can be found in the LICENSE file. |
| -#if defined(DART_USE_TCMALLOC) |
| +#include "platform/globals.h" |
| + |
| +#if !defined(DART_USE_TCMALLOC) || defined(PRODUCT) |
| #include "vm/malloc_hooks.h" |
| namespace dart { |
| -void MallocHooks::Init() { |
| - // TODO(bkonyi): Implement |
| +void MallocHooks::InitOnce() { |
|
bkonyi
2017/01/19 20:52:44
Apparently I had forgotten to change the names of
|
| + // Do nothing. |
| +} |
| + |
| + |
| +void MallocHooks::TearDown() { |
| + // Do nothing. |
| +} |
| + |
| + |
| +void MallocHooks::ResetStats() { |
| + // Do nothing. |
| +} |
| + |
| + |
| +intptr_t MallocHooks::allocation_count() { |
| + return 0; |
| +} |
| + |
| + |
| +intptr_t MallocHooks::heap_allocated_memory_in_bytes() { |
| + return 0; |
| } |
| } // namespace dart |
| -#endif // defined(DART_USE_TCMALLOC) |
| +#endif // defined(DART_USE_TCMALLOC) || defined(PRODUCT) |