Problem Description | Back to Top |
The program used in this module, named tariff, solves the linear asymmetric spatial price equilibrium problem with tariffs using the modified projection method. The tariff problem naturally lends itself to data parallelism, with all of the processors performing the same function(s), but on different segments of the data.
More information on the algorithm and model can also be found in Part 1 of the Tariff Case Study http://www.tc.cornell.edu/Edu/Talks/Tariff.Case.Study/Part1/. Note that this description is based on the algorithm and a serial implementation. In this module we examine the same Fortran program after it has been modified and tuned to use HPF directives (XL HPF).
Profile Analysis | Back to Top |
Another way to understand the program better is by getting a profile with a graphical tool. A profile of a program is an indication of how much time was spent in each part of the program. Each SP processor has a timer that "goes off" at set intervals. When generating a profile, the location in the executing program is noted every time the timer goes off. Think of it as "making a tick mark" next to the appropriate program location. At the end of the run, the number of ticks for each location or subroutine reflects the amount of time spent in that subroutine. This information is tallied into files, one per processor.
The xprofiler tool is an X Window System program that displays this profile information using a graphical user interface. View an example in which xprofiler is used to profile the tariff program at http://www.tc.cornell.edu/UserDoc/Software/PTools/xprofiler/Example/.
Change the program portion of the display to the complete annotated listing produced by xprofiler.
Change the program portion of the display back to the original copy.
Graphical Data Representation | Back to Top |
Click on the graphic to see the full image:
One way to visualize the tariff model is to look at a 3D cube, suppliers x buyers x timestep. Each plane of the cube represents one iteration ("timestep"). Each intersection in the plane represents a trading relationship between "supplier i" and "buyer j". If a trading relationship exists, then the color of the intersection represents the volume of sales.
The cube shown here represents the first 1000 iterations, with the first iteration in back. Sales that are increasing go from blue to yellow to red. Sales that are decreasing go to blue and then disappear. Note that the overall distribution of sales is converging to a few strong trading partnerships as time goes on.
Back to Top |