Skip to content

Commit

Permalink
Merge pull request #91 from MonashDeepNeuron/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
linton2000 committed Apr 20, 2024
2 parents 12cffb7 + 0205b8d commit 77317f3
Show file tree
Hide file tree
Showing 155 changed files with 478 additions and 176 deletions.
1 change: 0 additions & 1 deletion src/.chapter7/challenges.md

This file was deleted.

113 changes: 58 additions & 55 deletions src/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,72 +2,75 @@

[Welcome](home.md)

- [Installation & Set-up](./chapter1/getting-started.md)
- [Installation & Set-up](./getting-started/getting-started.md)

- [GitHub](./chapter1/github.md)
- [Windows](./chapter1/windows.md)
- [Mac](./chapter1/mac.md)
- [Linux](./chapter1/linux.md)
- [WSL](./chapter1/wsl.md)
- [M3 MASSIVE](./chapter1/m3.md)
- [Nectar Cloud](./chapter1/nectar.md)
- [Challenges](./chapter1/challenges.md)
- [GitHub](./getting-started/github.md)
- [Windows](./getting-started/windows.md)
- [Mac](./getting-started/mac.md)
- [Linux](./getting-started/linux.md)
- [WSL](./getting-started/wsl.md)
- [M3 MASSIVE](./getting-started/m3.md)
- [Nectar Cloud](./getting-started/nectar.md)
- [Challenges](./getting-started/challenges.md)

- [Intro to C](./chapter2/intro-to-c.md)
- [Intro to C](./intro-to-c/intro-to-c.md)

- [Hello World](./chapter2/helloworld.md)
- [Compilation](./chapter2/compilation.md)
- [Types & Variables](./chapter2/vars.md)
- [Printing](./chapter2/printing.md)
- [Input](./chapter2/input.md)
- [Arrays & Strings](./chapter2/array.md)
- [Control Flow](./chapter2/ctrl-flow.md)
- [Loops](./chapter2/loops.md)
- [Functions](./chapter2/functions.md)
- [Challenges](./chapter2/challenges.md)
- [Hello World](./intro-to-c/helloworld.md)
- [Compilation](./intro-to-c/compilation.md)
- [Types & Variables](./intro-to-c/vars.md)
- [Printing](./intro-to-c/printing.md)
- [Input](./intro-to-c/input.md)
- [Arrays & Strings](./intro-to-c/array.md)
- [Control Flow](./intro-to-c/ctrl-flow.md)
- [Loops](./intro-to-c/loops.md)
- [Functions](./intro-to-c/functions.md)
- [Challenges](./intro-to-c/challenges.md)

- [Operating Systems](./chapter3/chapter3.md)
- [Operating Systems](./operating-systems/operating-systems.md)

- [Computer Architecture](./chapter3/computer-architecture.md)
- [Pointers](./chapter3/memory-pointers.md)
- [Dynamic Memory](./chapter3/dynamic-memory.md)
- [Structures & Macros](./chapter3/structs-macros.md)
- [Intro to Linux](./chapter3/linux-intro.md)
- [VMs & Containers](./chapter3/vms-containers.md)
- [Challenges](./chapter3/challenges.md)
- [Computer Architecture](./operating-systems/computer-architecture.md)
- [Pointers](./operating-systems/memory-pointers.md)
- [Dynamic Memory](./operating-systems/dynamic-memory.md)
- [Structures & Macros](./operating-systems/structs-macros.md)
- [Intro to Linux](./operating-systems/linux-intro.md)
- [VMs & Containers](./operating-systems/vms-containers.md)
- [Bash CMDs & Scripts](./operating-systems/bash-cmds-scripts.md)
- [Processes & Threads](./operating-systems/processes-threads.md)
- [Scheduling Algorithms](./operating-systems/scheduling.md)
- [Challenges](./operating-systems/challenges.md)

- [M3 & SLURM](./chapter4/chapter4.md)
- [M3 & SLURM](./m3-slurm/m3-slurm.md)

- [Batch Processing vs. Cloud Computing](./chapter4/batch-cloud.md)
- [Parallel & Distributed Computing](./chapter4/parallel-distributed.md)
- [M3 Login - SSH & Strudel](./chapter4/login.md)
- [Intro to SLURM](./chapter4/slurm_intro.md)
- [M3 Interface & Usage](./chapter4/m3-interface.md)
- [Software & Tooling](./chapter4/software-tooling.md)
- [Challenges](./chapter4/challenges.md)
- [Batch Processing vs. Cloud Computing](./m3-slurm/batch-cloud.md)
- [Parallel & Distributed Computing](./m3-slurm/parallel-distributed.md)
- [M3 Login - SSH & Strudel](./m3-slurm/login.md)
- [Intro to SLURM](./m3-slurm/slurm_intro.md)
- [M3 Interface & Usage](./m3-slurm/m3-interface.md)
- [Software & Tooling](./m3-slurm/software-tooling.md)
- [Challenges](./m3-slurm/challenges.md)

- [Introduction to Parallel Computing](./chapter5/chapter5.md)
- [Intro to Parallel Computing](./intro-to-parallel-comp/intro-to-parallel-comp.md)

- [Multithreading](./chapter5/multithreading.md)
- [Synchronisation](./chapter5/synchronisation.md)
- [Locks](./chapter5/locks.md)
- [Message Passing](./chapter5/message-passing.md)
- [Challenges](./chapter5/challenges.md)
- [OpenMP: Multithreading](./intro-to-parallel-comp/multithreading.md)
- [Synchronisation Issues](./intro-to-parallel-comp/synchronisation.md)
- [Dead & Live Locks](./intro-to-parallel-comp/locks.md)
- [MPI: Message Passing](./intro-to-parallel-comp/message-passing.md)
- [Challenges](./intro-to-parallel-comp/challenges.md)

- [Parallellisation of Algorithms](./chapter6/chapter6.md)
- [Parallellisation of Algorithms](./parallel-algos/parallel-algos.md)

- [Parallel Search](./chapter6/parallel-search.md)
- [Parallel Sort](./chapter6/parallel-sort.md)
- [Other Parallel Algorithms](./chapter6/other-parallel-algos.md)
- [Machine Learning & HPC](./chapter6/machine-learning-and-hpc.md)
- [Optimisation Algorithms](./chapter6/optim-algos.md)
- [Challenges](./chapter6/challenges.md)
- [Parallel Search](./parallel-algos/parallel-search.md)
- [Parallel Sort](./parallel-algos/parallel-sort.md)
- [Other Parallel Algorithms](./parallel-algos/other-parallel-algos.md)
- [Machine Learning & HPC](./parallel-algos/machine-learning-and-hpc.md)
- [Optimisation Algorithms](./parallel-algos/optim-algos.md)
- [Challenges](./parallel-algos/challenges.md)

- [Apache Spark](./chapter7/chapter7.md)
- [Installation & Cluster Set-up](./chapter7/set-up.md)
- [Internal Architecture](./chapter7/internals.md)
- [Data Processing](./chapter7/data-processing.md)
- [Job Batching](./chapter7/job-batching.md)
- [Challenges](./chapter7/challenges.md)
- [Apache Spark](./apache-spark/apache-spark.md)
- [Installation & Cluster Set-up](./apache-spark/set-up.md)
- [Internal Architecture](./apache-spark/internals.md)
- [Data Processing](./apache-spark/data-processing.md)
- [Job Batching](./apache-spark/job-batching.md)
- [Challenges](./apache-spark/challenges.md)

[Acknowledgements](./acknowledgements.md)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
3 changes: 0 additions & 3 deletions src/chapter3/processes.md

This file was deleted.

3 changes: 0 additions & 3 deletions src/chapter3/scheduling.md

This file was deleted.

3 changes: 0 additions & 3 deletions src/chapter3/threads-concurrency.md

This file was deleted.

42 changes: 0 additions & 42 deletions src/chapter3/vms-containers.md

This file was deleted.

1 change: 0 additions & 1 deletion src/chapter4/job-scripting.md

This file was deleted.

File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Binary file added src/m3-slurm/imgs/slurm-on-m3.png
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Nearly all modern computer systems utilise parallel computing to speed up the ex

As you can see, in a scenario where a program (job) takes 3 seconds and 3 independent jobs have to be executed by a system, doing it serially in a single computer takes a total of 9 seconds. But doing it simultaneously across 3 computers will only take 3 seconds thus achieving a 3x speedup through parallel computing.

This is the fundamental principle that High Performance Computing is based on.
This is the fundamental principle that High Performance Computing is based on. The trouble (or fun) is when your tasks have dependencies on each other which is gonna be the case for the vast majority of algorithms. That's when things like synchronisation issues, data sharing and all of that comes into play - which we'll explore in later chapters.

## What is Distributed Computing?

Expand Down Expand Up @@ -52,4 +52,19 @@ And finally, not everything needs to be done on a parallel or distributed system
### Advantages of serial computing:
- **More simple** to design & implement algorithms. Parallel algorithms can get quite complex, especially when dealing with more complicated instructions with dependencies.
- **Less overhead** involved in managing a parallel & distributed job. No need to manage data sharing between threads, processes, nodes, etc...
- **No synchronisation issues** & headaches involved in concurrent computing. Don't have to deal with race conditions, deadlocks, livelocks, etc...
- **No synchronisation issues** & headaches involved in concurrent computing. Don't have to deal with race conditions, deadlocks, livelocks, etc...

## Parallel Scalability
The speed up achieved from parallelism is dictated by your algorithm. Notably the serial parts of your algorithm can not be sped up by increasing the number of processors. The diagram below looks at the benefits we can achieve from writing parallel code as the number of processes increases.

![amdahl](./imgs/parallel_scalability.jpg)

Amdahl's Law, formulated by computer architect Gene Amdahl in 1967, is a principle used to analyze the potential speedup of parallel computing. It states that the speedup of a program from parallelization is limited by the proportion of the program that must be executed serially. In other words, it helps to determine the maximum performance improvement that can be achieved by using parallel processing.

The implications of Amdahl's Law for HPC is very significant:

- **Limitation of Speedup:** Amdahl's Law highlights that even with an increase in the number of processors (parallelization), the overall speedup is limited by the sequential portion of the code. Thus, if a significant portion of the code is inherently serial, the potential speedup achievable through parallelization is restricted.
- **Importance of Identifying Serial Sections:** In HPC, it's crucial to identify the sections of code that are inherently serial and cannot be parallelized. Optimizing these sections can lead to better overall performance. Conversely, focusing solely on parallelizing code without addressing these serial bottlenecks can result in suboptimal speedup.
- **Efficiency vs. Scalability:** Amdahl's Law emphasizes the importance of balancing efficiency and scalability in parallel computing. While increasing the number of processors can improve performance to a certain extent, beyond a certain point, diminishing returns occur due to the overhead of synchronization, communication, and managing parallel tasks.
- **Architectural Considerations:** HPC system architects must consider Amdahl's Law when designing hardware and software architectures. Designing systems that minimize the impact of serial portions of code and optimize parallel execution can lead to better overall performance.
- **Algorithm Selection:** When choosing algorithms for HPC applications, it's essential to consider their parallelizability. Algorithms that can be efficiently parallelized are more suitable for HPC environments, as they can leverage the potential for speedup provided by parallel computing resources more effectively.
Loading

0 comments on commit 77317f3

Please sign in to comment.