-
Notifications
You must be signed in to change notification settings - Fork 752
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'sycl' into change-MAX_MEMORY_BANDWIDTH-device-query-to-…
…int64
- Loading branch information
Showing
236 changed files
with
4,023 additions
and
1,195 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
name: Coverity | ||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: '0 0 * * 0' | ||
|
||
permissions: read-all | ||
|
||
jobs: | ||
coverity: | ||
name: Coverity | ||
runs-on: [Linux, build] | ||
container: | ||
image: ghcr.io/intel/llvm/ubuntu2404_intel_drivers:alldeps | ||
options: -u 1001:1001 | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
sparse-checkout: | | ||
devops/actions | ||
- name: Register cleanup after job is finished | ||
uses: ./devops/actions/cleanup | ||
|
||
- uses: ./devops/actions/cached_checkout | ||
with: | ||
path: src | ||
ref: ${{ github.sha }} | ||
cache_path: "/__w/repo_cache/" | ||
|
||
- name: Get coverity tool | ||
run: | | ||
wget https://scan.coverity.com/download/linux64 --post-data "token=${{ secrets.COVERITY_TOKEN }}&project=intel%2Fllvm" -O coverity_tool.tgz | ||
tar -xf coverity_tool.tgz | ||
- name: Configure | ||
env: | ||
CC: gcc | ||
CXX: g++ | ||
CUDA_LIB_PATH: "/usr/local/cuda/lib64/stubs" | ||
run: | | ||
mkdir -p $GITHUB_WORKSPACE/build | ||
cd $GITHUB_WORKSPACE/build | ||
python3 $GITHUB_WORKSPACE/src/buildbot/configure.py -w $GITHUB_WORKSPACE \ | ||
-s $GITHUB_WORKSPACE/src -o $GITHUB_WORKSPACE/build -t Release \ | ||
--ci-defaults --hip --cuda \ | ||
--cmake-opt="-DNATIVECPU_USE_OCK=Off" \ | ||
--cmake-opt="-DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD=SPIRV" | ||
- name: Build with coverity | ||
run: $GITHUB_WORKSPACE/cov-analysis-linux64-*/bin/cov-build --dir cov-int cmake --build $GITHUB_WORKSPACE/build | ||
|
||
- name: Compress results | ||
run: tar -czf intel_llvm.tgz cov-int | ||
|
||
- name: Submit build | ||
run: | | ||
# Initialize a build. Fetch a cloud upload url. | ||
curl -X POST \ | ||
-d version="sycl: ${{ github.sha }}" \ | ||
-d description="Regular build" \ | ||
-d email=${{ secrets.COVERITY_EMAIL }} \ | ||
-d token=${{ secrets.COVERITY_TOKEN }} \ | ||
-d file_name="intel_llvm.tgz" \ | ||
https://scan.coverity.com/projects/31090/builds/init \ | ||
| tee response | ||
# Store response data to use in later stages. | ||
upload_url=$(jq -r '.url' response) | ||
build_id=$(jq -r '.build_id' response) | ||
# Upload the tarball to the Cloud. | ||
curl -X PUT \ | ||
--header 'Content-Type: application/json' \ | ||
--upload-file $PWD/intel_llvm.tgz \ | ||
$upload_url | ||
# Trigger the build on Scan. | ||
curl -X PUT \ | ||
-d token=${{ secrets.COVERITY_TOKEN }} \ | ||
https://scan.coverity.com/projects/31090/builds/$build_id/enqueue |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# This workflow performs a trivy check of docker config files. | ||
|
||
name: Trivy | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- 'devops/containers/**' | ||
- 'devops/.trivyignore.yaml' | ||
- '.github/workflows/trivy.yml' | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build: | ||
name: Trivy | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
sparse-checkout: devops | ||
|
||
# There is a github action, but for some reason it ignores ignore-file. | ||
- name: Install Trivy | ||
run: | | ||
curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh | ||
./bin/trivy --version | ||
- name: Run Trivy vulnerability scanner | ||
run: ./bin/trivy config --format json --output trivy-report.json --ignorefile=devops/.trivyignore.yaml devops/containers --exit-code 1 | ||
|
||
- name: Upload report artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: trivy-report | ||
path: trivy-report.json | ||
retention-days: 3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
clang/test/Driver/sycl-foffload-fp32-prec-div-old-model.cpp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// Test SYCL -foffload-fp32-prec-div | ||
|
||
// RUN: %clang -### -fsycl --no-offload-new-driver \ | ||
// RUN: -fsycl-targets=spir64_gen -foffload-fp32-prec-div %s 2>&1 \ | ||
// RUN: | FileCheck -check-prefix=AOT %s | ||
|
||
// RUN: %clang -### -fsycl --no-offload-new-driver \ | ||
// RUN: -foffload-fp32-prec-div %s 2>&1 \ | ||
// RUN: | FileCheck -check-prefix=JIT %s | ||
|
||
// AOT: "-ze-fp32-correctly-rounded-divide-sqrt" | ||
|
||
// JIT: clang-offload-wrapper{{.*}} "-compile-opts={{.*}}-foffload-fp32-prec-div" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// Test SYCL -foffload-fp32-prec-div | ||
|
||
// RUN: %clang -### -fsycl --offload-new-driver \ | ||
// RUN: -fsycl-targets=spir64_gen -foffload-fp32-prec-div %s 2>&1 \ | ||
// RUN: | FileCheck -check-prefix=AOT %s | ||
|
||
// RUN: %clang -### -fsycl --offload-new-driver \ | ||
// RUN: -foffload-fp32-prec-div %s 2>&1 \ | ||
// RUN: | FileCheck -check-prefix=JIT %s | ||
|
||
// AOT: clang-offload-packager{{.*}} "--image=file={{.*}}.bc,triple=spir64_gen-unknown-unknown,arch={{.*}},kind=sycl,compile-opts=-options -ze-fp32-correctly-rounded-divide-sqrt{{.*}}" | ||
|
||
// JIT: clang-offload-packager{{.*}} "--image=file={{.*}}.bc,triple=spir64-unknown-unknown,arch={{.*}}compile-opts={{.*}}-foffload-fp32-prec-div" |
13 changes: 13 additions & 0 deletions
13
clang/test/Driver/sycl-foffload-fp32-prec-sqrt-old-model.cpp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// Test SYCL -foffload-fp32-prec-sqrt | ||
|
||
// RUN: %clang -### -fsycl --no-offload-new-driver \ | ||
// RUN: -fsycl-targets=spir64_gen -foffload-fp32-prec-sqrt %s 2>&1 \ | ||
// RUN: | FileCheck -check-prefix=AOT %s | ||
|
||
// RUN: %clang -### -fsycl --no-offload-new-driver \ | ||
// RUN: -foffload-fp32-prec-sqrt %s 2>&1 \ | ||
// RUN: | FileCheck -check-prefix=JIT %s | ||
|
||
// AOT: "-ze-fp32-correctly-rounded-divide-sqrt" | ||
|
||
// JIT: clang-offload-wrapper{{.*}} "-compile-opts={{.*}}-foffload-fp32-prec-sqrt" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// Test SYCL -foffload-fp32-prec-sqrt | ||
|
||
// RUN: %clang -### -fsycl --offload-new-driver \ | ||
// RUN: -fsycl-targets=spir64_gen -foffload-fp32-prec-sqrt %s 2>&1 \ | ||
// RUN: | FileCheck -check-prefix=AOT %s | ||
|
||
// RUN: %clang -### -fsycl --offload-new-driver \ | ||
// RUN: -foffload-fp32-prec-sqrt %s 2>&1 \ | ||
// RUN: | FileCheck -check-prefix=JIT %s | ||
|
||
// AOT: clang-offload-packager{{.*}} "--image=file={{.*}}.bc,triple=spir64_gen-unknown-unknown,arch={{.*}},kind=sycl,compile-opts=-options -ze-fp32-correctly-rounded-divide-sqrt{{.*}}" | ||
|
||
// JIT: clang-offload-packager{{.*}} "--image=file={{.*}}.bc,triple=spir64-unknown-unknown,arch={{.*}}compile-opts={{.*}}-foffload-fp32-prec-sqrt" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
misconfigurations: | ||
- id: AVD-DS-0001 | ||
statement: "We use our own containers, no uncontrolled behavior is expected when the image is updated" | ||
- id: AVD-DS-0026 | ||
statement: "Our containers do not provide running services, but only preinstalled tools, there is not much value in adding HEALTHCHECK directives" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.