Commit Graph

112825 Commits

Author SHA1 Message Date
GDB Administrator
ab87a96bab Automatic date update in version.in 2023-02-02 00:00:44 +00:00
GDB Administrator
f3a27f0c3f Automatic date update in version.in 2023-02-01 00:01:03 +00:00
Nick Clifton
65dbb94214 Updated Swedish translation for the binutils sub-directory 2023-01-31 13:02:51 +00:00
Jan Beulich
27f59ec47a RISC-V: make C-extension JAL available again for (32-bit) assembly
Along with the normal JAL alias, the C-extension one should have been
moved as well by 839189bc93 ("RISC-V: re-arrange opcode table for
consistent alias handling"), for the assembler to actually be able to
use it where/when possible.

Since neither this nor any other compressed branch insn was being tested
so far, take the opportunity and introduce a new testcase covering those.
2023-01-31 09:49:32 +01:00
GDB Administrator
3bf9a43949 Automatic date update in version.in 2023-01-31 00:00:59 +00:00
GDB Administrator
376f26469f Automatic date update in version.in 2023-01-30 00:01:24 +00:00
GDB Administrator
e2ee5c1cf4 Automatic date update in version.in 2023-01-29 00:02:15 +00:00
GDB Administrator
5955845a07 Automatic date update in version.in 2023-01-28 00:02:03 +00:00
GDB Administrator
c1b591a3f7 Automatic date update in version.in 2023-01-27 00:01:35 +00:00
Vladimir Mezentsev
edd36b26f3 gprofng: PR30043 libgprofng.so.* are installed to a wrong location
gprofng/ChangeLog
2023-01-25  Vladimir Mezentsev  <vladimir.mezentsev@oracle.com>

	PR gprofng/30043
	PR gprofng/28972
	* src/Makefile.am: Use lib_LTLIBRARIES instead of pkglib_LTLIBRARIES.
	* src/Makefile.in: Rebuild.
2023-01-26 11:49:11 -08:00
GDB Administrator
abb1a617c7 Automatic date update in version.in 2023-01-26 00:01:12 +00:00
Vladimir Mezentsev
c6e269febb gprofng: PR29521 [docs] man pages are not in the release tarball
gprofng/ChangeLog
2023-01-20  Vladimir Mezentsev  <vladimir.mezentsev@oracle.com>

	PR gprofng/29521
	* configure.ac: Check if $MAKEINFO and $HELP2MAN are missing.
	* Makefile.am: Build doc if $MAKEINFO exists.
	* doc/gprofng.texi: Update documentation for gprofng.
	* doc/Makefile.am: Build gprofng.1.
	* src/Makefile.am: Move the build of gprofng.1 to doc/Makefile.am.
	* configure: Rebuild.
	* Makefile.in: Rebuild.
	* doc/Makefile.in: Rebuild.
	* src/Makefile.in: Rebuild.
2023-01-25 14:39:29 -08:00
GDB Administrator
6ff0b21822 Automatic date update in version.in 2023-01-25 00:01:32 +00:00
GDB Administrator
27dc715d82 Automatic date update in version.in 2023-01-24 00:01:26 +00:00
Nick Clifton
cca59642c9 Updated Swedish translation for the binutils sub-directory 2023-01-23 10:53:53 +00:00
GDB Administrator
94320fc7e1 Automatic date update in version.in 2023-01-23 00:01:06 +00:00
GDB Administrator
5898f97025 Automatic date update in version.in 2023-01-22 00:00:46 +00:00
GDB Administrator
80045a1932 Automatic date update in version.in 2023-01-21 00:00:55 +00:00
GDB Administrator
9c1671ab4b Automatic date update in version.in 2023-01-20 00:00:59 +00:00
Indu Bhagat
bcea253f5f toplevel: Makefile.def: add install-strip dependency on libsframe
As noted in PR libsframe/30014 - FTBFS: install-strip fails because
bfdlib relinks and fails to find libsframe, the install time
dependencies of libbfd need to be updated.

	PR libsframe/30014
	* Makefile.def: Reflect that libsframe needs to installed before
	libbfd.  Reorder a bit to better track libsframe dependencies.
	* Makefile.in: Regenerate.

(cherry picked from commit b8d21eb0cd)
2023-01-18 23:23:35 -08:00
GDB Administrator
ffb83e32fc Automatic date update in version.in 2023-01-19 00:01:26 +00:00
GDB Administrator
c8202bb28b Automatic date update in version.in 2023-01-18 00:01:11 +00:00
Nick Clifton
59706683fe Fix version number snafu in some configuration files: 2.40.00 should be 2.40 2023-01-17 12:02:56 +00:00
GDB Administrator
b4ca790f2e Automatic date update in version.in 2023-01-17 00:02:20 +00:00
Enze Li
f7c5db99b7 libctf: update regexp to allow makeinfo to build document
While trying to build gdb on latest openSUSE Tumbleweed, I noticed the
following warning,

 checking for makeinfo... makeinfo --split-size=5000000
 configure: WARNING:
 *** Makeinfo is too old. Info documentation will not be built.

then I checked the version of makeinfo, it said,
======
$ makeinfo --version
texi2any (GNU texinfo) 7.0.1

Copyright (C) 2022 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
======

After digging a little bit, it became quite obvious that a dot is
missing in regexp that makes it impossible to match versions higher than
7.0, and here's the solution:

-       | egrep 'texinfo[^0-9]*(6\.[3-9]|[7-9][0-9])' >/dev/null 2>&1; then
+       | egrep 'texinfo[^0-9]*(6\.[3-9]|[7-9]\.[0-9])' >/dev/null 2>&1; then

However, Eli pointed out that the solution above has another problem: it
will stop working when Texinfo 10.1 will be released.  Meanwhile, he
suggested to solve this problem permanently.  That is, we don't care
about the minor version for Texinfo > 6.9, we only care about the major
version.

In this way, the problem will be resolved permanently, thanks to Eli.

libctf/ChangeLog:

	* configure: Regenerated.
	* configure.ac: Update regexp to match versions higher than 7.0.
2023-01-16 23:23:52 +08:00
Nick Clifton
36795a207d Updated translations for the gas and binutils sub-directories 2023-01-16 10:44:44 +00:00
GDB Administrator
fb25c2afe5 Automatic date update in version.in 2023-01-16 00:01:23 +00:00
GDB Administrator
a2b1e3c0d1 Automatic date update in version.in 2023-01-15 00:01:21 +00:00
Nick Clifton
78eca0130f Re-enable development. Update version to 2.40.0 2023-01-14 15:34:17 +00:00
Nick Clifton
32778522c7 Fix snafu in version number. Regenerate files 2023-01-14 13:52:46 +00:00
Nick Clifton
c203a2e3a8 Set development and experimental to false. Update version number to 2.40. Add release markers. Regenerate files 2023-01-14 13:42:32 +00:00
GDB Administrator
44767ca811 Automatic date update in version.in 2023-01-14 00:00:52 +00:00
Nick Clifton
ea766c9dd6 Updated Romainian translation for the bfd sub-directory 2023-01-13 11:43:18 +00:00
GDB Administrator
b90d8cc85a Automatic date update in version.in 2023-01-13 00:01:17 +00:00
Hans-Peter Nilsson
fedaf87c95 ARM: Fix ld bloat introduced between binutils-2.38 and 2.39
Since commit 9833b7757d, "PR28824, relro security issues",
ELF_MAXPAGESIZE matters much more, with regards to layout of
the linked file.  That commit fixed an actual bug, but also
exposes a problem for targets were that value is too high.

For example, for ARM(32, a.k.a. "Aarch32") specifically
bfd_arch_arm, it's set to 64 KiB, making all Linux(/GNU)
targets pay an extra amount of up to 60 KiB of bloat in
DSO:s and executables.  This matters when there are many
such files, and where storage is expensive.

It's *mostly* bloat when using a Linux kernel, as ARM(32) is
a good example of an target where ELF_MAXPAGESIZE is set to
an extreme value for an obscure corner-case.  The ARM
(32-bit) kernel has 4 KiB pages, has had that value forever,
and can't be configured to any other value.  The use-case is
IIUC "Aarch32" emulation on an "Aarch64" (arm64) kernel, but
not just that, but a setup where the Linux page-size is
configured to something other than the *default* 4 KiB.  Not
sure there actually any such systems in use, again with
both Aarch32 compatibility support and a non-4KiB pagesize,
with all the warnings in the kernel config and requiring the
"EXPERT" level set on.

So, let's do like x86-64 in a2267dbfc9 "x86-64: Use only
one default max-page-size" and set ELF_MAXPAGESIZE to 4096.

bfd:
	* elf32-arm.c (ELF_MAXPAGESIZE): Always set to 0x1000.
(cherry picked from commit 1a26a53a0d)
2023-01-12 17:41:45 +01:00
Hans-Peter Nilsson
cd331e1d73 ld/testsuite: Adjust for ELF_MAXPAGESIZE 0x1000
Many tests reflect a setting of ELF_MAXPAGESIZE to 64 KiB.
With ELF_MAXPAGESIZE changed to 4 KiB, layout is sometimes
different and symbols end up in other places.  Avoid churn
and regexpification of old test patterns by passing the
max-page-size setting active at the time.

ld/testsuite:

	* testsuite/ld-arm/arm-elf.exp,
        testsuite/ld-arm/non-contiguous-arm2.d,
        testsuite/ld-arm/non-contiguous-arm3.d,
        testsuite/ld-arm/non-contiguous-arm5.d,
        testsuite/ld-arm/non-contiguous-arm6.d,
        testsuite/ld-arm/thumb-plt-got.d, testsuite/ld-arm/thumb-plt.d:
	Pass -z max-page-size=0x10000 explicitly to test that rely on
	that value in output-matching patterns.
(cherry picked from commit b305015577)
2023-01-12 17:41:08 +01:00
Nick Alcock
999e7ed7a2 libctf: ctf-link outdated input check faulty
This check has a pair of faults which, combined, can lead to memory
corruption.  Firstly, it assumes that the values of the ctf_link_inputs
hash are ctf_dict_t's: they are not, they are ctf_link_input_t's, a much
shorter structure.  So the flags check which is the core of this is
faulty (but happens, by chance, to give the right output on most
architectures, since usually we happen to get a 0 here, so the test that
checks this usually passes).  Worse, the warning that is emitted when
the test fails is added to the wrong dict -- it's added to the input
dict, whose warning list is never consumed, rendering the whole check
useless.  But the dict it adds to is still the wrong type, so we end up
overwriting something deep in memory (or, much more likely,
dereferencing a garbage pointer and crashing).

Fixing both reveals another problem: the link input is an *archive*
consisting of multiple members, so we have to consider whether to check
all of them for the outdated-func-info thing we are checking here.
However, no compiler exists that emits a mixture of members with this
flag on and members with it off, and the linker always reserializes (and
upgrades) such things when it sees them: so all members in a given
archive must have the same value of the flag, so we only need to check
one member per input archive.

libctf/
	PR libctf/29983
	* ctf-link.c (ctf_link_warn_outdated_inputs): Get the types of
        members of ctf_link_inputs right, fixing a possible spurious
        tesst failure / wild pointer deref / overwrite.  Emit the
        warning message into the right dict.
2023-01-12 15:23:51 +00:00
Nick Clifton
7145c3f610 Ensure that libbacktrace/allocfail.sh is not deleted when creating release tarballs.
* Makefile.am (CLEANFILES): Import patch from upstream to prevent
	allocafail.sh from being removed when running 'make clean'.
2023-01-12 13:37:59 +00:00
GDB Administrator
e888df8995 Automatic date update in version.in 2023-01-12 00:02:07 +00:00
Nick Clifton
3e307d538c Fix a potential illegal memory access in the BFD library when parsing a corrupt DWARF file.
PR 29988
	* dwarf2.c (read_indexed_address): Fix check for an out of range
	offset.
2023-01-11 12:13:46 +00:00
Jan Beulich
ad2021a0f7 gas/RISC-V: adjust assembler for opcode table re-ordering
PR gas/29940

With the single-operand JAL entry now sitting ahead of the two-operand
one, the parsing of a two-operand insn would first try to parse an 'a'-
style operand, resulting in the insertion of bogus (and otherwise
unused) undefined symbols in the symbol table, having register names.
Since 'a' is used as 1st operand only with J and JAL, and since JAL is
the only insn _also_ allowing for a register as 1st operand (and then
there being a 2nd one), special case this parsing aspect right there.

Reviewed-by: Palmer Dabbelt <palmer@rivosinc.com>
2023-01-11 10:35:54 +01:00
GDB Administrator
5cf8624d4d Automatic date update in version.in 2023-01-11 00:01:22 +00:00
Stefan Schulze Frielinghaus
38775ca9a7 IBM zSystems: Fix offset relative to static TLS
For local exec TLS relocations of the form foo@NTPOFF+x the addend was
ignored.

bfd/ChangeLog:

	* elf32-s390.c (elf_s390_relocate_section): Honor addend for
	R_390_TLS_LE32.
	* elf64-s390.c (elf_s390_relocate_section): Honor addend for
	R_390_TLS_LE64.

ld/ChangeLog:

	* testsuite/ld-s390/reloctlsle-1.d: New test.
	* testsuite/ld-s390/reloctlsle-1.s: New test.

(cherry picked from commit aefebe82dc)
2023-01-10 14:51:47 +01:00
GDB Administrator
ddf8d80aef Automatic date update in version.in 2023-01-10 00:01:55 +00:00
Indu Bhagat
b6250e0b72 sframe: fix the defined SFRAME_FRE_TYPE_*_LIMIT constants
An earlier commit 3f107464 defined the SFRAME_FRE_TYPE_*_LIMIT
constants.  These constants are used (by gas and libsframe) to pick an
SFrame FRE type based on the function size.  Those constants, however,
were buggy, causing the generated SFrame sections to be bloated as
SFRAME_FRE_TYPE_ADDR2/SFRAME_FRE_TYPE_ADDR4 got chosen more often than
necessary.

gas/
	* sframe-opt.c (sframe_estimate_size_before_relax): Use
	typecast.
	(sframe_convert_frag): Likewise.

libsframe/
	* sframe.c (sframe_calc_fre_type): Use a more appropriate type
	for argument.  Adjust the check for SFRAME_FRE_TYPE_ADDR4_LIMIT
	to keep it warning-free but meaningful.

include/
	* sframe-api.h (sframe_calc_fre_type): Use a more appropriate
	type for the argument.
	* sframe.h (SFRAME_FRE_TYPE_ADDR1_LIMIT): Correct the constant.
	(SFRAME_FRE_TYPE_ADDR2_LIMIT): Likewise.
	(SFRAME_FRE_TYPE_ADDR4_LIMIT): Likewise.

(cherry picked from commit 725a19bfd1)
2023-01-09 09:47:42 -08:00
Indu Bhagat
2ffa66fc9f libsframe: adjust an incorrect check in flip_sframe
When sframe_encoder_write needs to flip the buffer containing the SFrame
section before writing, it is not necessary that the SFrame FDES are in
the order of their sfde_func_start_fre_off.  On the contrary, SFrame
FDEs will be sorted in the order of their start address.  So, remove
this incorrect assumption which is basically assuming that the last
sfde_func_start_fre_off seen will help determine the end of the flipped
buffer.

The function now keeps track of the bytes_flipped and then compares it with
the expected value.  Also, added two more checks at appropriate places:
 - check that the SFrame FDE read is within bounds
 - check that the SFrame FRE read is within bounds

libsframe/

	* sframe.c (flip_sframe): Adjust an incorrect check.
	Add other checks to ensure reads are within the buffer size.

(cherry picked from commit cd9aea32cf)
2023-01-09 09:47:24 -08:00
Christophe Lyon
dcaa0ed8f6 Skip ld/pr23169 test on arm.
The test is already skipped on several targets (including AArch64)
because it's invalid.

	* testsuite/ld-ifunc/ifunc.exp: Skip pr23169 on arm.
2023-01-09 16:52:42 +01:00
Christophe Lyon
5d546b26ce Fix PR18841 ifunc relocation ordering
In order to get the ifunc relocs properly sorted the correct class
needs to be returned.  The code mimics what has been done for AArch64.

Fixes:
FAIL: Run pr18841 with libpr18841b.so
FAIL: Run pr18841 with libpr18841c.so
FAIL: Run pr18841 with libpr18841bn.so (-z now)
FAIL: Run pr18841 with libpr18841cn.so (-z now)

	bfd/
	PR ld/18841
	* elf32-arm.c (elf32_arm_reloc_type_class): Return
	reloc_class_ifunc for ifunc symbols.

	ld/testsuite/
	* ld-arm/ifunc-12.rd: Update relocations order.
	* ld-arm/ifunc-3.rd: Likewise.
	* ld-arm/ifunc-4.rd: Likewise.
2023-01-09 16:52:40 +01:00
Nick Clifton
417d329214 Updated transaltions for the gprof and binutils sub-directories 2023-01-09 10:23:27 +00:00
GDB Administrator
114a486049 Automatic date update in version.in 2023-01-09 00:02:09 +00:00