mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-05 15:15:42 +00:00
215ba4f398c1bfabf50368d7379bcd1337addbe2
This introduces a new line table flag is_weak.
The line entries at the end of a subroutine range,
use this to indicate that they may possibly
be part of the previous subroutine.
When there is a sequence of line entries at the
same address where an inline range ends, and the
last item has is_stmt = 0, we force all previous
items to have is_weak = 1.
Additionally this adds a "fake" end sequence to the
record_line function, that is line number -1.
That will be used in the next patch.
Finally this adds a handling for empty ranges to
record_block_range. Currently this function is
not called with empty ranges, but that will be used
in the next patch.
There should be no functional changes after this commit.
Well, except the new is-weak flag in the line table of course.
As an example consider the following test code:
$ cat test.c
inline int test ()
{
asm ("nop");
return 0;
}
int main ()
{
int x = test ();
return x;
}
$ gcc -g -O2 test.c
This will receive the following line table:
(gdb) maintenance info line-table
INDEX LINE REL-ADDRESS UNREL-ADDRESS IS-STMT IS-WEAK PROLOGUE-END EPILOGUE-BEGIN
0 8 0x0000555555555040 0x0000000000001040 Y
1 9 0x0000555555555040 0x0000000000001040 Y
2 1 0x0000555555555040 0x0000000000001040 Y
3 3 0x0000555555555040 0x0000000000001040 Y
4 4 0x0000555555555041 0x0000000000001041 Y Y
5 4 0x0000555555555041 0x0000000000001041 Y <---+ set is_weak
6 10 0x0000555555555041 0x0000000000001041 Y Y ^
7 11 0x0000555555555041 0x0000000000001041 <----+ no is-stmt
8 END 0x0000555555555044 0x0000000000001044 Y
…
…
…
…
…
…
…
…
…
…
…
…
README for GNU development tools This directory contains various GNU compilers, assemblers, linkers, debuggers, etc., plus their support routines, definitions, and documentation. If you are receiving this as part of a GDB release, see the file gdb/README. If with a binutils release, see binutils/README; if with a libg++ release, see libg++/README, etc. That'll give you info about this package -- supported targets, how to use it, how to report bugs, etc. It is now possible to automatically configure and build a variety of tools with one command. To build all of the tools contained herein, run the ``configure'' script here, e.g.: ./configure make To install them (by default in /usr/local/bin, /usr/local/lib, etc), then do: make install (If the configure script can't determine your type of computer, give it the name as an argument, for instance ``./configure sun4''. You can use the script ``config.sub'' to test whether a name is recognized; if it is, config.sub translates it to a triplet specifying CPU, vendor, and OS.) If you have more than one compiler on your system, it is often best to explicitly set CC in the environment before running configure, and to also set CC when running make. For example (assuming sh/bash/ksh): CC=gcc ./configure make A similar example using csh: setenv CC gcc ./configure make Much of the code and documentation enclosed is copyright by the Free Software Foundation, Inc. See the file COPYING or COPYING.LIB in the various directories, for a description of the GNU General Public License terms under which you can copy the files. REPORTING BUGS: Again, see gdb/README, binutils/README, etc., for info on where and how to report problems.
Description
Languages
C
50.5%
Makefile
22.7%
Assembly
13.2%
C++
5.9%
Roff
1.5%
Other
5.6%