User Tools

Site Tools


cs415:lab1

CS 415 (PDC) - Lab 1

For this first lab, we could use the early examples from Pacheco Chapter 3, or the tutorial programs at mpitutorial.com. For now I'm using mpi_hello_world:

  1. Compiled mpi_hello_world using mpicc
  2. Run mpi_hello_world as a regular executable. What does it do?
  3. Run mpi_hello_world using mpirun to access the MPI runtime system. What does it do?
  4. Use these parameters (more cores) and record the output
  5. Use these parameters (few cores) and …same…
  6. Can you use no cores?
  7. Demonstrate using command line to get host_file
  8. Demonstrate using envrionment variable to get host_file
  9. What happens if you put hive.sewanee.edu in host_file?
  10. What happens if you put farheen.sewanee.edu in host_file?
  11. Create a host_file with nearby machines (no more than 2 away). Dont' use farheen or edinburgh.
  12. Do this to skip the password part: ssh keygen
    1. ssh-keygen -t rsa
    2. cat .ssh/id_rsa.pub | ssh host 'cat » ~/.ssh/authorized_keys'
  13. Add the environment variables to your .bashrc file.

It might be interesting to cover run.py script at some point.

What about HW 3? I had some ideas but they dried up. One was to give detailed instructions on timing. Add timing code to the cpi.c program and run it on increasing number of processers. Average the time for three runs for each number of processors and record. Be very careful of runs when others are using the machines. Only run processors on 1. Compare this pi approx with the monte carlo version.

cs415/lab1.txt · Last modified: 2017/09/18 22:25 by scarl