How llanskoyll/ehc-labs works
Main Components
• Lab Modules: The repository is divided into several lab or experiment directories that each focus on a particular exercise (e.g., “1_mmult” for a matrix multiplication experiment, “2_aos_soa” for comparing memory layouts [Array of Structures vs. Structure of Arrays], “3_primary_nums” for prime number computations, various “4_vector_*” folders for vectorization experiments, “n_vector”, “n-body-example”, “sycl_example”, and the “LABS” directory with its subdirectories).
• Build System: Almost every lab includes a CMakeLists.txt – indicating that the build process and configuration system (CMake) is a central common component.
• Supporting Material: Additional directories like “docs”, “data”, “tutorials”, and “lab” suggest the presence of documentation, sample data, and guidance for setting up the development environment and dependency analysis.
File Structure and Relationships
• There is a grouping aspect – many labs are numbered (like “1_mmult”, “2_aos_soa”, “3_primary_nums”, “4_vector_functions”, etc.) as well as an additional “LABS” folder (with SR1 and SR2) which may represent more comprehensive or later-stage lab assignments.
• The “tutorials” and documentation files (“Lab1.md”, “Lab2.md”, etc.) serve as guides to help users understand environment setup and the conceptual background. They are not executables but indicate dependencies for understanding or setting up experiments.
• The “data” directory (with its “new” subdirectory) is likely used as input for some labs.
a. Main Modules (Rectangles):
• Out each lab as separate blocks: for example:
• 1_mmult (Matrix multiplication lab)
• 2_aos_soa (Memory layout experiments comparing AOS vs. SOA)
• 3_primary_nums (Prime number experiment)
• 4_vector_functions, 4_vector_map, 4_vector_remainder (Different vectorization experiments)
• LABS (grouped further into SR1 and SR2)
• n_vector (vectorization and data-parallel experiments)
• n-body-example (simulation example)
• sycl_example (SYCL-based experiment for heterogeneous computing)
b. Common Build and Configuration:
c. Supporting Resources:
Architectural Patterns and Design Principles
• Each lab is essentially an independent module following a similar pattern—a C++ source coupled with a CMake configuration for building. This modular approach reflects a component-based design.
• The separation between lab exercises themselves and shared resources (such as build scripts and tutorials) is an element of separation of concerns.