[X86][AVX512] add vmovss/sd missing encoding
[oota-llvm.git] / include / llvm / ADT / PriorityQueue.h
index 2503f75e81a265b279a1e0ed6d54ffb3c9b6295d..827d0b346e591a6ebb5f30302ec157908069c85d 100644 (file)
 //
 //===----------------------------------------------------------------------===//
 
-#ifndef LLVM_ADT_PRIORITY_QUEUE_H
-#define LLVM_ADT_PRIORITY_QUEUE_H
+#ifndef LLVM_ADT_PRIORITYQUEUE_H
+#define LLVM_ADT_PRIORITYQUEUE_H
 
+#include <algorithm>
 #include <queue>
 
 namespace llvm {
 
 /// PriorityQueue - This class behaves like std::priority_queue and
 /// provides a few additional convenience functions.
-/// 
+///
 template<class T,
          class Sequence = std::vector<T>,
          class Compare = std::less<typename Sequence::value_type> >
@@ -70,6 +71,12 @@ public:
   void reheapify() {
     std::make_heap(this->c.begin(), this->c.end(), this->comp);
   }
+
+  /// clear - Erase all elements from the queue.
+  ///
+  void clear() {
+    this->c.clear();
+  }
 };
 
 } // End llvm namespace