/* * Copyright 2007 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ #pragma ident "@(#)README.dbx-hack 1.3 07/05/30 SMI" ## ## DBX Debugging information for Legion ## ## This explains how to use the dbx debugging hooks in legion ## GETTING STARTED --------------- To get started, create a symlink from src/procs/sunsparc/debug/dbxrc to .dbxrc in the directory where sim is to be executed and run sim from within dbx. E.g: % ln -s /src/procs/sunsparc/debug/dbxrc .dbxrc % dbx (dbx) run -a 1.conf Note: control for executing debugging commands can be returned to dbx at anytime with ^C. DEBUGGING COMMANDS ------------------ simbreak Breakpoint on the given . Breakpoints can be installed prior to simulation or during after transferring control to dbx with ^C . The simulation is restarted with the conventional dbx "cont" command. simstep [n] Single step or times single step the current CPU. simregs Dump the current CPU's registers. simmmuregs Dump the current CPU's MMU-specific registers. simdumpdtlb Dump the current CPU's D-TLB. simdumpitlb Dump the current CPU's I-TLB. simfocus [n] Print the currently 'focused' CPU, the target of the "simregs", "simmmuregs" etc commands or switch the 'focus' to the supplied id. Note: this command operates using legion-gids, NOT cpuids. simx [n] Dump 8-bytes or dump successive 8-bytes at the supplied physical address. simtrans If possible translate the supplied virtual address into a physical address using the current context and current contents of the I&D-TLBs. simdis [n] Disassemble or disassemble successive instructions at the supplied physical address. simscratch [n] If no argument is provided, this will print the scratchpad registers for the currently 'focused' CPU. Otherwise it will print the scratchpad registers of the CPU passed as an argument. Note: this command operates using legion-gids, NOT cpuids. simcmpregs Dump the current CMP registers. simshowbreak Display active simulation breakpoints. simdumpbreak Dump the defined breakpoints to a text file. simrestorebreak Restore previously defined and saved breakpoints from a text file.