From 6acb04cb02e16e53db4562e40c3cfdd41d8731cd Mon Sep 17 00:00:00 2001 From: Andrei Elovikov Date: Thu, 22 Sep 2022 12:10:35 -0700 Subject: [PATCH 1/5] [Draft][SYCL][Doc] Change versioning process --- sycl/doc/developer/ABIPolicyGuide.md | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/sycl/doc/developer/ABIPolicyGuide.md b/sycl/doc/developer/ABIPolicyGuide.md index 7eefc8bf21163..7cd8ec635caef 100644 --- a/sycl/doc/developer/ABIPolicyGuide.md +++ b/sycl/doc/developer/ABIPolicyGuide.md @@ -35,13 +35,12 @@ Adding a new exported symbol is considered to be non-breaking change. The release version of the DPC++ runtime library follows [Semantic Versioning](https://semver.org/) scheme: `MAJOR.MINOR.PATCH`. `MAJOR` version indicates breaking change. Version `X` is backwards incompatible with -version `X-1`. `MINOR` indicates a non-breaking change. The development version -of the library has a postfix `-V` that indicates breaking changes between -releases. Every time a pull request introduces a breaking change, it must also -uplift `V`. It is pull request author responsibility to accordingly update -`V` part of library version. If `V > 0` on release date, then `MAJOR_VERSION` -is uplifted and `V` is set to zero. `MAJOR`, `MINOR`, and `PATCH` versions are -not updated between releases. +version `X-1`. `MINOR` indicates a non-breaking change. We only bump each of +them once per development cycles between releases. Immediately after the release +branch has been brached off, the `MINOR` version is incremented. If an +ABI-breaking change is introduced then it should be accompanied with the bump of +a `MAJOR` version in the same PR (unless it had been bumped before in this +development cycle). ## `__SYCL_EXPORT` Macro From eaa6932c0fecf7963778b83f9c8fde71143ed778 Mon Sep 17 00:00:00 2001 From: Andrei Elovikov Date: Fri, 23 Sep 2022 11:42:25 -0700 Subject: [PATCH 2/5] Assume ABI-breaking releases are known in advance. --- sycl/doc/developer/ABIPolicyGuide.md | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/sycl/doc/developer/ABIPolicyGuide.md b/sycl/doc/developer/ABIPolicyGuide.md index 7cd8ec635caef..0a695664acf6c 100644 --- a/sycl/doc/developer/ABIPolicyGuide.md +++ b/sycl/doc/developer/ABIPolicyGuide.md @@ -35,12 +35,10 @@ Adding a new exported symbol is considered to be non-breaking change. The release version of the DPC++ runtime library follows [Semantic Versioning](https://semver.org/) scheme: `MAJOR.MINOR.PATCH`. `MAJOR` version indicates breaking change. Version `X` is backwards incompatible with -version `X-1`. `MINOR` indicates a non-breaking change. We only bump each of -them once per development cycles between releases. Immediately after the release -branch has been brached off, the `MINOR` version is incremented. If an -ABI-breaking change is introduced then it should be accompanied with the bump of -a `MAJOR` version in the same PR (unless it had been bumped before in this -development cycle). +version `X-1`. `MINOR` indicates a non-breaking change. We bump the versions +immediately after the previous release had been branched off. As such, if next +release is allowed/expected to be ABI-breaking we bump `MAJOR` and drop `MINOR` +to zero otherwise increment `MINOR` in the beginning of the development cycles. ## `__SYCL_EXPORT` Macro From f129cdc6363e468b832d3731aa4b17aa0cfb6df0 Mon Sep 17 00:00:00 2001 From: Andrei Elovikov Date: Thu, 20 Apr 2023 09:51:27 -0700 Subject: [PATCH 3/5] Bump the version 6.2.0 -> 7.0.0 --- clang/lib/Driver/CMakeLists.txt | 2 +- sycl/CMakeLists.txt | 4 ++-- sycl/test/abi/sycl_symbols_windows.dump | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/clang/lib/Driver/CMakeLists.txt b/clang/lib/Driver/CMakeLists.txt index ee4e6baf082fe..c71fd7e6aebc6 100644 --- a/clang/lib/Driver/CMakeLists.txt +++ b/clang/lib/Driver/CMakeLists.txt @@ -19,7 +19,7 @@ endif() # This must be in sync with llvm/sycl/CMakeLists.txt. SET_SOURCE_FILES_PROPERTIES( ToolChains/MSVC.cpp ToolChains/Clang.cpp - PROPERTIES COMPILE_DEFINITIONS SYCL_MAJOR_VERSION="6" ) + PROPERTIES COMPILE_DEFINITIONS SYCL_MAJOR_VERSION="7" ) add_clang_library(clangDriver Action.cpp diff --git a/sycl/CMakeLists.txt b/sycl/CMakeLists.txt index b9cf1ad67b985..b54a1b44343d6 100644 --- a/sycl/CMakeLists.txt +++ b/sycl/CMakeLists.txt @@ -32,8 +32,8 @@ include(SYCLUtils) # # See doc/developer/ABIPolicyGuide.md for the meaning when in the middle of # development cycle. -set(SYCL_MAJOR_VERSION 6) -set(SYCL_MINOR_VERSION 2) +set(SYCL_MAJOR_VERSION 7) +set(SYCL_MINOR_VERSION 0) set(SYCL_PATCH_VERSION 0) set(SYCL_DEV_ABI_VERSION 0) diff --git a/sycl/test/abi/sycl_symbols_windows.dump b/sycl/test/abi/sycl_symbols_windows.dump index 5f56778c2c322..c9b772830fef9 100644 --- a/sycl/test/abi/sycl_symbols_windows.dump +++ b/sycl/test/abi/sycl_symbols_windows.dump @@ -3,7 +3,7 @@ # DO NOT EDIT IT MANUALLY. Refer to sycl/doc/developer/ABIPolicyGuide.md for more info. ################################################################################ -# RUN: env LLVM_BIN_PATH=%llvm_build_bin_dir %python %sycl_tools_src_dir/abi_check.py --mode check_symbols --reference %s %llvm_build_bin_dir/sycl6.dll +# RUN: env LLVM_BIN_PATH=%llvm_build_bin_dir %python %sycl_tools_src_dir/abi_check.py --mode check_symbols --reference %s %llvm_build_bin_dir/sycl7.dll # REQUIRES: windows # UNSUPPORTED: libcxx From a3e8f42012b40323d1553457d64fda3bf38ca1b3 Mon Sep 17 00:00:00 2001 From: Andrei Elovikov Date: Fri, 21 Apr 2023 12:53:11 -0700 Subject: [PATCH 4/5] Update LIT's %sycl_lib substitution --- sycl/test/lit.cfg.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sycl/test/lit.cfg.py b/sycl/test/lit.cfg.py index 3ca752c46b182..e2068ff033293 100644 --- a/sycl/test/lit.cfg.py +++ b/sycl/test/lit.cfg.py @@ -102,7 +102,7 @@ sycl_host_only_options += ' -isystem %s' % include_dir config.substitutions.append( ('%fsycl-host-only', sycl_host_only_options) ) -config.substitutions.append( ('%sycl_lib', ' -lsycl6' if platform.system() == "Windows" else '-lsycl') ) +config.substitutions.append( ('%sycl_lib', ' -lsycl7' if platform.system() == "Windows" else '-lsycl') ) llvm_config.add_tool_substitutions(['llvm-spirv'], [config.sycl_tools_dir]) From 1e1cd8ae5362f76af153e729b7f396b3e3930f77 Mon Sep 17 00:00:00 2001 From: Andrei Elovikov Date: Mon, 24 Apr 2023 09:40:28 -0700 Subject: [PATCH 5/5] Update substitutions for sycl/test-e2e as well --- sycl/test-e2e/lit.cfg.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sycl/test-e2e/lit.cfg.py b/sycl/test-e2e/lit.cfg.py index b05e8911b1262..419bd1d505c4a 100644 --- a/sycl/test-e2e/lit.cfg.py +++ b/sycl/test-e2e/lit.cfg.py @@ -197,7 +197,7 @@ config.substitutions.append( ('%opencl_include_dir', config.opencl_include_dir) ) if cl_options: - config.substitutions.append( ('%sycl_options', ' ' + config.sycl_libs_dir + '/../lib/sycl6.lib /I' + + config.substitutions.append( ('%sycl_options', ' ' + config.sycl_libs_dir + '/../lib/sycl7.lib /I' + config.sycl_include + ' /I' + os.path.join(config.sycl_include, 'sycl')) ) config.substitutions.append( ('%include_option', '/FI' ) ) config.substitutions.append( ('%debug_option', '/DEBUG' ) ) @@ -206,7 +206,7 @@ config.substitutions.append( ('%shared_lib', '/LD') ) else: config.substitutions.append( ('%sycl_options', - (' -lsycl6' if platform.system() == "Windows" else " -lsycl") + ' -I' + + (' -lsycl7' if platform.system() == "Windows" else " -lsycl") + ' -I' + config.sycl_include + ' -I' + os.path.join(config.sycl_include, 'sycl') + ' -L' + config.sycl_libs_dir) ) config.substitutions.append( ('%include_option', '-include' ) )