|
| 1 | +# oneDAL CI Infrastructure Documentation |
| 2 | + |
| 3 | +## Overview |
| 4 | + |
| 5 | +This document describes the CI infrastructure for oneDAL (Intel Data Analytics Library) |
| 6 | +## Directory Structure |
| 7 | + |
| 8 | +### `.ci` Folder |
| 9 | + |
| 10 | +The `.ci` folder contains the core CI infrastructure scripts and configurations organized into three main subdirectories: |
| 11 | + |
| 12 | +#### `.ci/env/` - Environment Setup Scripts |
| 13 | +- **`apt.sh`** - Package installation script for Ubuntu/Debian systems with functions for: |
| 14 | + - Intel OneAPI toolkit components (DPC++, TBB, DPL, MKL) |
| 15 | + - Development tools (clang-format, editorconfig-checker) |
| 16 | + - Base development packages and dependencies |
| 17 | +- **`bazelisk.sh`** - Bazel build system setup and installation |
| 18 | +- **`editorconfig-checker.sh`** - EditorConfig compliance checker installation |
| 19 | +- **`environment.yml`** - Conda environment specification |
| 20 | +- **`openblas.sh`** - OpenBLAS library installation and configuration |
| 21 | +- **`openrng.sh`** - OpenRNG backend setup for random number generation |
| 22 | +- **`tbb.sh`** / **`tbb.bat`** - Intel TBB (Threading Building Blocks) setup for Linux/Windows |
| 23 | +- **`riscv64-clang-crosscompile-toolchain.cmake`** - RISC-V cross-compilation toolchain configuration |
| 24 | + |
| 25 | +#### `.ci/pipeline/` - CI Pipeline Definitions |
| 26 | +- **`ci.yml`** - Main Azure DevOps pipeline configuration with: |
| 27 | + - Multi-platform build matrices (Linux, Windows) |
| 28 | + - Compiler configurations (GNU, Clang, Intel) |
| 29 | + - Build targets (daal, onedal_c) |
| 30 | + - Testing and validation jobs |
| 31 | + - Artifact publishing |
| 32 | +- **`docs.yml`** - Documentation build and deployment pipeline |
| 33 | + |
| 34 | +#### `.ci/scripts/` - Build and Test Scripts |
| 35 | +- **`build.sh`** / **`build.bat`** - Cross-platform build orchestration with support for: |
| 36 | + - Multiple compilers (gnu, clang, icx) |
| 37 | + - Architecture optimizations (AVX2, etc.) |
| 38 | + - Backend configurations (MKL, reference implementations) |
| 39 | + - Cross-compilation capabilities |
| 40 | +- **`test.sh`** / **`test.bat`** - Comprehensive testing framework execution |
| 41 | +- **`clang-format.sh`** - Code formatting verification |
| 42 | +- **`describe_system.sh`** - System information collection for debugging |
| 43 | +- **`abi_check.sh`** - ABI compatibility verification |
| 44 | +- **`install_basekit.bat`** - Intel OneAPI Base Toolkit installation for Windows |
| 45 | +- **`collect_opencl_rt.ps1`** - OpenCL runtime collection script |
| 46 | + |
| 47 | +### `.github/workflows/` - GitHub Actions Workflows |
| 48 | + |
| 49 | +#### Core CI Workflows |
| 50 | +- **`ci.yml`** - Main CI pipeline for x86 platforms with DPC++ builds |
| 51 | +- **`ci-aarch64.yml`** - AArch64 (ARM64) specific CI pipeline |
| 52 | +- **`nightly-build.yml`** / **`nightly-test.yml`** - Automated nightly builds and testing |
| 53 | + |
| 54 | +#### Specialized Workflows |
| 55 | +- **`docker-validation-ci.yml`** / **`docker-validation-nightly.yml`** - Container-based validation |
| 56 | +- **`docs-release.yml`** - Documentation deployment and release management |
| 57 | +- **`label-enforcement.yml`** - PR labeling automation |
| 58 | +- **`pr-checklist.yml`** - Pull request compliance verification |
| 59 | +- **`renovate-validation.yml`** - Dependency update validation |
| 60 | +- **`skywalking-eyes.yml`** - License header compliance checking |
| 61 | +- **`slack-pr-notification.yml`** - Team notification system |
| 62 | +- **`openssf-scorecard.yml`** - Security scorecard assessment |
| 63 | + |
| 64 | +## CI/CD Architecture |
| 65 | + |
| 66 | +### Multi-Platform Strategy |
| 67 | +The oneDAL CI infrastructure supports: |
| 68 | +- **Architectures**: x86-64, AArch64, RISC-V |
| 69 | +- **Operating Systems**: Ubuntu (multiple versions), Windows Server 2022 |
| 70 | +- **Compilers**: GNU GCC, Clang, Intel DPC++/ICX |
| 71 | +- **Build Systems**: Make, Bazel |
| 72 | +- **Hardware**: CPU and GPU (Intel) testing |
| 73 | + |
| 74 | +### CI Platform Integration |
| 75 | +- **GitHub Actions**: Primary CI/CD platform for public workflows |
| 76 | +- **Azure DevOps**: Extended validation and internal testing |
| 77 | +- **Mergify**: Automated merge management |
| 78 | +- **Renovate**: Dependency update automation |
| 79 | +- **Codefactor**: Code quality analysis |
| 80 | + |
| 81 | +### Build Matrix Configuration |
| 82 | +The CI system employs comprehensive build matrices covering: |
| 83 | +- **Instruction Sets**: AVX2, AVX-512, and architecture-specific optimizations |
| 84 | +- **Backends**: Intel MKL, OpenBLAS reference implementations |
| 85 | +- **Threading**: Intel TBB, OpenMP |
| 86 | +- **Random Number Generation**: Intel MKL RNG, OpenRNG |
| 87 | + |
| 88 | +### Quality Assurance |
| 89 | +- **Code Formatting**: clang-format enforcement |
| 90 | +- **License Compliance**: Automated header checking |
| 91 | +- **ABI Compatibility**: Binary interface stability validation |
| 92 | +- **Security**: OpenSSF Scorecard integration |
| 93 | +- **Documentation**: Automated doc generation and validation |
| 94 | + |
| 95 | +## Usage Guidelines |
| 96 | + |
| 97 | +### Local Development |
| 98 | +Developers can leverage the CI scripts locally: |
| 99 | +```bash |
| 100 | +# Set up development environment |
| 101 | +.ci/env/apt.sh dev-base |
| 102 | +.ci/env/apt.sh mkl |
| 103 | + |
| 104 | +# Build the library |
| 105 | +.ci/scripts/build.sh --compiler gnu --optimizations avx2 --target daal |
| 106 | + |
| 107 | +# Run tests |
| 108 | +.ci/scripts/test.sh |
| 109 | +``` |
| 110 | + |
| 111 | +### Internal CI |
| 112 | +Internal CI integration done in separate repository, though checks are enforced in PRs. |
0 commit comments