lebedev.ri added a comment. > Not sure how to test this though? I guess we can trust that std::map is > always sorted just as it says in its description.
You could add a test that contains several entries in `OpenCLTypeExtMap` and several entries in `OpenCLDeclExtMap`. In that test, write te PCH, and then apply `llvm-bcanalyzer` to that PCH. It should dump it the bitcode in textual dump. And then simply apply FileCheck to that textual dump, with CHECK lines requiring the specific order of these entries. If the order is not deterministic in PCH, then that test would (should!) fail sporadically. At least that is my guess. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60778/new/ https://reviews.llvm.org/D60778 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits