brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.3 KiB · 5c22a77 Raw
82 lines · plain
1; RUN: llc -mtriple mipsel-windows -filetype=obj < %s | obj2yaml | FileCheck %s2 3; CHECK:  Machine:         IMAGE_FILE_MACHINE_R40004 5 6 7; CHECK:  - Name:            .text8; CHECK:    Relocations:9 10declare void @bar()11define i32 @foo_jmp() {12  call i32 @bar()13; CHECK:      - VirtualAddress:  814; CHECK:        SymbolName:      bar15; CHECK:        Type:            IMAGE_REL_MIPS_JMPADDR16  ret i32 017}18 19@var = external global i3220define i32 @foo_var() {21  %1 = load i32, i32* @var22; CHECK:      - VirtualAddress:  3223; CHECK:        SymbolName:      var24; CHECK:        Type:            IMAGE_REL_MIPS_REFHI25; CHECK:      - VirtualAddress:  3226; CHECK:        SymbolName:      .text27; CHECK:        Type:            IMAGE_REL_MIPS_PAIR28; CHECK:      - VirtualAddress:  4029; CHECK:        SymbolName:      var30; CHECK:        Type:            IMAGE_REL_MIPS_REFLO31  ret i32 %132}33 34 35 36; CHECK:  - Name:            .data37; CHECK:    Relocations:38 39%struct._PTR = type { ptr }40 41@var1 = internal global %struct._PTR { ptr @var2 }42@var2 = external global i3243; CHECK:      - VirtualAddress:  044; CHECK:        SymbolName:      var245; CHECK:        Type:            IMAGE_REL_MIPS_REFWORD46 47 48 49 50; CHECK:  - Name:            '.debug$S'51; CHECK:    Relocations:52 53!llvm.dbg.cu = !{!0}54!llvm.module.flags = !{!2, !3, !4}55 56!0 = distinct !DICompileUnit(language: DW_LANG_C11, file: !1, emissionKind: FullDebug)57!1 = !DIFile(filename: "dummy.c", directory: "/tmp/private")58!2 = !{i32 2, !"CodeView", i32 1}59!3 = !{i32 2, !"Debug Info Version", i32 3}60!4 = !{i32 1, !"wchar_size", i32 2}61!5 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !6, scopeLine: 2, spFlags: DISPFlagDefinition, unit: !0)62!6 = !DISubroutineType(types: !7)63!7 = !{null}64!8 = !DILocation(line: 3, scope: !5)65 66define dso_local void @foo_dbg() #0 !dbg !5 {67  ret void, !dbg !868; CHECK:      - VirtualAddress:  9269; CHECK:        SymbolName:      foo_dbg70; CHECK:        Type:            IMAGE_REL_MIPS_SECREL71; CHECK:      - VirtualAddress:  9672; CHECK:        SymbolName:      foo_dbg73; CHECK:        Type:            IMAGE_REL_MIPS_SECTION74; CHECK:      - VirtualAddress:  14875; CHECK:        SymbolName:      foo_dbg76; CHECK:        Type:            IMAGE_REL_MIPS_SECREL77; CHECK:      - VirtualAddress:  15278; CHECK:        SymbolName:      foo_dbg79; CHECK:        Type:            IMAGE_REL_MIPS_SECTION80}81 82