summaryrefslogtreecommitdiffstats
path: root/clang/utils/TableGen/ClangOptionDocEmitter.cpp
diff options
context:
space:
mode:
authorMandeep Singh Grang <mgrang@codeaurora.org>2018-03-27 16:50:00 +0000
committerMandeep Singh Grang <mgrang@codeaurora.org>2018-03-27 16:50:00 +0000
commitc205d8cc8dcce3d9f47f9d78c03eed7820d265e9 (patch)
tree3e4c2781e80d071551b7ad85dbcbd7fa2fbd6b72 /clang/utils/TableGen/ClangOptionDocEmitter.cpp
parent52396bb9c55044063c25bc19e8f22e32d4df11e3 (diff)
downloadbcm5719-llvm-c205d8cc8dcce3d9f47f9d78c03eed7820d265e9.tar.gz
bcm5719-llvm-c205d8cc8dcce3d9f47f9d78c03eed7820d265e9.zip
[clang] Change std::sort to llvm::sort in response to r327219
r327219 added wrappers to std::sort which randomly shuffle the container before sorting. This will help in uncovering non-determinism caused due to undefined sorting order of objects having the same key. To make use of that infrastructure we need to invoke llvm::sort instead of std::sort. llvm-svn: 328636
Diffstat (limited to 'clang/utils/TableGen/ClangOptionDocEmitter.cpp')
-rw-r--r--clang/utils/TableGen/ClangOptionDocEmitter.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/utils/TableGen/ClangOptionDocEmitter.cpp b/clang/utils/TableGen/ClangOptionDocEmitter.cpp
index 734ff0bfd84..7fe487e5469 100644
--- a/clang/utils/TableGen/ClangOptionDocEmitter.cpp
+++ b/clang/utils/TableGen/ClangOptionDocEmitter.cpp
@@ -111,7 +111,7 @@ Documentation extractDocumentation(RecordKeeper &Records) {
auto DocumentationForOption = [&](Record *R) -> DocumentedOption {
auto &A = Aliases[R];
- std::sort(A.begin(), A.end(), CompareByName);
+ llvm::sort(A.begin(), A.end(), CompareByName);
return {R, std::move(A)};
};
@@ -120,7 +120,7 @@ Documentation extractDocumentation(RecordKeeper &Records) {
Documentation D;
auto &Groups = GroupsInGroup[R];
- std::sort(Groups.begin(), Groups.end(), CompareByLocation);
+ llvm::sort(Groups.begin(), Groups.end(), CompareByLocation);
for (Record *G : Groups) {
D.Groups.emplace_back();
D.Groups.back().Group = G;
@@ -129,7 +129,7 @@ Documentation extractDocumentation(RecordKeeper &Records) {
}
auto &Options = OptionsInGroup[R];
- std::sort(Options.begin(), Options.end(), CompareByName);
+ llvm::sort(Options.begin(), Options.end(), CompareByName);
for (Record *O : Options)
D.Options.push_back(DocumentationForOption(O));
OpenPOWER on IntegriCloud