brintos

brintos / llvm-project-archived public Read only

0
0
Text · 6.7 KiB · 7b66148 Raw
152 lines · plain
1; This file contains exception section testing for when debug information is present.2; The 32-bit test should not print exception auxilliary entries because they are a 64-bit only feature.3; Exception auxilliary entries are present in the 64-bit tests because 64-bit && debug enabled are the requirements.4; RUN: llc -mtriple=powerpc-ibm-aix-xcoff -mcpu=ppc -filetype=obj -o %t_32.o < %s5; RUN: llvm-readobj --syms %t_32.o | FileCheck %s --check-prefix=SYMS326; RUN: llc -mtriple=powerpc64-unknown-aix -mcpu=ppc -filetype=obj -o %t_32.o < %s7; RUN: llvm-readobj --syms %t_32.o | FileCheck %s --check-prefix=SYMS648 9; If any debug information is included in a module and is XCOFF64, exception auxilliary entries are emitted10 11!llvm.module.flags = !{!0, !1}12!llvm.dbg.cu = !{!2}13 14!0 = !{i32 2, !"Dwarf Version", i32 3}15!1 = !{i32 2, !"Debug Info Version", i32 3}16!2 = distinct !DICompileUnit(language: DW_LANG_Fortran95, file: !3, producer: "ASTI IR translator", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, splitDebugInlining: false)17!3 = !DIFile(filename: "t.f", directory: ".")18!4 = distinct !DISubprogram(name: "test__trap_annotation_debug", linkageName: "test__trap_annotation_debug", scope: !3, file: !3, line: 1, type: !5, scopeLine: 1, flags: DIFlagPrototyped, spFlags: DISPFlagDefinition, unit: !2, retainedNodes: !6)19!5 = !DISubroutineType(types: !6)20!6 = !{}21!7 = !DILocation(line: 4, column: 1, scope: !4)22!8 = !{!"ppc-trap-reason", !"1", !"2"}23declare void @llvm.ppc.trap(i32 %a)24define dso_local void @sub_test() {25  call void @llvm.ppc.trap(i32 1), !annotation !826  ret void27}28define dso_local void @test__trap_annotation_debug(i32 %a) !dbg !4 {29  call void @llvm.ppc.trap(i32 %a), !annotation !830  call void @sub_test()31  call void @llvm.ppc.trap(i32 %a), !annotation !832  ret void33}34 35; SYMS32:           Index: [[#IND:]]{{.*}}{{[[:space:]] *}}Name: .sub_test36; SYMS32-NEXT:      Value (RelocatableAddress): 0x037; SYMS32-NEXT:      Section: .text38; SYMS32-NEXT:      Type: 0x2039; SYMS32-NEXT:      StorageClass: C_EXT (0x2)40; SYMS32-NEXT:      NumberOfAuxEntries: 241; SYMS32-NEXT:      Function Auxiliary Entry {42; SYMS32-NEXT:        Index: [[#IND+1]]43; SYMS32-NEXT:        OffsetToExceptionTable: 0x2B844; SYMS32-NEXT:        SizeOfFunction: 0xC45; SYMS32-NEXT:        PointerToLineNum: 0x046; SYMS32-NEXT:        SymbolIndexOfNextBeyond: [[#IND+3]] 47; SYMS32-NEXT:      }48; SYMS32-NEXT:      CSECT Auxiliary Entry {49; SYMS32-NEXT:        Index: [[#IND+2]]50; SYMS32-NEXT:        ContainingCsectSymbolIndex: [[#IND-2]]51; SYMS32-NEXT:        ParameterHashIndex: 0x052; SYMS32-NEXT:        TypeChkSectNum: 0x053; SYMS32-NEXT:        SymbolAlignmentLog2: 054; SYMS32-NEXT:        SymbolType: XTY_LD (0x2)55; SYMS32-NEXT:        StorageMappingClass: XMC_PR (0x0)56; SYMS32-NEXT:        StabInfoIndex: 0x057; SYMS32-NEXT:        StabSectNum: 0x058; SYMS32-NEXT:      }59; SYMS32-NEXT:    }60; SYMS32-NEXT:    Symbol {61; SYMS32-NEXT:      Index: [[#IND+3]]62; SYMS32-NEXT:      Name: .test__trap_annotation63; SYMS32-NEXT:      Value (RelocatableAddress): 0x2864; SYMS32-NEXT:      Section: .text65; SYMS32-NEXT:      Type: 0x2066; SYMS32-NEXT:      StorageClass: C_EXT (0x2)67; SYMS32-NEXT:      NumberOfAuxEntries: 268; SYMS32-NEXT:      Function Auxiliary Entry {69; SYMS32-NEXT:        Index: [[#IND+4]]70; SYMS32-NEXT:        OffsetToExceptionTable: 0x2C471; SYMS32-NEXT:        SizeOfFunction: 0x3472; SYMS32-NEXT:        PointerToLineNum: 0x073; SYMS32-NEXT:        SymbolIndexOfNextBeyond: [[#IND+6]]74; SYMS32-NEXT:      }75; SYMS32-NEXT:      CSECT Auxiliary Entry {76; SYMS32-NEXT:        Index: [[#IND+5]]77; SYMS32-NEXT:        ContainingCsectSymbolIndex: [[#IND-2]]78; SYMS32-NEXT:        ParameterHashIndex: 0x079; SYMS32-NEXT:        TypeChkSectNum: 0x080; SYMS32-NEXT:        SymbolAlignmentLog2: 081; SYMS32-NEXT:        SymbolType: XTY_LD (0x2)82; SYMS32-NEXT:        StorageMappingClass: XMC_PR (0x0)83; SYMS32-NEXT:        StabInfoIndex: 0x084; SYMS32-NEXT:        StabSectNum: 0x085; SYMS32-NEXT:      }86; SYMS32-NEXT:    }87 88; SYMS64:           Index: [[#IND:]]{{.*}}{{[[:space:]] *}}Name: .sub_test89; SYMS64-NEXT:      Value (RelocatableAddress): 0x090; SYMS64-NEXT:      Section: .text91; SYMS64-NEXT:      Type: 0x092; SYMS64-NEXT:      StorageClass: C_EXT (0x2)93; SYMS64-NEXT:      NumberOfAuxEntries: 394; SYMS64-NEXT:      Exception Auxiliary Entry {95; SYMS64-NEXT:        Index: [[#IND+1]]96; SYMS64-NEXT:        OffsetToExceptionTable: 0x3AC97; SYMS64-NEXT:        SizeOfFunction: 0x1898; SYMS64-NEXT:        SymbolIndexOfNextBeyond: [[#IND+4]]99; SYMS64-NEXT:        Auxiliary Type: AUX_EXCEPT (0xFF)100; SYMS64-NEXT:      }101; SYMS64-NEXT:      Function Auxiliary Entry {102; SYMS64-NEXT:        Index: [[#IND+2]]103; SYMS64-NEXT:        SizeOfFunction: 0x18104; SYMS64-NEXT:        PointerToLineNum: 0x0105; SYMS64-NEXT:        SymbolIndexOfNextBeyond: [[#IND+4]]106; SYMS64-NEXT:        Auxiliary Type: AUX_FCN (0xFE)107; SYMS64-NEXT:      }108; SYMS64-NEXT:      CSECT Auxiliary Entry {109; SYMS64-NEXT:        Index: [[#IND+3]]110; SYMS64-NEXT:        ContainingCsectSymbolIndex: [[#IND-2]]111; SYMS64-NEXT:        ParameterHashIndex: 0x0112; SYMS64-NEXT:        TypeChkSectNum: 0x0113; SYMS64-NEXT:        SymbolAlignmentLog2: 0114; SYMS64-NEXT:        SymbolType: XTY_LD (0x2)115; SYMS64-NEXT:        StorageMappingClass: XMC_PR (0x0)116; SYMS64-NEXT:        Auxiliary Type: AUX_CSECT (0xFB)117; SYMS64-NEXT:      }118; SYMS64-NEXT:    }119; SYMS64-NEXT:    Symbol {120; SYMS64-NEXT:      Index: [[#IND+4]]121; SYMS64-NEXT:      Name: .test__trap_annotation_debug122; SYMS64-NEXT:      Value (RelocatableAddress): 0x28123; SYMS64-NEXT:      Section: .text124; SYMS64-NEXT:      Type: 0x0125; SYMS64-NEXT:      StorageClass: C_EXT (0x2)126; SYMS64-NEXT:      NumberOfAuxEntries: 3127; SYMS64-NEXT:      Exception Auxiliary Entry {128; SYMS64-NEXT:        Index: [[#IND+5]]129; SYMS64-NEXT:        OffsetToExceptionTable: 0x3C0130; SYMS64-NEXT:        SizeOfFunction: 0x68131; SYMS64-NEXT:        SymbolIndexOfNextBeyond: [[#IND+8]]132; SYMS64-NEXT:        Auxiliary Type: AUX_EXCEPT (0xFF)133; SYMS64-NEXT:      }134; SYMS64-NEXT:      Function Auxiliary Entry {135; SYMS64-NEXT:        Index: [[#IND+6]]136; SYMS64-NEXT:        SizeOfFunction: 0x68137; SYMS64-NEXT:        PointerToLineNum: 0x0138; SYMS64-NEXT:        SymbolIndexOfNextBeyond: [[#IND+8]]139; SYMS64-NEXT:        Auxiliary Type: AUX_FCN (0xFE)140; SYMS64-NEXT:      }141; SYMS64-NEXT:      CSECT Auxiliary Entry {142; SYMS64-NEXT:        Index: [[#IND+7]]143; SYMS64-NEXT:        ContainingCsectSymbolIndex: [[#IND-2]]144; SYMS64-NEXT:        ParameterHashIndex: 0x0145; SYMS64-NEXT:        TypeChkSectNum: 0x0146; SYMS64-NEXT:        SymbolAlignmentLog2: 0147; SYMS64-NEXT:        SymbolType: XTY_LD (0x2)148; SYMS64-NEXT:        StorageMappingClass: XMC_PR (0x0)149; SYMS64-NEXT:        Auxiliary Type: AUX_CSECT (0xFB)150; SYMS64-NEXT:      }151; SYMS64-NEXT:    }152