Skip to content

Commit 4251ba8

Browse files
committed
Merge remote-tracking branch 'origin/sycl' into uwe/fasternativecpuenqueue_async_ops_eventswait_onetbb_merge
2 parents f856e32 + 954cc7b commit 4251ba8

File tree

67 files changed

+1441
-826
lines changed

Some content is hidden

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

67 files changed

+1441
-826
lines changed

.github/workflows/sycl-ur-perf-benchmarking.yml

Lines changed: 73 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,18 @@ on:
2828
deployment branch will be used.
2929
required: false
3030
default: ''
31+
save_name:
32+
type: string
33+
description: |
34+
Specify a custom name to use for the benchmark result: If uploading
35+
results, this will be the name used to refer results from the current
36+
run.
37+
required: false
38+
default: ''
3139
upload_results:
3240
type: string # true/false: workflow_dispatch does not support booleans
41+
description: |
42+
Upload results to https://intel.github.io/llvm/benchmarks/.
3343
required: true
3444
runner:
3545
type: string
@@ -67,8 +77,14 @@ on:
6777
Leave both pr_no and commit_hash empty to use latest commit.
6878
required: false
6979
default: ''
80+
save_name:
81+
type: string
82+
description: |
83+
Name to use for the benchmark result:
84+
required: false
85+
default: ''
7086
upload_results:
71-
description: 'Save and upload results'
87+
description: 'Save and upload results (to https://intel.github.io/llvm/benchmarks)'
7288
type: choice
7389
options:
7490
- false
@@ -90,16 +106,61 @@ on:
90106
permissions: read-all
91107

92108
jobs:
109+
sanitize_inputs:
110+
name: Sanitize inputs
111+
runs-on: ubuntu-latest
112+
env:
113+
COMMIT_HASH: ${{ inputs.commit_hash }}
114+
PR_NO: ${{ inputs.pr_no }}
115+
SAVE_NAME: ${{ inputs.save_name }}
116+
outputs:
117+
benchmark_save_name: ${{ steps.sanitize.outputs.benchmark_save_name }}
118+
build_ref: ${{ steps.sanitize.outputs.build_ref }}
119+
steps:
120+
- id: sanitize
121+
run: |
122+
# Validate user inputs:
123+
# usage: check_if_nonempty <var> <regex to check var against> <err message>
124+
check_nonempty() {
125+
[ -z "$1" ] && return
126+
if [ -z "$(echo "$1" | grep -P "$2")" ]; then
127+
echo "$3"
128+
exit 1
129+
fi
130+
}
131+
check_nonempty "$COMMIT_HASH" '^[0-9a-f]{7,}$' "Bad commit hash (or hash short)."
132+
check_nonempty "$PR_NO" '^[0-9]+$' "Bad PR number."
133+
check_nonempty "$SAVE_NAME" '^[A-Za-z][A-Za-z0-9_-]+$' "Bad save name."
134+
135+
BENCHMARK_SAVE_NAME=""
136+
BUILD_REF="${{ github.ref }}"
137+
if [ -n "$SAVE_NAME" ]; then
138+
BENCHMARK_SAVE_NAME="$(echo "$SAVE_NAME" | tr -cd 'A-Za-z0-9_-')"
139+
fi;
140+
if [ -n "$COMMIT_HASH" ]; then
141+
echo "Using commit hash $COMMIT_HASH for build..."
142+
BUILD_REF="$COMMIT_HASH"
143+
shortened_commit="$(echo "$COMMIT_HASH" | cut -c 1-7)"
144+
[ -z "$BENCHMARK_SAVE_NAME" ] && BENCHMARK_SAVE_NAME="Commit_${shortened_commit}"
145+
elif [ -n "$PR_NO" ]; then
146+
echo "Using PR no. $PR_NO for build..."
147+
BUILD_REF="refs/pull/$PR_NO/head"
148+
[ -z "$BENCHMARK_SAVE_NAME" ] && BENCHMARK_SAVE_NAME="PR_${PR_NO}"
149+
fi
150+
[ -z "$BENCHMARK_SAVE_NAME" ] && BENCHMARK_SAVE_NAME="Baseline"
151+
152+
echo "benchmark_save_name=$BENCHMARK_SAVE_NAME" >> $GITHUB_OUTPUT
153+
echo "build_ref=$BUILD_REF" >> $GITHUB_OUTPUT
154+
155+
echo "Final sanitized values:"
156+
cat $GITHUB_OUTPUT
157+
93158
build_sycl:
94159
name: Build SYCL
160+
needs: [ sanitize_inputs ]
95161
uses: ./.github/workflows/sycl-linux-build.yml
96162
with:
97-
build_ref: |
98-
${{
99-
inputs.commit_hash != '' && inputs.commit_hash ||
100-
inputs.pr_no != '' && format('refs/pull/{0}/head', inputs.pr_no) ||
101-
github.ref
102-
}}
163+
build_ref: ${{ needs.sanitize_inputs.outputs.build_ref }}
103164
build_cache_root: "/__w/"
104165
build_cache_suffix: "prod_noassert"
105166
build_configure_extra_args: "--no-assertions"
@@ -112,14 +173,12 @@ jobs:
112173

113174
run_benchmarks_build:
114175
name: Run Benchmarks on Build
115-
needs: [ build_sycl ]
176+
needs: [ build_sycl, sanitize_inputs ]
116177
strategy:
117178
matrix:
118179
include:
119-
- ref: ${{ inputs.commit_hash != '' && inputs.commit_hash || inputs.pr_no != '' && format('refs/pull/{0}/head', inputs.pr_no) || github.ref }}
120-
save_name: ${{ inputs.commit_hash != '' && format('Commit{0}', inputs.commit_hash) || inputs.pr_no != '' && format('PR{0}', inputs.pr_no) || 'Baseline' }}
121-
# Set default values if not specified:
122-
runner: ${{ inputs.runner || '["PVC_PERF"]' }}
180+
# Set default values if not specified:
181+
- runner: ${{ inputs.runner || '["PVC_PERF"]' }}
123182
backend: ${{ inputs.backend || 'level_zero:gpu' }}
124183
uses: ./.github/workflows/sycl-linux-run-tests.yml
125184
secrets: inherit
@@ -131,9 +190,9 @@ jobs:
131190
target_devices: ${{ matrix.backend }}
132191
tests_selector: benchmarks
133192
benchmark_upload_results: ${{ inputs.upload_results }}
134-
benchmark_save_name: ${{ matrix.save_name }}
193+
benchmark_save_name: ${{ needs.sanitize_inputs.outputs.benchmark_save_name }}
135194
benchmark_preset: ${{ inputs.preset }}
136-
repo_ref: ${{ matrix.ref }}
195+
repo_ref: ${{ needs.sanitize_inputs.outputs.build_ref }}
137196
toolchain_artifact: ${{ needs.build_sycl.outputs.toolchain_artifact }}
138197
toolchain_artifact_filename: ${{ needs.build_sycl.outputs.toolchain_artifact_filename }}
139198
toolchain_decompress_command: ${{ needs.build_sycl.outputs.toolchain_decompress_command }}

README.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,6 @@ for general guidelines around contributing to this project. You can then see
7979
[ContributeToDPCPP](./sycl/doc/developer/ContributeToDPCPP.md) for DPC++ specific
8080
guidelines.
8181

82-
## Late-outline OpenMP\* and OpenMP\* Offload
83-
84-
See [openmp](/openmp) branch.
85-
8682
# License
8783

8884
See [LICENSE](./sycl/LICENSE.TXT) for details.

clang/include/clang/Basic/DiagnosticSemaKinds.td

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13038,6 +13038,8 @@ def err_free_function_first_occurrence_missing_attr: Error<
1303813038
"the first occurrence of SYCL kernel free function should be declared with 'sycl-nd-range-kernel' or 'sycl-single-task-kernel' compile time properties">;
1303913039
def err_free_function_class_method : Error<
1304013040
"%select{static |}0class method cannot be used to define a SYCL kernel free function kernel">;
13041+
def err_sycl_kernel_virtual_arg : Error<
13042+
"argument type '%0' virtually inherited from base class `%1` is not supported as a SYCL kernel argument">;
1304113043

1304213044

1304313045
// SYCL kernel entry point diagnostics

clang/include/clang/Driver/Options.td

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9265,14 +9265,11 @@ class CLRemainingArgsJoined<string name,
92659265
// (We don't put any of these in cl_compile_Group as the options they alias are
92669266
// already in the right group.)
92679267

9268-
// INTEL_CUSTOMIZATION
92699268
def _SLASH_Qfp_accuracy_EQ : CLJoined<"Qfp-accuracy=">,
92709269
Alias<ffp_accuracy_EQ>;
92719270
def _SLASH_Qfp_accuracy_COL : CLJoined<"Qfp-accuracy:">,
92729271
Alias<ffp_accuracy_EQ>,HelpText<"Specifies the required accuracy for "
92739272
"floating-point operations and library calls.">;
9274-
// END INTEL_CUSTOMIZATION
9275-
92769273
def _SLASH_Brepro : CLFlag<"Brepro">,
92779274
HelpText<"Do not write current time into COFF output (breaks link.exe /incremental)">,
92789275
Alias<mno_incremental_linker_compatible>;

0 commit comments

Comments
 (0)