Files
TheRock/compiler/amd-llvm/llvm/test/tools/llvm-readobj/COFF/codeview-merging.test
T
derek.holloway 7502bf64a4
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
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

114 lines
3.4 KiB
Plaintext

# To regenerate t1.obj and t2.obj, run the following:
# $ cat t.cpp
# #ifdef CONFIG1
# struct A;
# struct B {
# A *a;
# };
# int f(A *a);
# int g(B *b) { return f(b->a); }
# #else
# struct B;
# struct A {
# B *b;
# };
# int g(B *b);
# int f(A *a) { return g(a->b); }
# #endif
# $ cl -c -DCONFIG1 -Z7 t.cpp -Fot1.obj && cl -c -Z7 t.cpp -Fot2.obj
RUN: llvm-readobj --codeview %S/Inputs/codeview-merging-1.obj | FileCheck %s --check-prefix=OBJ1
RUN: llvm-readobj --codeview %S/Inputs/codeview-merging-2.obj | FileCheck %s --check-prefix=OBJ2
RUN: llvm-readobj --codeview-merged-types %S/Inputs/codeview-merging-1.obj %S/Inputs/codeview-merging-2.obj | FileCheck %s
OBJ1: Procedure ({{.*}}) {
OBJ1-NEXT: TypeLeafKind: LF_PROCEDURE (0x1008)
OBJ1-NEXT: ReturnType: int (0x74)
OBJ1-NEXT: CallingConvention: NearC (0x0)
OBJ1-NEXT: FunctionOptions [ (0x0)
OBJ1-NEXT: ]
OBJ1-NEXT: NumParameters: 1
OBJ1-NEXT: ArgListType: (A*) (0x1002)
OBJ1-NEXT: }
OBJ1: FuncId (0x100D) {
OBJ1-NEXT: TypeLeafKind: LF_FUNC_ID (0x1601)
OBJ1-NEXT: ParentScope: 0x0
OBJ1-NEXT: FunctionType: int (B*) (0x100C)
OBJ1-NEXT: Name: g
OBJ1-NEXT: }
OBJ1-NEXT: FuncId (0x100E) {
OBJ1-NEXT: TypeLeafKind: LF_FUNC_ID (0x1601)
OBJ1-NEXT: ParentScope: 0x0
OBJ1-NEXT: FunctionType: int (A*) (0x1003)
OBJ1-NEXT: Name: f
OBJ1-NEXT: }
OBJ1-NOT: FuncId
OBJ2: FuncId (0x100D) {
OBJ2-NEXT: TypeLeafKind: LF_FUNC_ID (0x1601)
OBJ2-NEXT: ParentScope: 0x0
OBJ2-NEXT: FunctionType: int (A*) (0x100C)
OBJ2-NEXT: Name: f
OBJ2-NEXT: }
OBJ2: FuncId (0x1069) {
OBJ2-NEXT: TypeLeafKind: LF_FUNC_ID (0x1601)
OBJ2-NEXT: ParentScope: 0x0
OBJ2-NEXT: FunctionType: int (B*) (0x1003)
OBJ2-NEXT: Name: g
OBJ2-NEXT: }
OBJ2-NOT: FuncId
CHECK: MergedTypeStream [
CHECK: Procedure ({{.*}}) {
CHECK-NEXT: TypeLeafKind: LF_PROCEDURE (0x1008)
CHECK-NEXT: ReturnType: int (0x74)
CHECK-NEXT: CallingConvention: NearC (0x0)
CHECK-NEXT: FunctionOptions [ (0x0)
CHECK-NEXT: ]
CHECK-NEXT: NumParameters: 1
CHECK-NEXT: ArgListType: (A*) (0x1002)
CHECK-NEXT: }
CHECK: Struct (0x1007) {
CHECK-NEXT: TypeLeafKind: LF_STRUCTURE (0x1505)
CHECK-NEXT: MemberCount: 1
CHECK-NEXT: Properties [ (0x200)
CHECK-NEXT: HasUniqueName (0x200)
CHECK-NEXT: ]
CHECK-NEXT: FieldList: <field list> (0x1006)
CHECK-NEXT: DerivedFrom: 0x0
CHECK-NEXT: VShape: 0x0
CHECK-NEXT: SizeOf: 8
CHECK-NEXT: Name: B
CHECK-NEXT: LinkageName: .?AUB@@
CHECK-NEXT: }
CHECK: ]
CHECK: MergedIDStream [
CHECK-NEXT: StringId (0x1000) {
CHECK-NEXT: TypeLeafKind: LF_STRING_ID (0x1605)
CHECK-NEXT: Id: 0x0
CHECK-NEXT: StringData: d:\src\llvm\build\t.cpp
CHECK-NEXT: }
# Test that we contextually dump item ids and type ids from different databases.
CHECK-NEXT: UdtSourceLine (0x1001) {
CHECK-NEXT: TypeLeafKind: LF_UDT_SRC_LINE (0x1606)
CHECK-NEXT: UDT: B (0x1007)
CHECK-NEXT: SourceFile: d:\src\llvm\build\t.cpp (0x1000)
CHECK-NEXT: LineNumber: 3
CHECK-NEXT: }
CHECK: FuncId (0x1002) {
CHECK-NEXT: TypeLeafKind: LF_FUNC_ID (0x1601)
CHECK-NEXT: ParentScope: 0x0
CHECK-NEXT: FunctionType: int (B*)
CHECK-NEXT: Name: g
CHECK-NEXT: }
CHECK-NEXT: FuncId (0x1003) {
CHECK-NEXT: TypeLeafKind: LF_FUNC_ID (0x1601)
CHECK-NEXT: ParentScope: 0x0
CHECK-NEXT: FunctionType: int (A*)
CHECK-NEXT: Name: f
CHECK-NEXT: }
CHECK-NOT: FuncId
CHECK: ]