Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 84 additions & 0 deletions .github/workflows/conformance-hip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,8 @@ jobs:
-DOPENVX_INCLUDES="$GITHUB_WORKSPACE/amd_openvx/openvx/include" \
-DOPENVX_LIBRARIES="$GITHUB_WORKSPACE/install/lib/libopenvx.so;$GITHUB_WORKSPACE/install/lib/libvxu.so;pthread;dl;m;rt" \
-DOPENVX_CONFORMANCE_VISION=ON \
-DOPENVX_USE_PIPELINING=ON \
-DOPENVX_USE_STREAMING=ON \
-DCMAKE_C_STANDARD_LIBRARIES="-L${ROCM_PATH}/lib -lamdhip64" \
-DCMAKE_CXX_STANDARD_LIBRARIES="-L${ROCM_PATH}/lib -lamdhip64" \
-DCMAKE_EXE_LINKER_FLAGS="-Wl,-rpath-link,${ROCM_PATH}/lib"
Expand Down Expand Up @@ -1031,6 +1033,88 @@ jobs:
path: profraw/
if-no-files-found: ignore

pipelining-hip:
name: KHR EXT - Pipelining (HIP)
runs-on:
group: linux-shark39-runner-group
container:
image: mivisionx/ubuntu-24.04:rocm-20260710
options: --device /dev/kfd --device /dev/dri
needs: build-hip-debug
steps:
- name: Download debug build artifacts
uses: actions/download-artifact@v4
with:
name: build-artifacts-hip-debug
- name: Validate ROCm
run: |
rocminfo
amd-smi || true
- name: Run pipelining tests
run: |
mkdir -p profraw
chmod +x OpenVX-cts/build/bin/vx_test_conformance
cd OpenVX-cts/build
export LD_LIBRARY_PATH=$GITHUB_WORKSPACE/install/lib:${ROCM_PATH}/lib:$GITHUB_WORKSPACE/OpenVX-cts/build/lib
export VX_TEST_DATA_PATH=$GITHUB_WORKSPACE/OpenVX-cts/test_data/
export HIP_VISIBLE_DEVICES=0 # ROCR_VISIBLE_DEVICES already pins the assigned GPU; the runner also sets HIP_VISIBLE_DEVICES to the same host index, which stacks and yields hipErrorNoDevice on index-1 GPUs. After ROCR filtering the device is index 0 for HIP.
export AGO_LOG_STDERR=1
export LLVM_PROFILE_FILE=$GITHUB_WORKSPACE/profraw/pipelining_%p.profraw
for target in CPU GPU; do
echo "::group::pipelining (AGO_DEFAULT_TARGET=$target)"
AGO_DEFAULT_TARGET=$target timeout 1800 ./bin/vx_test_conformance --filter="GraphPipeline.*"
echo "::endgroup::"
done
- name: Upload profraw
if: always()
continue-on-error: true
uses: actions/upload-artifact@v4
with:
name: profraw-hip-pipelining
path: profraw/
if-no-files-found: ignore

streaming-hip:
name: KHR EXT - Streaming (HIP)
runs-on:
group: linux-shark39-runner-group
container:
image: mivisionx/ubuntu-24.04:rocm-20260710
options: --device /dev/kfd --device /dev/dri
needs: build-hip-debug
steps:
- name: Download debug build artifacts
uses: actions/download-artifact@v4
with:
name: build-artifacts-hip-debug
- name: Validate ROCm
run: |
rocminfo
amd-smi || true
- name: Run streaming tests
run: |
mkdir -p profraw
chmod +x OpenVX-cts/build/bin/vx_test_conformance
cd OpenVX-cts/build
export LD_LIBRARY_PATH=$GITHUB_WORKSPACE/install/lib:${ROCM_PATH}/lib:$GITHUB_WORKSPACE/OpenVX-cts/build/lib
export VX_TEST_DATA_PATH=$GITHUB_WORKSPACE/OpenVX-cts/test_data/
export HIP_VISIBLE_DEVICES=0 # ROCR_VISIBLE_DEVICES already pins the assigned GPU; the runner also sets HIP_VISIBLE_DEVICES to the same host index, which stacks and yields hipErrorNoDevice on index-1 GPUs. After ROCR filtering the device is index 0 for HIP.
export AGO_LOG_STDERR=1
export LLVM_PROFILE_FILE=$GITHUB_WORKSPACE/profraw/streaming_%p.profraw
for target in CPU GPU; do
echo "::group::streaming (AGO_DEFAULT_TARGET=$target)"
AGO_DEFAULT_TARGET=$target timeout 900 ./bin/vx_test_conformance --filter="GraphStreaming.*"
echo "::endgroup::"
done
- name: Upload profraw
if: always()
continue-on-error: true
uses: actions/upload-artifact@v4
with:
name: profraw-hip-streaming
path: profraw/
if-no-files-found: ignore

# --- Local Tests (API + GDF) ---

api-tests-hip:
Expand Down
58 changes: 57 additions & 1 deletion .github/workflows/conformance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,9 @@ jobs:
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
-DOPENVX_INCLUDES="${{ github.workspace }}/amd_openvx/openvx/include" \
-DOPENVX_LIBRARIES="${INSTALL_PREFIX}/lib/libopenvx.so;${INSTALL_PREFIX}/lib/libvxu.so;pthread;dl;m;rt" \
-DOPENVX_CONFORMANCE_VISION=ON
-DOPENVX_CONFORMANCE_VISION=ON \
-DOPENVX_USE_PIPELINING=ON \
-DOPENVX_USE_STREAMING=ON
make -j$(nproc)

- name: Upload debug build artifacts
Expand Down Expand Up @@ -637,6 +639,60 @@ jobs:
path: profraw/
if-no-files-found: ignore

pipelining-cpu:
name: KHR EXT - Pipelining (CPU)
runs-on: ubuntu-24.04
needs: build-debug
steps:
- uses: actions/checkout@v4
- name: Download debug build artifacts
uses: actions/download-artifact@v4
with:
name: build-artifacts-debug
- name: Run pipelining tests
run: |
mkdir -p profraw
chmod +x OpenVX-cts/build/bin/vx_test_conformance
cd OpenVX-cts/build
export LD_LIBRARY_PATH=${{ github.workspace }}/install/lib:${{ github.workspace }}/OpenVX-cts/build/lib
export VX_TEST_DATA_PATH=${{ github.workspace }}/OpenVX-cts/test_data/
export LLVM_PROFILE_FILE=${{ github.workspace }}/profraw/pipelining_%p.profraw
timeout 1800 ./bin/vx_test_conformance --filter="GraphPipeline.*"
- name: Upload profraw
if: always()
uses: actions/upload-artifact@v4
with:
name: profraw-pipelining
path: profraw/
if-no-files-found: ignore

streaming-cpu:
name: KHR EXT - Streaming (CPU)
runs-on: ubuntu-24.04
needs: build-debug
steps:
- uses: actions/checkout@v4
- name: Download debug build artifacts
uses: actions/download-artifact@v4
with:
name: build-artifacts-debug
- name: Run streaming tests
run: |
mkdir -p profraw
chmod +x OpenVX-cts/build/bin/vx_test_conformance
cd OpenVX-cts/build
export LD_LIBRARY_PATH=${{ github.workspace }}/install/lib:${{ github.workspace }}/OpenVX-cts/build/lib
export VX_TEST_DATA_PATH=${{ github.workspace }}/OpenVX-cts/test_data/
export LLVM_PROFILE_FILE=${{ github.workspace }}/profraw/streaming_%p.profraw
timeout 900 ./bin/vx_test_conformance --filter="GraphStreaming.*"
- name: Upload profraw
if: always()
uses: actions/upload-artifact@v4
with:
name: profraw-streaming
path: profraw/
if-no-files-found: ignore

# --- Local Tests (API + GDF) ---

api-tests:
Expand Down
9 changes: 9 additions & 0 deletions amd_openvx/openvx/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,13 @@ set(VERSION "1.3.2")

project(openvx VERSION ${VERSION} LANGUAGES CXX)

option(OPENVX_USE_PIPELINING "Enable OpenVX Graph Pipelining/Streaming/Event extension (vx_khr_pipelining)" ON)
if(OPENVX_USE_PIPELINING)
add_definitions(-DOPENVX_USE_PIPELINING=1)
else()
add_definitions(-DOPENVX_USE_PIPELINING=0)
endif()

include_directories(include ago api)

list(APPEND SOURCES
Expand Down Expand Up @@ -63,13 +70,15 @@ list(APPEND SOURCES
ago/ago_interface.cpp
ago/ago_kernel_api.cpp
ago/ago_kernel_list.cpp
ago/ago_pipelining.cpp
ago/ago_platform.cpp
ago/ago_util.cpp
ago/ago_util_opencl.cpp
ago/ago_util_hip.cpp
api/vxu.cpp
api/vx_api.cpp
api/vx_nodes.cpp
api/vx_pipelining_api.cpp
)

add_library(openvx SHARED ${SOURCES})
Expand Down
Loading
Loading