Page MenuHomePhabricator

Clean up some ordering and strata edge cases in Phrequent
ClosedPublic

Authored by epriestley on Oct 18 2013, 9:43 PM.
Tags
None
Referenced Files
F18284051: D7350.id16603.diff
Sat, Aug 23, 2:27 AM
F18284049: D7350.id16553.diff
Sat, Aug 23, 2:27 AM
F18284048: D7350.id.diff
Sat, Aug 23, 2:27 AM
F18106778: D7350.id.diff
Sun, Aug 10, 11:22 PM
F17940722: D7350.id16603.diff
Thu, Jul 31, 4:42 AM
F17936812: D7350.id.diff
Thu, Jul 31, 12:35 AM
F17690063: D7350.id.diff
Jul 14 2025, 3:23 PM
F17683066: D7350.diff
Jul 13 2025, 11:00 PM
Subscribers

Details

Summary

Ref T3569. Two issues:

  1. Since sort() is not stable, instantaneous events (ending on the same second they start) would sometime sort wrong and produce the wrong results. Guarantee they sort correctly.
  2. Because events can end at any time, there are some additional special cases the algorithm didn't handle properly. Draw a bunch of ASCII art diagrams so these cases work properly.
Test Plan
  • No more fatal when tracking an object for the first time.
  • Unit tests.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

"Thank goodness for the ASCII art" the reviewer thought to himself. :D