Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Side by Side Diff: runtime/vm/malloc_hooks_unsupported.cc

Issue 2644903003: Implemented basic heap memory allocation tracking in MallocHooks using hooks registered with tcmall… (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/vm/malloc_hooks_test.cc ('k') | runtime/vm/vm_sources.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #if defined(DART_USE_TCMALLOC) 5 #include "platform/globals.h"
6
7 #if !defined(DART_USE_TCMALLOC) || defined(PRODUCT)
6 8
7 #include "vm/malloc_hooks.h" 9 #include "vm/malloc_hooks.h"
8 10
9 namespace dart { 11 namespace dart {
10 12
11 void MallocHooks::Init() { 13 void MallocHooks::InitOnce() {
bkonyi 2017/01/19 20:52:44 Apparently I had forgotten to change the names of
12 // TODO(bkonyi): Implement 14 // Do nothing.
15 }
16
17
18 void MallocHooks::TearDown() {
19 // Do nothing.
20 }
21
22
23 void MallocHooks::ResetStats() {
24 // Do nothing.
25 }
26
27
28 intptr_t MallocHooks::allocation_count() {
29 return 0;
30 }
31
32
33 intptr_t MallocHooks::heap_allocated_memory_in_bytes() {
34 return 0;
13 } 35 }
14 36
15 } // namespace dart 37 } // namespace dart
16 38
17 #endif // defined(DART_USE_TCMALLOC) 39 #endif // defined(DART_USE_TCMALLOC) || defined(PRODUCT)
OLDNEW
« no previous file with comments | « runtime/vm/malloc_hooks_test.cc ('k') | runtime/vm/vm_sources.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698