Lecture 1
Introduction and Motivation
Lecture
Outline
- Introduction.
- Information on course administration.
- Course motivation.
- Historical perspective.
Workshop
Outline
- Introduction: the instructor meets the class.
- Information on workshop organisation (goals, topics). and administration (attendance, homeworks, grading).
- Introduction to software tools.
- RARS.
- Godbolt.
- VirtualBox.
- Linux Ubuntu VM.
- Introduction to Cloud Ubuntu VM via SSH.
- Introduction to Git and GitHub.
- Practice: play with matrix multiplication and see the benchmarks.
Tasks
- Read documentation on software tools (RARS, Virtual Box, Ubuntu).
- Download and install the tools.
- Generate SSH keys for access to Cloud and GitHub. Save the public key to the table.
- Create a private GitHub repository and give access to it to the lecturer,
workshop instructor, and teaching assistant.
- Name it
<group>_<surname>
, e.g.204_tatarnikov
- Name it
- Download, compile, and run matrix computation examples:
Notes
VirtualBox
Some laptops might have issues with hardware virtualization. It should be enabled in BIOS. If you face problems running the VM, please refer to this instruction.
Connecting to the running VirtualBox VM
- Run terminal in your host operating system (Git Bash for Windows).
- Execute the following command:
ssh acos@localhost -p2022
- Use the password
acos2020
.
Bash Commands
Information on useful Linux and MacOS command-line tools can be found here.
Git and GitHub
Notes on how to work with GitHub and Git can be found here.
Example
For example, a MacBook with the following configuration:
Model Name: MacBook Pro
Model Identifier: MacBookPro9,1
Processor Name: Quad-Core Intel Core i7
Processor Speed: 2,3 GHz
Number of Processors: 1
Total Number of Cores: 4
L2 Cache (per Core): 256 KB
L3 Cache: 6 MB
Hyper-Threading Technology: Enabled
Memory: 8 GB
gives these results:
(base) Andreis-MacBook-Pro:01_Introduction andrew$ javac Matrix.java
(base) Andreis-MacBook-Pro:01_Introduction andrew$ gcc matrix.c -o matrix
(base) Andreis-MacBook-Pro:01_Introduction andrew$ gcc matrix_ikj.c -o matrix_ikj
(base) Andreis-MacBook-Pro:01_Introduction andrew$ gcc matrix_jki.c -o matrix_jki
(base) Andreis-MacBook-Pro:01_Introduction andrew$ python3 matrix.py
503.130450
(base) Andreis-MacBook-Pro:01_Introduction andrew$ java Matrix
12.946224373000002
(base) Andreis-MacBook-Pro:01_Introduction andrew$ ./matrix
13.714264
(base) Andreis-MacBook-Pro:01_Introduction andrew$ ./matrix_ikj
2.739385
(base) Andreis-MacBook-Pro:01_Introduction andrew$ ./matrix_jki
19.074106
Homework
- Finish installing all required software.
- Save a link to the SSH public key to the table.
- Finish experiments with matrix multiplication and provide benchmarks (for your machine).
- Run matrix multiplication in Python and C (all versions) in your machine.
- Provide a table with execution time.
- Commit the file with the table to your private GitHub account. Place it into the folder
ca/lab01
.
Homework is successful if:
- GitHub account is created.
- Table with execution time is uploaded to GitHub.
- Cloud VM account is created.
References
- History of computers and operating systems. Chapter 1 in [MOS].
- Computer technology overview. Chapter 1 in [CODR].
- MIT 6.172. Lecture 1.
- FLOPS (Wikipedia).
- Analytical Engine (Wikipedia).
- Von Neumann Architecture (Wikipedia).
- Turing machine (Wikipedia).
- Moore’s law (Wikipedia).
- Internet of Things (Wikipedia).
- Compiler Explorer Godbolt