Skip to content

M2A: bounded continuous PTP–SMV phase authority and guarded ESP32-P4 observer #1739

M2A: bounded continuous PTP–SMV phase authority and guarded ESP32-P4 observer

M2A: bounded continuous PTP–SMV phase authority and guarded ESP32-P4 observer #1739

name: BRCB Hard Profile CI
on:
push:
branches:
- main
pull_request:
types: [opened, synchronize, reopened, ready_for_review]
paths:
- 'embedded/brcb_hard_profile/**'
- 'embedded/brcb_*.cpp'
- 'embedded/mms_brcb_*.cpp'
- 'include/ariec61850/mms/**'
- 'src/mms/**'
- 'include/ariec61850/control/**'
- 'src/control/**'
- 'include/ariec61850/asn1/**'
- 'src/asn1/**'
- 'tests/fixtures/scl/**'
- '.github/workflows/brcb-hard-profile-ci.yml'
permissions:
contents: read
jobs:
brcb-hard-profile:
if: ${{ github.event_name != 'pull_request' || !github.event.pull_request.draft }}
name: BRCB Hard / ${{ matrix.compiler }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
compiler: [gcc, clang]
steps:
- uses: actions/checkout@v4
- name: Select compiler
shell: bash
run: |
if [ "${{ matrix.compiler }}" = "clang" ]; then
echo "CC=clang" >> "$GITHUB_ENV"
echo "CXX=clang++" >> "$GITHUB_ENV"
else
echo "CC=gcc" >> "$GITHUB_ENV"
echo "CXX=g++" >> "$GITHUB_ENV"
fi
- name: Configure BRCB hard profile
run: cmake -S embedded/brcb_hard_profile -B build-brcb-hard
- name: Build BRCB hard profile
run: cmake --build build-brcb-hard --parallel
- name: Run BRCB smokes
run: >-
ctest --test-dir build-brcb-hard
--output-on-failure
--output-junit brcb-ctest.xml
- name: Prove exception runtime is absent
shell: bash
run: |
set -euo pipefail
for binary in \
build-brcb-hard/ariec61850_hard_mms_brcb_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_control_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_objects_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_lifecycle_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_connection_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_recovery_v2_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_persistence_smoke; do
if nm -C "$binary" | grep -E '__cxa_throw|__cxa_begin_catch|__cxa_end_catch|__gxx_personality_v0'; then
echo "exception runtime symbol found in $binary" >&2
exit 1
fi
done
echo 'NO_EXCEPTION_RUNTIME=PASS'
- name: Report footprint
shell: bash
run: |
set -euo pipefail
{
echo "compiler=${{ matrix.compiler }}"
size \
build-brcb-hard/ariec61850_hard_mms_brcb_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_control_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_objects_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_lifecycle_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_connection_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_recovery_v2_smoke \
build-brcb-hard/ariec61850_hard_mms_brcb_persistence_smoke
} | tee build-brcb-hard/brcb-footprint.txt
- name: Upload BRCB evidence
uses: actions/upload-artifact@v4
with:
name: brcb-hard-${{ matrix.compiler }}-${{ github.event.pull_request.head.sha || github.sha }}
if-no-files-found: error
retention-days: 14
path: |
build-brcb-hard/brcb-ctest.xml
build-brcb-hard/brcb-footprint.txt