Use the proper comparator for set_intersection.
authorJakob Stoklund Olesen <stoklund@2pi.dk>
Thu, 15 Dec 2011 19:26:23 +0000 (19:26 +0000)
committerJakob Stoklund Olesen <stoklund@2pi.dk>
Thu, 15 Dec 2011 19:26:23 +0000 (19:26 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@146674 91177308-0d34-0410-b5e6-96231b3b80d8

utils/TableGen/CodeGenRegisters.cpp

index 35afaf8efbf1080286c058869bc543d9693703c9..ddb5329fb794af9dd9e46180ed402a676b2c3562 100644 (file)
@@ -775,7 +775,8 @@ void CodeGenRegBank::inferCommonSubClass(CodeGenRegisterClass *RC) {
     CodeGenRegister::Set Intersection;
     std::set_intersection(Memb1.begin(), Memb1.end(),
                           Memb2.begin(), Memb2.end(),
-                          std::inserter(Intersection, Intersection.begin()));
+                          std::inserter(Intersection, Intersection.begin()),
+                          CodeGenRegister::Less());
 
     // Skip disjoint class pairs.
     if (Intersection.empty())