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

add rocm-examples #898

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
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
29 changes: 28 additions & 1 deletion .jenkins/common.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def runCompileCommand(platform, project, jobName, boolean sameOrg=false, boolean
platform.runCommand(this, command)
}

def runTestCommand (platform, project, gfilter)
def runTestCommand (platform, project, gfilter, boolean rocmExamples=false)
{
String buildType = project.buildName.contains('Debug') ? 'debug' : 'release'
String hmmTestCommand = platform.jenkinsLabel.contains('gfx90a') ? 'HSA_XNACK=1 ./rocsolver-test --gtest_filter=*MANAGED_MALLOC* || true' : ''
Expand All @@ -71,6 +71,33 @@ def runTestCommand (platform, project, gfilter)


platform.runCommand(this, command)
if (rocmExamples)
{
String buildString = ""
if (platform.os.contains("ubuntu")){
buildString += "sudo dpkg -i *.deb"
}
else {
buildString += "sudo rpm -i *.rpm"
}
testCommand = """#!/usr/bin/env bash
set -ex
cd ${project.paths.project_build_prefix}/build/release/package
${buildString}
cd ../../..
testDirs=("Libraries/rocSOLVER")
git clone https://github.com/ROCm/rocm-examples.git
rocm_examples_dir=\$(readlink -f rocm-examples)
for testDir in \${testDirs[@]}; do
cd \${rocm_examples_dir}/\${testDir}
cmake -S . -B build
cmake --build build
cd ./build
ctest --output-on-failure
done
"""
platform.runCommand(this, testCommand, "ROCM Examples")
}
junit "${project.paths.project_build_prefix}/build/${buildType}/clients/staging/*.xml"
}

Expand Down
2 changes: 1 addition & 1 deletion .jenkins/precheckin.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def runCI =
platform, project->

def gfilter = 'checkin*'
commonGroovy.runTestCommand(platform, project, gfilter)
commonGroovy.runTestCommand(platform, project, gfilter, true)
}

def packageCommand =
Expand Down