This is an archive of the discontinued LLVM Phabricator instance.

[flang] Refine symbol sorting
ClosedPublic

Authored by klausler on Mar 18 2021, 10:30 AM.

Details

Summary

Replace semantics::SymbolSet with alternatives that clarify
whether the set should order its contents by source position
or not. This matters because positionally-ordered sets must
not be used for Symbols that might be subjected to name
replacement during name resolution, and address-ordered
sets must not be used (without sorting) in circumstances
where the order of their contents affects the output of the
compiler.

All set<> and map<> instances in the compiler that are keyed
by Symbols now have explicit Compare types in their template
instantiations. Symbol::operator< is no more.

Resolves lingering portability problems from https://reviews.llvm.org/D98743

Diff Detail

Event Timeline

klausler created this revision.Mar 18 2021, 10:30 AM
klausler requested review of this revision.Mar 18 2021, 10:30 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 18 2021, 10:30 AM
PeteSteinfeld accepted this revision.Mar 18 2021, 10:44 AM

All builds, tests, and looks good.

This revision is now accepted and ready to land.Mar 18 2021, 10:44 AM
tskeith accepted this revision.Mar 18 2021, 11:12 AM
This revision was landed with ongoing or failed builds.Mar 18 2021, 11:18 AM
This revision was automatically updated to reflect the committed changes.