brintos

brintos / llvm-project-archived public Read only

0
0
Text · 957 B · 2c05769 Raw
33 lines · plain
1// Testing that we won't record the type ID from external modules.2//3// RUN: rm -rf %t4// RUN: split-file %s %t5// RUN: cd %t6//7// RUN: %clang_cc1 -std=c++20 %t/a.cppm -emit-module-interface -o %t/a.pcm8// RUN: %clang_cc1 -std=c++20 %t/b.cppm -emit-module-interface -o %t/b.pcm \9// RUN:     -fmodule-file=a=%t/a.pcm10// RUN: llvm-bcanalyzer --dump --disable-histogram %t/b.pcm | FileCheck %t/b.cppm11//12// RUN: %clang_cc1 -std=c++20 %t/a.v1.cppm -emit-module-interface -o %t/a.v1.pcm13// RUN: %clang_cc1 -std=c++20 %t/b.cppm -emit-module-interface -o %t/b.v1.pcm \14// RUN:     -fmodule-file=a=%t/a.v1.pcm15// RUN: diff %t/b.pcm %t/b.v1.pcm &> /dev/null16 17//--- a.cppm18export module a;19export int a();20 21//--- b.cppm22export module b;23import a;24export int b();25 26// CHECK: <DECL_FUNCTION {{.*}} op8=[[#]]27// CHECK: <TYPE_FUNCTION_PROTO28 29//--- a.v1.cppm30// We remove the unused the function and testing if the format of the BMI of B will change.31export module a;32 33