diff --git a/.github/actions/do_build_opencl_cts/action.yml b/.github/actions/do_build_opencl_cts/action.yml index bae51173d..a82cf72bb 100644 --- a/.github/actions/do_build_opencl_cts/action.yml +++ b/.github/actions/do_build_opencl_cts/action.yml @@ -35,7 +35,37 @@ runs: repository: KhronosGroup/OpenCL-CTS path: OpenCL-CTS - - name: build opencl cts + - name: build opencl cts x86_64 + if: ARCH == x86_64 + shell: bash + env: + # TODO: host-x86_64-linux 'toolchain' - expand for other targets + CMAKE_TOOLCHAIN: "-DCMAKE_C_COMPILER=gcc -DCMAKE_C_FLAGS=-m64 -DCMAKE_CXX_COMPILER=g++ \ + -DCMAKE_CXX_FLAGS=-m64 -DPKG_CONFIG_EXECUTABLE=pkg-config" + run: | + # get spirv-as + sudo apt-get update + sudo apt-get install -y spirv-tools + # apply patches + pushd OpenCL-CTS + git log -1 + git apply $GITHUB_WORKSPACE/.github/patches/OpenCL-CTS-0001-Patch-sub-group-testing.patch + git apply $GITHUB_WORKSPACE/.github/patches/OpenCL-CTS-0002-Permit-building-for-unknown-architectures.patch + popd + # do build + set -x + cmake -G Ninja $CMAKE_TOOLCHAIN $GITHUB_WORKSPACE/OpenCL-CTS \ + -DCMAKE_BUILD_TYPE=Release \ + -DOPENCL_LIBRARIES=OpenCL \ + -DCL_INCLUDE_DIR=$GITHUB_WORKSPACE/install_headers/include \ + -DCL_LIB_DIR=$GITHUB_WORKSPACE/install_icd/lib + ninja -v + python3 $GITHUB_WORKSPACE/OpenCL-CTS/test_conformance/spirv_new/assemble_spirv.py -v \ + --source-dir $GITHUB_WORKSPACE/OpenCL-CTS/test_conformance/spirv_new/spirv_asm \ + --output-dir $GITHUB_WORKSPACE/test_conformance/spirv_bin + + - name: build opencl cts aarch64 + if: ARCH == aarch64 shell: bash env: # TODO: host-x86_64-linux 'toolchain' - expand for other targets diff --git a/.github/actions/run_opencl_cts/action.yml b/.github/actions/run_opencl_cts/action.yml index 975a67586..ebf04bd9b 100644 --- a/.github/actions/run_opencl_cts/action.yml +++ b/.github/actions/run_opencl_cts/action.yml @@ -19,7 +19,30 @@ runs: name: ock_${{inputs.target}} path: install_ock - - name: Run opencl cts + - name: Run opencl cts x86_64 + if: ARCH == x86_64 + shell: bash + env: + CTS_CSV_FILE: opencl_conformance_tests_${{inputs.test_type}}.csv + # TODO: host-x86_64-linux filter - expand for other targets + CTS_FILTER: cts-3.0-online-ignore-linux-host.csv + CTS_TIMEOUT: 18:00:00 # OK for github? + run: | + cd "$GITHUB_WORKSPACE/OpenCL-CTS" + echo "Running OpenCL CTS tests with CTS file $CTS_CSV_FILE with filter $CTS_FILTER" + set -x + python -u "$GITHUB_WORKSPACE/scripts/testing/run_cities.py" -v \ + --color=always --timeout $CTS_TIMEOUT \ + -b "$GITHUB_WORKSPACE/test_conformance" \ + -L "$GITHUB_WORKSPACE/install_icd/lib" \ + -e "CLC_EXECUTABLE=$GITHUB_WORKSPACE/install_ock/bin/clc" \ + -e "OCL_ICD_FILENAMES=$GITHUB_WORKSPACE/install_ock/lib/libCL.so" \ + -e "CL_PLATFORM_INDEX=0" \ + -s "$GITHUB_WORKSPACE/test_conformance/$CTS_CSV_FILE" \ + -i "$GITHUB_WORKSPACE/source/cl/scripts/$CTS_FILTER" + + - name: Run opencl cts aarch64 + if: ARCH == aarch64 shell: bash env: CTS_CSV_FILE: opencl_conformance_tests_${{inputs.test_type}}.csv diff --git a/.github/workflows/planned_testing.yml b/.github/workflows/planned_testing.yml index 07ad9348e..1e3480ec5 100644 --- a/.github/workflows/planned_testing.yml +++ b/.github/workflows/planned_testing.yml @@ -124,7 +124,7 @@ jobs: strategy: matrix: target: ${{ fromJson(inputs.target_list) }} - exclude: ${{ fromJson(needs.workflow_vars.outputs.matrix_only_linux_x86_64) }} + exclude: ${{ fromJson(needs.workflow_vars.outputs.matrix_only_linux_x86_64_aarch64) }} # TODO: host-x86_64-linux only - expand for other targets runs-on: ubuntu-22.04