agent/src/share/classes/sun/jvm/hotspot/bugspot/BugSpotAgent.java
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File 7089790_full Cdiff agent/src/share/classes/sun/jvm/hotspot/bugspot/BugSpotAgent.java

agent/src/share/classes/sun/jvm/hotspot/bugspot/BugSpotAgent.java

Print this page
rev 2695 : shared changes

*** 27,36 **** --- 27,37 ---- import java.io.PrintStream; import java.net.*; import java.rmi.*; import sun.jvm.hotspot.*; import sun.jvm.hotspot.debugger.*; + import sun.jvm.hotspot.debugger.bsd.*; import sun.jvm.hotspot.debugger.proc.*; import sun.jvm.hotspot.debugger.cdbg.*; import sun.jvm.hotspot.debugger.windbg.*; import sun.jvm.hotspot.debugger.linux.*; import sun.jvm.hotspot.debugger.sparc.*;
*** 512,521 **** --- 513,524 ---- setupDebuggerSolaris(); } else if (os.equals("win32")) { setupDebuggerWin32(); } else if (os.equals("linux")) { setupDebuggerLinux(); + } else if (os.equals("bsd")) { + setupDebuggerBsd(); } else { // Add support for more operating systems here throw new DebuggerException("Operating system " + os + " not yet supported"); } if (isServer) {
*** 563,572 **** --- 566,578 ---- db = new HotSpotTypeDataBase(machDesc, new Win32VtblAccess(debugger, jvmLibNames), debugger, jvmLibNames); } else if (os.equals("linux")) { db = new HotSpotTypeDataBase(machDesc, new LinuxVtblAccess(debugger, jvmLibNames), debugger, jvmLibNames); + } else if (os.equals("bsd")) { + db = new HotSpotTypeDataBase(machDesc, new BsdVtblAccess(debugger, jvmLibNames), + debugger, jvmLibNames); } else { throw new DebuggerException("OS \"" + os + "\" not yet supported (no VtblAccess implemented yet)"); } } catch (NoSuchSymbolException e) {
*** 664,673 **** --- 670,681 ---- setupJVMLibNamesSolaris(); } else if (os.equals("win32")) { setupJVMLibNamesWin32(); } else if (os.equals("linux")) { setupJVMLibNamesLinux(); + } else if (os.equals("bsd")) { + setupJVMLibNamesBsd(); } else { throw new RuntimeException("Unknown OS type"); } cpu = debugger.getCPU();
*** 741,750 **** --- 749,786 ---- } private void setupJVMLibNamesLinux() { // same as solaris setupJVMLibNamesSolaris(); + } + + // + // BSD + // + + private void setupDebuggerBsd() { + setupJVMLibNamesBsd(); + + if (cpu.equals("x86")) { + machDesc = new MachineDescriptionIntelX86(); + } else if (cpu.equals("amd64")) { + machDesc = new MachineDescriptionAMD64(); + } else { + throw new DebuggerException("Bsd only supported on x86/amd64"); + } + + // Note we do not use a cache for the local debugger in server + // mode; it will be taken care of on the client side (once remote + // debugging is implemented). + + debugger = new BsdDebuggerLocal(machDesc, !isServer); + attachDebugger(); + } + + private void setupJVMLibNamesBsd() { + // same as solaris + setupJVMLibNamesSolaris(); } /** Convenience routine which should be called by per-platform debugger setup. Should not be called when startupMode is REMOTE_MODE. */
agent/src/share/classes/sun/jvm/hotspot/bugspot/BugSpotAgent.java
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File