From: Lisong Xu <lis...@gm...> - 2012-06-19 16:40:55
|
Maynard, Thank you very much! One more question about that equation. On Mon, Jun 18, 2012 at 10:05 AM, Maynard Johnson <may...@us...>wrote: > > 2. my understanding is that the total number of samples above the > non-indented line (functions called it) should be equal to the total number > of samples of below it (functions called by it). However, in this example, > the number of scoped_ptr samples is 88, but the number of Impl and > checked_delete samples is 99. Why there is a difference between 88 and 99? > > There is no such equation. Take the example of a()->b()->printf(), but > b() only calls printf() when a() passes a particular value. The callgraph > entry for b() would show a higher count for a() than for printf(). > > For your example, I guess we will have the following output x 100 a y ... b y .... b [self] z .... printf According to your example, we have z < x. But I think x = y+z. is it right? Thank you again! Lisong |