Mercurial > hg > graal-compiler
diff src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp @ 20257:7426d8d76305
8034761: Remove the do_code_roots parameter from process_strong_roots
Reviewed-by: tschatzl, mgerdin, jmasa
author | stefank |
---|---|
date | Thu, 13 Feb 2014 17:44:39 +0100 |
parents | b0b97602393a |
children | b7d24d2bc8be |
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp Mon Feb 10 12:58:09 2014 +0100 +++ b/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp Thu Feb 13 17:44:39 2014 +0100 @@ -3390,13 +3390,12 @@ if (!silent) { gclog_or_tty->print("Roots "); } VerifyRootsClosure rootsCl(vo); - G1VerifyCodeRootOopClosure codeRootsCl(this, &rootsCl, vo); - G1VerifyCodeRootBlobClosure blobsCl(&codeRootsCl); VerifyKlassClosure klassCl(this, &rootsCl); // We apply the relevant closures to all the oops in the - // system dictionary, the string table and the code cache. - const int so = SO_AllClasses | SO_Strings | SO_AllCodeCache; + // system dictionary, class loader data graph and the string table. + // Don't verify the code cache here, since it's verified below. + const int so = SO_AllClasses | SO_Strings; // Need cleared claim bits for the strong roots processing ClassLoaderDataGraph::clear_claimed_marks(); @@ -3404,10 +3403,14 @@ process_strong_roots(true, // activate StrongRootsScope ScanningOption(so), // roots scanning options &rootsCl, - &blobsCl, &klassCl ); + // Verify the nmethods in the code cache. + G1VerifyCodeRootOopClosure codeRootsCl(this, &rootsCl, vo); + G1VerifyCodeRootBlobClosure blobsCl(&codeRootsCl); + CodeCache::blobs_do(&blobsCl); + bool failures = rootsCl.failures() || codeRootsCl.failures(); if (vo != VerifyOption_G1UseMarkWord) { @@ -4865,12 +4868,9 @@ BufferingOopClosure buf_scan_non_heap_roots(scan_non_heap_roots); - CodeBlobToOopClosure scan_code_roots(&buf_scan_non_heap_roots, true /* do_marking */); - process_strong_roots(false, // no scoping; this is parallel code so, &buf_scan_non_heap_roots, - &scan_code_roots, scan_klasses ); @@ -4930,12 +4930,6 @@ _process_strong_tasks->all_tasks_completed(); } -void -G1CollectedHeap::g1_process_weak_roots(OopClosure* root_closure) { - CodeBlobToOopClosure roots_in_blobs(root_closure, /*do_marking=*/ false); - SharedHeap::process_weak_roots(root_closure, &roots_in_blobs); -} - class G1StringSymbolTableUnlinkTask : public AbstractGangTask { private: BoolObjectClosure* _is_alive;