SPARC instruction types


We'll just touch briefly on some of the SPARC instructions, so you can get a feel for what you'll be seeing in disassembled output. The operations can be divided into some basic functional types based on what they do.

  • Load/store ” Move data between a register and a memory location.

  • Arithmetic/logical instructions ” Do the real work, but only using data already in registers.

  • Transfer of control instructions ” Include subroutine jumps and conditional branches, as well as trap instructions that are used to issue system calls.

  • Control register manipulation (normally done only by the kernel) ” Allow the system to do things like indicate when a register window overflow should occur. These registers are not accessible to user programs, and you will only see these instructions in assembly-language kernel code.

  • Coprocessor and floating-point instructions ” Immediately pass off the special operation codes.

  • Miscellaneous category ” Instructions that just don't fit anywhere else. These include things like flushi , which clears the CPU instruction cache.

The load and store instructions we'll look at in more detail shortly. These are the only ones that reference memory. Therefore, any kernel panic resulting in a data fault message (an example of a memory access error condition) will most likely involve one of these instructions.

All arithmetic and logical instructions refer to registers or small constants in the instruction code itself. These cannot cause memory reference traps, because there is nothing that they can do except touch registers. The instructions include things like add, subtract, multiply and divide, plus the logical or Boolean operations: AND, OR, NOT, exclusive OR. These also come in two flavors: one that just does the operation and another that adds the action of setting condition code bits based on the result.



PANIC. UNIX System Crash Dump Analysis Handbook
PANIC! UNIX System Crash Dump Analysis Handbook (Bk/CD-ROM)
ISBN: 0131493868
EAN: 2147483647
Year: 1994
Pages: 289
Authors: Chris Drake

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net