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
54 lines
2.5 KiB
C++
54 lines
2.5 KiB
C++
// RUN: %clang_cc1 -triple x86_64-linux-gnu -std=c++17 -emit-llvm \
|
|
// RUN: -debug-info-kind=standalone -o - %s | FileCheck %s
|
|
|
|
using uint16_t = unsigned short;
|
|
using uint32_t = unsigned int;
|
|
using uint64_t = unsigned long long;
|
|
|
|
struct Test {
|
|
static inline constexpr char STR[] = "Hello";
|
|
static inline constexpr int NUMS[] = {1, 2, 3};
|
|
static inline constexpr uint16_t SHORTS[] = {256, 512, 1024};
|
|
static inline constexpr uint32_t INTS[] = {70000, 80000};
|
|
static inline constexpr uint64_t LONGS[] = {4294967296ULL, 123456789ULL};
|
|
static inline constexpr int NEG[] = {-1, -128, 42};
|
|
// 128-bit integers and floating-point arrays should NOT produce extraData
|
|
// (not yet supported).
|
|
static inline constexpr __int128_t I128[] = {1, -1};
|
|
static inline constexpr __uint128_t U128[] = {1, 2};
|
|
static inline constexpr float FLOATS[] = {1.0f, 2.0f};
|
|
static inline constexpr double DOUBLES[] = {1.0, 2.0};
|
|
};
|
|
|
|
void use(const void*);
|
|
void test() {
|
|
use(&Test::STR);
|
|
use(&Test::NUMS);
|
|
use(&Test::SHORTS);
|
|
use(&Test::INTS);
|
|
use(&Test::LONGS);
|
|
use(&Test::NEG);
|
|
use(&Test::I128);
|
|
use(&Test::U128);
|
|
use(&Test::FLOATS);
|
|
use(&Test::DOUBLES);
|
|
}
|
|
|
|
// Integer arrays: extraData on DIDerivedType member declarations.
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "STR",{{.*}}extraData: [6 x i8] c"Hello\00")
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "NUMS",{{.*}}extraData: [3 x i32] [i32 1, i32 2, i32 3])
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "SHORTS",{{.*}}extraData: [3 x i16] [i16 256, i16 512, i16 1024])
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "INTS",{{.*}}extraData: [2 x i32] [i32 70000, i32 80000])
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "LONGS",{{.*}}extraData: [2 x i64] [i64 4294967296, i64 123456789])
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "NEG",{{.*}}extraData: [3 x i32] [i32 -1, i32 -128, i32 42])
|
|
// 128-bit integers: no extraData (not yet supported).
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "I128",{{.*}}flags: DIFlagStaticMember)
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "U128",{{.*}}flags: DIFlagStaticMember)
|
|
// CHECK-NOT: name: "I128",{{.*}}extraData:
|
|
// CHECK-NOT: name: "U128",{{.*}}extraData:
|
|
// Floating-point arrays: no extraData.
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "FLOATS",{{.*}}flags: DIFlagStaticMember)
|
|
// CHECK-DAG: !DIDerivedType(tag: DW_TAG_member, name: "DOUBLES",{{.*}}flags: DIFlagStaticMember)
|
|
// CHECK-NOT: name: "FLOATS",{{.*}}extraData:
|
|
// CHECK-NOT: name: "DOUBLES",{{.*}}extraData:
|