tools/trace-malloc/rules.txt

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

     1 # Categorization rules for spacetrace
     2 #
     3 # This file defines the stack frame rules that will categorize
     4 # allocations that spacetrace processes. The format of this file is
     5 #
     6 #       <categoryname>
     7 #       initial string match for stack frame n
     8 #       initial string match for stack frame n+1
     9 #       initial string match for stack frame n+2
    10 #
    11 # The key in the matching rule is that for every rule, we provide a
    12 # snippet of the stack frame - contiguous substring matches.
    13 # categorynames and rules substring matches are case sensitive
    14 #
    15 # Predefined Categories
    16 # "All"           - All allocations [default]
    17 # "uncategorized" - All allocations that don't match any category
    18 #
    19 #
    20 # Suresh Duddi <dp@netscape.com>
    21 ###########################################################################
    22 # NOTE: This is still under definition
    23 ###########################################################################
    24 # General principle of categorization:
    25 #
    26 # - Each category, in general, denotes a module or feature.
    27 #
    28 # - We assign each allocation to the module/feature that directly
    29 #   caused the allocation irrespective of which higher level module
    30 #   caused the allocation. There are very few exceptions usually when
    31 #   an allocation belongs both to a feature-category and to a
    32 #   module-category.
    33 #
    34 # bookmarks
    35 #       Bookmarks. Mainly initialization. Does not include menu cost.
    36 # css
    37 #       Cascading style sheets
    38 # dom
    39 #       Memory held by DOM.
    40 # font
    41 #       All font stuff
    42 # global-history
    43 # html
    44 #       html parsing and layout
    45 # layout
    46 #       reflow, frames, line, view
    47 # images
    48 #       All images.
    49 # jar
    50 #       jar, zip
    51 # js
    52 #       javascript
    53 # necko
    54 #       All protocol and uri stuff. All urls created accounted here
    55 # preferences
    56 #       Preferences stuff. All js cost for preferences is included here.
    57 ## rdf
    58 #       Most of the rdf allocations. rdf cost from xul, chromeregistry,
    59 #       is assigned to xul. 
    60 #
    61 # wallet
    62 #       Form cache.
    63 #
    64 # xbl
    65 #       xbl stuff. Includes js in xbl.
    66 # xpcom
    67 #       xpcom, xpt. Allocations for creations of objects are assigned
    68 #       onto the respective modules 
    69 # xul
    70 #       XUL parsing and layout. Includes rdf overhead from xul like
    71 #       nsChromeRegistry
    72 # 
    75 #
    77 # ===========================================================================
    78 # Leaf rules. We categorize them out first.
    79 # All allocations matching these rules DO belong to the category.
    80 # ===========================================================================
    82 <js>
    83 nsXULPrototypeScript::Deserialize
    85 <X>
    86 XSupportsLocale
    88 <X>
    89 /usr/X11R6/lib/libX11.so
    91 <js>
    92 JS_Init
    94 <atoms>
    95 NS_NewPermanentAtom
    97 <images>
    98 gif_write
   100 <images>
   101 imgRequest::OnDataAvailable
   103 <images>
   104 imgLoader::
   106 <images>
   107 jinit_master_decompress
   109 <images>
   110 jinit_marker_reader
   112 <images>
   113 jinit_marker_decompress
   115 <images>
   116 nsJPEGDecoder::
   118 <images>
   119 nsGIFDecoder2::
   121 <jar>
   122 nsZipArchive::BuildFileList
   124 <jar>
   125 nsZipArchive::ReadInit
   127 <jar>
   128 nsJARChannel::Open
   130 <xpcom>
   131 NS_InitXPCOM2
   133 # xpt file loads
   134 <xpcom>
   135 xptiInterfaceInfoManager::LoadFile
   137 <xpcom>
   138 nsGenericModule::Initialize
   140 <intl>
   141 nsStringBundle
   143 <intl>
   144 nsLocale::
   146 <intl>
   147 nsCharsetConverterManager::
   149 <necko>
   150 nsDiskCacheDevice::Init
   152 <necko>
   153 nsCacheEntryDescriptor::nsTransportWrapper::OpenOutputStream
   155 <necko>
   156 nsSocketTransport::
   158 <necko>
   159 nsCacheService::
   161 <necko>
   162 nsDiskCacheStreamIO::
   164 <necko>
   165 nsHttpResponseHead::
   167 <wallet>
   168 WLLT
   170 <xul>
   171 nsXULElement::Create
   173 <xul>
   174 nsXULAttribute::Create
   176 <xul>
   177 nsXULDocument::AddElementToMap
   179 <xul>
   180 XULContentSinkImpl::AddAttributes
   182 <xul>
   183 XULContentSinkImpl::CreateElement
   185 <xul>
   186 nsXULElement::SetAttr
   188 <xul>
   189 nsXULDocument::InsertElement
   191 <xul>
   192 NS_NewXULContentBuilder
   194 <xul>
   195 nsXULElement::AppendChildTo
   197 <xbl>
   198 nsXBLPrototypeHandler::AppendHandlerText(
   200 <html>
   201 FrameArena::AllocateFrame
   203 <global-history>
   204 nsGlobalHistory::OpenDB
   206 <font>
   207 nsFontCache::
   209 <font>
   210 nsFont::nsFont
   212 <gtk>
   213 gtk_init
   215 <rdf>
   216 RDFServiceImpl::GetResource
   218 <rdf>
   219 RDFContentSinkImpl::AddProperties
   221 <rdf>
   222 RDFContainerImpl::AppendElement
   224 <rdf>
   225 RDFXMLDataSourceImpl::Assert
   227 <rdf>
   228 NS_NewRDFInMemoryDataSource
   230 <css>
   231 CSSLoaderImpl::ParseSheet
   233 <css>
   234 CSSParserImpl::Parse(
   236 <css>
   237 NS_NewCSS
   239 <css>
   240 RuleHash::AppendRule
   242 <css>
   243 nsRuleNode::GetStyleData
   245 <CSS>
   246 SelectorList::
   248 <css>
   249 CSSRuleProcessor::RulesMatching
   251 <css>
   252 CSSStyleSheetImpl::Clone
   254 <necko>
   255 nsHttpHeaderArray::
   257 <html>
   258 nsScanner::Append
   260 <html>
   261 nsHTMLTokenizer::
   263 <html>
   264 NS_NewHTMLTokenizer
   266 <html>
   267 nsSlidingString::
   269 <html>
   270 nsParser::
   272 <html>
   273 nsIParserService::
   275 <html>
   276 nsCParserNode::
   278 <html>
   279 CNavDTD::CNavDTD
   281 <html>
   282 nsHTMLDocument::
   284 <layout>
   285 IncrementalReflow::AddCommand
   287 <layout>
   288 nsBlockFrame::
   290 <layout>
   291 nsBoxFrame::
   293 <layout>
   294 nsImageFrame::
   296 <layout>
   297 nsInlineFrame::
   299 <layout>
   300 nsLeafFrame::
   302 <layout>
   303 nsLineLayout::
   305 <layout>
   306 nsReflowPath::EnsureSubtreeFor
   308 <layout>
   309 nsSliderFrame::
   311 <layout>
   312 nsScrollBoxFrame::
   314 <layout>
   315 nsTextFrame::
   317 <layout>
   318 nsTableRowFrame::
   320 <layout>
   321 nsTableRowGroupFrame::
   323 <layout>
   324 nsViewManager::
   326 <layout>
   327 PresShell::ProcessReflowCommands
   330 # ======================================================================
   331 # Rules that match higher up on the stack
   332 # These go later.
   333 # ======================================================================
   335 <preferences>
   336 PREF_
   338 <bookmarks>
   339 nsBookmarksService::
   341 <xbl>
   342 nsXBLService::LoadBindings
   344 <xbl>
   345 nsXBLBinding::ExecuteAttachedHandler
   347 <js>
   348 nsXULDocument::LoadScript
   350 <js>
   351 nsXULDocument::ExecuteScript
   353 <xul>
   354 XULContentSinkImpl::Open
   356 <rdf>
   357 RDFContentSinkImpl::HandleEndElement
   359 <html>
   360 HTMLContentSink::AddAttributes
   362 <html>
   363 HTMLContentSink::OpenContainer
   365 <html>
   366 HTMLContentSink::CloseContainer
   368 # XXX whom to account LoadImage to? I am going with images.
   369 <images>
   370 imgLoader::LoadImage
   372 <html>
   373 StackArena::
   375 # ======================================================================
   376 # Even more genralized rules. There could be lots of activity that
   377 # happens below them in the stack. But we are sure we have categorized
   378 # a lot of them by using the rules above and know the category of the
   379 # most of the rest.
   380 # ======================================================================
   382 <rdf>
   383 RDFContentSinkImpl::
   385 <dom>
   386 nsGenericDOMDataNode::
   388 <dom>
   389 nsDOMClassInfo::
   391 <dom>
   392 nsDOMSOFactory::
   394 <xul>
   395 nsXULTemplateBuilder::
   397 <xul>
   398 XULContentSinkImpl::HandleEndElement
   400 <xul>
   401 nsChromeRegistry::
   403 <js>
   404 nsJSContext::EvaluateString
   406 # Almost all of what is left with XULContentSink belongs to xul
   407 # Also, this was roughly 0.3% of startup memory
   408 <xul>
   409 XULContentSinkImpl::
   411 # XXX this is a wild guess -> html What remains here is about
   412 # XXX 1.5% of startup footprint
   413 <html>
   414 HTMLContentSink::
   416 <xbl>
   417 nsXBLContentSink::
   419 <xbl>
   420 nsXBLStreamListener::OnDataAvailable
   422 <necko>
   423 nsIOService::NewURI
   425 <necko>
   426 nsIOService::NewChannelFromURI
   428 <necko>
   429 nsSegmentedBuffer::AppendNewSegment
   431 <necko>
   432 nsHttpChannel::
   434 # Catchalls to help categorize
   435 # ----------------------------------------------------------------------
   436 <js-catchall>
   437 js_
   439 # Everything else
   440 # ----------------------------------------------------------------------
   441 # <uncategorized>
   442 # This is a predefined category. Don't create it yourself.

mercurial