This is an archive of the discontinued LLVM Phabricator instance.

[Assignment Tracking] Fix faulty assertion inside std::sort predicate
ClosedPublic

Authored by Orlando on Apr 24 2023, 2:30 AM.

Details

Summary

The vectors being sorted here shouldn't contain duplicate entries. Prior to this patch this was checked with an assert within the std::sort predicate. However, std::sort may compare an element against itself which causes the assert to fire (false positive). Move the assert outside of the sort predicate to avoid such issues.

Diff Detail

Event Timeline

Orlando created this revision.Apr 24 2023, 2:30 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 24 2023, 2:30 AM
Orlando requested review of this revision.Apr 24 2023, 2:30 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 24 2023, 2:30 AM
StephenTozer accepted this revision.Apr 26 2023, 2:43 AM
This revision is now accepted and ready to land.Apr 26 2023, 2:43 AM
This revision was landed with ongoing or failed builds.Apr 26 2023, 3:15 AM
This revision was automatically updated to reflect the committed changes.