File: unwind-info-excess-x86_64.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 (67 lines) | stat: -rw-r--r-- 3,733 bytes parent folder | download | duplicates (19)
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
56
57
58
59
60
61
62
63
64
65
66
67
## Ensure that per-page compact encodings (indexes 127 and greater)
## appear in the output of llvm-objdump --unwind-info
## Verify that the common encodings table is full at 0x7f (127) entries.
##
## TODO(gkm): The input is a binary object file constructed from a
## large generated assembler file. For sake of expediency and
## test-time performance, I am following the unfortunate precedent
## that MachO test inputs are binary.
##
## Non-MachO tests largely use YAML inputs. As I understand it, the
## rationale is that these MachO tests were written prior to
## availability of sufficiently-expressive YAML processors.
##
## I consider YAML a submoptimal input format. Better would be
## assembler language inputs convertable to binary via llvm-mc.  In
## the case of this test however, the input is very large and the
## overhead of llvm-mc is terrible (~10s) on a debug build. Overhead
## for a release build of llvm-mc is acceptable at ~1s. It would be
## good if there were a way to prefer an installed version of llvm-mc
## to process tests in debug build trees when not testing llvm-mc
## itself.

# RUN: llvm-objdump --unwind-info %p/Inputs/unwind-info-excess.macho-x86_64 2>/dev/null | FileCheck %s

# CHECK:Contents of __unwind_info section:
# CHECK-NEXT:  Version:                                   0x1
# CHECK-NEXT:  Common encodings array section offset:     0x1c
# CHECK-NEXT:  Number of common encodings in array:       0x7f

# CHECK:  Second level indices:
# CHECK:    Second level index[0]: offset in section
# CHECK:      Page encodings: (count = 17)
# CHECK:        encoding[127]: 0x01010003
# CHECK:        encoding[128]: 0x01010002
# CHECK:        encoding[129]: 0x01010001
# CHECK:        encoding[130]: 0x0102001d
# CHECK:        encoding[131]: 0x01020015
# CHECK:        encoding[132]: 0x0102000d
# CHECK:        encoding[133]: 0x0102001c
# CHECK:        encoding[134]: 0x01020014
# CHECK:        encoding[135]: 0x0102000c
# CHECK:        encoding[136]: 0x01020013
# CHECK:        encoding[137]: 0x0102000b
# CHECK:        encoding[138]: 0x01020022
# CHECK:        encoding[139]: 0x0102001a
# CHECK:        encoding[140]: 0x0102000a
# CHECK:        encoding[141]: 0x01020021
# CHECK:        encoding[142]: 0x01020019
# CHECK:        encoding[143]: 0x01020011

# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[127]=0x01010003
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[128]=0x01010002
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[129]=0x01010001
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[130]=0x0102001d
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[131]=0x01020015
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[132]=0x0102000d
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[133]=0x0102001c
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[134]=0x01020014
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[135]=0x0102000c
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[136]=0x01020013
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[137]=0x0102000b
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[138]=0x01020022
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[139]=0x0102001a
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[140]=0x0102000a
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[141]=0x01020021
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[142]=0x01020019
# CHECK:      [{{[0-9]+}}]: function offset={{[x0-9a-f]+}}, encoding[143]=0x01020011