Bank Addressing Examples No Bank Conflicts No Bank Conflicts Linear addressing, stride == 1 permutation Random 1:1 Thread Thread Thread Thread Thread Thread Thread Thread 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 Thread 15 Bank Bank Bank Bank Bank Bank Bank Bank 0 1 2 3 4 5 6 7 Bank 15 Thread Thread Thread Thread Thread Thread Thread Thread Thread 15 Bank Bank Bank Bank Bank Bank Bank Bank 0 1 2 3 4 5 6 7 Bank 15 Performance Considerations – Slide 23
Bank Addressing Examples (cont.) Two-way Bank Conflicts Conflicts Eight-way Bank Linear addressing stride == 2 Linear addressing stride x8 Thread Bank 0 Thread 0 Bank 0 == 8 0 Thread Thread Thread Thread Thread Thread Thread Thread 1 2 3 4 8 9 10 11 Bank Bank Bank Bank Bank Bank Bank 1 2 3 4 5 6 7 Bank 15 Thread Thread Thread Thread Thread Thread Thread 1 2 3 4 5 6 7 Thread 15 Bank 1 Bank 2 Bank 7 Bank 8 x8 Bank 9 Bank 15 Performance Considerations – Slide 24
Linear Addressing Examples s=1 s=3 Thread 0 Thread 1 Bank 0 Bank 1 Thread 0 Thread 1 Bank 0 Bank 1 Thread 2 Thread 3 Bank 2 Bank 3 Thread 2 Thread 3 Bank 2 Bank 3 Thread 4 Bank 4 Thread 4 Bank 4 Thread 5 Thread 6 Bank 5 Bank 6 Thread 5 Thread 6 Bank 5 Bank 6 Thread 7 Bank 7 Thread 7 Bank 7 Thread 15 Bank 15 Thread 15 Bank 15 Performance Considerations – Slide 29
Finding the Climate Data for Your Hometown • To find the average temperature and precipitation for your hometown go to http://www.worldclimate.com. • Type the name of your hometown in the search box and click enter. • You may not find your hometown. If your hometown is not listed go to a larger city near your home. • Be sure to use the data from a location that has both average temperature and average precipitation. You may want to write this data on a piece of paper or print it out.
XP Modify 3-D chart options • A 3-D chart has several options for modifying the 3-D effect. – Perspective is the illusion that parts of the 3-D chart that are farther away from you decrease in size – Elevation is the illusion that you are looking at the 3-D chart from some particular height—either above or below the chart – You may also rotate the 3-D chart to bring different parts of the chart to the forefront • • • Elevation and rotation are options that you can change with the 3-D View dialog box, available from the Chart menu. Excel creates each 3-D chart with a default elevation, rotation and height. To change the appearance of a 3-D chart once you have created one, make sure it is an active chart then click Chart on the menu bar and then click 3-D View. ﴀNew Perspectives on Microsoft Office 2003, Premium Edition Excel Tutorial 4 27
Details: Parallel Memory Architecture In a parallel machine, many threads access memory Therefore, memory is divided into banks Essential to achieve high bandwidth Each bank can service one address per cycle A memory can service as many simultaneous accesses as it has banks Multiple simultaneous accesses to a Bank Bank Bank Bank Bank Bank Bank Bank 0 1 2 3 4 5 6 7 Bank 15 bank result in a bank conflict Conflicting accesses are serialized Performance Considerations – Slide 22
Using climographs to compare the climate of Chongqing, China to the climate of your hometown: • Which are the warmest months in Chongqing, China? • Which are the warmest months in your hometown? • Which are the coolest months in Chongqing, China? • Which are the coolest months in your hometown? • Which place has the highest average temperature for the year? • Write a sentence comparing the average monthly temperatures in Chongqing to the average monthly temperatures in your hometown.
Some Simple Queries Auto 677 Red 17 Company 17 People 654 6 Ford 99… 9 135 6546 Kevin 135 677 25 City 135 Orlando Florida Where do do all all the the Kevin’s Kevin’s live? live? Where Retrieve People.Hometown.Name People.Hometown.Name Retrieve Where People.name People.name == ‘Kevin’ ‘Kevin’ Where Who live live in in Orlando? Orlando? Who Retrieve People.Name People.Name Retrieve Where People.Hometown.name People.Hometown.name == ‘Orlando’ ‘Orlando’ Where
std::string input limitations string name; string hometown; cout << “What’s your name? ”; cin >> name; cout << “What is your hometown?”; cin >> hometown; System outputs: What is your hometown? http://cs.mst.edu
std::string input limitations string name; string hometown; cout << “What’s your name? ”; cin >> name; cout << “What is your hometown?”; cin >> hometown; Instead “Marshall” is pulled from the buffer and into hometown http://cs.mst.edu