This preview shows page 1. Sign up to view the full content.
Unformatted text preview: or begins executing the machine-language instructions in the hello program’s main routine. These instruction copy the bytes 1.5. CACHES MATTER
CPU register file PC ALU system bus memory bus 9 Memory Interface I/O bridge "hello,world\n" main memory hello code I/O bus USB controller mouse keyboard graphics adapter display disk disk controller Expansion slots for other devices such as network adapters. hello executable stored on disk Figure 1.6: Loading the executable from disk into main memory. in the ”hello, world\n” string from memory to the register ﬁle, and from there to the display device, where they are displayed on the screen. This step is shown in Figure 1.7. 1.5 Caches Matter
An important lesson from this simple example is that a system spends a lot time moving information from one place to another. The machine instructions in the hello program are originally stored on disk. When the program is loaded, they are copied to main memory. When the processor runs the programs, they are copied from main memory into the processor. Similarly, the data...
View Full Document
- Spring '10
- The American