aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2022-12-21Updated Romanian translation for the BFD sub-directory.Nick Clifton2-1970/+2073
2022-12-21Fix an attempt to allocate an unreasonably large amount of memory when ↵Nick Clifton2-1/+9
parsing a corrupt ELF file. PR 29924 * objdump.c (load_specific_debug_section): Check for excessively large sections.
2022-12-21Keep the .drectve section when performing a relocateable link.Nick Clifton3-2/+9
PR 29900 * scripttempl/pe.sc: Keep the .drectve section when performing a relocateable link. * scripttempl/pep.sc: Likewise.
2022-12-21x86: rename CheckRegSize to CheckOperandSizeJan Beulich4-513/+513
While originally indeed used for register size checking only, the attribute has been used for memory operand size checking as well already for quite a while, with more such uses recently having been added.
2022-12-21gprofng/testsuite: restrict testing to native configurationsJan Beulich1-0/+7
The binaries involved in testing gprofng are native ones, and hence a cross build of binutils won't really test intended functionality. Since this testing takes quite a bit of time (typically more than running all of binutils, gas, and ld testsuites together), restrict the testing to native configurations only.
2022-12-21enable-non-contiguous-regions warningsAlan Modra18-66/+59
The warning about discarded sections in elf_link_input_bfd doesn't belong there since the code is dealing with symbols. Multiple symbols in a discarded section will result in multiple identical warnings about the section. Move the warning to a new function in ldlang.c. The patch also tidies the warning quoting of section and file names, consistently using `%pA' and `%pB'. I'm no stickler for one style of section and file name quoting, but they ought to be consistent within a warning, eg. see the first one fixed in ldlang.c, and when a warning is emitted for multiple targets they all ought to use exactly the same format string to reduce translation work. elf64-ppc.c loses the build_one_stub errors since we won't get there before hitting the fatal errors in size_one_stub. bfd/ * elflink.c (elf_link_input_bfd): Don't warn here about discarded sections. * elf32-arm.c (arm_build_one_stub): Use consistent style in --enable-non-contiguous-regions error. * elf32-csky.c (csky_build_one_stub): Likewise. * elf32-hppa.c (hppa_build_one_stub): Likewise. * elf32-m68hc11.c (m68hc11_elf_build_one_stub): Likewise. * elf32-m68hc12.c (m68hc12_elf_build_one_stub): Likewise. * elf32-metag.c (metag_build_one_stub): Likewise. * elf32-nios2.c (nios2_build_one_stub): Likewise. * elfnn-aarch64.c (aarch64_build_one_stub): Likewise. * xcofflink.c (xcoff_build_one_stub): Likewise. * elf64-ppc.c (ppc_size_one_stub): Likewise. (ppc_build_one_stub): Delete dead code. ld/ * ldlang.c (lang_add_section): Use consistent style in --enable-non-contiguous-regions warnings. (size_input_section): Likewise. (warn_non_contiguous_discards): New function. (lang_process): Call it. * testsuite/ld-arm/non-contiguous-arm.d: Update. * testsuite/ld-arm/non-contiguous-arm4.d: Update. * testsuite/ld-arm/non-contiguous-arm7.d: Add --enable-non-contiguous-regions-warnings. * testsuite/ld-arm/non-contiguous-arm7.err: New. * testsuite/ld-powerpc/non-contiguous-powerpc.d: Update. * testsuite/ld-powerpc/non-contiguous-powerpc64.d: Update.
2022-12-21PR29922, SHT_NOBITS section avoids section size sanity checkAlan Modra1-3/+9
PR 29922 * dwarf2.c (find_debug_info): Ignore sections without SEC_HAS_CONTENTS.
2022-12-21sim: fully merge sim_cpu_base into sim_cpuMike Frysinger1-26/+19
Now that all ports have migrated to the new framework, drop support for the old sim_cpu_base layout. There's a lot of noise here, so it's been split into a dedicated commit.
2022-12-21sim: enable common sim_cpu usage everywhereMike Frysinger29-66/+1
All ports should be migrated now. Drop the SIM_HAVE_COMMON_SIM_CPU knob and require it be used everywhere now.
2022-12-21sim: or1k: invert sim_cpu storageMike Frysinger5-30/+43
The cpu.h change is in generated cgen code, but that has been sent upstream too, so the next regen should include it automatically.
2022-12-21sim: m32r: invert sim_cpu storageMike Frysinger5-14/+10
The cpu*.h changes are in generated cgen code, but that has been sent upstream too, so the next regen should include it automatically.
2022-12-21sim: lm32: invert sim_cpu storageMike Frysinger3-12/+7
The cpu.h change is in generated cgen code, but that has been sent upstream too, so the next regen should include it automatically.
2022-12-21sim: iq2000: invert sim_cpu storageMike Frysinger3-11/+7
The cpu.h change is in generated cgen code, but that has been sent upstream too, so the next regen should include it automatically.
2022-12-21sim: frv: invert sim_cpu storageMike Frysinger3-23/+18
The cpu.h change is in generated cgen code, but that has been sent upstream too, so the next regen should include it automatically.
2022-12-21sim: cris: invert sim_cpu storageMike Frysinger6-239/+244
The cpu*.h changes are in generated cgen code, but that has been sent upstream too, so the next regen should include it automatically.
2022-12-21sim: bpf: invert sim_cpu storageMike Frysinger3-7/+13
The cpu.h change is in generated cgen code, but that has been sent upstream too, so the next regen should include it automatically.
2022-12-21sim: cgen: prep for inverting sim_cpu storageMike Frysinger2-0/+15
Some common cgen code changes to allow cgen ports to invert their sim_cpu storage one-by-one.
2022-12-21sim: riscv: invert sim_cpu storageMike Frysinger3-191/+258
2022-12-21sim: pru: invert sim_cpu storageMike Frysinger3-8/+31
2022-12-21sim: example-synacor: invert sim_cpu storageMike Frysinger3-37/+47
2022-12-21sim: h8300: invert sim_cpu storageMike Frysinger2-34/+36
2022-12-21sim: m68hc11: invert sim_cpu storageMike Frysinger10-354/+446
2022-12-21sim: mips: invert sim_cpu storageMike Frysinger2-73/+90
2022-12-21sim: v850: invert sim_cpu storageMike Frysinger3-20/+23
2022-12-21sim: mcore: invert sim_cpu storageMike Frysinger2-27/+41
2022-12-21sim: aarch64: invert sim_cpu storageMike Frysinger5-108/+152
2022-12-21sim: microblaze: invert sim_cpu storageMike Frysinger3-8/+8
2022-12-21sim: avr: invert sim_cpu storageMike Frysinger2-99/+108
2022-12-21sim: moxie: invert sim_cpu storageMike Frysinger2-14/+13
2022-12-21sim: msp430: invert sim_cpu storageMike Frysinger3-120/+106
2022-12-21sim: ft32: invert sim_cpu storageMike Frysinger3-95/+99
2022-12-21sim: bfin: invert sim_cpu storageMike Frysinger2-10/+5
2022-12-20sim: sim_cpu: invert sim_cpu storageMike Frysinger7-39/+45
Currently all ports have to declare sim_cpu themselves in their sim-main.h and then embed the common sim_cpu_base in it. This dynamic makes it impossible to share common object code among multiple ports because the core data structure is always different. Let's invert this relationship: common code declares sim_cpu, and the port uses the new arch_data field for its per-cpu state. This is the first in a series of changes: it adds a define to select between the old & new layouts, then converts all the ports that don't need custom state over to the new layout. This includes mn10300 that, while it defines custom fields in its cpu struct, never uses them.
2022-12-20sim: move register headers into sim/ namespace [PR sim/29869]Mike Frysinger39-24/+24
These headers define the register numbers for each port to implement the sim_fetch_register & sim_store_register interfaces. While gdb uses these, the APIs are part of the sim, not gdb. Move the headers out of the gdb/ include namespace and into sim/ instead.
2022-12-20sim: ppc: drop old dgen.c generatorMike Frysinger3-363/+6
The spreg.[ch] files live in the source tree now and are created with the dgen.py script, so we don't need this old tool anymore.
2022-12-20sim: ppc: move spreg.[ch] files to the source treeMike Frysinger5-0/+1608
Simplify the build by moving the generation of these files from build-time (via dgen.c that we have to compile & execute on the build system) to maintainer/release mode (via spreg-gen.py that we only ever execute when the spreg table actually changes). It speeds up the build process and makes it easier for us to reason about & review changes to the code generator. The tool is renamed from "dgen" because it's hardcoded to only generated spreg files. It isn't a generalized tool for creating lookup tables.
2022-12-21Automatic date update in version.inGDB Administrator1-1/+1
2022-12-20Fix install-strip targetHannes Domani1-2/+2
The libtool patch broke install-strip of gdb: /bin/sh ../../gdb/../mkinstalldirs /src/gdb/inst/share/gdb/python/gdb transformed_name=`t='s,y,y,'; \ echo gdb | sed -e "$t"` ; \ if test "x$transformed_name" = x; then \ transformed_name=gdb ; \ else \ true ; \ fi ; \ /bin/sh ../../gdb/../mkinstalldirs /src/gdb/inst/bin ; \ /bin/sh ./libtool --mode=install STRIPPROG='strip' /bin/sh /src/gdb/gdb.git/install-sh -c -s \ gdb \ /src/gdb/inst/bin/$transformed_name ; \ /bin/sh ../../gdb/../mkinstalldirs /src/gdb/inst/include/gdb ; \ /usr/bin/install -c -m 644 jit-reader.h /src/gdb/inst/include/gdb/jit-reader.h libtool: install: `/src/gdb/inst/bin/gdb' is not a directory libtool: install: Try `libtool --help --mode=install' for more information. Since INSTALL_PROGRAM_ENV is no longer at the beginning of the command, the gdb executable is not installed with install-strip.
2022-12-20bfd: Discard symbol regardless of warning flagTorbjörn SVENSSON5-5/+58
The discard of symbols should be performed whether the warning for the discard is enabled or not. Without this patch, ld would segfault in bfd_section_removed_from_list, called in the if-statement right after this block, as the argument isec->output_section can be NULL. Signed-off-by: Torbjörn SVENSSON <torbjorn.svensson@foss.st.com> Co-Authored-By: Yvan ROUX <yvan.roux@foss.st.com>
2022-12-20PR29915, bfdio.c does not compile with mingw.org's MinGWAlan Modra4-6/+22
PR 29915 * configure.ac: Add AC_CHECK_DECLS test ___lc_codepage_func. * configure: Regenerate. * config.in: Regenerate. * bfdio.c (___lc_codepage_func): Move declaration to.. (_bfd_real_fopen): ..here, and use !HAVE_DECL____LC_CODEPAGE_FUNC.
2022-12-20Re: x86: remove i386-opc.cAlan Modra1-1/+0
Regen opcodes/po/POTFILES.in
2022-12-19sim: ppc: change spreg switch table generation to compile-timeMike Frysinger4-15/+16
Simplify the generator by always outputting the switch tables, and leave the choice of whether to use them to the compiler via a -D flag.
2022-12-19sim: dv-core: add hw_detach_address method [PR sim/25211]Mike Frysinger2-13/+18
The core device has an attach address method as the root of the tree which calls out to the sim API. But it doesn't have a corresponding detach method which means we just crash if anything tries to detach itself from the core. In practice, the m68hc11 is the only model that actually tries to detach itself on the fly, so no one noticed earlier. With this in place, we can delete the existing detach code from the m68hc11 model since it defaults to "passthru" callback which will in turn call the dv-core detach, and they have the same behavior -- call the sim core API to detach from the address space. Bug: https://sourceware.org/PR25211
2022-12-19gprofng: PR29646 Various warningsVladimir Mezentsev10-13/+22
gprofng/ChangeLog 2022-12-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com> PR gprofng/29646 * common/core_pcbe.c: Fix missingReturn warning. * libcollector/iolib.c: Fix -Waddress warnings. * src/Settings.cc: Likewise. * src/checks.cc: Likewise. * libcollector/linetrace.c: Likewise. * libcollector/iotrace.c: Fix va_end_missing error. * libcollector/libcol_util.c: Fix uninitvar warning. * src/Command.cc: Fix arrayIndexOutOfBounds error. * src/Function.cc: Fix uninitStructMember warning. * src/ipc.cc: Fix -Wwrite-strings warnings.
2022-12-20Automatic date update in version.inGDB Administrator1-1/+1
2022-12-19Avoid compiler warning in dwarf-do-refreshTom Tromey2-1/+5
The Emacs 28 compiler warns about dwarf-mode.el: Warning (comp): dwarf-mode.el:180:32: Warning: Unused lexical argument `ignore' This is easily fixed by prepending "_" to the parameter's name. binutils/ChangeLog 2022-12-19 Tom Tromey <tromey@adacore.com> * dwarf-mode.el (dwarf-do-refresh): Avoid compiler warning.
2022-12-19Use bool in bpstatTom Tromey6-30/+31
This changes bpstat to use 'bool' rather than 'char', and updates the uses.
2022-12-19Use bool constants for value_print_optionsTom Tromey19-60/+60
This changes the uses of value_print_options to use 'true' and 'false' rather than integers.
2022-12-19Remove quick_symbol_functions::relocatedTom Tromey4-91/+4
quick_symbol_functions::relocated is only needed for psymtabs, and there it is only needed for Rust. However, because we've switched the DWARF reader away from psymtabs, this means there's no longer a need for this method at all.
2022-12-19Remove MI version 1Tom Tromey11-126/+11
MI version 1 is long since obsolete. Several years ago, I filed PR mi/23170 for this. I think it's finally time to remove this. Any users of MI 1 can and should upgrade to a newer version. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=23170