Mercurial > hg > graal-jvmci-8
comparison src/share/vm/compiler/compileBroker.hpp @ 20465:7301840ea20e
8023461: Thread holding lock at safepoint that vm can block on: MethodCompileQueue_lock
Reviewed-by: kvn, iveresov
author | vlivanov |
---|---|
date | Tue, 11 Mar 2014 15:06:34 +0400 |
parents | 7b9127b17b7a |
children | dd89808e49ba |
comparison
equal
deleted
inserted
replaced
20464:b2029969cc16 | 20465:7301840ea20e |
---|---|
186 Monitor* _lock; | 186 Monitor* _lock; |
187 | 187 |
188 CompileTask* _first; | 188 CompileTask* _first; |
189 CompileTask* _last; | 189 CompileTask* _last; |
190 | 190 |
191 CompileTask* _first_stale; | |
192 | |
191 int _size; | 193 int _size; |
194 | |
195 void purge_stale_tasks(); | |
192 public: | 196 public: |
193 CompileQueue(const char* name, Monitor* lock) { | 197 CompileQueue(const char* name, Monitor* lock) { |
194 _name = name; | 198 _name = name; |
195 _lock = lock; | 199 _lock = lock; |
196 _first = NULL; | 200 _first = NULL; |
197 _last = NULL; | 201 _last = NULL; |
198 _size = 0; | 202 _size = 0; |
203 _first_stale = NULL; | |
199 } | 204 } |
200 | 205 |
201 const char* name() const { return _name; } | 206 const char* name() const { return _name; } |
202 Monitor* lock() const { return _lock; } | 207 Monitor* lock() const { return _lock; } |
203 | 208 |
204 void add(CompileTask* task); | 209 void add(CompileTask* task); |
205 void remove(CompileTask* task); | 210 void remove(CompileTask* task); |
211 void remove_and_mark_stale(CompileTask* task); | |
206 CompileTask* first() { return _first; } | 212 CompileTask* first() { return _first; } |
207 CompileTask* last() { return _last; } | 213 CompileTask* last() { return _last; } |
208 | 214 |
209 CompileTask* get(); | 215 CompileTask* get(); |
210 | 216 |
211 bool is_empty() const { return _first == NULL; } | 217 bool is_empty() const { return _first == NULL; } |
212 int size() const { return _size; } | 218 int size() const { return _size; } |
219 | |
213 | 220 |
214 // Redefine Classes support | 221 // Redefine Classes support |
215 void mark_on_stack(); | 222 void mark_on_stack(); |
216 void delete_all(); | 223 void delete_all(); |
217 void print(); | 224 void print(); |