]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - gold/workqueue.cc
Framework for relocation scanning. Implement simple static TLS
[thirdparty/binutils-gdb.git] / gold / workqueue.cc
index 716f93db7851437a932e04f6dcb4f63286d001b6..3ef342257377f551c061cbf40cf8943b818e6a19 100644 (file)
@@ -192,6 +192,8 @@ Workqueue::~Workqueue()
   assert(this->running_ == 0);
 }
 
+// Add a task to the queue.
+
 void
 Workqueue::queue(Task* t)
 {
@@ -199,6 +201,15 @@ Workqueue::queue(Task* t)
   this->tasks_.push_back(t);
 }
 
+// Add a task to the front of the queue.
+
+void
+Workqueue::queue_front(Task* t)
+{
+  Hold_lock hl(this->tasks_lock_);
+  this->tasks_.push_front(t);
+}
+
 // Clear the list of completed tasks.  Return whether we cleared
 // anything.  The completed_lock_ must be held when this is called.