Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[clang-3.4-debuginfo-statistics] Fix the LNT submissions run order #291

Merged
merged 1 commit into from
Nov 1, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 17 additions & 22 deletions zorg/jenkins/jobs/jobs/clang-3.4-debuginfo-statistics
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ pipeline {

string(name: 'GIT_SHA', defaultValue: params.GIT_REVISION ?: '*/release/13.x', description: 'Git commit to build.')

string(name: 'ARTIFACT', defaultValue: params.ARTIFACT ?: 'clang-stage1-RA/latest', description: 'Clang artifact to use')
string(name: 'STAGE_1_JOB_NAME', defaultValue: params.STAGE_1_JOB_NAME ?: 'clang-stage1-RA', description: 'Stage 1 job name to download the artifact from.')

string(name: 'BUILD_TYPE', defaultValue: params.BUILD_TYPE ?: 'Release', description: 'Default CMake build type; one of: Release, Debug, ...')

Expand Down Expand Up @@ -68,6 +68,19 @@ pipeline {
'''
}
}
stage('Download Properties File') {
environment {
PATH="$PATH:/usr/bin:/usr/local/bin"
}
steps {
withCredentials([string(credentialsId: 's3_resource_bucket', variable: 'S3_BUCKET')]) {
sh """
source ./venv/bin/activate
aws s3 cp "{S3_BUCKET}/clangci/${params.STAGE_1_JOB_NAME}/last_good_build.properties" "."
"""
}
}
}
stage('Fetch Artifact') {
environment {
PATH="$PATH:/usr/bin:/usr/local/bin"
Expand All @@ -76,7 +89,7 @@ pipeline {
withCredentials([string(credentialsId: 's3_resource_bucket', variable: 'S3_BUCKET')]) {
sh """
source ./venv/bin/activate
echo "ARTIFACT=${params.ARTIFACT}"
export $(grep ARTIFACT last_good_build.properties)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I this still downloading the toolchain package?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it should. It points the ARTIFACT to the one listed in last_good_build.properties and that is fetched in the next line.

python llvm-zorg/zorg/jenkins/monorepo_build.py fetch
ls $WORKSPACE/host-compiler/lib/clang/
VERSION=`ls $WORKSPACE/host-compiler/lib/clang/`
Expand All @@ -102,21 +115,9 @@ pipeline {
sh '''
source ./venv/bin/activate

cd src/clang-13
git tag -a -m "First Commit" first_commit 97724f18c79c7cc81ced24239eb5e883bf1398ef || true

git_desc=$(git describe --match "first_commit")
export GIT_DISTANCE=$(echo ${git_desc} | cut -f 2 -d "-")

sha=$(echo ${git_desc} | cut -f 3 -d "-")
export GIT_SHA=${sha:1}

cd -

set -eux

$CXX --version
LLVM_REV=${GIT_DISTANCE}

mkdir -p $HISTORIC_COMPILER-src
mkdir -p $HISTORIC_COMPILER-build
Expand Down Expand Up @@ -166,17 +167,11 @@ pipeline {
sh '''
source ./venv/bin/activate

cd src/clang-13
git tag -a -m "First Commit" first_commit 97724f18c79c7cc81ced24239eb5e883bf1398ef || true

git_desc=$(git describe --match "first_commit")
export GIT_DISTANCE=$(echo ${git_desc} | cut -f 2 -d "-")

cd -
export GIT_DISTANCE=$(grep GIT_DISTANCE last_good_build.properties)

python llvm-zorg/zorg/jenkins/jobs/util/submit-debuginfo-statistics-to-lnt.py
'''
}
}
}
}
}