xref: /llvm-project/llvm/test/DebugInfo/AArch64/test-fexceptions-debug-frame.ll (revision fe8eab468eee18329922901bcf74310534e08b59)
1; This test is added to provide test coverage for the
2; .cfi_sections .debug_frame intrinsic. It aims to make sure that for a AArch64
3; output compiled with -fexceptions, no .cfi_sections .debug_frame is emitted.
4
5; RUN: llc --filetype=asm %s -o - | FileCheck %s
6; CHECK-NOT: .cfi_sections .debug_frame
7; CHECK: .cfi_startproc
8
9
10; ModuleID = 'test.cpp'
11source_filename = "test.cpp"
12target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
13target triple = "arm64-apple-macosx13.0.0"
14
15; Function Attrs: noinline norecurse nounwind optnone ssp uwtable(sync)
16define i32 @main() #0 !dbg !10 {
17  %1 = alloca i32, align 4
18  store i32 0, ptr %1, align 4
19  ret i32 1, !dbg !15
20}
21
22attributes #0 = { noinline norecurse nounwind optnone ssp uwtable(sync)}
23
24!llvm.module.flags = !{!0, !1, !2, !3, !4, !5, !6}
25!llvm.dbg.cu = !{!7}
26!llvm.ident = !{!9}
27
28!0 = !{i32 2, !"SDK Version", [2 x i32] [i32 14, i32 0]}
29!1 = !{i32 7, !"Dwarf Version", i32 4}
30!2 = !{i32 2, !"Debug Info Version", i32 3}
31!3 = !{i32 1, !"wchar_size", i32 4}
32!4 = !{i32 8, !"PIC Level", i32 2}
33!5 = !{i32 7, !"uwtable", i32 1}
34!6 = !{i32 7, !"frame-pointer", i32 1}
35!7 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !8, producer: "clang", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, splitDebugInlining: false, nameTableKind: None, sysroot: "/Applications/Xcode.app", sdk: "MacOSX.sdk")
36!8 = !DIFile(filename: "test.cpp", directory: "/Users/shubham/Development")
37!9 = !{!"clang"}
38!10 = distinct !DISubprogram(name: "main", scope: !8, file: !8, line: 1, type: !11, scopeLine: 1, flags: DIFlagPrototyped, spFlags: DISPFlagDefinition, unit: !7, retainedNodes: !14)
39!11 = !DISubroutineType(types: !12)
40!12 = !{!13}
41!13 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
42!14 = !{}
43!15 = !DILocation(line: 2, column: 5, scope: !10)
44