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

Side by Side Diff: third_party/WebKit/Source/wtf/Partitions.cpp

Issue 1327793003: Move WebCache memory dump provider to blink for sub-allocation edges. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Moving branch. Created 5 years, 3 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 29 matching lines...) Expand all
40 40
41 int Partitions::s_initializationLock = 0; 41 int Partitions::s_initializationLock = 0;
42 bool Partitions::s_initialized = false; 42 bool Partitions::s_initialized = false;
43 43
44 PartitionAllocatorGeneric Partitions::m_fastMallocAllocator; 44 PartitionAllocatorGeneric Partitions::m_fastMallocAllocator;
45 PartitionAllocatorGeneric Partitions::m_bufferAllocator; 45 PartitionAllocatorGeneric Partitions::m_bufferAllocator;
46 SizeSpecificPartitionAllocator<3328> Partitions::m_nodeAllocator; 46 SizeSpecificPartitionAllocator<3328> Partitions::m_nodeAllocator;
47 SizeSpecificPartitionAllocator<1024> Partitions::m_layoutAllocator; 47 SizeSpecificPartitionAllocator<1024> Partitions::m_layoutAllocator;
48 HistogramEnumerationFunction Partitions::m_histogramEnumeration = nullptr; 48 HistogramEnumerationFunction Partitions::m_histogramEnumeration = nullptr;
49 49
50 const char* Partitions::m_allocatorPoolNameForTracing;
51
50 void Partitions::initialize() 52 void Partitions::initialize()
51 { 53 {
52 spinLockLock(&s_initializationLock); 54 spinLockLock(&s_initializationLock);
53 55
54 if (!s_initialized) { 56 if (!s_initialized) {
55 partitionAllocGlobalInit(&Partitions::handleOutOfMemory); 57 partitionAllocGlobalInit(&Partitions::handleOutOfMemory);
56 m_fastMallocAllocator.init(); 58 m_fastMallocAllocator.init();
57 m_bufferAllocator.init(); 59 m_bufferAllocator.init();
58 m_nodeAllocator.init(); 60 m_nodeAllocator.init();
59 m_layoutAllocator.init(); 61 m_layoutAllocator.init();
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 if (totalUsage >= 64 * 1024 * 1024) 206 if (totalUsage >= 64 * 1024 * 1024)
205 partitionsOutOfMemoryUsing64M(); 207 partitionsOutOfMemoryUsing64M();
206 if (totalUsage >= 32 * 1024 * 1024) 208 if (totalUsage >= 32 * 1024 * 1024)
207 partitionsOutOfMemoryUsing32M(); 209 partitionsOutOfMemoryUsing32M();
208 if (totalUsage >= 16 * 1024 * 1024) 210 if (totalUsage >= 16 * 1024 * 1024)
209 partitionsOutOfMemoryUsing16M(); 211 partitionsOutOfMemoryUsing16M();
210 partitionsOutOfMemoryUsingLessThan16M(); 212 partitionsOutOfMemoryUsingLessThan16M();
211 } 213 }
212 214
213 } // namespace WTF 215 } // namespace WTF
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/wtf/Partitions.h ('k') | third_party/WebKit/public/platform/WebProcessMemoryDump.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698