Replace readdir_r with readdir
[platform/upstream/ltrace.git] / NEWS
1 -*-org-*-
2 * Version 0.8.0
3 ** Prototype libraries
4    - Each DSO can now ship an ltrace config file (called prototype
5      library) that ltrace will open when that DSO is loaded to process
6      image.  See ltrace(1) for details.
7
8    - ltrace.conf is no longer part of installation tarball.  Instead,
9      we now ship libc.so.conf, libm.so.conf, libacl.so.conf, and
10      syscalls.conf.  Those are now istalled to /usr/share/ltrace by
11      default.  /etc/ltrace.conf and $HOME/.ltrace.conf are still
12      loaded if present, and can contain arbitrary user configuration.
13
14    - The option -F was retrofitted to be a colon-separated list of
15      prototype libraries, and directories to look for prototype
16      libraries in.  On Linux, ltrace looks into XDG_CONFIG_HOME,
17      XDG_CONFIG_DIRS, and /usr/share/ltrace as well.
18
19    - Wide character strings are supported in prototypes.  Use "string"
20      lens as usual, but use array of integers as underlying type.
21      libc.so.conf now contains prototypes of wide character functions.
22
23    - Sole void function parameter such as in the following example, is
24      now considered obsolete:
25
26      | int fork(void); |
27
28      This use is still accepted, taken to mean "hide(int)", but
29      produces a warning, and will be removed in future.
30
31    - Prototypes are now read from DWARF debug info, if available. This
32      complements the data available in config files
33
34 ** Architectural support
35    - MIPS and MIPSel are now handled by the same backend.
36    - ARMv6, ARMv7 and ARMv8 (AArch64) are supported, including full
37      fetch backend.  ARMv8 backend doesn't support tracing of 32-bit
38      binaries, as currently there's no 32-bit userspace available for
39      ARM64 processors.
40    - Imagination Technologies Meta is now supported.
41    - PowerPC64 ELFv2 little-endian ABI is now supported including full
42      fetch backend.
43
44    - On Linux, tracing of IFUNC symbols is supported.  On i386,
45      x86_64, ppc32 with secure PLT and ppc64, IRELATIVE PLT slots are
46      traced as well.
47
48 ** -w output now shows full library path
49     The output format is similar to glibc's backtrace_symbols, e.g.:
50      > /bin/ls(_init+0x19be) [0x40398e]
51      > /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xed) [0x7f50cbc3676d]
52      > /bin/ls(_init+0x25fd) [0x4045cd]
53
54 * Version 0.7.3 [2013-09-15 Sun]
55 ** Bugfixes
56 *** [MIPS] Fix build on mips big endian
57     This bug caused messages like:
58     | Making all in mips
59     | /bin/sh: line 17: cd: mips: No such file or directory
60 *** [MIPS] Fix SIGSEGV on mips big endian
61     This bug caused runtime messages like:
62     | [0x4000000] --- SIGSEGV (Segmentation fault) ---
63     | [0xffffffff] +++ killed by SIGSEGV +++
64 *** Fix build with CLANG on FREEBSD
65
66 * Version 0.7.2 [2012-12-07 Fri]
67 ** Bugfixes
68 *** (Again) detect VDSO entry in r_debug linkmap with non-empty name
69     This bug caused messages like:
70     | Couldn't determine base address of linux-vdso32.so.1
71     | Couldn't load ELF object linux-vdso32.so.1: No such file or directory
72 *** Fix building with libunwind 1.1
73 *** Fix prototype lookup for -x symbols from shared libraries
74     Ltrace was unable to find prototypes of static symbols in shared
75     libraries.  It changed the symbol name internally to the form
76     name@libfoo.so.  Thus mangled, symbols were not found in config
77     files.
78
79 * Version 0.7.1 [2012-11-29 Thu]
80 ** Bugfixes
81 *** ltrace.conf.5 is now installed to man5 as it should be
82 *** [PowerPC] A header file necessary for building is now shipped
83 *** [MIPS] Work around duplicate symbol request bug
84     This fixes the ltrace abort:
85     | ./ltrace: proc.c: 755: breakpoint_for_symbol: Assertion `bp->libsym == ((void *)0)' failed.
86
87 *** Detect VDSO entry in r_debug linkmap with non-empty name
88     This bug caused messages like:
89     | Couldn't determine base address of linux-vdso32.so.1
90     | Couldn't load ELF object linux-vdso32.so.1: No such file or directory
91
92 *** Temporary files are wiped properly after the test suite has been run
93 *** Parsing typedefs with common prefix now works as it should
94     More exactly, if there were typedefs X and XY (in this order), and
95     a reference was made to X, ltrace would match XY instead.
96
97 ** Cofiguration Files
98 *** The following prototypes in ltrace.conf were added or updated
99     __ctype_get_mb_cur_max, __endmntent, __getmntent_r, __setmntent,
100     a64l, abort, abs, addmntent, getmntent_r, hasmntopt, inet_addr,
101     inet_aton, inet_lnaof, inet_makeaddr, inet_netof, inet_network,
102     inet_ntoa, kill, l64a, labs, memcpy, memmove, setlocale,
103     sigaction, sigaddset, sigandset, sigdelset, sigemptyset,
104     sigfillset, sigisemptyset, sigismember, signal, sigorset,
105     sigpending, sigprocmask, sigsuspend.
106
107 *** Duplicate typedefs are now guarded against
108 *** It's now possible to define recursive structures
109     Please read ltrace.conf(5) man page, chapter "recursive
110     structures", to learn about this new feature.
111
112 *** New lens "bitvec" is available
113     This allows displaying various data types as bit vectors.  Please
114     read ltrace.conf(5) to learn more.
115
116 *** Octal lens renamed to "oct"
117     For reasons of consistency with "hex".  "octal" is still valid and
118     will be for forseeable future.
119
120 *** The hex lens can now format floating point arguments
121
122 * Version 0.7.0 [2012-11-09 Fri]
123 ** Tracing
124 *** Full support for tracing multi-threaded processes
125
126     Ltrace now understands thread groups, and it stops all threads
127     before manipulating breakpoints.  The downside is that performance
128     of multi-threaded processes is rather bad, because handling any
129     event implies stopping the whole job.  The upside is that
130     individual threads don't get random SIGILL's and SIGSEGV's and
131     events are not missed.
132
133 *** Support for tracing inter-library calls
134
135     -e and -x were extended to allow library selectors.  See the man
136     page for details.
137
138 *** Better support for parameter passing ("fetch backend")
139
140     This version brings more complete support for parameter passing,
141     including passing structures in registers, passing double on i386,
142     and other edge cases that were not handled correctly before.  The
143     following architectures now have implementation of fetch backend:
144     i386, x86_64, ppc, ppc64, ia64, s390, s390x, m68k.
145
146 *** Awareness of deny_ptrace SELinux boolean
147
148     The deny_ptrace boolean denies all processes from being able to
149     use ptrace to manipulate other processes.  Ltrace now understands
150     that this boolean exists, and recommends turning it off, if it is
151     on and ltrace fails to attach to a process.
152
153 *** Limited support for tracing returns from tail call functions
154 *** -e, -x and -l selectors now allow using globs and regular expressions
155
156     See the man page for details of the selector syntax.  This changes
157     the way -x and -l behave with respect to tracing libraries opened
158     by dlopen:
159
160     - In 0.6.0, only those -x symbols that were unmatched in main
161       binary were used to search through symbol table of libraries
162       opened with dlopen.  In 0.7.0, -x and -e are applied uniformly
163       to each mapped binary: the main binary, dependent DSO's, and any
164       dlopened libraries.
165
166     - In 0.6.0, -l argument was a filename to open and inspect.  In
167       0.7.0, -l is a glob expression matched against each mapped
168       binary.
169
170 *** -g command line option dropped
171
172     This option was introduced in 0.6.0 with the meaning identical to
173     -L, which should be used instead.
174
175 *** Test suite can now be run under valgrind
176
177     Use --enable-valgrind to turn this on.
178
179 *** [ppc] Support both BSS and secure PLTs for 32-bit processes
180 *** [mips] Implement software singlestepping
181 *** [mips] Add support for CPIC main programs
182 *** Support tracing PIE binaries
183
184 ** Configuration Files
185
186 *** New abstraction: parameter pack
187
188     Parameter packs describe zero or more of actual arguments, whose
189     type can be determined in runtime.  The only parameter pack
190     currently implemented is "format" for decoding printf-style format
191     strings.
192
193     In future, it should be relatively straightforward to add more
194     parameter packs for functions like execl, and others.
195
196 *** New expression: zero
197
198     When used in array length expressions, it means "this array ends
199     at the first element with zero value".  C strings are essentially
200     array(char, zero)*.
201
202 *** Lenses: change the way that underlying type is rendered
203
204     Lenses are used similarly to parametrized types, e.g.:
205     | void func(lens(int)); |
206
207 **** octal
208
209      "octal", which used to be a separate type, is now lens, which can
210      be used to render any underlying type in base 8.  Plain "octal"
211      is still valid and means the same thing as "octal(int)".
212
213 **** hex, hide, bool
214
215      Similarly, "hex" lens was introduced to format as base 16.
216      "hide" was introduced to conceal given argument.  "bool" lens was
217      added to format objects as either true, or false.
218
219 **** enum
220
221      "enum" became lens as well.  Because enum already uses
222      parentheses to denote the list of enumeration values, the
223      underlying type is selected by square brackets:
224
225      | void func(enum[short](RED,GREEN,BLUE)); |
226
227 **** string
228
229      "string" was also turned to lens.  The argument can be either a
230      char*, or pointer to array of char, or array of char.  The latter
231      is useful in cases like the following:
232
233      | void func_struct_2(struct(string(array(char, 6)))); |
234
235 *** Misspelling of "int" as "itn" temporarily accepted, but deprecated
236
237     Pre-0.7 ltrace shipped a buggy version of ltrace.conf that
238     contained the following prototype:
239
240     | itn acl_valid(addr); |
241
242     To support extant versions of ltrace.conf, that use is now
243     considered valid, and "itn" is a synonym of "int".  It is however
244     deprecated, and will produce a warning in future.
245
246 *** Using void as top-level function argument now deprecated
247
248     Functions that take no arguments shouldn't pretend to take one
249     parameter of void type.  For example the following:
250
251     | int fork(void); |
252
253     ... should be declared like this:
254
255     | int fork(); |
256
257     To support extant versions of ltrace.conf, that use is now
258     considered valid.  It is however deprecated, and will produce a
259     warning in future.
260
261 *** Using void to hide one argument is now obsolete
262
263     Ltrace needs to know the exact underlying type to decide what the
264     calling convention is.  The use of void to mean "hide this
265     argument", such as the following example, is therefore obsolete:
266
267     | void func(void, array(int, arg1)); |
268
269     Instead, rewrite the prototype depending on the exact underlying
270     type:
271
272     | void func(hide(int), array(int, arg1));  |
273     | void func(hide(long), array(int, arg1)); |
274
275     To support extant versions of ltrace.conf, this use is still
276     accepted, and "void" is taken to mean "hide(int)".  It is however
277     obsolete, produces a warning, and will be removed in future.
278
279 ** Documentation
280
281 *** New manual page ltrace.conf(5)
282 *** README, INSTALL brought up to date
283 *** New file CREDITS with a list of contributors
284
285 ** Bugfixes
286
287 *** Fix detaching from a process
288
289     Earlier, a process that ltrace detached from would sometimes die
290     of SIGSEGV, SIGTRAP, or SIGILL.  These were caused by ltrace
291     detaching from the process just after that process hit a
292     breakpoint.  Program counter would thus be left pointing
293     mid-instruction, or signals would be left pending.
294
295 *** Argument to -n is now checked for validity
296 *** Fix tracing across exec in a stripped binary
297 *** [x86] ORIG_RAX/ORIG_EAX may not contain original syscall number
298
299     In cases where the system call shouldn't be restarted, these are
300     set to -1.  In that case assume that the return is from the
301     topmost syscall.  This gets rid of some "unexpected breakpoint"
302     messages on x86_64 and i386.
303
304 *** [ppc] Fix races in tracing -e events in 64-bit processes
305
306     On ppc, the contents of PLT table change after the first call.
307     Ltrace used to handle this by reinserting the (now overwritten)
308     breakpoint after the function returns.  This introduced a window
309     where calls to the same function from the same binary (either a
310     recursive calls, or calls from another thread) weren't traced.
311     This is fixed as of 0.7.0.
312
313     As a side effect, events requested via -e now only hit when a PLT
314     call is made, which is consistent with other architectures.
315
316 *** [ppc] Allow stepping over lwarx instruction
317
318 ** Known bugs
319
320 *** [arm] Tracing is not supported at all on ARM
321
322     ltrace might work on older kernels, but no attempt was made to
323     fully support it.  Newer kernels don't support PTRACE_SINGLESTEP,
324     which ltrace depends on.  Before singlestepping is implemented in
325     software, ARM is considered unsupported.
326
327 * Version 0.6.0 [2011-01-06 Thu]
328
329 ** General Features
330
331 *** Use autotools for building
332 *** New option -b: disables output of signals received by the tracee
333 *** New option -w: print stack trace of events
334
335     Pass --with-libunwind to configure to enable the feature.  This
336     requires libunwind.
337
338 *** Support tracing of symbols from libraries opened with dlopen
339
340     These symbols are selected by -x.
341
342 ** Architecture-specific Changes
343
344 *** Various fixes for MIPS and PowerPC
345 *** Support for ARM Thumb mode
346 *** Implement fetching of 5th and further function arguments on s390
347 *** Support fork/exec syscalls on 31-bit s390
348 *** Support for float and double arguments on x86_64
349 *** Fixes for return arguments (after '+') in nested calls on x86_64
350
351 * License
352 -------------------------------------------------------------------------------
353 Copyright (C) 2012-2014 Petr Machata <pmachata@redhat.com>
354 This file is part of ltrace.
355
356 ltrace is free software; you can redistribute it and/or modify it
357 under the terms of the GNU General Public License as published by the
358 Free Software Foundation; either version 2 of the License, or (at your
359 option) any later version.
360
361 ltrace is distributed in the hope that it will be useful, but WITHOUT
362 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
363 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
364 for more details.
365
366 You should have received a copy of the GNU General Public License
367 along with this program.  If not, see <http://www.gnu.org/licenses/>.