6996747: SIGSEGV in nmethod::cleanup_inline_caches / CompiledIC::verify

Reviewed-by: kvn, iveresov
This commit is contained in:
Tom Rodriguez 2011-05-16 22:16:44 -07:00
parent 0e10a5ad61
commit a16e057c0a
5 changed files with 160 additions and 2 deletions

View file

@ -439,7 +439,7 @@ class Thread: public ThreadShadow {
// GC support
// Apply "f->do_oop" to all root oops in "this".
// Apply "cf->do_code_blob" (if !NULL) to all code blobs active in frames
void oops_do(OopClosure* f, CodeBlobClosure* cf);
virtual void oops_do(OopClosure* f, CodeBlobClosure* cf);
// Handles the parallel case for the method below.
private:
@ -1381,7 +1381,7 @@ public:
void trace_frames() PRODUCT_RETURN;
// Print an annotated view of the stack frames
void print_frame_layout(int depth = 0, bool validate_only = false) PRODUCT_RETURN;
void print_frame_layout(int depth = 0, bool validate_only = false) NOT_DEBUG_RETURN;
void validate_frame_layout() {
print_frame_layout(0, true);
}
@ -1698,6 +1698,8 @@ class CompilerThread : public JavaThread {
CompileQueue* _queue;
BufferBlob* _buffer_blob;
nmethod* _scanned_nmethod; // nmethod being scanned by the sweeper
public:
static CompilerThread* current();
@ -1726,6 +1728,11 @@ class CompilerThread : public JavaThread {
_log = log;
}
// GC support
// Apply "f->do_oop" to all root oops in "this".
// Apply "cf->do_code_blob" (if !NULL) to all code blobs active in frames
void oops_do(OopClosure* f, CodeBlobClosure* cf);
#ifndef PRODUCT
private:
IdealGraphPrinter *_ideal_graph_printer;
@ -1737,6 +1744,12 @@ public:
// Get/set the thread's current task
CompileTask* task() { return _task; }
void set_task(CompileTask* task) { _task = task; }
// Track the nmethod currently being scanned by the sweeper
void set_scanned_nmethod(nmethod* nm) {
assert(_scanned_nmethod == NULL || nm == NULL, "should reset to NULL before writing a new value");
_scanned_nmethod = nm;
}
};
inline CompilerThread* CompilerThread::current() {