Skip to content

Commit bc6e32a

Browse files
committed
Merge branch 'sycl' into bf16_builtins
2 parents 2f3afe4 + 647249c commit bc6e32a

File tree

242 files changed

+11611
-7423
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

242 files changed

+11611
-7423
lines changed

.github/CODEOWNERS

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ libdevice/ @intel/llvm-reviewers-runtime
2222
sycl/ @intel/llvm-reviewers-runtime
2323

2424
# Documentation
25-
sycl/ReleaseNotes.md @intel/dpcpp-doc-reviewers
25+
sycl/ReleaseNotes.md @intel/dpcpp-doc-reviewers @tfzhu
2626
sycl/doc/ @intel/dpcpp-doc-reviewers
2727
sycl/doc/design/ @intel/dpcpp-specification-reviewers
2828
sycl/doc/design/spirv-extensions/ @intel/dpcpp-spirv-doc-reviewers
@@ -50,5 +50,6 @@ clang/tools/clang-offload-*/ @intel/dpcpp-tools-reviewers
5050
# Explicit SIMD
5151
ESIMD/ @intel/dpcpp-esimd-reviewers
5252
esimd/ @intel/dpcpp-esimd-reviewers
53-
sycl/include/sycl/ext/intel/experimental/esimd.hpp @intel/dpcpp-esimd-reviewers
53+
sycl/include/sycl/ext/intel/esimd.hpp @intel/dpcpp-esimd-reviewers
5454
sycl/doc/extensions/experimental/sycl_ext_intel_esimd/ @intel/dpcpp-esimd-reviewers
55+
llvm/lib/SYCLLowerIR/CMakeLists.txt @intel/dpcpp-tools-reviewers @intel/dpcpp-esimd-reviewers

.github/workflows/sycl_cleanup.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Cleanup
2+
3+
on:
4+
workflow_run:
5+
workflows:
6+
- SYCL
7+
- SYCL Nightly Builds
8+
- SYCL Post Commit
9+
types: [completed]
10+
11+
jobs:
12+
cleanup:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/github-script@v6
16+
with:
17+
script: |
18+
let allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({
19+
owner: context.repo.owner,
20+
repo: context.repo.repo,
21+
run_id: context.payload.workflow_run.id,
22+
});
23+
let matchArtifacts = allArtifacts.data.artifacts.filter((artifact) => {
24+
return artifact.name.startsWith("sycl_linux_");
25+
});
26+
matchArtifacts.forEach(async (artifact) => {
27+
await github.rest.actions.deleteArtifact({
28+
owner: context.repo.owner,
29+
repo: context.repo.repo,
30+
artifact_id: artifact.id
31+
});
32+
});

.github/workflows/sycl_containers.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,15 @@ on:
1010
paths:
1111
- 'devops/containers/**'
1212
- 'devops/dependencies.json'
13+
- 'devops/scripts/install_drivers.sh'
14+
- 'devops/scripts/install_build_tools.sh'
1315
- '.github/workflows/sycl_containers.yaml'
1416
pull_request:
1517
paths:
1618
- 'devops/containers/**'
1719
- 'devops/dependencies.json'
20+
- 'devops/scripts/install_drivers.sh'
21+
- 'devops/scripts/install_build_tools.sh'
1822
- '.github/workflows/sycl_containers.yaml'
1923

2024
jobs:

.github/workflows/sycl_linux_build_and_test.yml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,6 @@ on:
1515
type: string
1616
required: false
1717
default: "ghcr.io/intel/llvm/ubuntu2004_build:latest"
18-
build_runs_on:
19-
type: string
20-
required: false
21-
default: "build"
2218
build_ref:
2319
type: string
2420
required: false
@@ -43,7 +39,7 @@ on:
4339
intel_drivers_image:
4440
type: string
4541
required: false
46-
default: "ghcr.io/intel/llvm/ubuntu2004_intel_drivers:latest"
42+
default: "ghcr.io/intel/llvm/ubuntu2004_intel_drivers:unstable"
4743
lts_config:
4844
type: string
4945
required: false
@@ -68,7 +64,7 @@ on:
6864
jobs:
6965
build:
7066
name: Build + LIT
71-
runs-on: ${{ inputs.build_runs_on }}
67+
runs-on: [Linux, build]
7268
container:
7369
image: ${{ inputs.build_image }}
7470
options: -u 1001:1001

.github/workflows/sycl_nightly.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ jobs:
6464
if: github.repository == 'intel/llvm'
6565
uses: ./.github/workflows/sycl_linux_build_and_test.yml
6666
with:
67-
build_runs_on: build
6867
build_cache_root: "/__w/"
6968
build_cache_suffix: new_pm
7069
build_artifact_suffix: new_pm

.github/workflows/sycl_post_commit.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,12 @@ jobs:
1515
name: Linux Default
1616
uses: ./.github/workflows/sycl_linux_build_and_test.yml
1717
with:
18-
build_runs_on: build
1918
build_cache_root: "/__w/llvm"
2019
build_artifact_suffix: default
2120
linux_no_assert:
2221
name: Linux (no assert)
2322
uses: ./.github/workflows/sycl_linux_build_and_test.yml
2423
with:
25-
build_runs_on: build
2624
build_cache_root: "/__w/llvm"
2725
build_cache_suffix: gcc_no_assertions
2826
build_artifact_suffix: gcc_no_assertions

.github/workflows/sycl_precommit.yml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,16 @@ on:
44
pull_request:
55
branches:
66
- sycl
7+
# Do not run builds if changes are only in the following locations
8+
paths-ignore:
9+
- 'devops/containers/**'
10+
- 'devops/scripts/install_drivers.sh'
11+
- 'devops/scripts/install_build_tools.sh'
12+
- 'sycl/doc/**'
13+
- 'sycl/gdb/**'
14+
- 'clang/docs/**'
15+
- '**.md'
16+
- '**.rst'
717

818
jobs:
919
lint:
@@ -25,7 +35,6 @@ jobs:
2535
if: always() && (success() || contains(github.event.pull_request.labels.*.name, 'ignore-lint'))
2636
uses: ./.github/workflows/sycl_linux_build_and_test.yml
2737
with:
28-
build_runs_on: "build"
2938
build_cache_root: "/__w/"
3039
build_cache_size: "8G"
3140
build_artifact_suffix: "default"

CONTRIBUTING.md

Lines changed: 41 additions & 115 deletions
Original file line numberDiff line numberDiff line change
@@ -15,25 +15,18 @@ these terms.
1515

1616
### Development
1717

18-
**NB**: For any changes not related to DPC++, but rather to LLVM in general, it
19-
is strongly encouraged that you submit the patch to https://llvm.org/ directly.
20-
See [LLVM contribution guidelines](https://llvm.org/docs/Contributing.html)
21-
for more information.
22-
23-
**NB**: A change in compiler and runtime should be accompanied with
24-
corresponding test changes.
25-
See [Test DPC++ toolchain](sycl/doc/GetStartedGuide.md#test-dpc-toolchain)
26-
section of Get Started guide for more information.
27-
28-
**Note (October, 2020)**: DPC++ runtime and compiler ABI is currently in frozen
29-
state. This means that no ABI-breaking changes will be accepted by default.
30-
Project maintainers may still approve breaking changes in some cases. Please,
31-
see [ABI Policy Guide](sycl/doc/developer/ABIPolicyGuide.md) for more
32-
information.
18+
For any changes not related to Intel Project for LLVM\* technology, but rather
19+
to LLVM in general, it is strongly encouraged that you submit the patch to
20+
https://llvm.org/ directly. See
21+
[LLVM contribution guidelines](https://llvm.org/docs/Contributing.html) for
22+
more information.
23+
24+
Every change should be accompanied with corresponding test modification (adding
25+
new test(s), extending, removing or modifying existing test(s)).
26+
27+
To contribute:
3328

3429
- Create a personal fork of the project on GitHub
35-
- For the DPC++ Compiler project, use **sycl** branch as baseline for your
36-
changes. See [Get Started Guide](sycl/doc/GetStartedGuide.md).
3730
- Prepare your patch
3831
- follow [LLVM coding standards](https://llvm.org/docs/CodingStandards.html)
3932
- [clang-format](https://clang.llvm.org/docs/ClangFormat.html) and
@@ -48,110 +41,41 @@ information.
4841
./clang/tools/clang-format/git-clang-format `git merge-base origin/sycl HEAD`
4942
```
5043

51-
to check the format of your current changes against the `origin/sycl`
52-
branch.
44+
to check the format of your current changes. `origin/sycl` branch is an
45+
example here
5346
- `-f` to also correct unstaged changes
5447
- `--diff` to only print the diff without applying
55-
- Build the project following
56-
[Get Started Guide instructions](sycl/doc/GetStartedGuide.md#build-dpc-toolchain).
57-
- Run regression tests -
58-
[instructions](sycl/doc/GetStartedGuide.md#test-dpc-toolchain).
59-
60-
### Tests development
61-
62-
Every product change should be accompanied with corresponding test modification
63-
(adding new test(s), extending, removing or modifying existing test(s)).
64-
65-
There are 3 types of tests which are used for DPC++ toolchain validation:
66-
* DPC++ in-tree tests including [check-llvm](llvm/test),
67-
[check-clang](clang/test), [check-llvm-spirv](llvm-spirv/test) and
68-
[check-sycl](sycl/test) targets stored in this repository. These tests
69-
should not have hardware (e.g. GPU, FPGA, etc.) or external software
70-
dependencies (e.g. OpenCL, Level Zero, CUDA runtimes). All tests not following
71-
this approach should be moved to DPC++ end-to-end or SYCL-CTS tests.
72-
Generally, any functional change to any of the DPC++ toolchain components
73-
should be accompanied by one or more tests of this type when possible. They
74-
allow verifying individual components and tend to be more lightweight than
75-
end-to-end or SYCL-CTS tests.
76-
77-
**General guidelines for adding DPC++ in-tree tests**:
7848

79-
- Use `sycl::` namespace instead of `cl::sycl::`
49+
#### Project-specific contribution guidelines
8050

81-
- Add a helpful comment describing what the test does at the beginning and
82-
other comments throughout the test as necessary.
51+
- [Contribute to DPC++](/../sycl/sycl/doc/developer/ContributeToDPCPP.md)
8352

84-
- Try to follow descriptive naming convention for variables, functions as
85-
much as possible.
86-
Please refer to
87-
[LLVM naming convention](https://llvm.org/docs/CodingStandards.html#name-types-functions-variables-and-enumerators-properly)
88-
89-
**DPC++ clang FE tests**:
90-
91-
- Include sycl mock headers as system headers.
92-
Example: `-internal-isystem %S/Inputs`
93-
`#include "sycl.hpp"`
94-
95-
- Use SYCL functions for invoking kernels from the mock header
96-
`(single_task, parallel_for, parallel_for_work_group)`
97-
Example:
98-
```bash
99-
`#include "Inputs/sycl.hpp"`
100-
sycl::queue q;
101-
q.submit([&](cl::sycl::handler &h) {
102-
h.single_task( { //code });
103-
});
104-
```
53+
### Pull request
10554

106-
**DPC++ headers and runtime tests**:
107-
108-
- [check-sycl](sycl/test) target contains 2 types of tests: LIT tests and
109-
unit tests. LIT tests make compile-time checks of DPC++ headers, e.g. device
110-
code IR verification, static_assert tests. Unit tests check DPC++ runtime
111-
behavior and do not perform any device code compilation, instead relying on
112-
redefining plugin API with [PiMock](sycl/unittests/helpers/PiMock.hpp) when
113-
necessary.
114-
115-
* DPC++ end-to-end (E2E) tests which are extension to
116-
[LLVM\* test suite](https://github.com/intel/llvm-test-suite/tree/intel/SYCL).
117-
A test which requires full stack including backend runtimes (e.g. OpenCL,
118-
Level Zero or CUDA) should be put to DPC++ E2E test suite following
119-
[CONTRIBUTING](https://github.com/intel/llvm-test-suite/blob/intel/CONTRIBUTING.md).
120-
121-
* SYCL-CTS are official
122-
[Khronos\* SYCL\* conformance tests](https://github.com/KhronosGroup/SYCL-CTS).
123-
They verify SYCL specification compatibility. All implementation details or
124-
extensions are out of scope for the tests. If SYCL specification has changed
125-
(SYCL CTS tests conflict with recent version of SYCL specification) or change
126-
is required in the way the tests are built with DPC++ compiler (defined in
127-
[FindIntel_SYCL](https://github.com/KhronosGroup/SYCL-CTS/blob/SYCL-1.2.1/master/cmake/FindIntel_SYCL.cmake))
128-
pull request should be created under
129-
[KhronosGroup/SYCL-CTS](https://github.com/KhronosGroup/SYCL-CTS) with required
130-
patch.
131-
132-
### Commit message
133-
134-
- When writing your commit message, please make sure to follow
55+
- When creating your commit messages, please make sure to follow
13556
[LLVM developer policies](
13657
https://llvm.org/docs/DeveloperPolicy.html#commit-messages) on the subject.
137-
- For any DPC++-related commit, the `[SYCL]` tag should be present in the
138-
commit message title. To a reasonable extent, additional tags can be used
139-
to signify the component changed, e.g.: `[PI]`, `[CUDA]`, `[Doc]`.
140-
- For product changes which require modification in tests outside of the current repository
141-
(see [Test DPC++ toolchain](sycl/doc/GetStartedGuide.md#test-dpc-toolchain)),
142-
the commit message should contain the link to corresponding test PR, e.g.: E2E
143-
test changes are available under intel/llvm-test-suite#88 or SYCL
144-
conformance test changes are available under KhronosGroup/SYCL-CTS#65 (see
145-
[Autolinked references and URLs](https://docs.github.com/en/free-pro-team/github/writing-on-github/autolinked-references-and-urls)
58+
- [The seven rules of a great Git commit message](https://cbea.ms/git-commit)
59+
are recommended read and follow.
60+
- To a reasonable extent, title tags can be used to signify the component
61+
changed, e.g.: `[PI]`, `[CUDA]`, `[Doc]`.
62+
- Create a pull request (PR) for your changes following
63+
[Creating a pull request instructions](https://help.github.com/articles/creating-a-pull-request/).
64+
- Make sure PR has a good description explaining all of the changes made,
65+
represented by commits in the PR.
66+
- When PR is merged all commits are squashed and PR description is used as
67+
the merged commit message.
68+
- Consider splitting the large set of changes on small independent PRs that
69+
can be reviewed, tested and merged independently.
70+
- For changes which require modification in tests outside of the current repository
71+
the commit message should contain the link to corresponding test PR.
72+
For example: intel/llvm-test-suite#88 or KhronosGroup/SYCL-CTS#65. (see
73+
[Autolinked references and URLs](https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/autolinked-references-and-urls)
14674
for more details). The same message should be present both in commit
14775
message and in PR description.
14876

14977
### Review and acceptance testing
15078

151-
- Create a pull request for your changes following [Creating a pull request
152-
instructions](https://help.github.com/articles/creating-a-pull-request/).
153-
- CI will run a signed-off check as soon as your PR is created - see the
154-
**check_pr** CI action results.
15579
- CI will run several build and functional testing checks as soon as the PR is
15680
approved by an Intel representative.
15781
- A new approval is needed if the PR was updated (e.g. during code review).
@@ -160,12 +84,14 @@ ready for merge.
16084

16185
### Merge
16286

163-
Project maintainers merge pull requests using one of the following options:
87+
Project gatekeepers (@intel/llvm-gatekeepers) merge pull requests using [Squash
88+
and merge] and using PR description as the commit message, replacing all
89+
individual comments made per commit. Authors of the change must ensure PR
90+
description is up to date at the merge stage, as sometimes comments addressed
91+
during code reviews can invalidate original PR description. Feel free to ping
92+
@intel/llvm-gatekeepers if your PR is green and can be merged.
16493

165-
- [Rebase and merge] The preferable choice for PRs containing a single commit
166-
- [Squash and merge] Used when there are multiple commits in the PR
167-
- Squashing is done to make sure that the project is buildable on any commit
168-
- [Create a merge commit] Used for LLVM pull-down PRs to preserve hashes of the
169-
commits pulled from the LLVM community repository
94+
Pulldown from LLVM upstream is done through merge commits to preserve hashes of
95+
the original commits pulled from the LLVM community repository.
17096

171-
*Other names and brands may be claimed as the property of others.
97+
<sub>\*Other names and brands may be claimed as the property of others.</sub>

0 commit comments

Comments
 (0)