Fix command tree grouping by frame.
Fix command tree grouping by frame.

Fixes a bug introduced by commit 62fa80ab0, where the "last in
frame" events inferred from "start of frame" commands where added
after the "start of frame" event instead of before it, essentially
ending frames on the same command as starting them.

google/agi,Qining/gapid,Qining/gapid,pmuetschard/gapid,Qining/gapid,pmuetschard/gapid,Qining/gapid,google/agi,google/agi,pmuetschard/gapid,google/agi,Qining/gapid,google/gapid,google/gapid,google/gapid,Qining/gapid,google/gapid,google/gapid,google/agi,google/gapid,Qining/gapid,google/agi,pmuetschard/gapid,google/agi,pmuetschard/gapid,pmuetschard/gapid,google/gapid,google/gapid,Qining/gapid,pmuetschard/gapid,google/agi,pmuetschard/gapid