diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index c4b1ab9c43f75..66c2e269852d0 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -63,7 +63,7 @@ jobs: fetch-depth: 1 - name: Get subprojects that have doc changes id: docs-changed-subprojects - uses: tj-actions/changed-files@v41 + uses: tj-actions/changed-files@v42 with: files_yaml: | llvm: @@ -98,7 +98,7 @@ jobs: with: fetch-depth: 1 - name: Setup Python env - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.11' cache: 'pip' diff --git a/.github/workflows/gh_pages.yml b/.github/workflows/gh_pages.yml index bdec66d3750d0..d0d4a130d6f78 100644 --- a/.github/workflows/gh_pages.yml +++ b/.github/workflows/gh_pages.yml @@ -13,10 +13,10 @@ on: jobs: build: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest if: github.repository == 'intel/llvm' steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: path: repo - name: Install deps diff --git a/.github/workflows/libclang-abi-tests.yml b/.github/workflows/libclang-abi-tests.yml index ccfc1e5fb8a74..92499ba8df90d 100644 --- a/.github/workflows/libclang-abi-tests.yml +++ b/.github/workflows/libclang-abi-tests.yml @@ -131,7 +131,7 @@ jobs: sed -i 's/LLVM_[0-9]\+/LLVM_NOVERSION/' $lib-${{ matrix.ref }}.abi done - name: Upload ABI file - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: ${{ matrix.name }} path: '*${{ matrix.ref }}.abi' @@ -144,12 +144,12 @@ jobs: - abi-dump steps: - name: Download baseline - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: build-baseline path: build-baseline - name: Download latest - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: build-latest path: build-latest @@ -163,7 +163,7 @@ jobs: done - name: Upload ABI Comparison if: always() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: compat-report-${{ github.sha }} path: compat_reports/ diff --git a/.github/workflows/libcxx-build-and-test.yaml b/.github/workflows/libcxx-build-and-test.yaml index 0cab9b841e4ee..c984cf76435bb 100644 --- a/.github/workflows/libcxx-build-and-test.yaml +++ b/.github/workflows/libcxx-build-and-test.yaml @@ -75,7 +75,7 @@ jobs: CC: ${{ matrix.cc }} CXX: ${{ matrix.cxx }} ENABLE_CLANG_TIDY: ${{ matrix.clang_tidy }} - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 if: always() with: name: ${{ matrix.config }}-${{ matrix.cxx }}-results @@ -124,7 +124,7 @@ jobs: CC: ${{ matrix.cc }} CXX: ${{ matrix.cxx }} ENABLE_CLANG_TIDY: ${{ matrix.clang_tidy }} - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 if: always() # Upload artifacts even if the build or test suite fails with: name: ${{ matrix.config }}-results @@ -189,7 +189,7 @@ jobs: CC: clang-18 CXX: clang++-18 ENABLE_CLANG_TIDY: "OFF" - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 if: always() with: name: ${{ matrix.config }}-results diff --git a/.github/workflows/llvm-bugs.yml b/.github/workflows/llvm-bugs.yml index f592dd6ccd903..4797eea4e3d3d 100644 --- a/.github/workflows/llvm-bugs.yml +++ b/.github/workflows/llvm-bugs.yml @@ -14,13 +14,13 @@ jobs: runs-on: ubuntu-latest if: github.repository == 'llvm/llvm-project' steps: - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 18 check-latest: true - run: npm install mailgun.js form-data - name: Send notification - uses: actions/github-script@v6 + uses: actions/github-script@v7 env: MAILGUN_API_KEY: ${{ secrets.LLVM_BUGS_KEY }} with: diff --git a/.github/workflows/llvm-project-tests.yml b/.github/workflows/llvm-project-tests.yml index a1404e1f1efa9..350bfe652f7a6 100644 --- a/.github/workflows/llvm-project-tests.yml +++ b/.github/workflows/llvm-project-tests.yml @@ -74,7 +74,7 @@ jobs: # lldb. Using this setup-python action to make 3.10 the default # python fixes this. - name: Setup Python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: ${{ inputs.python_version }} - name: Install Ninja diff --git a/.github/workflows/llvm-tests.yml b/.github/workflows/llvm-tests.yml index cc9855ce182b2..01046e7c0bd28 100644 --- a/.github/workflows/llvm-tests.yml +++ b/.github/workflows/llvm-tests.yml @@ -147,14 +147,14 @@ jobs: # Remove symbol versioning from dumps, so we can compare across major versions. sed -i 's/LLVM_${{ matrix.llvm_version_major }}/LLVM_NOVERSION/' ${{ matrix.ref }}.abi - name: Upload ABI file - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: ${{ matrix.name }} path: ${{ matrix.ref }}.abi - name: Upload symbol list file if: matrix.name == 'build-baseline' - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: symbol-list path: llvm.symbols @@ -167,17 +167,17 @@ jobs: - abi-dump steps: - name: Download baseline - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: build-baseline path: build-baseline - name: Download latest - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: build-latest path: build-latest - name: Download symbol list - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: symbol-list path: symbol-list @@ -196,7 +196,7 @@ jobs: abi-compliance-checker "$EXTRA_ARGS" -l libLLVM.so -old build-baseline/*.abi -new build-latest/*.abi || test "${{ needs.abi-dump-setup.outputs.ABI_HEADERS }}" = "llvm-c" - name: Upload ABI Comparison if: always() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: compat-report-${{ github.sha }} path: compat_reports/ diff --git a/.github/workflows/new-prs.yml b/.github/workflows/new-prs.yml index a52e4e9436263..ee6bd46beeebb 100644 --- a/.github/workflows/new-prs.yml +++ b/.github/workflows/new-prs.yml @@ -68,7 +68,7 @@ jobs: github.event.pull_request.draft == false && github.event.pull_request.commits < 10 steps: - - uses: actions/labeler@v4 + - uses: actions/labeler@v5 with: configuration-path: .github/new-prs-labeler.yml # workaround for https://github.com/actions/labeler/issues/112 diff --git a/.github/workflows/pr-code-format.yml b/.github/workflows/pr-code-format.yml index 99e685ab7cd17..a28d6c9f49e0d 100644 --- a/.github/workflows/pr-code-format.yml +++ b/.github/workflows/pr-code-format.yml @@ -22,7 +22,7 @@ jobs: - name: Get changed files id: changed-files - uses: tj-actions/changed-files@v41 + uses: tj-actions/changed-files@v42 with: separator: "," skip_initial_fetch: true @@ -52,7 +52,7 @@ jobs: clangformat: 17.0.1 - name: Setup Python env - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.11' cache: 'pip' diff --git a/.github/workflows/release-documentation.yml b/.github/workflows/release-documentation.yml index 64572906988ba..02ffbb142a940 100644 --- a/.github/workflows/release-documentation.yml +++ b/.github/workflows/release-documentation.yml @@ -37,7 +37,7 @@ jobs: uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - name: Setup Python env - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: cache: 'pip' cache-dependency-path: './llvm/docs/requirements.txt' @@ -59,7 +59,7 @@ jobs: ./llvm/utils/release/build-docs.sh -release "${{ inputs.release-version }}" -no-doxygen - name: Create Release Notes Artifact - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: release-notes path: docs-build/html-export/ diff --git a/.github/workflows/release-doxygen.yml b/.github/workflows/release-doxygen.yml index 5e322849a1d09..f39822bdff387 100644 --- a/.github/workflows/release-doxygen.yml +++ b/.github/workflows/release-doxygen.yml @@ -39,7 +39,7 @@ jobs: uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - name: Setup Python env - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: cache: 'pip' cache-dependency-path: './llvm/docs/requirements.txt' diff --git a/.github/workflows/scorecard.yml b/.github/workflows/scorecard.yml index b8e8ab26c3ffa..3bfc5a062df12 100644 --- a/.github/workflows/scorecard.yml +++ b/.github/workflows/scorecard.yml @@ -31,12 +31,12 @@ jobs: steps: - name: "Checkout code" - uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v3.1.0 + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 with: persist-credentials: false - name: "Run analysis" - uses: ossf/scorecard-action@e38b1902ae4f44df626f11ba0734b14fb91f8f86 # v2.1.2 + uses: ossf/scorecard-action@0864cf19026789058feabb7e87baa5f140aac736 # v2.3.1 with: results_file: results.sarif results_format: sarif @@ -49,7 +49,7 @@ jobs: # Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF # format to the repository Actions tab. - name: "Upload artifact" - uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0 + uses: actions/upload-artifact@26f96dfa697d77e81fd5907df203aa23a56210a8 # v4.3.0 with: name: SARIF file path: results.sarif @@ -57,6 +57,6 @@ jobs: # Upload the results to GitHub's code scanning dashboard. - name: "Upload to code-scanning" - uses: github/codeql-action/upload-sarif@17573ee1cc1b9d061760f3a006fc4aac4f944fd5 # v2.2.4 + uses: github/codeql-action/upload-sarif@0b21cf2492b6b02c465a3e5d7c473717ad7721ba # v3.23.1 with: sarif_file: results.sarif diff --git a/.github/workflows/sycl_containers.yaml b/.github/workflows/sycl_containers.yaml index 1115d5ef43239..011d45ee9fee5 100644 --- a/.github/workflows/sycl_containers.yaml +++ b/.github/workflows/sycl_containers.yaml @@ -28,7 +28,7 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 2 - name: Build and Push Container @@ -47,7 +47,7 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 2 - name: Build and Push Container @@ -70,7 +70,7 @@ jobs: needs: base_image_ubuntu2204 steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 2 - name: Get dependencies configuration @@ -108,7 +108,7 @@ jobs: needs: base_image_ubuntu2204 steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: fetch-depth: 2 - name: Get dependencies configuration diff --git a/.github/workflows/sycl_detect_changes.yml b/.github/workflows/sycl_detect_changes.yml index b3de9d128d13d..0948642344190 100644 --- a/.github/workflows/sycl_detect_changes.yml +++ b/.github/workflows/sycl_detect_changes.yml @@ -60,7 +60,7 @@ jobs: - name: Set output id: result - uses: actions/github-script@v6 + uses: actions/github-script@v7 with: script: | console.log("Number of files changed:"); diff --git a/.github/workflows/sycl_linux_build.yml b/.github/workflows/sycl_linux_build.yml index 826ab445458b9..6c64e0c56c409 100644 --- a/.github/workflows/sycl_linux_build.yml +++ b/.github/workflows/sycl_linux_build.yml @@ -137,7 +137,7 @@ jobs: echo "Unsupported extension" exit 1 fi - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: sparse-checkout: | devops/actions @@ -227,7 +227,7 @@ jobs: run: tar -I '${{ steps.artifact_info.outputs.COMPRESS }}' -cf ${{ steps.artifact_info.outputs.ARCHIVE_NAME }} -C $GITHUB_WORKSPACE/build/install . - name: Upload toolchain if: ${{ always() && !cancelled() && steps.build.conclusion == 'success' }} - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: sycl_linux_${{ inputs.build_artifact_suffix }} path: ${{ steps.artifact_info.outputs.ARCHIVE_NAME }} diff --git a/.github/workflows/sycl_linux_precommit_aws.yml b/.github/workflows/sycl_linux_precommit_aws.yml index 5bb0cb908bd07..3fce40107d90e 100644 --- a/.github/workflows/sycl_linux_precommit_aws.yml +++ b/.github/workflows/sycl_linux_precommit_aws.yml @@ -18,7 +18,7 @@ jobs: create-check: runs-on: [Linux, build] steps: - - uses: actions/github-script@v6 + - uses: actions/github-script@v7 with: script: | const sha = context.payload.workflow_run.head_sha @@ -40,7 +40,7 @@ jobs: runs-on: ubuntu-20.04 environment: aws steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: sparse-checkout: devops/actions/aws-ec2 - run: npm install ./devops/actions/aws-ec2 @@ -75,7 +75,7 @@ jobs: if: always() runs-on: [Linux, build] steps: - - uses: actions/github-script@v6 + - uses: actions/github-script@v7 with: script: | const sha = context.payload.workflow_run.head_sha @@ -99,7 +99,7 @@ jobs: runs-on: ubuntu-20.04 environment: aws steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: sparse-checkout: devops/actions/aws-ec2 - run: npm install ./devops/actions/aws-ec2 diff --git a/.github/workflows/sycl_linux_run_tests.yml b/.github/workflows/sycl_linux_run_tests.yml index fb3e027f0f959..639c788c7fbd3 100644 --- a/.github/workflows/sycl_linux_run_tests.yml +++ b/.github/workflows/sycl_linux_run_tests.yml @@ -145,7 +145,7 @@ jobs: run: | sudo mount -t debugfs none /sys/kernel/debug sudo bash -c 'echo 1 > /sys/kernel/debug/dri/0/i915_wedged' - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ inputs.ref }} sparse-checkout: | @@ -197,7 +197,7 @@ jobs: rm env_before env_after - name: Download SYCL toolchain if: inputs.sycl_toolchain_artifact != '' && github.event_name != 'workflow_run' - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: ${{ inputs.sycl_toolchain_artifact }} - name: Debug prints [workflow_run] @@ -207,7 +207,7 @@ jobs: ls - name: Download SYCL toolchain [workflow_run] if: inputs.sycl_toolchain_artifact != '' && github.event_name == 'workflow_run' - uses: actions/github-script@v6 + uses: actions/github-script@v7 with: script: | const name = '${{ inputs.sycl_toolchain_artifact }}' diff --git a/.github/workflows/sycl_macos_build_and_test.yml b/.github/workflows/sycl_macos_build_and_test.yml index 9fd65ce7706ba..b79fbb3fa7ad5 100644 --- a/.github/workflows/sycl_macos_build_and_test.yml +++ b/.github/workflows/sycl_macos_build_and_test.yml @@ -29,11 +29,11 @@ jobs: steps: - name: Install dependencies run: brew install ccache ninja - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ inputs.build_ref }} path: src - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: build_cache_${{ inputs.build_cache_suffix }} key: sycl-${{ runner.os }}-${{ inputs.build_cache_suffix }}-${{ github.sha }} diff --git a/.github/workflows/sycl_nightly.yml b/.github/workflows/sycl_nightly.yml index c2b8a3cf5a5d8..e802af89a29b4 100644 --- a/.github/workflows/sycl_nightly.yml +++ b/.github/workflows/sycl_nightly.yml @@ -101,10 +101,10 @@ jobs: needs: [ubuntu2204_build, build-win] runs-on: ubuntu-latest steps: - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: sycl_linux_default - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: sycl_windows_default - name: Compute tag @@ -133,8 +133,8 @@ jobs: runs-on: [Linux, build] needs: ubuntu2204_build steps: - - uses: actions/checkout@v3 - - uses: actions/download-artifact@v3 + - uses: actions/checkout@v4 + - uses: actions/download-artifact@v4 with: name: sycl_linux_default path: devops/ diff --git a/.github/workflows/sycl_stale_issues.yml b/.github/workflows/sycl_stale_issues.yml index 1e199d5d08faf..a362cf1faa803 100644 --- a/.github/workflows/sycl_stale_issues.yml +++ b/.github/workflows/sycl_stale_issues.yml @@ -8,7 +8,7 @@ jobs: close-issues: runs-on: ubuntu-20.04 steps: - - uses: actions/stale@v7 + - uses: actions/stale@v9 with: stale-issue-message: 'This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be automatically closed in 30 days.' close-issue-message: 'This issue was closed because it has been stalled for 30 days with no activity. Please, re-open if the issue still exists.' diff --git a/.github/workflows/sycl_update_gpu_driver.yml b/.github/workflows/sycl_update_gpu_driver.yml index 65f93f6852877..9dcb66b7d95bd 100644 --- a/.github/workflows/sycl_update_gpu_driver.yml +++ b/.github/workflows/sycl_update_gpu_driver.yml @@ -10,7 +10,7 @@ jobs: runs-on: ubuntu-20.04 if: github.repository == 'intel/llvm' steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Update dependencies file run: | version="$(python3 devops/scripts/update_drivers.py linux)" diff --git a/.github/workflows/sycl_windows_build.yml b/.github/workflows/sycl_windows_build.yml index 4c5d7d035c12a..64e62b7ef58fd 100644 --- a/.github/workflows/sycl_windows_build.yml +++ b/.github/workflows/sycl_windows_build.yml @@ -60,7 +60,7 @@ jobs: outputs: build_conclusion: ${{ steps.build.conclusion }} steps: - - uses: ilammy/msvc-dev-cmd@7315a94840631165970262a99c72cfb48a65d25d + - uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 with: arch: amd64 - name: Set env @@ -69,7 +69,7 @@ jobs: git config --global core.autocrlf false echo "C:\Program Files\Git\usr\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append echo "SCCACHE_DIR=D:\github\_work\cache\${{ inputs.build_cache_suffix }}" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: path: src ref: ${{ inputs.build_ref || github.sha }} @@ -143,7 +143,7 @@ jobs: tar -czf ${{ inputs.artifact_archive_name }} -C install . - name: Upload toolchain if: ${{ always() && !cancelled() && steps.build.conclusion == 'success' }} - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: sycl_windows_default path: ${{ inputs.artifact_archive_name }} diff --git a/.github/workflows/sycl_windows_run_tests.yml b/.github/workflows/sycl_windows_run_tests.yml index 3c22e42db7384..f5a718c6cc9c1 100644 --- a/.github/workflows/sycl_windows_run_tests.yml +++ b/.github/workflows/sycl_windows_run_tests.yml @@ -39,7 +39,7 @@ jobs: environment: WindowsCILock env: ${{ fromJSON(inputs.env) }} steps: - - uses: ilammy/msvc-dev-cmd@7315a94840631165970262a99c72cfb48a65d25d + - uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 with: arch: amd64 - name: Set env @@ -48,7 +48,7 @@ jobs: git config --global core.autocrlf false echo "C:\Program Files\Git\usr\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append # TODO: use cached_checkout - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: persist-credentials: false ref: ${{ inputs.ref || github.sha }} @@ -56,7 +56,7 @@ jobs: - name: Register cleanup after job is finished uses: ./llvm/devops/actions/cleanup - name: Download compiler toolchain - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: ${{ inputs.sycl_toolchain_artifact }} - name: Extract SYCL toolchain diff --git a/.github/workflows/sync-main.yml b/.github/workflows/sync-main.yml index b34257e389661..54d50acd9f80b 100644 --- a/.github/workflows/sync-main.yml +++ b/.github/workflows/sync-main.yml @@ -8,7 +8,7 @@ jobs: runs-on: ubuntu-20.04 if: github.repository == 'intel/llvm' steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: # persist-credentials: false allows us to use our own credentials for # pushing to the repository. Otherwise, the default github actions token diff --git a/clang/lib/CodeGen/CGDebugInfo.cpp b/clang/lib/CodeGen/CGDebugInfo.cpp index 3be77912ab75a..3ba83811d09d4 100644 --- a/clang/lib/CodeGen/CGDebugInfo.cpp +++ b/clang/lib/CodeGen/CGDebugInfo.cpp @@ -6027,6 +6027,18 @@ bool clang::CodeGen::noSystemDebugInfo(const Decl *D, const CodeGenModule &CGM) { // Declaration is in system file if (CGM.getContext().getSourceManager().isInSystemHeader(D->getLocation())) { + // Make an exception for typedefs in system header files. Generate debug + // information for these decls because these are rare (thus they will not + // greatly increase debug size) and a user could rely on these typedefs + // during debugging. For example uid_t in in "sys/types.h" can be used in + // the gdb command: + // + // print ruid == (uid_t)-1 + // + // This occurs in GDB test gdb.reverse/getresuid-reverse.c + if (isa(D)) + return false; + // -fno-system-debug was used. Do not generate debug info. if (CGM.getCodeGenOpts().NoSystemDebug) return true; diff --git a/clang/test/CodeGen/debug-info-system-typedef.c b/clang/test/CodeGen/debug-info-system-typedef.c new file mode 100644 index 0000000000000..bbea7531e3f00 --- /dev/null +++ b/clang/test/CodeGen/debug-info-system-typedef.c @@ -0,0 +1,37 @@ +// Ensure that debug info for typedefs in system headers is still generated +// even if -fno-system-debug is used. This is justified because debug size +// savings is small, but debugging is commonly done with types that are +// typedef-ed in system headers. Thus, the increased debuggability +// is worth the small extra cost. + +// RUN: %clang -fno-system-debug -emit-llvm -S -g %s -o %t.ll + +// RUN: FileCheck %s < %t.ll + +// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "int_fast8_t", +// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "int_fast16_t", +// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "int_fast32_t", +// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "int_fast64_t", + +// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "uint_fast8_t", +// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "uint_fast16_t", +// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "uint_fast32_t", +// CHECK-DAG: !DIDerivedType(tag: DW_TAG_typedef, name: "uint_fast64_t", + +#include + +int_fast8_t f8; +int_fast16_t f16; +int_fast32_t f32; +int_fast64_t f64; + +uint_fast8_t uf8; +uint_fast16_t uf16; +uint_fast32_t uf32; +uint_fast64_t uf64; + +int +main (void) +{ + return 0; +} diff --git a/clang/test/Driver/sycl-offload-amdgcn.cpp b/clang/test/Driver/sycl-offload-amdgcn.cpp index ececd41c3b680..407dfd02c9205 100644 --- a/clang/test/Driver/sycl-offload-amdgcn.cpp +++ b/clang/test/Driver/sycl-offload-amdgcn.cpp @@ -1,6 +1,7 @@ /// Tests specific to `-fsycl-targets=amdgcn-amd-amdhsa` // UNSUPPORTED: system-windows +// REQUIRES: amdgpu-registered-target // Check that the offload arch is required // RUN: not %clangxx -### -std=c++11 -target x86_64-unknown-linux-gnu -fsycl \ diff --git a/clang/test/Driver/sycl-triple-dae-flags.cpp b/clang/test/Driver/sycl-triple-dae-flags.cpp index 1fe662a7f980d..a0eb8c490dfc8 100644 --- a/clang/test/Driver/sycl-triple-dae-flags.cpp +++ b/clang/test/Driver/sycl-triple-dae-flags.cpp @@ -1,3 +1,5 @@ +// REQUIRES: nvptx-registered-target, amdgpu-registered-target + // RUN: %clangxx -### -fsycl -fsycl-targets=amdgcn-amd-amdhsa -Xsycl-target-backend --offload-arch=gfx906 -fsycl-dead-args-optimization -nogpulib %s 2> %t.rocm.out // RUN: FileCheck %s --input-file %t.rocm.out // CHECK-NOT: -fenable-sycl-dae diff --git a/clang/test/Driver/sycl-unsupported-arch.cpp b/clang/test/Driver/sycl-unsupported-arch.cpp index e5fd47f339fd5..7d6d1bb1dac58 100644 --- a/clang/test/Driver/sycl-unsupported-arch.cpp +++ b/clang/test/Driver/sycl-unsupported-arch.cpp @@ -1,3 +1,5 @@ +// REQUIRES: amdgpu-registered-target + /// Verify that compiler passes are correctly determined // RUN: %clangxx -fsycl -fsycl-targets=amdgcn-amd-amdhsa -Xsycl-target-backend=amdgcn-amd-amdhsa --offload-arch=gfx600 -nogpulib -c -ccc-print-phases %s 2>&1 | FileCheck %s --check-prefix=CHECK-PHASES // CHECK-PHASES: offload, "device-sycl (amdgcn-amd-amdhsa:gfx600)" diff --git a/libclc/ptx-nvidiacl/libspirv/atomic/atomic_cmpxchg.cl b/libclc/ptx-nvidiacl/libspirv/atomic/atomic_cmpxchg.cl index 078eb86cdc294..fceeda0f60361 100644 --- a/libclc/ptx-nvidiacl/libspirv/atomic/atomic_cmpxchg.cl +++ b/libclc/ptx-nvidiacl/libspirv/atomic/atomic_cmpxchg.cl @@ -86,7 +86,7 @@ SemanticsMask4FlagES##SUBSTITUTION2##_##TYPE_MANGLED##TYPE_MANGLED( \ enum MemorySemanticsMask semantics2, TYPE cmp, TYPE value) { \ /* Semantics mask may include memory order, storage class and other info \ Memory order is stored in the lowest 5 bits */ \ - unsigned int order = (semantics1 | semantics2) & 0x1F; \ + unsigned int order = semantics1 & 0x1F; \ switch (order) { \ case None: \ __CLC_NVVM_ATOMIC_CAS_IMPL_ORDER(TYPE, TYPE_NV, TYPE_MANGLED_NV, OP, \ diff --git a/llvm/docs/requirements-hashed.txt b/llvm/docs/requirements-hashed.txt index 19d1cfdfc572d..1f31ecb3b60b5 100644 --- a/llvm/docs/requirements-hashed.txt +++ b/llvm/docs/requirements-hashed.txt @@ -4,17 +4,17 @@ # # pip-compile --generate-hashes --output-file=requirements-hashed.txt requirements.txt # -alabaster==0.7.13 \ - --hash=sha256:1ee19aca801bbabb5ba3f5f258e4422dfa86f82f3e9cefb0859b283cdd7f62a3 \ - --hash=sha256:a27a4a084d5e690e16e01e03ad2b2e552c61a65469419b907243193de1a84ae2 +alabaster==0.7.16 \ + --hash=sha256:75a8b99c28a5dad50dd7f8ccdd447a121ddb3892da9e53d1ca5cca3106d58d65 \ + --hash=sha256:b46733c07dce03ae4e150330b975c75737fa60f0a7c591b6c8bf4928a28e2c92 # via sphinx babel==2.14.0 \ --hash=sha256:6919867db036398ba21eb5c7a0f6b28ab8cbc3ae7a73a44ebe34ae74a4e7d363 \ --hash=sha256:efb1a25b7118e67ce3a259bed20545c29cb68be8ad2c784c83689981b7a57287 # via sphinx -beautifulsoup4==4.12.2 \ - --hash=sha256:492bbc69dca35d12daac71c4db1bfff0c876c00ef4a2ffacce226d4638eb72da \ - --hash=sha256:bd2520ca0d9d7d12694a53d44ac482d181b4ec1888909b035a3dbf40d0f57d4a +beautifulsoup4==4.12.3 \ + --hash=sha256:74e3d1928edc070d21748185c46e3fb33490f22f52a3addee9aee0f4f7781051 \ + --hash=sha256:b80878c9f40111313e55da8ba20bdba06d8fa3969fc68304167741bbf9e082ed # via furo certifi==2023.11.17 \ --hash=sha256:9b469f3a900bf28dc19b8cfbf8019bf47f7fdd1a65a1d4ffb98fc14166beb4d1 \ @@ -124,9 +124,9 @@ docutils==0.20.1 \ # myst-parser # recommonmark # sphinx -furo==2023.8.19 \ - --hash=sha256:12f99f87a1873b6746228cfde18f77244e6c1ffb85d7fed95e638aae70d80590 \ - --hash=sha256:e671ee638ab3f1b472f4033b0167f502ab407830e0db0f843b1c1028119c9cd1 +furo==2023.9.10 \ + --hash=sha256:513092538537dc5c596691da06e3c370714ec99bc438680edc1debffb73e5bfc \ + --hash=sha256:5707530a476d2a63b8cad83b4f961f3739a69f4b058bcf38a03a39fa537195b2 # via -r requirements.txt idna==3.6 \ --hash=sha256:9ecdbbd083b06798ae1e86adcbfe8ab1479cf864e4ee30fe4e46a003d12491ca \ @@ -136,15 +136,15 @@ imagesize==1.4.1 \ --hash=sha256:0d8d18d08f840c19d0ee7ca1fd82490fdc3729b7ac93f49870406ddde8ef8d8b \ --hash=sha256:69150444affb9cb0d5cc5a92b3676f0b2fb7cd9ae39e947a5e11a36b4497cd4a # via sphinx -jinja2==3.1.2 \ - --hash=sha256:31351a702a408a9e7595a8fc6150fc3f43bb6bf7e319770cbc0db9df9437e852 \ - --hash=sha256:6088930bfe239f0e6710546ab9c19c9ef35e29792895fed6e6e31a023a182a61 +jinja2==3.1.3 \ + --hash=sha256:7d6d50dd97d52cbc355597bd845fabfbac3f551e1f99619e39a35ce8c370b5fa \ + --hash=sha256:ac8bd6544d4bb2c9792bf3a159e80bba8fda7f07e81bc3aed565432d5925ba90 # via # myst-parser # sphinx -markdown==3.5.1 \ - --hash=sha256:5874b47d4ee3f0b14d764324d2c94c03ea66bee56f2d929da9f2508d65e722dc \ - --hash=sha256:b65d7beb248dc22f2e8a31fb706d93798093c308dc1aba295aedeb9d41a813bd +markdown==3.5.2 \ + --hash=sha256:d43323865d89fc0cb9b20c75fc8ad313af307cc087e84b657d9eec768eddeadd \ + --hash=sha256:e1ac7b3dc550ee80e602e71c1d168002f062e49f1b11e26a36264dafd4df2ef8 # via sphinx-markdown-tables markdown-it-py==3.0.0 \ --hash=sha256:355216845c60bd96232cd8d8c40e8f9765cc86f46880e43a8fd22dc1a1a8cab1 \ @@ -152,67 +152,67 @@ markdown-it-py==3.0.0 \ # via # mdit-py-plugins # myst-parser -markupsafe==2.1.3 \ - --hash=sha256:05fb21170423db021895e1ea1e1f3ab3adb85d1c2333cbc2310f2a26bc77272e \ - --hash=sha256:0a4e4a1aff6c7ac4cd55792abf96c915634c2b97e3cc1c7129578aa68ebd754e \ - --hash=sha256:10bbfe99883db80bdbaff2dcf681dfc6533a614f700da1287707e8a5d78a8431 \ - --hash=sha256:134da1eca9ec0ae528110ccc9e48041e0828d79f24121a1a146161103c76e686 \ - --hash=sha256:14ff806850827afd6b07a5f32bd917fb7f45b046ba40c57abdb636674a8b559c \ - --hash=sha256:1577735524cdad32f9f694208aa75e422adba74f1baee7551620e43a3141f559 \ - --hash=sha256:1b40069d487e7edb2676d3fbdb2b0829ffa2cd63a2ec26c4938b2d34391b4ecc \ - --hash=sha256:1b8dd8c3fd14349433c79fa8abeb573a55fc0fdd769133baac1f5e07abf54aeb \ - --hash=sha256:1f67c7038d560d92149c060157d623c542173016c4babc0c1913cca0564b9939 \ - --hash=sha256:282c2cb35b5b673bbcadb33a585408104df04f14b2d9b01d4c345a3b92861c2c \ - --hash=sha256:2c1b19b3aaacc6e57b7e25710ff571c24d6c3613a45e905b1fde04d691b98ee0 \ - --hash=sha256:2ef12179d3a291be237280175b542c07a36e7f60718296278d8593d21ca937d4 \ - --hash=sha256:338ae27d6b8745585f87218a3f23f1512dbf52c26c28e322dbe54bcede54ccb9 \ - --hash=sha256:3c0fae6c3be832a0a0473ac912810b2877c8cb9d76ca48de1ed31e1c68386575 \ - --hash=sha256:3fd4abcb888d15a94f32b75d8fd18ee162ca0c064f35b11134be77050296d6ba \ - --hash=sha256:42de32b22b6b804f42c5d98be4f7e5e977ecdd9ee9b660fda1a3edf03b11792d \ - --hash=sha256:47d4f1c5f80fc62fdd7777d0d40a2e9dda0a05883ab11374334f6c4de38adffd \ - --hash=sha256:504b320cd4b7eff6f968eddf81127112db685e81f7e36e75f9f84f0df46041c3 \ - --hash=sha256:525808b8019e36eb524b8c68acdd63a37e75714eac50e988180b169d64480a00 \ - --hash=sha256:56d9f2ecac662ca1611d183feb03a3fa4406469dafe241673d521dd5ae92a155 \ - --hash=sha256:5bbe06f8eeafd38e5d0a4894ffec89378b6c6a625ff57e3028921f8ff59318ac \ - --hash=sha256:65c1a9bcdadc6c28eecee2c119465aebff8f7a584dd719facdd9e825ec61ab52 \ - --hash=sha256:68e78619a61ecf91e76aa3e6e8e33fc4894a2bebe93410754bd28fce0a8a4f9f \ - --hash=sha256:69c0f17e9f5a7afdf2cc9fb2d1ce6aabdb3bafb7f38017c0b77862bcec2bbad8 \ - --hash=sha256:6b2b56950d93e41f33b4223ead100ea0fe11f8e6ee5f641eb753ce4b77a7042b \ - --hash=sha256:715d3562f79d540f251b99ebd6d8baa547118974341db04f5ad06d5ea3eb8007 \ - --hash=sha256:787003c0ddb00500e49a10f2844fac87aa6ce977b90b0feaaf9de23c22508b24 \ - --hash=sha256:7ef3cb2ebbf91e330e3bb937efada0edd9003683db6b57bb108c4001f37a02ea \ - --hash=sha256:8023faf4e01efadfa183e863fefde0046de576c6f14659e8782065bcece22198 \ - --hash=sha256:8758846a7e80910096950b67071243da3e5a20ed2546e6392603c096778d48e0 \ - --hash=sha256:8afafd99945ead6e075b973fefa56379c5b5c53fd8937dad92c662da5d8fd5ee \ - --hash=sha256:8c41976a29d078bb235fea9b2ecd3da465df42a562910f9022f1a03107bd02be \ - --hash=sha256:8e254ae696c88d98da6555f5ace2279cf7cd5b3f52be2b5cf97feafe883b58d2 \ - --hash=sha256:8f9293864fe09b8149f0cc42ce56e3f0e54de883a9de90cd427f191c346eb2e1 \ - --hash=sha256:9402b03f1a1b4dc4c19845e5c749e3ab82d5078d16a2a4c2cd2df62d57bb0707 \ - --hash=sha256:962f82a3086483f5e5f64dbad880d31038b698494799b097bc59c2edf392fce6 \ - --hash=sha256:9aad3c1755095ce347e26488214ef77e0485a3c34a50c5a5e2471dff60b9dd9c \ - --hash=sha256:9dcdfd0eaf283af041973bff14a2e143b8bd64e069f4c383416ecd79a81aab58 \ - --hash=sha256:aa57bd9cf8ae831a362185ee444e15a93ecb2e344c8e52e4d721ea3ab6ef1823 \ - --hash=sha256:aa7bd130efab1c280bed0f45501b7c8795f9fdbeb02e965371bbef3523627779 \ - --hash=sha256:ab4a0df41e7c16a1392727727e7998a467472d0ad65f3ad5e6e765015df08636 \ - --hash=sha256:ad9e82fb8f09ade1c3e1b996a6337afac2b8b9e365f926f5a61aacc71adc5b3c \ - --hash=sha256:af598ed32d6ae86f1b747b82783958b1a4ab8f617b06fe68795c7f026abbdcad \ - --hash=sha256:b076b6226fb84157e3f7c971a47ff3a679d837cf338547532ab866c57930dbee \ - --hash=sha256:b7ff0f54cb4ff66dd38bebd335a38e2c22c41a8ee45aa608efc890ac3e3931bc \ - --hash=sha256:bfce63a9e7834b12b87c64d6b155fdd9b3b96191b6bd334bf37db7ff1fe457f2 \ - --hash=sha256:c011a4149cfbcf9f03994ec2edffcb8b1dc2d2aede7ca243746df97a5d41ce48 \ - --hash=sha256:c9c804664ebe8f83a211cace637506669e7890fec1b4195b505c214e50dd4eb7 \ - --hash=sha256:ca379055a47383d02a5400cb0d110cef0a776fc644cda797db0c5696cfd7e18e \ - --hash=sha256:cb0932dc158471523c9637e807d9bfb93e06a95cbf010f1a38b98623b929ef2b \ - --hash=sha256:cd0f502fe016460680cd20aaa5a76d241d6f35a1c3350c474bac1273803893fa \ - --hash=sha256:ceb01949af7121f9fc39f7d27f91be8546f3fb112c608bc4029aef0bab86a2a5 \ - --hash=sha256:d080e0a5eb2529460b30190fcfcc4199bd7f827663f858a226a81bc27beaa97e \ - --hash=sha256:dd15ff04ffd7e05ffcb7fe79f1b98041b8ea30ae9234aed2a9168b5797c3effb \ - --hash=sha256:df0be2b576a7abbf737b1575f048c23fb1d769f267ec4358296f31c2479db8f9 \ - --hash=sha256:e09031c87a1e51556fdcb46e5bd4f59dfb743061cf93c4d6831bf894f125eb57 \ - --hash=sha256:e4dd52d80b8c83fdce44e12478ad2e85c64ea965e75d66dbeafb0a3e77308fcc \ - --hash=sha256:f698de3fd0c4e6972b92290a45bd9b1536bffe8c6759c62471efaa8acb4c37bc \ - --hash=sha256:fec21693218efe39aa7f8599346e90c705afa52c5b31ae019b2e57e8f6542bb2 \ - --hash=sha256:ffcc3f7c66b5f5b7931a5aa68fc9cecc51e685ef90282f4a82f0f5e9b704ad11 +markupsafe==2.1.4 \ + --hash=sha256:0042d6a9880b38e1dd9ff83146cc3c9c18a059b9360ceae207805567aacccc69 \ + --hash=sha256:0c26f67b3fe27302d3a412b85ef696792c4a2386293c53ba683a89562f9399b0 \ + --hash=sha256:0fbad3d346df8f9d72622ac71b69565e621ada2ce6572f37c2eae8dacd60385d \ + --hash=sha256:15866d7f2dc60cfdde12ebb4e75e41be862348b4728300c36cdf405e258415ec \ + --hash=sha256:1c98c33ffe20e9a489145d97070a435ea0679fddaabcafe19982fe9c971987d5 \ + --hash=sha256:21e7af8091007bf4bebf4521184f4880a6acab8df0df52ef9e513d8e5db23411 \ + --hash=sha256:23984d1bdae01bee794267424af55eef4dfc038dc5d1272860669b2aa025c9e3 \ + --hash=sha256:31f57d64c336b8ccb1966d156932f3daa4fee74176b0fdc48ef580be774aae74 \ + --hash=sha256:3583a3a3ab7958e354dc1d25be74aee6228938312ee875a22330c4dc2e41beb0 \ + --hash=sha256:36d7626a8cca4d34216875aee5a1d3d654bb3dac201c1c003d182283e3205949 \ + --hash=sha256:396549cea79e8ca4ba65525470d534e8a41070e6b3500ce2414921099cb73e8d \ + --hash=sha256:3a66c36a3864df95e4f62f9167c734b3b1192cb0851b43d7cc08040c074c6279 \ + --hash=sha256:3aae9af4cac263007fd6309c64c6ab4506dd2b79382d9d19a1994f9240b8db4f \ + --hash=sha256:3ab3a886a237f6e9c9f4f7d272067e712cdb4efa774bef494dccad08f39d8ae6 \ + --hash=sha256:47bb5f0142b8b64ed1399b6b60f700a580335c8e1c57f2f15587bd072012decc \ + --hash=sha256:49a3b78a5af63ec10d8604180380c13dcd870aba7928c1fe04e881d5c792dc4e \ + --hash=sha256:4df98d4a9cd6a88d6a585852f56f2155c9cdb6aec78361a19f938810aa020954 \ + --hash=sha256:5045e892cfdaecc5b4c01822f353cf2c8feb88a6ec1c0adef2a2e705eef0f656 \ + --hash=sha256:5244324676254697fe5c181fc762284e2c5fceeb1c4e3e7f6aca2b6f107e60dc \ + --hash=sha256:54635102ba3cf5da26eb6f96c4b8c53af8a9c0d97b64bdcb592596a6255d8518 \ + --hash=sha256:54a7e1380dfece8847c71bf7e33da5d084e9b889c75eca19100ef98027bd9f56 \ + --hash=sha256:55d03fea4c4e9fd0ad75dc2e7e2b6757b80c152c032ea1d1de487461d8140efc \ + --hash=sha256:698e84142f3f884114ea8cf83e7a67ca8f4ace8454e78fe960646c6c91c63bfa \ + --hash=sha256:6aa5e2e7fc9bc042ae82d8b79d795b9a62bd8f15ba1e7594e3db243f158b5565 \ + --hash=sha256:7653fa39578957bc42e5ebc15cf4361d9e0ee4b702d7d5ec96cdac860953c5b4 \ + --hash=sha256:765f036a3d00395a326df2835d8f86b637dbaf9832f90f5d196c3b8a7a5080cb \ + --hash=sha256:78bc995e004681246e85e28e068111a4c3f35f34e6c62da1471e844ee1446250 \ + --hash=sha256:7a07f40ef8f0fbc5ef1000d0c78771f4d5ca03b4953fc162749772916b298fc4 \ + --hash=sha256:8b570a1537367b52396e53325769608f2a687ec9a4363647af1cded8928af959 \ + --hash=sha256:987d13fe1d23e12a66ca2073b8d2e2a75cec2ecb8eab43ff5624ba0ad42764bc \ + --hash=sha256:9896fca4a8eb246defc8b2a7ac77ef7553b638e04fbf170bff78a40fa8a91474 \ + --hash=sha256:9e9e3c4020aa2dc62d5dd6743a69e399ce3de58320522948af6140ac959ab863 \ + --hash=sha256:a0b838c37ba596fcbfca71651a104a611543077156cb0a26fe0c475e1f152ee8 \ + --hash=sha256:a4d176cfdfde84f732c4a53109b293d05883e952bbba68b857ae446fa3119b4f \ + --hash=sha256:a76055d5cb1c23485d7ddae533229039b850db711c554a12ea64a0fd8a0129e2 \ + --hash=sha256:a76cd37d229fc385738bd1ce4cba2a121cf26b53864c1772694ad0ad348e509e \ + --hash=sha256:a7cc49ef48a3c7a0005a949f3c04f8baa5409d3f663a1b36f0eba9bfe2a0396e \ + --hash=sha256:abf5ebbec056817057bfafc0445916bb688a255a5146f900445d081db08cbabb \ + --hash=sha256:b0fe73bac2fed83839dbdbe6da84ae2a31c11cfc1c777a40dbd8ac8a6ed1560f \ + --hash=sha256:b6f14a9cd50c3cb100eb94b3273131c80d102e19bb20253ac7bd7336118a673a \ + --hash=sha256:b83041cda633871572f0d3c41dddd5582ad7d22f65a72eacd8d3d6d00291df26 \ + --hash=sha256:b835aba863195269ea358cecc21b400276747cc977492319fd7682b8cd2c253d \ + --hash=sha256:bf1196dcc239e608605b716e7b166eb5faf4bc192f8a44b81e85251e62584bd2 \ + --hash=sha256:c669391319973e49a7c6230c218a1e3044710bc1ce4c8e6eb71f7e6d43a2c131 \ + --hash=sha256:c7556bafeaa0a50e2fe7dc86e0382dea349ebcad8f010d5a7dc6ba568eaaa789 \ + --hash=sha256:c8f253a84dbd2c63c19590fa86a032ef3d8cc18923b8049d91bcdeeb2581fbf6 \ + --hash=sha256:d18b66fe626ac412d96c2ab536306c736c66cf2a31c243a45025156cc190dc8a \ + --hash=sha256:d5291d98cd3ad9a562883468c690a2a238c4a6388ab3bd155b0c75dd55ece858 \ + --hash=sha256:d5c31fe855c77cad679b302aabc42d724ed87c043b1432d457f4976add1c2c3e \ + --hash=sha256:d6e427c7378c7f1b2bef6a344c925b8b63623d3321c09a237b7cc0e77dd98ceb \ + --hash=sha256:dac1ebf6983148b45b5fa48593950f90ed6d1d26300604f321c74a9ca1609f8e \ + --hash=sha256:de8153a7aae3835484ac168a9a9bdaa0c5eee4e0bc595503c95d53b942879c84 \ + --hash=sha256:e1a0d1924a5013d4f294087e00024ad25668234569289650929ab871231668e7 \ + --hash=sha256:e7902211afd0af05fbadcc9a312e4cf10f27b779cf1323e78d52377ae4b72bea \ + --hash=sha256:e888ff76ceb39601c59e219f281466c6d7e66bd375b4ec1ce83bcdc68306796b \ + --hash=sha256:f06e5a9e99b7df44640767842f414ed5d7bedaaa78cd817ce04bbd6fd86e2dd6 \ + --hash=sha256:f6be2d708a9d0e9b0054856f07ac7070fbe1754be40ca8525d5adccdbda8f475 \ + --hash=sha256:f9917691f410a2e0897d1ef99619fd3f7dd503647c8ff2475bf90c3cf222ad74 \ + --hash=sha256:fc1a75aa8f11b87910ffd98de62b29d6520b6d6e8a3de69a70ca34dea85d2a8a \ + --hash=sha256:fe8512ed897d5daf089e5bd010c3dc03bb1bdae00b35588c49b98268d4a01e00 # via jinja2 mdit-py-plugins==0.4.0 \ --hash=sha256:b51b3bb70691f57f974e257e367107857a93b36f322a9e6d44ca5bf28ec2def9 \ @@ -304,9 +304,9 @@ soupsieve==2.5 \ --hash=sha256:5663d5a7b3bfaeee0bc4372e7fc48f9cff4940b3eec54a6451cc5299f1097690 \ --hash=sha256:eaa337ff55a1579b6549dc679565eac1e3d000563bcb1c8ab0d0fefbc0c2cdc7 # via beautifulsoup4 -sphinx==7.1.2 \ - --hash=sha256:780f4d32f1d7d1126576e0e5ecc19dc32ab76cd24e950228dcf7b1f6d3d9e22f \ - --hash=sha256:d170a81825b2fcacb6dfd5a0d7f578a053e45d3f2b153fecc948c37344eb4cbe +sphinx==7.2.6 \ + --hash=sha256:1e09160a40b956dc623c910118fa636da93bd3ca0b9876a7b3df90f07d691560 \ + --hash=sha256:9a5160e1ea90688d5963ba09a2dcd8bdd526620edbb65c328728f1b2228d5ab5 # via # -r requirements.txt # furo @@ -334,31 +334,31 @@ sphinx-markdown-tables==0.0.17 \ --hash=sha256:2bd0c30779653e4dd120300cbd9ca412c480738cc2241f6dea477a883f299e04 \ --hash=sha256:6bc6d3d400eaccfeebd288446bc08dd83083367c58b85d40fe6c12d77ef592f1 # via -r requirements.txt -sphinxcontrib-applehelp==1.0.4 \ - --hash=sha256:29d341f67fb0f6f586b23ad80e072c8e6ad0b48417db2bde114a4c9746feb228 \ - --hash=sha256:828f867945bbe39817c210a1abfd1bc4895c8b73fcaade56d45357a348a07d7e +sphinxcontrib-applehelp==1.0.8 \ + --hash=sha256:c40a4f96f3776c4393d933412053962fac2b84f4c99a7982ba42e09576a70619 \ + --hash=sha256:cb61eb0ec1b61f349e5cc36b2028e9e7ca765be05e49641c97241274753067b4 # via # -r requirements.txt # sphinx -sphinxcontrib-devhelp==1.0.5 \ - --hash=sha256:63b41e0d38207ca40ebbeabcf4d8e51f76c03e78cd61abe118cf4435c73d4212 \ - --hash=sha256:fe8009aed765188f08fcaadbb3ea0d90ce8ae2d76710b7e29ea7d047177dae2f +sphinxcontrib-devhelp==1.0.6 \ + --hash=sha256:6485d09629944511c893fa11355bda18b742b83a2b181f9a009f7e500595c90f \ + --hash=sha256:9893fd3f90506bc4b97bdb977ceb8fbd823989f4316b28c3841ec128544372d3 # via sphinx -sphinxcontrib-htmlhelp==2.0.4 \ - --hash=sha256:6c26a118a05b76000738429b724a0568dbde5b72391a688577da08f11891092a \ - --hash=sha256:8001661c077a73c29beaf4a79968d0726103c5605e27db92b9ebed8bab1359e9 +sphinxcontrib-htmlhelp==2.0.5 \ + --hash=sha256:0dc87637d5de53dd5eec3a6a01753b1ccf99494bd756aafecd74b4fa9e729015 \ + --hash=sha256:393f04f112b4d2f53d93448d4bce35842f62b307ccdc549ec1585e950bc35e04 # via sphinx sphinxcontrib-jsmath==1.0.1 \ --hash=sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178 \ --hash=sha256:a9925e4a4587247ed2191a22df5f6970656cb8ca2bd6284309578f2153e0c4b8 # via sphinx -sphinxcontrib-qthelp==1.0.6 \ - --hash=sha256:62b9d1a186ab7f5ee3356d906f648cacb7a6bdb94d201ee7adf26db55092982d \ - --hash=sha256:bf76886ee7470b934e363da7a954ea2825650013d367728588732c7350f49ea4 +sphinxcontrib-qthelp==1.0.7 \ + --hash=sha256:053dedc38823a80a7209a80860b16b722e9e0209e32fea98c90e4e6624588ed6 \ + --hash=sha256:e2ae3b5c492d58fcbd73281fbd27e34b8393ec34a073c792642cd8e529288182 # via sphinx -sphinxcontrib-serializinghtml==1.1.9 \ - --hash=sha256:0c64ff898339e1fac29abd2bf5f11078f3ec413cfe9c046d3120d7ca65530b54 \ - --hash=sha256:9b36e503703ff04f20e9675771df105e58aa029cfcbc23b8ed716019b7416ae1 +sphinxcontrib-serializinghtml==1.1.10 \ + --hash=sha256:326369b8df80a7d2d8d7f99aa5ac577f51ea51556ed974e7716cfd4fca3f6cb7 \ + --hash=sha256:93f3f5dc458b91b192fe10c397e324f262cf163d79f3282c158e8436a2c4511f # via sphinx urllib3==2.1.0 \ --hash=sha256:55901e917a5896a349ff771be919f8bd99aff50b79fe58fec595eb37bbc56bb3 \ diff --git a/llvm/docs/requirements.txt b/llvm/docs/requirements.txt index d66569c1b3e79..697ce2e3adb6d 100644 --- a/llvm/docs/requirements.txt +++ b/llvm/docs/requirements.txt @@ -1,9 +1,9 @@ -sphinx==7.1.2 +sphinx==7.2.6 docutils==0.20.1 sphinx-markdown-tables==0.0.17 recommonmark==0.7.1 sphinx-automodapi==0.16.0 sphinx-bootstrap-theme==0.8.1 -sphinxcontrib-applehelp==1.0.4 -furo==2023.8.19 +sphinxcontrib-applehelp==1.0.8 +furo==2023.9.10 myst-parser==2.0.0 diff --git a/llvm/lib/SYCLLowerIR/CompileTimePropertiesPass.cpp b/llvm/lib/SYCLLowerIR/CompileTimePropertiesPass.cpp index da14bc2772c61..32a476a8ac893 100644 --- a/llvm/lib/SYCLLowerIR/CompileTimePropertiesPass.cpp +++ b/llvm/lib/SYCLLowerIR/CompileTimePropertiesPass.cpp @@ -444,8 +444,10 @@ attributeToExecModeMetadata(const Attribute &Attr, Function &F) { // TODO: Remove SYCL_REGISTER_ALLOC_MODE_ATTR support in next ABI break. uint32_t PropVal = getAttributeAsInteger(Attr); if (AttrKindStr == SYCL_GRF_SIZE_ATTR) { - assert((PropVal == 0 || PropVal == 128 || PropVal == 256) && - "Unsupported GRF Size"); + // The RegisterAllocMode metadata supports only 0, 128, and 256 for + // PropVal. + if (PropVal != 0 && PropVal != 128 && PropVal != 256) + return std::nullopt; // Map sycl-grf-size values to RegisterAllocMode values used in SPIR-V. static constexpr int SMALL_GRF_REGALLOCMODE_VAL = 1; static constexpr int LARGE_GRF_REGALLOCMODE_VAL = 2; diff --git a/llvm/test/SYCLLowerIR/CompileTimePropertiesPass/sycl-grf-mode.ll b/llvm/test/SYCLLowerIR/CompileTimePropertiesPass/sycl-grf-mode.ll new file mode 100644 index 0000000000000..a5d491bb54db0 --- /dev/null +++ b/llvm/test/SYCLLowerIR/CompileTimePropertiesPass/sycl-grf-mode.ll @@ -0,0 +1,10 @@ +; Check we don't assert for different GRF values and don't add the RegisterAllocMode metadata +; RUN: opt -passes=compile-time-properties %s -S | FileCheck %s --implicit-check-not=RegisterAllocMode + +; CHECK: spir_kernel void @foo() +define weak_odr dso_local spir_kernel void @foo() #0 { +entry: + ret void +} + +attributes #0 = { convergent mustprogress norecurse nounwind "frame-pointer"="all" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "sycl-grf-size"="16384" "sycl-module-id"="main.cpp" "sycl-optlevel"="2" "uniform-work-group-size"="true" } diff --git a/sycl-fusion/common/include/DynArray.h b/sycl-fusion/common/include/DynArray.h index d69e0cea26eae..818a2b5e10c4f 100644 --- a/sycl-fusion/common/include/DynArray.h +++ b/sycl-fusion/common/include/DynArray.h @@ -97,7 +97,7 @@ template class DynArray { /// String-like class that owns its character storage. class DynString { public: - explicit DynString(const char *Str) : Chars{std::strlen(Str) + 1} { + explicit DynString(const char *Str = "") : Chars{std::strlen(Str) + 1} { std::copy(Str, Str + Chars.size(), Chars.begin()); } diff --git a/sycl-fusion/common/include/Kernel.h b/sycl-fusion/common/include/Kernel.h index 9db4138e28def..c889552bf6e07 100644 --- a/sycl-fusion/common/include/Kernel.h +++ b/sycl-fusion/common/include/Kernel.h @@ -12,12 +12,11 @@ #include "DynArray.h" #include -#include #include #include #include -#include -#include +#include +#include namespace jit_compiler { @@ -131,7 +130,7 @@ using ArgUsageUT = std::underlying_type_t; /// /// Describe the list of arguments by their kind and usage. struct SYCLArgumentDescriptor { - explicit SYCLArgumentDescriptor(size_t NumArgs) + explicit SYCLArgumentDescriptor(size_t NumArgs = 0) : Kinds(NumArgs), UsageMask(NumArgs){}; DynArray Kinds; @@ -339,6 +338,8 @@ struct SYCLKernelInfo { SYCLKernelBinaryInfo BinaryInfo; + SYCLKernelInfo() = default; + SYCLKernelInfo(const char *KernelName, const SYCLArgumentDescriptor &ArgDesc, const NDRange &NDR, const SYCLKernelBinaryInfo &BinInfo) : Name{KernelName}, Args{ArgDesc}, Attributes{}, NDR{NDR}, @@ -348,33 +349,6 @@ struct SYCLKernelInfo { : Name{KernelName}, Args{NumArgs}, Attributes{}, NDR{}, BinaryInfo{} {} }; -/// -/// Represents a SPIR-V translation unit containing SYCL kernels by the -/// KernelInfo for each of the contained kernels. -class SYCLModuleInfo { -public: - using KernelInfoList = std::vector; - - void addKernel(SYCLKernelInfo &Kernel) { Kernels.push_back(Kernel); } - - KernelInfoList &kernels() { return Kernels; } - - bool hasKernelFor(const std::string &KernelName) { - return getKernelFor(KernelName) != nullptr; - } - - SYCLKernelInfo *getKernelFor(const std::string &KernelName) { - auto It = - std::find_if(Kernels.begin(), Kernels.end(), [&](SYCLKernelInfo &K) { - return K.Name == KernelName.c_str(); - }); - return (It != Kernels.end()) ? &*It : nullptr; - } - -private: - KernelInfoList Kernels; -}; - } // namespace jit_compiler #endif // SYCL_FUSION_COMMON_KERNEL_H diff --git a/sycl-fusion/common/include/View.h b/sycl-fusion/common/include/View.h new file mode 100644 index 0000000000000..f9592e06d7749 --- /dev/null +++ b/sycl-fusion/common/include/View.h @@ -0,0 +1,45 @@ +//==------------- View.h - Non-owning view to contiguous memory ------------==// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// + +#ifndef SYCL_FUSION_COMMON_VIEW_H +#define SYCL_FUSION_COMMON_VIEW_H + +#include +#include + +namespace jit_compiler { + +/// Read-only, non-owning view of a linear sequence of \p T. +template class View { +public: + constexpr View(const T *Ptr, size_t Size) : Ptr(Ptr), Size(Size) {} + + template