Even for application programmers there are some

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: a new value is pushed onto the stack, the value in register %st(7) is lost. When the stack is popped, the new value in %st(7) is not predictable. Compilers must generate code that works within the limited capacity of the register stack. Figure 3.30 shows the set of instructions used to push values onto the floating-point register stack. The first group of these read from a memory location, where the argument Ö is a memory address given in one of the memory operand formats listed in Figure 3.3. These instructions differ by the presumed format of the source operand and hence the number of bytes that must be read from memory. We use the notation Å ÑÒ Ö to denote accessing of Ò bytes with starting address Ö . All of these instructions convert the operand to extended-precision format before pushing it onto the stack. The final load instruction fld is used to duplicate a stack value. That is, it pushes a copy of floating-point register %st( ) onto the stack. For example, the instruction fld %st(0) pushes a cop...
View Full Document

This note was uploaded on 09/02/2010 for the course ELECTRICAL 360 taught by Professor Schultz during the Spring '10 term at BYU.

Ask a homework question - tutors are online