Debian Codegraph @

llvm/test/tools/dsymutil/X86/swift-ast-x86_64.test

raw
1 RUN: rm -rf %t && mkdir %t
2 RUN: dsymutil -oso-prepend-path %p/.. %p/../Inputs/swift-ast.macho.x86_64 -o %t/swift-ast.dSYM -verbose -no-swiftmodule-timestamp | FileCheck %s --check-prefix=DSYMUTIL
3 RUN: dsymutil -oso-prepend-path %p/.. %p/../Inputs/swift-ast.macho.x86_64 -o %t/swift-ast.dSYM -verbose | FileCheck %s --check-prefix=DSYMUTIL
4 RUN: llvm-readobj --sections --section-data %t/swift-ast.dSYM/Contents/Resources/DWARF/swift-ast.macho.x86_64 | FileCheck %s --check-prefix=READOBJ
5 RUN: llvm-dwarfdump --show-section-sizes %t/swift-ast.dSYM/Contents/Resources/DWARF/swift-ast.macho.x86_64 | FileCheck %s --check-prefix=DWARFDUMP
6
7 RUN: dsymutil --linker parallel -oso-prepend-path %p/.. %p/../Inputs/swift-ast.macho.x86_64 -o %t/swift-ast.dSYM -verbose -no-swiftmodule-timestamp | FileCheck %s --check-prefix=DSYMUTIL
8 RUN: dsymutil --linker parallel -oso-prepend-path %p/.. %p/../Inputs/swift-ast.macho.x86_64 -o %t/swift-ast.dSYM -verbose | FileCheck %s --check-prefix=DSYMUTIL
9 RUN: llvm-readobj --sections --section-data %t/swift-ast.dSYM/Contents/Resources/DWARF/swift-ast.macho.x86_64 | FileCheck %s --check-prefix=READOBJ
10 RUN: llvm-dwarfdump --show-section-sizes %t/swift-ast.dSYM/Contents/Resources/DWARF/swift-ast.macho.x86_64 | FileCheck %s --check-prefix=DWARFDUMP
11
12
13 The tested object file has been created by the dummy Swift code:
14 let x = 1
15
16 Compiled with:
17 swiftc /tmp/test.swift -Onone -target x86_64-apple-macosx10.9 -c
18 ld swift-ast.o -add_ast_path Inputs/swift-ast.swiftmodule -arch x86_64 -lSystem -macosx_version_min 10.9.0
19
20 DSYMUTIL: filename:{{.*}}swift-ast.swiftmodule
21 DSYMUTIL-NOT: The file was not recognized as a valid object file
22 DSYMUTIL-NOT: timestamp mismatch
23 DSYMUTIL: DEBUG MAP OBJECT:{{.*}}swift-ast.swiftmodule
24
25 READOBJ: Name:{{.*}}__swift_ast
26 READOBJ: |SWIFTMODULE DATA|
27 READOBJ-NEXT: |.|
28
29 DWARFDUMP: __swift_ast
30
31 RUN: dsymutil -s %t/swift-ast.dSYM/Contents/Resources/DWARF/swift-ast.macho.x86_64 | FileCheck %s --check-prefix=NAST
32 NAST-NOT: N_AST