1LLVM-STRINGS(1)                      LLVM                      LLVM-STRINGS(1)
2
3
4

NAME

6       llvm-strings - print strings
7

SYNOPSIS

9       llvm-strings [options] [input...]
10

DESCRIPTION

12       llvm-strings  is  a  tool  intended  as a drop-in replacement for GNU's
13       strings, which looks for printable strings in files and writes them  to
14       the  standard output stream. A printable string is any sequence of four
15       (by default) or more printable ASCII characters. The end of  the  file,
16       or any other byte, terminates the current sequence.
17
18       llvm-strings  looks  for  strings in each input file specified.  Unlike
19       GNU strings it looks in the entire input file, regardless of file  for‐
20       mat,  rather  than restricting the search to certain sections of object
21       files. If "-" is specified as an input, or no input is  specified,  the
22       program reads from the standard input stream.
23

EXAMPLE

25          $ cat input.txt
26          bars
27          foo
28          wibble blob
29          $ llvm-strings input.txt
30          bars
31          wibble blob
32

OPTIONS

34       --all, -a
35              Silently ignored. Present for GNU strings compatibility.
36
37       --bytes=<length>, -n
38              Set  the  minimum  number of printable ASCII characters required
39              for a sequence of bytes to be considered a string.  The  default
40              value is 4.
41
42       --help, -h
43              Display a summary of command line options.
44
45       --print-file-name, -f
46              Display the name of the containing file before each string.
47
48              Example:
49
50                 $ llvm-strings --print-file-name test.o test.elf
51                 test.o: _Z5hellov
52                 test.o: some_bss
53                 test.o: test.cpp
54                 test.o: main
55                 test.elf: test.cpp
56                 test.elf: test2.cpp
57                 test.elf: _Z5hellov
58                 test.elf: main
59                 test.elf: some_bss
60
61       --radix=<radix>, -t
62              Display  the  offset  within the file of each string, before the
63              string and using the specified radix. Valid <radix>  values  are
64              o, d and x for octal, decimal and hexadecimal respectively.
65
66              Example:
67
68                 $ llvm-strings --radix=o test.o
69                     1054 _Z5hellov
70                     1066 .rela.text
71                     1101 .comment
72                     1112 some_bss
73                     1123 .bss
74                     1130 test.cpp
75                     1141 main
76                 $ llvm-strings --radix=d test.o
77                     556 _Z5hellov
78                     566 .rela.text
79                     577 .comment
80                     586 some_bss
81                     595 .bss
82                     600 test.cpp
83                     609 main
84                 $ llvm-strings -t x test.o
85                     22c _Z5hellov
86                     236 .rela.text
87                     241 .comment
88                     24a some_bss
89                     253 .bss
90                     258 test.cpp
91                     261 main
92
93       --version
94              Display the version of the llvm-strings executable.
95
96       @<FILE>
97              Read command-line options from response file <FILE>.
98

EXIT STATUS

100       llvm-strings  exits  with  a  non-zero  exit code if there is an error.
101       Otherwise, it exits with code 0.
102

BUGS

104       To         report         bugs,         please         visit         <‐
105       https://github.com/llvm/llvm-project/labels/tools:llvm-strings/>.
106

AUTHOR

108       Maintained by the LLVM Team (https://llvm.org/).
109
111       2003-2023, LLVM Project
112
113
114
115
11616                                2023-07-20                   LLVM-STRINGS(1)
Impressum