In most traditional System-on-Chip (SoC) debugging method, software debugging is performed at the source/instruction-level while the hardware is debugged at the cycle-level. To make SoC debugging more efficient, this thesis presents a unified co-debugging method with the primary goal of bridging the abstraction gap between software debugging and hardware debugging. With the help of the proposed retargetable socket-based in circuit emulator (SBICE), the transaction of any socket-compliant intellectual property core (IP-core) on the system interconnect could be halted, monitored or even modified. The GNU Debugger (GDB) and Open On-Chip Debugger (OpenOCD) are also enhanced to provide a unified interface for integrated manipulation of SBICE and the on-chip CPU's ICE. On this interface, a system developer could monitor/debug the system software and the interacting IP-cores in a consistent way. This makes the process of system bug identification more efficient and time-to-market could be reduced substantially.