llvm.org GIT mirror llvm / 3abe103
[IR/Verifier] List the CU we weren't able to find in `llvm.dbg.cu`. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@295678 91177308-0d34-0410-b5e6-96231b3b80d8 Davide Italiano 2 years ago
3 changed file(s) with 5 addition(s) and 6 deletion(s). Raw diff Collapse all Expand all
44204420 SmallPtrSet Listed;
44214421 if (CUs)
44224422 Listed.insert(CUs->op_begin(), CUs->op_end());
4423 AssertDI(
4424 all_of(CUVisited,
4425 [&Listed](const Metadata *CU) { return Listed.count(CU); }),
4426 "All DICompileUnits must be listed in llvm.dbg.cu");
4423 for (auto *CU : CUVisited)
4424 AssertDI(Listed.count(CU), "DICompileUnit not listed in llvm.dbg.cu", CU);
44274425 CUVisited.clear();
44284426 }
44294427
0 ; RUN: bugpoint -load %llvmshlibdir/BugpointPasses%shlibext %s -output-prefix %t -bugpoint-crash-too-many-cus -silence-passes 2>&1 | FileCheck %s
11 ; REQUIRES: loadable_module
2 ; CHECK: All DICompileUnits must be listed in llvm.dbg.cu
2 ; CHECK: DICompileUnit not listed in llvm.dbg.cu
33
44 ; When bugpoint hacks at this testcase it will at one point create illegal IR
55 ; that won't even pass the Verifier. A bugpoint *driver* built with assertions
0 ; RUN: not llvm-as -disable-output <%s 2>&1 | FileCheck %s
11 ; CHECK: assembly parsed, but does not verify
2 ; CHECK-NEXT: All DICompileUnits must be listed in llvm.dbg.cu
2 ; CHECK-NEXT: DICompileUnit not listed in llvm.dbg.cu
3 ; CHECK-NEXT: !0 = distinct !DICompileUnit(language: DW_LANG_Fortran77, file: !1, isOptimized: false, runtimeVersion: 0, emissionKind: NoDebug)
34
45 !named = !{!1}
56 !llvm.module.flags = !{!0}