--- old/src/share/vm/memory/strongRootsScope.hpp 2015-04-01 12:45:25.111899612 +0200 +++ new/src/share/vm/memory/strongRootsScope.hpp 2015-04-01 12:45:24.999899617 +0200 @@ -25,17 +25,24 @@ #ifndef SHARE_VM_MEMORY_STRONGROOTSSCOPE_HPP #define SHARE_VM_MEMORY_STRONGROOTSSCOPE_HPP -#include "memory/iterator.hpp" - // Some collectors will perform "process_strong_roots" in parallel. // Such a call will involve claiming some fine-grained tasks, such as // scanning of threads and code blobs. // Claiming of these tasks requires that sequential code calls // initialization methods to set the claiming code in the right // state for parallel task claiming. -// StrongRootsScope is a way to capture such setup code to make -// sure that it is executed in the correct way. -class StrongRootsScope : public MarkingCodeBlobClosure::MarkScope { +// StrongRootsScope and MarkScope provide ways to capture such +// setup code to make sure that it is executed in the correct way. + +class MarkScope : public StackObj { + protected: + bool _active; + public: + MarkScope(bool activate = true); + ~MarkScope(); +}; + +class StrongRootsScope : public MarkScope { public: StrongRootsScope(bool activate = true); ~StrongRootsScope();