Enforce minimum visibility only for normal and panel windows
[chromium-blink-merge.git] / tools / deep_memory_profiler / README.policy
blob48ad9579cc3d1164183a1716fe48e70d5cb6da2c
1 Policy files contains a classification policy for dmprof.py.
3 Each line indicates a group to be classified and conditions for classifying
4 in the following format.
5   Format: <group-name> <region-type> <pattern>
7 <group-name> is a name for the group to be classified.  Same names can appear
8 in the same policy file multiple times.  <region-type> represents a type of
9 the memory region.  It's one of {malloc, mmap, default, optional}.  <pattern>
10 is a Python-style regular expression to match with calling stack frames.
12 For each memory chunks allocated by malloc, its calling stack frame of malloc
13 is compared with these classification policies whose <region-type> is 'malloc'
14 from the top.  If <pattern> of the policy matches the frame, the memory chunk
15 is classified into <group-name>.  The same way for 'mmap'.
17 Policy lines whose <region-type>s are 'optional' and 'default' are used by
18 dmprof.py internally.  'optional' policies can be disabled by removing or
19 commenting-out.
22 Guidelines to write a new policy.
24 Better policies would classify memory on a single layer, or simple combination
25 of layers.  For example,
26 - Large-level components (V8, WebKit, ...)
27 - Mid-level components (Font, FileAPI, ...)
28 - Low-level libraries (StringImpl, HashTable, ...)
29 - Mid-level libraries (SharedBuf, XHR, ...)
31 For example of combinations,
32 - How about SharedBuf in Font API v.s. other APIs?
33 - How about Strings in IndexedDB v.s. File APIs?
36 Deprecated policies for references.
38 total-vm                       optional        optional
39 anonymous-vm                   optional        optional
40 filemapped-vm                  optional        optional
41 other-vm                       optional        optional
42 vm-profiler                    optional        optional
43 vm-total                       optional        optional
44 mmap-v8-heap-new               mmap    .*v8::.*::ReserveInitialChunk.*
45 mmap-v8-heap-coderange         mmap    .*v8::.*::CodeRange::Setup.*
46 mmap-v8-heap-old-evacuate      mmap    .*v8::.*::OldSpace::.* v8::internal::ScavengingVisitor::EvacuateObject.*
47 mmap-v8-heap-old               mmap    .*v8::.*::OldSpace::.*
48 mmap-v8-heap-largeobj          mmap    .*v8::.*::LargeObjectChunk::New.*
49 mmap-v8-heap-other             mmap    .*VirtualMemory.*
50 mmap-v8-heap-other             mmap    .*v8::internal::OS::Allocate.*
51 mmap-v8-nonheap                        mmap    .*v8::.*
52 mmap-webkit                    mmap    .*(WTF::|WebCore::|WebKit::).*
53 mmap-sqlite                    mmap    .*sqlite3MemMalloc.*
54 mmap-pl-arena                  mmap    .*PL_ArenaAllocate.*
55 mmap-sk                        mmap    .*sk_malloc_flags.*
56 mmap-total-record-vm           default default