8150013: ParNew: Prune nmethods scavengable list

Speed up ParNew collections by pruning the list of scavengable nmethods.

Reviewed-by: jmasa, tonyp, twisti
This commit is contained in:
Carsten Varming 2016-03-07 14:41:31 -05:00
parent eadcb3b145
commit f913f3be69
7 changed files with 57 additions and 31 deletions

View file

@ -285,9 +285,12 @@ class CodeBlobToOopClosure : public CodeBlobClosure {
protected:
void do_nmethod(nmethod* nm);
public:
// If fix_relocations(), then cl must copy objects to their new location immediately to avoid
// patching nmethods with the old locations.
CodeBlobToOopClosure(OopClosure* cl, bool fix_relocations) : _cl(cl), _fix_relocations(fix_relocations) {}
virtual void do_code_blob(CodeBlob* cb);
bool fix_relocations() const { return _fix_relocations; }
const static bool FixRelocations = true;
};