concurrentGCThread.cpp revision 342
2362N/A * Copyright 2001-2005 Sun Microsystems, Inc. All Rights Reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 0N/A * published by the Free Software Foundation. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2362N/A * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 2362N/A * CA 95054 USA or visit www.sun.com if you need additional information or 0N/A// CopyrightVersion 1.2 0N/A#
include "incls/_precompiled.incl" // warning("CGC: about to try stopping world"); // warning("CGC: successfully stopped world"); // warning("CGC: successfully restarted world"); // XXX: need to set this to low priority // unless "agressive mode" set; priority // should be just less than that of VMThread. // From this time Thread::current() should be working. // Signal that it is terminated // Thread destructor usually does this.. "SuspendibleThreadSetLock",
true);
"Long delay; whodunit?");
const char thread_name[] =
"Surrogate Locker Thread (CMS)";
// Initialize thread_oop to put it into the system threadGroup // At this point it may be possible that no osthread was created for the // JavaThread due to lack of memory. We would have to throw an exception // in that case. However, since this must work and we do not allow // exceptions anyway, check and abort if this fails. "unable to create new native thread");
os::
yield();
// This seems to help with initial start-up of SLT // ======= Surrogate Locker Thread ============= while (
/* !isTerminated() */ 1) {
// Since we are a JavaThread, we can't be here at a safepoint. // wait for msg buffer to become non-empty guarantee(
false,
"Unexpected message in _buffer");
// Since we are a JavaThread, we can't be here at a safepoint. // ===== STS Access From Outside CGCT ===== "only a conc GC thread can call this" );
"only a conc GC thread can call this" );
"only a conc GC thread can call this" );
"only a conc GC thread can call this" );