Skip to content

Commit

Permalink
Merge branch 'sycl' into jtodd/bfloat16_support
Browse files Browse the repository at this point in the history
  • Loading branch information
joeatodd committed Oct 14, 2024
2 parents f95dc85 + a5161f2 commit d7b8676
Show file tree
Hide file tree
Showing 6,462 changed files with 473,900 additions and 486,114 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
3 changes: 2 additions & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,10 @@ sycl/include/sycl/ext/oneapi/experimental/graph.hpp @intel/sycl-graphs-reviewers
sycl/source/detail/graph_impl.cpp @intel/sycl-graphs-reviewers
sycl/source/detail/graph_impl.hpp @intel/sycl-graphs-reviewers
sycl/unittests/Extensions/CommandGraph/ @intel/sycl-graphs-reviewers
sycl/doc/design/CommandGraph.md @intel/sycl-graphs-reviewers
sycl/test-e2e/Graph @intel/sycl-graphs-reviewers
sycl/doc/design/CommandGraph.md @intel/sycl-graphs-reviewers
sycl/doc/extensions/**/sycl_ext_oneapi_graph.asciidoc @intel/sycl-graphs-reviewers
sycl/doc/syclgraph/ @intel/sycl-graphs-reviewers

# syclcompat library
sycl/**/syclcompat/ @intel/syclcompat-lib-reviewers
Expand Down
37 changes: 37 additions & 0 deletions .github/workflows/libcxx-build-and-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ jobs:
'generic-no-experimental',
'generic-no-filesystem',
'generic-no-localization',
'generic-no-terminal',
'generic-no-random_device',
'generic-no-threads',
'generic-no-tzdb',
Expand Down Expand Up @@ -190,6 +191,42 @@ jobs:
**/CMakeError.log
**/CMakeOutput.log
**/crash_diagnostics/*
macos:
runs-on: macos-14
needs: [ stage1 ]
strategy:
fail-fast: true
matrix:
config: [
generic-cxx03,
generic-cxx23,
generic-modules,
apple-configuration
]
steps:
- uses: actions/checkout@v4
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: 'latest'
- uses: seanmiddleditch/gha-setup-ninja@master
- name: Build and test
run: |
python3 -m venv .venv
source .venv/bin/activate
python -m pip install psutil
bash libcxx/utils/ci/run-buildbot ${{ matrix.config }}
- uses: actions/upload-artifact@26f96dfa697d77e81fd5907df203aa23a56210a8 # v4.3.0
if: always() # Upload artifacts even if the build or test suite fails
with:
name: macos-${{ matrix.config }}-results
path: |
**/test-results.xml
**/*.abilist
**/CMakeError.log
**/CMakeOutput.log
**/crash_diagnostics/*
windows:
runs-on: windows-2022
needs: [ stage1 ]
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/pr-code-format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ on:
jobs:
code_formatter:
runs-on: ubuntu-latest
timeout-minutes: 30
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
cancel-in-progress: true
if: (github.repository == 'llvm/llvm-project' || github.repository == 'intel/llvm') && !contains(github.event.pull_request.labels.*.name, 'disable-lint')
steps:
- name: Fetch LLVM sources
Expand Down
17 changes: 16 additions & 1 deletion .github/workflows/release-asset-audit.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,21 @@
import github
import sys

_SPECIAL_CASE_BINARIES = {
"keith": {"clang+llvm-18.1.8-arm64-apple-macos11.tar.xz"},
}


def _is_valid(uploader_name, valid_uploaders, asset_name):
if uploader_name in valid_uploaders:
return True

if uploader_name in _SPECIAL_CASE_BINARIES:
return asset_name in _SPECIAL_CASE_BINARIES[uploader_name]

return False


def main():
token = sys.argv[1]

Expand Down Expand Up @@ -41,7 +56,7 @@ def main():
print(
f"{asset.name} : {asset.uploader.login} [{created_at} {updated_at}] ( {asset.download_count} )"
)
if asset.uploader.login not in uploaders:
if not _is_valid(asset.uploader.login, uploaders, asset.name):
with open('comment', 'w') as file:
file.write(f'@{asset.uploader.login} is not a valid uploader.')
sys.exit(1)
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/release-binaries-save-stage/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ inputs:
required: true
type: 'string'

permissions:
contents: read

runs:
using: "composite"
steps:
Expand All @@ -18,6 +21,9 @@ runs:
- name: Package Build and Source Directories
shell: bash
run: |
# Remove .git/config to avoid leaking GITHUB_TOKEN stored there.
# See https://unit42.paloaltonetworks.com/github-repo-artifacts-leak-tokens/
rm -Rf .git/config
# Windows does not support symlinks, so we need to dereference them.
tar --exclude build/ ${{ (runner.os == 'Windows' && '-h') || '' }} -c . | zstd -T0 -c > ../llvm-project.tar.zst
mv ../llvm-project.tar.zst .
Expand Down
8 changes: 0 additions & 8 deletions .github/workflows/release-binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -135,16 +135,8 @@ jobs:
target_cmake_flags="$target_cmake_flags -DBOOTSTRAP_DARWIN_osx_ARCHS=$arches -DBOOTSTRAP_DARWIN_osx_BUILTIN_ARCHS=$arches"
fi
# x86 macOS and x86 Windows have trouble building flang, so disable it.
# Windows: https://github.com/llvm/llvm-project/issues/100202
# macOS: 'rebase opcodes terminated early at offset 1 of 80016' when building __fortran_builtins.mod
build_flang="true"
if [ "$target" = "Windows-X64" ]; then
target_cmake_flags="$target_cmake_flags -DLLVM_RELEASE_ENABLE_PROJECTS=\"clang;lld;lldb;clang-tools-extra;bolt;polly;mlir\""
build_flang="false"
fi
if [ "${{ runner.os }}" = "Windows" ]; then
# The build times out on Windows, so we need to disable LTO.
target_cmake_flags="$target_cmake_flags -DLLVM_RELEASE_ENABLE_LTO=OFF"
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/release-doxygen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ on:
description: 'Upload documentation'
required: false
type: boolean
secrets:
RELEASE_TASKS_USER_TOKEN:
description: "Secret used to check user permissions."
required: false

jobs:
release-doxygen:
Expand Down Expand Up @@ -64,5 +68,6 @@ jobs:
if: env.upload
env:
GITHUB_TOKEN: ${{ github.token }}
USER_TOKEN: ${{ secrets.RELEASE_TASKS_USER_TOKEN }}
run: |
./llvm/utils/release/github-upload-release.py --token "$GITHUB_TOKEN" --release "${{ inputs.release-version }}" --user "${{ github.actor }}" upload --files ./*doxygen*.tar.xz
./llvm/utils/release/github-upload-release.py --token "$GITHUB_TOKEN" --release "${{ inputs.release-version }}" --user "${{ github.actor }}" --user-token "$USER_TOKEN" upload --files ./*doxygen*.tar.xz
7 changes: 6 additions & 1 deletion .github/workflows/release-lit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ on:
description: 'Release Version'
required: true
type: string
secrets:
RELEASE_TASKS_USER_TOKEN:
description: "Secret used to check user permissions."
required: false

jobs:
release-lit:
Expand All @@ -36,8 +40,9 @@ jobs:
- name: Check Permissions
env:
GITHUB_TOKEN: ${{ github.token }}
USER_TOKEN: ${{ secrets.RELEASE_TASKS_USER_TOKEN }}
run: |
./llvm/utils/release/./github-upload-release.py --token "$GITHUB_TOKEN" --user ${{ github.actor }} check-permissions
./llvm/utils/release/./github-upload-release.py --token "$GITHUB_TOKEN" --user ${{ github.actor }} --user-token "$USER_TOKEN" check-permissions
- name: Setup Cpp
uses: aminya/setup-cpp@v1
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/release-sources.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ on:
description: Release Version
required: true
type: string
secrets:
RELEASE_TASKS_USER_TOKEN:
description: "Secret used to check user permissions."
required: false
# Run on pull_requests for testing purposes.
pull_request:
paths:
Expand Down
12 changes: 12 additions & 0 deletions .github/workflows/release-tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,19 @@ jobs:
with:
release-version: ${{ needs.validate-tag.outputs.release-version }}
upload: true
# Called workflows don't have access to secrets by default, so we need to explicitly pass secrets that we use.
secrets:
RELEASE_TASKS_USER_TOKEN: ${{ secrets.RELEASE_TASKS_USER_TOKEN }}

release-lit:
name: Release Lit
needs: validate-tag
uses: ./.github/workflows/release-lit.yml
with:
release-version: ${{ needs.validate-tag.outputs.release-version }}
# Called workflows don't have access to secrets by default, so we need to explicitly pass secrets that we use.
secrets:
RELEASE_TASKS_USER_TOKEN: ${{ secrets.RELEASE_TASKS_USER_TOKEN }}

release-binaries:
name: Build Release Binaries
Expand All @@ -97,6 +103,9 @@ jobs:
release-version: ${{ needs.validate-tag.outputs.release-version }}
upload: true
runs-on: ${{ matrix.runs-on }}
# Called workflows don't have access to secrets by default, so we need to explicitly pass secrets that we use.
secrets:
RELEASE_TASKS_USER_TOKEN: ${{ secrets.RELEASE_TASKS_USER_TOKEN }}

release-sources:
name: Package Release Sources
Expand All @@ -109,3 +118,6 @@ jobs:
uses: ./.github/workflows/release-sources.yml
with:
release-version: ${{ needs.validate-tag.outputs.release-version }}
# Called workflows don't have access to secrets by default, so we need to explicitly pass secrets that we use.
secrets:
RELEASE_TASKS_USER_TOKEN: ${{ secrets.RELEASE_TASKS_USER_TOKEN }}
56 changes: 27 additions & 29 deletions .github/workflows/sycl-docs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Generate Doxygen documentation
name: Generate documentation

on:
schedule:
Expand All @@ -10,13 +10,21 @@ on:
- '.github/workflows/sycl-docs.yml'
- 'clang/docs/**'
- 'sycl/doc/**'
push:
branches:
- sycl
paths:
- '.github/workflows/sycl-docs.yml'
- 'clang/docs/**'
- 'sycl/doc/**'

permissions: read-all
permissions:
contents: read
pages: write
id-token: write

jobs:
build:
permissions:
contents: write # for Git to git push
runs-on: ubuntu-latest
if: github.repository == 'intel/llvm'
steps:
Expand All @@ -25,38 +33,28 @@ jobs:
path: repo
- name: Install deps
run: |
sudo apt-get install -y doxygen graphviz ssh ninja-build libhwloc-dev
sudo apt-get install -y graphviz ssh ninja-build libhwloc-dev
sudo pip3 install -r repo/llvm/docs/requirements.txt
- name: Build Docs
run: |
mkdir -p $GITHUB_WORKSPACE/build
cd $GITHUB_WORKSPACE/build
python $GITHUB_WORKSPACE/repo/buildbot/configure.py -w $GITHUB_WORKSPACE \
-s $GITHUB_WORKSPACE/repo -o $GITHUB_WORKSPACE/build -t Release --docs
cmake --build . --target doxygen-sycl
cmake --build . --target doxygen-clang
cmake --build . --target docs-sycl-html
cmake --build . --target docs-clang-html
- name: Deploy
if: ${{ github.event_name == 'schedule' }}
env:
SSH_KEY: ${{secrets.ACTIONS_DEPLOY_KEY}}
run: |
mkdir -p ~/.ssh
echo "$SSH_KEY" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
eval "$(ssh-agent -s)"
ssh-add -k ~/.ssh/id_rsa
git clone git@github.com:intel/llvm-docs.git docs
cd $GITHUB_WORKSPACE/docs
git rm -rf .
# Copy the generated docs to a separate directory for uploading.
mkdir $GITHUB_WORKSPACE/install_docs
cd $GITHUB_WORKSPACE/install_docs
mkdir clang
mv $GITHUB_WORKSPACE/build/tools/sycl/doc/html/* .
mv $GITHUB_WORKSPACE/build/tools/clang/docs/html/* clang/
touch .nojekyll
yes | \cp -rf $GITHUB_WORKSPACE/build/tools/sycl/doc/html/* .
mv $GITHUB_WORKSPACE/build/tools/sycl/doc/doxygen/html doxygen/
mv $GITHUB_WORKSPACE/build/tools/clang/docs/html clang/
mv $GITHUB_WORKSPACE/build/tools/clang/docs/doxygen/html clang_doxygen/
git config --global user.name "iclsrc"
git config --global user.email "ia.compiler.tools.git@intel.com"
git add .
git diff-index --quiet HEAD || git commit --amend -m "Update docs" -s
git push -f
# Upload the generated docs as an artifact and deploy to GitHub Pages.
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./install_docs
- name: Deploy to GitHub Pages
if: ${{ github.event_name == 'push' }}
uses: actions/deploy-pages@v4
18 changes: 13 additions & 5 deletions .github/workflows/sycl-linux-precommit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,22 +83,22 @@ jobs:
- name: Intel
runner: '["Linux", "gen12"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: level_zero:gpu;opencl:gpu;opencl:cpu
reset_intel_gpu: true
extra_lit_opts: --param gpu-intel-gen12=True
- name: E2E tests on Intel Arc A-Series Graphics
runner: '["Linux", "arc"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: level_zero:gpu;opencl:gpu
reset_intel_gpu: true
extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True
env: '{"LIT_FILTER":${{ needs.determine_arc_tests.outputs.arc_tests }} }'
- name: E2E tests with dev igc on Intel Arc A-Series Graphics
runner: '["Linux", "arc"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:devigc
image_options: -u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: level_zero:gpu;opencl:gpu
reset_intel_gpu: true
extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True
Expand All @@ -116,8 +116,16 @@ jobs:
extra_lit_opts: ${{ matrix.extra_lit_opts }}
env: ${{ matrix.env || '{}' }}

install_igc_driver: ${{ contains(needs.detect_changes.outputs.filters, 'drivers') }}
install_dev_igc_driver: ${{ matrix.use_igc_dev && contains(needs.detect_changes.outputs.filters, 'devigccfg') || 'false' }}
# Do not install drivers on AMD and CUDA runners.
install_igc_driver: >-
${{ !contains(matrix.target_devices, 'ext_oneapi_cuda') &&
!contains(matrix.target_devices, 'ext_oneapi_hip') &&
contains(needs.detect_changes.outputs.filters, 'drivers') }}
install_dev_igc_driver: >-
${{ !contains(matrix.target_devices, 'ext_oneapi_cuda') &&
!contains(matrix.target_devices, 'ext_oneapi_hip') &&
matrix.use_igc_dev && contains(needs.detect_changes.outputs.filters, 'devigccfg') ||
'false' }}
# Run only if the PR does not have the 'ci-no-devigc' label.
skip_run: ${{matrix.use_igc_dev && contains(github.event.pull_request.labels.*.name, 'ci-no-devigc') || 'false'}}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sycl-linux-run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ permissions:

jobs:
run:
if: inputs.skip_run == 'false'
if: github.event_name == 'workflow_dispatch' || inputs.skip_run == 'false'
name: ${{ inputs.name }}
runs-on: ${{ fromJSON(inputs.runner) }}
container:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/sycl-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
- name: Intel L0 GPU
runner: '["Linux", "gen12"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: level_zero:gpu
reset_intel_gpu: true
tests_selector: e2e
Expand All @@ -62,7 +62,7 @@ jobs:
- name: Intel OCL GPU
runner: '["Linux", "gen12"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: opencl:gpu
reset_intel_gpu: true
tests_selector: e2e
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sycl-post-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ jobs:
name: ${{ matrix.name }}
runner: ${{ matrix. runner }}
image: ${{ matrix.image || 'ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest' }}
image_options: ${{ matrix.image_options || '-u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN' }}
image_options: ${{ matrix.image_options || '-u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN' }}
target_devices: ${{ matrix.target_devices || 'level_zero:gpu' }}
reset_intel_gpu: ${{ matrix.reset_intel_gpu }}

Expand Down
Loading

0 comments on commit d7b8676

Please sign in to comment.