Skip to content

Commit 8349ec9

Browse files
Merge pull request #10 from ndechesne/warmup
The matrix jobs results in a large amount of jobs being started at the same time. Running all jobs in parallel is not ideal to leverage the OE sstate cache. For any common tasks (native, armv8, .. ) when the object is missing from the sstate cache, it's likely going to be a miss for several jobs. As a result, each of them will build the missed object, and each of them will attempt to create the object in the sstate cache. Instead, with this change, we first build for the qcs8300 platform, for both BSP variants. If these builds succeed we carry on with the other machines/configs, with the hope that the sstate cache hit will be better.
2 parents bb3e050 + 129399c commit 8349ec9

File tree

3 files changed

+83
-32
lines changed

3 files changed

+83
-32
lines changed

.github/actions/compile/action.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Run a specific build configuration
2+
inputs:
3+
machine:
4+
required: true
5+
bsp:
6+
required: true
7+
cache_dir:
8+
required: true
9+
manifest_url:
10+
required: true
11+
manifest_branch:
12+
required: true
13+
qli_version:
14+
required: true
15+
runs:
16+
using: "composite"
17+
steps:
18+
- name: Get manifest file
19+
shell: bash
20+
run: |
21+
git clone --depth=1 ${{inputs.manifest_url}} -b ${{inputs.manifest_branch}}
22+
cd qcom-manifest
23+
MANIFEST_FILE=$(ls *${{inputs.qli_version}}*.xml | sort | grep -v -e realtime-linux -e qim-product-sdk -e robotics-product-sdk | tail -1)
24+
echo "Manifest file: ${MANIFEST_FILE}"
25+
echo "MANIFEST_FILE=${MANIFEST_FILE}" >> "$GITHUB_ENV"
26+
27+
- name: Setup workspace
28+
shell: bash
29+
run: |
30+
mkdir QLI
31+
cd QLI
32+
repo init -u ${{inputs.manifest_url}} -b ${{inputs.manifest_branch}} -m ${MANIFEST_FILE}
33+
repo sync
34+
mkdir -p ${{inputs.cache_dir}}/{downloads,sstate-cache}
35+
ln -s ${{inputs.cache_dir}}/downloads
36+
ln -s ${{inputs.cache_dir}}/sstate-cache
37+
38+
- name: Build QLI
39+
shell: bash
40+
run: |
41+
cd QLI
42+
# FIXME: apply_poky_patches() fails in setup-environment and it's not
43+
# needed, so skip it for now, until it's fixed properly.
44+
sed -i '/ apply_poky_patches/d' setup-environment
45+
MACHINE=${{ inputs.machine }} DISTRO=qcom-wayland QCOM_SELECTED_BSP=${{ inputs.bsp }} source setup-environment
46+
bitbake-layers add-layer $GITHUB_WORKSPACE
47+
bitbake qcom-console-image

.github/workflows/build.yml

Lines changed: 35 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,34 @@ env:
1111
QLI_VERSION: QLI.1.4
1212

1313
jobs:
14+
build_warmup:
15+
if: github.repository == 'qualcomm-linux/meta-qcom-3rdparty'
16+
runs-on: [self-hosted, x86]
17+
strategy:
18+
fail-fast: true
19+
matrix:
20+
machine:
21+
- qcs8300-ride-sx
22+
bsp:
23+
- custom
24+
- base
25+
steps:
26+
- uses: actions/checkout@v4
27+
28+
- name: Run build
29+
uses: ./.github/actions/compile
30+
with:
31+
machine: ${{matrix.machine}}
32+
bsp: ${{matrix.bsp}}
33+
cache_dir: ${CACHE_DIR}
34+
manifest_url: ${MANIFEST_URL}
35+
manifest_branch: ${MANIFEST_BRANCH}
36+
qli_version: ${QLI_VERSION}
37+
1438
build:
39+
needs: build_warmup
1540
if: github.repository == 'qualcomm-linux/meta-qcom-3rdparty'
41+
runs-on: [self-hosted, x86]
1642
strategy:
1743
fail-fast: true
1844
matrix:
@@ -22,42 +48,20 @@ jobs:
2248
- qcs9075-ride-sx
2349
- qcs9075-rb8-core-kit
2450
- qcs9100-ride-sx
25-
- qcs8300-ride-sx
2651
bsp:
2752
- custom
2853
include:
2954
- machine: qcs9100-ride-sx
3055
bsp: base
31-
- machine: qcs8300-ride-sx
32-
bsp: base
33-
runs-on: [self-hosted, x86]
3456
steps:
3557
- uses: actions/checkout@v4
3658

37-
- name: Get manifest file
38-
run: |
39-
git clone --depth=1 ${MANIFEST_URL} -b ${MANIFEST_BRANCH}
40-
cd qcom-manifest
41-
MANIFEST_FILE=$(ls *${QLI_VERSION}*.xml | sort | grep -v -e realtime-linux -e qim-product-sdk -e robotics-product-sdk | tail -1)
42-
echo "Manifest file: ${MANIFEST_FILE}"
43-
echo "MANIFEST_FILE=${MANIFEST_FILE}" >> "$GITHUB_ENV"
44-
45-
- name: Setup workspace
46-
run: |
47-
mkdir QLI
48-
cd QLI
49-
repo init -u ${MANIFEST_URL} -b ${MANIFEST_BRANCH} -m ${MANIFEST_FILE}
50-
repo sync
51-
mkdir -p ${CACHE_DIR}/{downloads,sstate-cache}
52-
ln -s ${CACHE_DIR}/downloads
53-
ln -s ${CACHE_DIR}/sstate-cache
54-
55-
- name: Build QLI
56-
run: |
57-
cd QLI
58-
# FIXME: apply_poky_patches() fails in setup-environment and it's not
59-
# needed, so skip it for now, until it's fixed properly.
60-
sed -i '/ apply_poky_patches/d' setup-environment
61-
MACHINE=${{ matrix.machine }} DISTRO=qcom-wayland QCOM_SELECTED_BSP=${{ matrix.bsp }} source setup-environment
62-
bitbake-layers add-layer $GITHUB_WORKSPACE
63-
bitbake qcom-console-image
59+
- name: Run build
60+
uses: ./.github/actions/compile
61+
with:
62+
machine: ${{matrix.machine}}
63+
bsp: ${{matrix.bsp}}
64+
cache_dir: ${CACHE_DIR}
65+
manifest_url: ${MANIFEST_URL}
66+
manifest_branch: ${MANIFEST_BRANCH}
67+
qli_version: ${QLI_VERSION}

.github/workflows/push.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Build on push
33
on:
44
push:
55
branches:
6-
- kirkstone
6+
- scarthgap
77

88
jobs:
99
build:

0 commit comments

Comments
 (0)