|
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 # |
|
73 |
|
74 |
|
75 # |
|
76 |
|
77 # =========================================================================== |
|
78 # Leaf rules. We categorize them out first. |
|
79 # All allocations matching these rules DO belong to the category. |
|
80 # =========================================================================== |
|
81 |
|
82 <js> |
|
83 nsXULPrototypeScript::Deserialize |
|
84 |
|
85 <X> |
|
86 XSupportsLocale |
|
87 |
|
88 <X> |
|
89 /usr/X11R6/lib/libX11.so |
|
90 |
|
91 <js> |
|
92 JS_Init |
|
93 |
|
94 <atoms> |
|
95 NS_NewPermanentAtom |
|
96 |
|
97 <images> |
|
98 gif_write |
|
99 |
|
100 <images> |
|
101 imgRequest::OnDataAvailable |
|
102 |
|
103 <images> |
|
104 imgLoader:: |
|
105 |
|
106 <images> |
|
107 jinit_master_decompress |
|
108 |
|
109 <images> |
|
110 jinit_marker_reader |
|
111 |
|
112 <images> |
|
113 jinit_marker_decompress |
|
114 |
|
115 <images> |
|
116 nsJPEGDecoder:: |
|
117 |
|
118 <images> |
|
119 nsGIFDecoder2:: |
|
120 |
|
121 <jar> |
|
122 nsZipArchive::BuildFileList |
|
123 |
|
124 <jar> |
|
125 nsZipArchive::ReadInit |
|
126 |
|
127 <jar> |
|
128 nsJARChannel::Open |
|
129 |
|
130 <xpcom> |
|
131 NS_InitXPCOM2 |
|
132 |
|
133 # xpt file loads |
|
134 <xpcom> |
|
135 xptiInterfaceInfoManager::LoadFile |
|
136 |
|
137 <xpcom> |
|
138 nsGenericModule::Initialize |
|
139 |
|
140 <intl> |
|
141 nsStringBundle |
|
142 |
|
143 <intl> |
|
144 nsLocale:: |
|
145 |
|
146 <intl> |
|
147 nsCharsetConverterManager:: |
|
148 |
|
149 <necko> |
|
150 nsDiskCacheDevice::Init |
|
151 |
|
152 <necko> |
|
153 nsCacheEntryDescriptor::nsTransportWrapper::OpenOutputStream |
|
154 |
|
155 <necko> |
|
156 nsSocketTransport:: |
|
157 |
|
158 <necko> |
|
159 nsCacheService:: |
|
160 |
|
161 <necko> |
|
162 nsDiskCacheStreamIO:: |
|
163 |
|
164 <necko> |
|
165 nsHttpResponseHead:: |
|
166 |
|
167 <wallet> |
|
168 WLLT |
|
169 |
|
170 <xul> |
|
171 nsXULElement::Create |
|
172 |
|
173 <xul> |
|
174 nsXULAttribute::Create |
|
175 |
|
176 <xul> |
|
177 nsXULDocument::AddElementToMap |
|
178 |
|
179 <xul> |
|
180 XULContentSinkImpl::AddAttributes |
|
181 |
|
182 <xul> |
|
183 XULContentSinkImpl::CreateElement |
|
184 |
|
185 <xul> |
|
186 nsXULElement::SetAttr |
|
187 |
|
188 <xul> |
|
189 nsXULDocument::InsertElement |
|
190 |
|
191 <xul> |
|
192 NS_NewXULContentBuilder |
|
193 |
|
194 <xul> |
|
195 nsXULElement::AppendChildTo |
|
196 |
|
197 <xbl> |
|
198 nsXBLPrototypeHandler::AppendHandlerText( |
|
199 |
|
200 <html> |
|
201 FrameArena::AllocateFrame |
|
202 |
|
203 <global-history> |
|
204 nsGlobalHistory::OpenDB |
|
205 |
|
206 <font> |
|
207 nsFontCache:: |
|
208 |
|
209 <font> |
|
210 nsFont::nsFont |
|
211 |
|
212 <gtk> |
|
213 gtk_init |
|
214 |
|
215 <rdf> |
|
216 RDFServiceImpl::GetResource |
|
217 |
|
218 <rdf> |
|
219 RDFContentSinkImpl::AddProperties |
|
220 |
|
221 <rdf> |
|
222 RDFContainerImpl::AppendElement |
|
223 |
|
224 <rdf> |
|
225 RDFXMLDataSourceImpl::Assert |
|
226 |
|
227 <rdf> |
|
228 NS_NewRDFInMemoryDataSource |
|
229 |
|
230 <css> |
|
231 CSSLoaderImpl::ParseSheet |
|
232 |
|
233 <css> |
|
234 CSSParserImpl::Parse( |
|
235 |
|
236 <css> |
|
237 NS_NewCSS |
|
238 |
|
239 <css> |
|
240 RuleHash::AppendRule |
|
241 |
|
242 <css> |
|
243 nsRuleNode::GetStyleData |
|
244 |
|
245 <CSS> |
|
246 SelectorList:: |
|
247 |
|
248 <css> |
|
249 CSSRuleProcessor::RulesMatching |
|
250 |
|
251 <css> |
|
252 CSSStyleSheetImpl::Clone |
|
253 |
|
254 <necko> |
|
255 nsHttpHeaderArray:: |
|
256 |
|
257 <html> |
|
258 nsScanner::Append |
|
259 |
|
260 <html> |
|
261 nsHTMLTokenizer:: |
|
262 |
|
263 <html> |
|
264 NS_NewHTMLTokenizer |
|
265 |
|
266 <html> |
|
267 nsSlidingString:: |
|
268 |
|
269 <html> |
|
270 nsParser:: |
|
271 |
|
272 <html> |
|
273 nsIParserService:: |
|
274 |
|
275 <html> |
|
276 nsCParserNode:: |
|
277 |
|
278 <html> |
|
279 CNavDTD::CNavDTD |
|
280 |
|
281 <html> |
|
282 nsHTMLDocument:: |
|
283 |
|
284 <layout> |
|
285 IncrementalReflow::AddCommand |
|
286 |
|
287 <layout> |
|
288 nsBlockFrame:: |
|
289 |
|
290 <layout> |
|
291 nsBoxFrame:: |
|
292 |
|
293 <layout> |
|
294 nsImageFrame:: |
|
295 |
|
296 <layout> |
|
297 nsInlineFrame:: |
|
298 |
|
299 <layout> |
|
300 nsLeafFrame:: |
|
301 |
|
302 <layout> |
|
303 nsLineLayout:: |
|
304 |
|
305 <layout> |
|
306 nsReflowPath::EnsureSubtreeFor |
|
307 |
|
308 <layout> |
|
309 nsSliderFrame:: |
|
310 |
|
311 <layout> |
|
312 nsScrollBoxFrame:: |
|
313 |
|
314 <layout> |
|
315 nsTextFrame:: |
|
316 |
|
317 <layout> |
|
318 nsTableRowFrame:: |
|
319 |
|
320 <layout> |
|
321 nsTableRowGroupFrame:: |
|
322 |
|
323 <layout> |
|
324 nsViewManager:: |
|
325 |
|
326 <layout> |
|
327 PresShell::ProcessReflowCommands |
|
328 |
|
329 |
|
330 # ====================================================================== |
|
331 # Rules that match higher up on the stack |
|
332 # These go later. |
|
333 # ====================================================================== |
|
334 |
|
335 <preferences> |
|
336 PREF_ |
|
337 |
|
338 <bookmarks> |
|
339 nsBookmarksService:: |
|
340 |
|
341 <xbl> |
|
342 nsXBLService::LoadBindings |
|
343 |
|
344 <xbl> |
|
345 nsXBLBinding::ExecuteAttachedHandler |
|
346 |
|
347 <js> |
|
348 nsXULDocument::LoadScript |
|
349 |
|
350 <js> |
|
351 nsXULDocument::ExecuteScript |
|
352 |
|
353 <xul> |
|
354 XULContentSinkImpl::Open |
|
355 |
|
356 <rdf> |
|
357 RDFContentSinkImpl::HandleEndElement |
|
358 |
|
359 <html> |
|
360 HTMLContentSink::AddAttributes |
|
361 |
|
362 <html> |
|
363 HTMLContentSink::OpenContainer |
|
364 |
|
365 <html> |
|
366 HTMLContentSink::CloseContainer |
|
367 |
|
368 # XXX whom to account LoadImage to? I am going with images. |
|
369 <images> |
|
370 imgLoader::LoadImage |
|
371 |
|
372 <html> |
|
373 StackArena:: |
|
374 |
|
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 # ====================================================================== |
|
381 |
|
382 <rdf> |
|
383 RDFContentSinkImpl:: |
|
384 |
|
385 <dom> |
|
386 nsGenericDOMDataNode:: |
|
387 |
|
388 <dom> |
|
389 nsDOMClassInfo:: |
|
390 |
|
391 <dom> |
|
392 nsDOMSOFactory:: |
|
393 |
|
394 <xul> |
|
395 nsXULTemplateBuilder:: |
|
396 |
|
397 <xul> |
|
398 XULContentSinkImpl::HandleEndElement |
|
399 |
|
400 <xul> |
|
401 nsChromeRegistry:: |
|
402 |
|
403 <js> |
|
404 nsJSContext::EvaluateString |
|
405 |
|
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:: |
|
410 |
|
411 # XXX this is a wild guess -> html What remains here is about |
|
412 # XXX 1.5% of startup footprint |
|
413 <html> |
|
414 HTMLContentSink:: |
|
415 |
|
416 <xbl> |
|
417 nsXBLContentSink:: |
|
418 |
|
419 <xbl> |
|
420 nsXBLStreamListener::OnDataAvailable |
|
421 |
|
422 <necko> |
|
423 nsIOService::NewURI |
|
424 |
|
425 <necko> |
|
426 nsIOService::NewChannelFromURI |
|
427 |
|
428 <necko> |
|
429 nsSegmentedBuffer::AppendNewSegment |
|
430 |
|
431 <necko> |
|
432 nsHttpChannel:: |
|
433 |
|
434 # Catchalls to help categorize |
|
435 # ---------------------------------------------------------------------- |
|
436 <js-catchall> |
|
437 js_ |
|
438 |
|
439 # Everything else |
|
440 # ---------------------------------------------------------------------- |
|
441 # <uncategorized> |
|
442 # This is a predefined category. Don't create it yourself. |