File: strip-all.test

package info (click to toggle)
llvm-toolchain-14 1%3A14.0.6-12
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,496,180 kB
  • sloc: cpp: 5,593,972; ansic: 986,872; asm: 585,869; python: 184,223; objc: 72,530; lisp: 31,119; f90: 27,793; javascript: 9,780; pascal: 9,762; sh: 9,482; perl: 7,468; ml: 5,432; awk: 3,523; makefile: 2,538; xml: 953; cs: 573; fortran: 567
file content (55 lines) | stat: -rw-r--r-- 1,662 bytes parent folder | download | duplicates (21)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# RUN: yaml2obj %s -o %t.in.o

# RUN: llvm-objdump -t %t.in.o | FileCheck %s --check-prefixes=SYMBOLS,SYMBOLS-PRE

# RUN: llvm-objcopy --strip-all %t.in.o %t.out.o
# RUN: llvm-objdump -t %t.out.o | FileCheck %s --check-prefix=SYMBOLS
# RUN: llvm-readobj -r %t.out.o | FileCheck %s --check-prefix=RELOCS

# Test that -S, llvm-strip without arguments and --strip-all-gnu produces
# output identical to --strip-all above.
# RUN: llvm-objcopy -S %t.in.o %t.out-short.o
# RUN: cmp %t.out.o %t.out-short.o

# RUN: cp %t.in.o %t.out-strip.o
# RUN: llvm-strip %t.out-strip.o
# RUN: cmp %t.out.o %t.out-strip.o

# RUN: llvm-objcopy --strip-all-gnu %t.in.o %t.out-gnu.o
# RUN: cmp %t.out.o %t.out-gnu.o

# SYMBOLS: SYMBOL TABLE:
# SYMBOLS-PRE-NEXT: external
# SYMBOLS-PRE-NEXT: external_undefined
# SYMBOLS-EMPTY:

# RELOCS:      Relocations [
# RELOCS-NEXT: ]

--- !COFF
header:          
  Machine:         IMAGE_FILE_MACHINE_AMD64
  Characteristics: [  ]
sections:        
  - Name:            .text
    Characteristics: [  ]
    Alignment:       4
    SectionData:     488B0500000000C3
    Relocations:     
      - VirtualAddress:  3
        SymbolName:      external_undefined
        Type:            IMAGE_REL_AMD64_REL32
symbols:         
  - Name:            external
    Value:           0
    SectionNumber:   1
    SimpleType:      IMAGE_SYM_TYPE_NULL
    ComplexType:     IMAGE_SYM_DTYPE_NULL
    StorageClass:    IMAGE_SYM_CLASS_EXTERNAL
  - Name:            external_undefined
    Value:           0
    SectionNumber:   0
    SimpleType:      IMAGE_SYM_TYPE_NULL
    ComplexType:     IMAGE_SYM_DTYPE_NULL
    StorageClass:    IMAGE_SYM_CLASS_EXTERNAL
...