1 // This test is for testing that the --threshold options in both Massif and
2 // ms_print work as they should. A threshold of 10% is a good choice for
3 // this file, because in some parts of the tree it renders all children
4 // insignificant, and in others parts of the tree it renders only some
5 // children insignificant.
7 // Also, it's deliberate that the 'malloc(2000)' and 'my_malloc1(500)' calls
8 // are in 'main' -- at one point, ms_print was failing to connect some
9 // children arrows when a more significant child didn't have any children of
13 // ->20.00% (2000B) 0x804846A: main (thresholds.c:43)
15 // ->13.00% (1300B) 0x80483A4: my_malloc2 (thresholds.c:16)
17 // (There must be a '|' between the '->'s.)
21 void my_malloc1(int n
)
26 void my_malloc2(int n
)
31 void my_malloc3(int n
)
54 my_malloc1(4000); // All sizes are divisible by 16 -- no slop.