Definitions

filterTimes[timer[name_,val_,children_],thresh_]:=
Module[{isOK,f},
isOK[timer[n_,v_,ch_]]:=
v>thresh;
f[t_]:=filterTimes[t,thresh];
timer[name,val,f/@Select[children,isOK]]]

addRest[tim:timer[n_,t_,c_]]:=
Module[{cTot,rest},
If[Length[c]===0,Return[tim]];
cTot=Plus@@Map[time,c];
rest=t-cTot;
timer[n,t,Append[addRest/@c,timer["rest",rest,{}]]]];

time[timer[n_,t_,c_]]:=t

prune[t:timer[n_,v_,c_],lev_]:=
timer[n,v,If[lev==0,{},Map[prune[#,lev-1]&,c]]]

norm[timer[n_,v_,c_],tot_]:=
timer[n,100v/tot,Map[norm[#,tot]&,c]]

norm[t:timer[n_,v_,c_]]:=
norm[t,v]

Load timers

timersXML=Import["~/timers.0.xml"];

timers1=timersXML//.{XMLElement[x_,attrs_,{t_,children___}]:>timer["name"/.attrs,ToExpression[t],{children}],
XMLObject[_][_,d_,_]:>d};

timers2=First@Cases[{timers1},timer["Evolve",v_,c_],Infinity];

timers3=norm[timers2];

timers4=filterTimes[timers3,1];

timers5=addRest[timers4];

timers6=filterTimes[timers5,1];

timers=timers6;

Other

XMLNote[XMLElement[tag_,attributes_,data_], m_Integer]:=Cell[CellGroupData[{
Cell[TextData[
StyleBox[tag,FontFamily->"Swiss",
FontWeight->"Bold",FontSize->15]]],
Sequence@@(XMLNote[#1,m]&)/@attributes,
Sequence@@(XMLNote[#1,m+30]&)/@data
},Open],
CellMargins->{{m,Inherited},{Inherited,Inherited}}]

XMLNote[{an_String,a_String}->v_String,m_Integer]:=
Cell[TextData[
StyleBox[an,FontColor->Hue[0.6]]," ",
StyleBox[a,FontWeight->"Bold"]," = ",
StyleBox[v,Background->GrayLevel[0.8]]],
CellMargins->{{m+5,Inherited},{Inherited,Inherited}}]

XMLNote[a_String->v_String,m_Integer]:=
Cell[TextData[
StyleBox[a,FontWeight->"Bold"]," = ",
StyleBox[v,Background->GrayLevel[0.8]]],
CellMargins->{{m+5,Inherited},{Inherited,Inherited}}]

XMLNote[s_String,m_Integer]:=
Cell[s,Background->GrayLevel[0.9],
CellMargins->{{m+25,Inherited},{Inherited,Inherited}}]

NotebookPut@
Notebook[{XMLNote[xml[[2]],0]},CellGrouping->"Manual"]

?CellGroupData

NotebookPut[Notebook[{CellGroupData[{CellGroupData[{Cell["1"],Cell["2"]}],CellGroupData[{Cell["1"],Cell["2"]}]}]}]]

Tree Display

treeView[t:timer[n_,v_,c_]]:=
Module[{node},
If[c==={},
Row[{"  ",v,"% ",n}],
OpenerView[{Row[{v,"% ",n}],
Column[treeView/@c]},True]]]

treeView[timers]

pos[th_]:=
If[th≥7Pi/4||th<Pi/4,{-1,0},
If[th<3Pi/4,{0,-1},
If[th<5Pi/4,{1,0},
If[th<7Pi/4,{0,1}]]]]

remQual[name_]:=StringReplace[name,__~~"::"~~x__:>x]

pieView[timer[n_,v_,c_],th_,r_,idx_]:=
Module[{angles,d=0.01,lineInner,lineOuter,indices,ph=RandomReal[{th,th+2Pi v/100}],ph2,rl=1.2,colRef=ColorData[1][colIdx++],col},
col=If[Length[c]===0,colRef,Lighter@Lighter@colRef];
{col,EdgeForm[Directive[Black]],Tooltip[Disk[{0,0},r,{th,th+2Pi v/100}],n],
ph2=ph;

If[Length[c]===0,
Rotate[Style[Text[remQual@n,{0.1,0},{-1,0}],White],th+2Pi v/100/2,{0,0}],
{Style[Text[remQual@n,rl{Cos[ph2],Sin[ph2]},pos[ph2]],Black,Background->col],
lineInner=(r-0.05){Cos[ph],Sin[ph]};
lineOuter=(rl-0.05){Cos[ph2],Sin[ph2]};
Style[Line[{lineInner,lineOuter}],Directive[Thick]],
Disk[lineInner,0.01]}],
angles=Table[th+Sum[2Pi/100time[c[[j]]],{j,1,i}],{i,0,Length[c]-1}];
indices=Table[i,{i,1,Length[c]}];
MapThread[pieView[#1,#2,r-0.1,idx+1]&,{c,angles}]}]

colIdx=0;Graphics[pieView[prune[timers,20],0,1,1],ImageSize->700]