131 access = new BsdAMD64JavaThreadPDAccess();
132 }
133 } else if (os.equals("darwin")) {
134 if (cpu.equals("amd64") || cpu.equals("x86_64")) {
135 access = new BsdAMD64JavaThreadPDAccess();
136 } else if (cpu.equals("aarch64")) {
137 access = new BsdAARCH64JavaThreadPDAccess();
138 }
139 }
140
141 if (access == null) {
142 throw new RuntimeException("OS/CPU combination " + os + "/" + cpu +
143 " not yet supported");
144 }
145
146 virtualConstructor = new VirtualConstructor(db);
147 // Add mappings for all known thread types
148 virtualConstructor.addMapping("JavaThread", JavaThread.class);
149 if (!VM.getVM().isCore()) {
150 virtualConstructor.addMapping("CompilerThread", CompilerThread.class);
151 }
152 virtualConstructor.addMapping("JvmtiAgentThread", JvmtiAgentThread.class);
153 virtualConstructor.addMapping("ServiceThread", ServiceThread.class);
154 virtualConstructor.addMapping("MonitorDeflationThread", MonitorDeflationThread.class);
155 virtualConstructor.addMapping("NotificationThread", NotificationThread.class);
156 virtualConstructor.addMapping("StringDedupThread", StringDedupThread.class);
157 virtualConstructor.addMapping("AttachListenerThread", AttachListenerThread.class);
158 }
159
160 public Threads() {
161 _list = VMObjectFactory.newObject(ThreadsList.class, threadListField.getValue());
162 }
163
164 /** NOTE: this returns objects of type JavaThread, CompilerThread,
165 JvmtiAgentThread, NotificationThread, MonitorDeflationThread,
166 StringDedupThread, AttachListenerThread and ServiceThread.
167 The latter seven subclasses of the former. Most operations
168 (fetching the top frame, etc.) are only allowed to be performed on
169 a "pure" JavaThread. For this reason, {@link
170 sun.jvm.hotspot.runtime.JavaThread#isJavaThread} has been
|
131 access = new BsdAMD64JavaThreadPDAccess();
132 }
133 } else if (os.equals("darwin")) {
134 if (cpu.equals("amd64") || cpu.equals("x86_64")) {
135 access = new BsdAMD64JavaThreadPDAccess();
136 } else if (cpu.equals("aarch64")) {
137 access = new BsdAARCH64JavaThreadPDAccess();
138 }
139 }
140
141 if (access == null) {
142 throw new RuntimeException("OS/CPU combination " + os + "/" + cpu +
143 " not yet supported");
144 }
145
146 virtualConstructor = new VirtualConstructor(db);
147 // Add mappings for all known thread types
148 virtualConstructor.addMapping("JavaThread", JavaThread.class);
149 if (!VM.getVM().isCore()) {
150 virtualConstructor.addMapping("CompilerThread", CompilerThread.class);
151 virtualConstructor.addMapping("TrainingReplayThread", TrainingReplayThread.class);
152 }
153 virtualConstructor.addMapping("JvmtiAgentThread", JvmtiAgentThread.class);
154 virtualConstructor.addMapping("ServiceThread", ServiceThread.class);
155 virtualConstructor.addMapping("MonitorDeflationThread", MonitorDeflationThread.class);
156 virtualConstructor.addMapping("NotificationThread", NotificationThread.class);
157 virtualConstructor.addMapping("StringDedupThread", StringDedupThread.class);
158 virtualConstructor.addMapping("AttachListenerThread", AttachListenerThread.class);
159 }
160
161 public Threads() {
162 _list = VMObjectFactory.newObject(ThreadsList.class, threadListField.getValue());
163 }
164
165 /** NOTE: this returns objects of type JavaThread, CompilerThread,
166 JvmtiAgentThread, NotificationThread, MonitorDeflationThread,
167 StringDedupThread, AttachListenerThread and ServiceThread.
168 The latter seven subclasses of the former. Most operations
169 (fetching the top frame, etc.) are only allowed to be performed on
170 a "pure" JavaThread. For this reason, {@link
171 sun.jvm.hotspot.runtime.JavaThread#isJavaThread} has been
|