Top Fields Constructors Methods
sun.jvm.hotspot.runtime

public Class Threads

Additional top-level class in compilation unit: ThreadsList.

extends Object
Class Inheritance
Imports
java.util.*, sun.jvm.hotspot.debugger.*, sun.jvm.hotspot.types.*, sun.jvm.hotspot.runtime.win32_x86.Win32X86JavaThreadPDAccess, sun.jvm.hotspot.runtime.win32_amd64.Win32AMD64JavaThreadPDAccess, sun.jvm.hotspot.runtime.win32_aarch64.Win32AARCH64JavaThreadPDAccess, sun.jvm.hotspot.runtime.linux_x86.LinuxX86JavaThreadPDAccess, sun.jvm.hotspot.runtime.linux_amd64.LinuxAMD64JavaThreadPDAccess, sun.jvm.hotspot.runtime.linux_aarch64.LinuxAARCH64JavaThreadPDAccess, sun.jvm.hotspot.runtime.linux_riscv64.LinuxRISCV64JavaThreadPDAccess, sun.jvm.hotspot.runtime.linux_ppc64.LinuxPPC64JavaThreadPDAccess, sun.jvm.hotspot.runtime.bsd_x86.BsdX86JavaThreadPDAccess, sun.jvm.hotspot.runtime.bsd_amd64.BsdAMD64JavaThreadPDAccess, sun.jvm.hotspot.runtime.bsd_aarch64.BsdAARCH64JavaThreadPDAccess, sun.jvm.hotspot.utilities.*, .Observable, .Observer

Field Summary

Modifier and TypeField and Description
private static ThreadsList
private static JavaThreadPDAccess
private static JavaThreadFactory
private static AddressField
private static VirtualConstructor

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public JavaThread
createJavaThreadWrapper(Address threadAddr)

Routine for instantiating appropriately-typed wrapper for a JavaThread.

public JavaThread
getJavaThreadAt(int i)

Note

this returns objects of type JavaThread, CompilerThread, JvmtiAgentThread, NotificationThread, MonitorDeflationThread, StringDedupThread, AttachListenerThread and ServiceThread.

public int
public List<JavaThread>
public List<JavaThread>
private static synchronized void
public void
oopsDo(AddressVisitor oopVisitor)

Memory operations

public JavaThread
public JavaThread
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

_listback to summary
private static ThreadsList _list
accessback to summary
private static JavaThreadPDAccess access
threadFactoryback to summary
private static JavaThreadFactory threadFactory
threadListFieldback to summary
private static AddressField threadListField
virtualConstructorback to summary
private static VirtualConstructor virtualConstructor

Constructor Detail

Threadsback to summary
public Threads()

Method Detail

createJavaThreadWrapperback to summary
public JavaThread createJavaThreadWrapper(Address threadAddr)

Routine for instantiating appropriately-typed wrapper for a JavaThread. Currently needs to be public for OopUtilities to access it.

getJavaThreadAtback to summary
public JavaThread getJavaThreadAt(int i)

Note

this returns objects of type JavaThread, CompilerThread, JvmtiAgentThread, NotificationThread, MonitorDeflationThread, StringDedupThread, AttachListenerThread and ServiceThread. The latter seven subclasses of the former. Most operations (fetching the top frame, etc.) are only allowed to be performed on a "pure" JavaThread. For this reason, sun.jvm.hotspot.runtime.JavaThread#isJavaThread has been changed from the definition in the VM (which returns true for all of these thread types) to return true for JavaThreads and false for the seven subclasses. FIXME: should reconsider the inheritance hierarchy; see sun.jvm.hotspot.runtime.JavaThread#isJavaThread.

getNumberOfThreadsback to summary
public int getNumberOfThreads()
getPendingThreadsback to summary
public List<JavaThread> getPendingThreads(ObjectMonitor monitor)
getWaitingThreadsback to summary
public List<JavaThread> getWaitingThreads(ObjectMonitor monitor)
initializeback to summary
private static synchronized void initialize(TypeDataBase db)
oopsDoback to summary
public void oopsDo(AddressVisitor oopVisitor)

Memory operations

owningThreadFromMonitorback to summary
public JavaThread owningThreadFromMonitor(Address o)
owningThreadFromMonitorback to summary
public JavaThread owningThreadFromMonitor(ObjectMonitor monitor)