invalid.ll 853 B

123456789101112131415161718
  1. ; RUN: llvm-as -disable-output %s 2>&1 | FileCheck %s
  2. ; Make sure we emit this diagnostic only once (which means we don't visit the
  3. ; same DISubprogram twice.
  4. ; CHECK: subprogram definitions must have a compile unit
  5. ; CHECK-NEXT: !3 = distinct !DISubprogram(name: "patatino", scope: null, spFlags: DISPFlagDefinition)
  6. ; CHECK-NOT: subprogram definitions must have a compile unit
  7. ; CHECK-NOT: !3 = distinct !DISubprogram(name: "patatino", scope: null, spFlags: DISPFlagDefinition)
  8. ; CHECK: warning: ignoring invalid debug info
  9. define void @tinkywinky() !dbg !3 { ret void }
  10. !llvm.module.flags = !{!4}
  11. !llvm.dbg.cu = !{!0}
  12. !0 = distinct !DICompileUnit(language: 12, file: !1)
  13. !1 = !DIFile(filename: "/home/davide", directory: "/home/davide")
  14. !3 = distinct !DISubprogram(name: "patatino", isDefinition: true)
  15. !4 = !{i32 2, !"Debug Info Version", i32 3}