70 likes | 81 Views
Learn about addressing modes in computer programming and how to achieve increased performance. Explore the impact of improvements using Amdahl's Law. Discover the differences between Pentium III and Pentium 4 processors. Also, find out the top 3 places you most and least want to visit.
E N D
Ubiquitous Presenterhttp://up.ucsd.edu Beth Simon William Griswold and the UCSD UP development team
Addressing Modeshow do we specify the operand we want? Immediate #25 The operand (25) is part of the instruction R3 (sometimes written $3) The operand is the contents of register 3 M[R3] Use contents of R3 as address into memory; find the operand there. This is a special case of... M[R3 + 160] Add the displacement (160) to contents of R3, look in that memory location for the operand • If register is PC, this is “PC-relative addressing” All our example ISA’s have the above modes Register (direct) Register (indirect) Base+Displacement One other used for jumps, in the book psuedodirect
How do we achieve increased performance?(Gene) Amdahl’s Law IBM • The impact of an improvement is limited by the fraction of time affected by the improvement. • If you make MMX instructions run 10 times as fast, a program which doesn’t use MMX instructions will not run faster. ETnew = ETold affected/amount of improve + ETold unaffected ETnew = 0sec/10 + 100sec ET new = 100sec Etnew = 50sec/10 + 50 sec Etnew = 5+50 = 55
SPEC on Pentium III and Pentium 4 --doubling the GHz doesn’t double the SPEC number --Bigger imporvement on P4 on FP SSE2 instruction set – stack registers to regular FP register set Had to recompile to use these instruction sets • What do you notice?
Which of these things is not like the other? Mention Sesame Street B A D C Why?
Label the following 3 things: Epidermis Dermis Fat Cells
What are the top 3 places you most want to visit? What are the top 3 places you least want to visit?