8080110: Remove usage of CollectedHeap::n_par_threads() from root processing

Reviewed-by: jmasa, kbarrett
This commit is contained in:
Stefan Karlsson 2015-05-21 09:23:00 +02:00
parent e13e75547c
commit c13872f88d
14 changed files with 176 additions and 142 deletions

View file

@ -29,18 +29,21 @@
class MarkScope : public StackObj {
protected:
bool _active;
public:
MarkScope(bool activate = true);
MarkScope();
~MarkScope();
};
// Sets up and tears down the required state for parallel root processing.
class StrongRootsScope : public MarkScope {
// Number of threads participating in the roots processing.
const uint _n_threads;
public:
StrongRootsScope(bool activate = true);
StrongRootsScope(uint n_threads);
~StrongRootsScope();
uint n_threads() const { return _n_threads; }
};
#endif // SHARE_VM_GC_SHARED_STRONGROOTSSCOPE_HPP