CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
28 lines
1.4 KiB
C
28 lines
1.4 KiB
C
// REQUIRES: zstd
|
|
|
|
// Regression test for a magic-byte collision in the compressed offload bundle
|
|
// (CCOB) reader. To find the boundary between concatenated bundles the reader
|
|
// used to scan for the literal 4-byte magic "CCOB"; those bytes can appear by
|
|
// chance inside a compressed payload, which truncated a valid single bundle and
|
|
// made decompression fail with "Src size is incorrect".
|
|
//
|
|
// Inputs/clang-offload-bundler-magic-collision.co is a single compressed bundle
|
|
// whose compressed region embeds the bytes "CCOB" inside a zstd skippable frame
|
|
// (regenerate with Inputs/clang-offload-bundler-magic-collision.py). The frame
|
|
// is ignored by the decompressor, so the bundle is valid, but a naive
|
|
// find("CCOB", 4) scan stops at the planted bytes. A reader that advances by
|
|
// the header's FileSize handles this file correctly.
|
|
|
|
// RUN: clang-offload-bundler -type=bc -list \
|
|
// RUN: -input=%S/Inputs/clang-offload-bundler-magic-collision.co \
|
|
// RUN: | FileCheck %s --check-prefix=LIST
|
|
// LIST-DAG: hip-amdgcn-amd-amdhsa--gfx906
|
|
// LIST-DAG: hip-amdgcn-amd-amdhsa--gfx908
|
|
|
|
// RUN: clang-offload-bundler -type=bc -unbundle \
|
|
// RUN: -targets=hip-amdgcn-amd-amdhsa--gfx906 \
|
|
// RUN: -input=%S/Inputs/clang-offload-bundler-magic-collision.co \
|
|
// RUN: -output=%t.gfx906
|
|
// RUN: FileCheck %s --check-prefix=EXTRACT --input-file=%t.gfx906
|
|
// EXTRACT: Content of device file 1
|