Merge remote-tracking branch 'up/master' into master-riscv64

Signed-off-by: David Abdurachmanov <david.abdurachmanov@gmail.com>
This commit is contained in:
David Abdurachmanov 2019-04-12 18:56:37 +02:00
commit daed0b2af2
Signed by: davidlt
GPG Key ID: 7108702C938B13C1
38 changed files with 577 additions and 852 deletions

2
.gitignore vendored
View File

@ -1,3 +1,3 @@
/gdb-libstdc++-v3-python-8.1.1-20180626.tar.xz
/v2.0.tar.gz
/gdb-8.2.50.20190219.tar.xz
/gdb-8.3.50.20190321.tar.xz

View File

@ -45,434 +45,426 @@ Patch011: gdb-6.3-inferior-notification-20050721.patch
#=fedoratest
Patch012: gdb-6.3-inheritancetest-20050726.patch
# Add readnever option
#=push
Patch013: gdb-6.3-readnever-20050907.patch
# Support TLS symbols (+`errno' suggestion if no pthread is found) (BZ 185337).
#=push+jan: It should be replaced by Infinity project.
Patch014: gdb-6.5-bz185337-resolve-tls-without-debuginfo-v2.patch
Patch013: gdb-6.5-bz185337-resolve-tls-without-debuginfo-v2.patch
# Fix TLS symbols resolving for shared libraries with a relative pathname.
# The testsuite needs `gdb-6.5-tls-of-separate-debuginfo.patch'.
#=fedoratest: One should recheck if it is really fixed upstream.
Patch015: gdb-6.5-sharedlibrary-path.patch
Patch014: gdb-6.5-sharedlibrary-path.patch
# Improved testsuite results by the testsuite provided by the courtesy of BEA.
#=fedoratest: For upstream it should be rewritten as a dejagnu test, the test of no "??" was useful.
Patch016: gdb-6.5-BEA-testsuite.patch
Patch015: gdb-6.5-BEA-testsuite.patch
# Testcase for deadlocking on last address space byte; for corrupted backtraces.
#=fedoratest
Patch017: gdb-6.5-last-address-space-byte-test.patch
Patch016: gdb-6.5-last-address-space-byte-test.patch
# Fix readline segfault on excessively long hand-typed lines.
#=fedoratest
Patch018: gdb-6.5-readline-long-line-crash-test.patch
Patch017: gdb-6.5-readline-long-line-crash-test.patch
# Fix bogus 0x0 unwind of the thread's topmost function clone(3) (BZ 216711).
#=fedora
Patch019: gdb-6.5-bz216711-clone-is-outermost.patch
Patch018: gdb-6.5-bz216711-clone-is-outermost.patch
# Test sideeffects of skipping ppc .so libs trampolines (BZ 218379).
#=fedoratest
Patch020: gdb-6.5-bz218379-ppc-solib-trampoline-test.patch
Patch019: gdb-6.5-bz218379-ppc-solib-trampoline-test.patch
# Fix lockup on trampoline vs. its function lookup; unreproducible (BZ 218379).
#=fedora
Patch021: gdb-6.5-bz218379-solib-trampoline-lookup-lock-fix.patch
Patch020: gdb-6.5-bz218379-solib-trampoline-lookup-lock-fix.patch
# Find symbols properly at their original (included) file (BZ 109921).
#=fedoratest
Patch022: gdb-6.5-bz109921-DW_AT_decl_file-test.patch
Patch021: gdb-6.5-bz109921-DW_AT_decl_file-test.patch
# Update PPC unwinding patches to their upstream variants (BZ 140532).
#=fedoratest
Patch023: gdb-6.3-bz140532-ppc-unwinding-test.patch
Patch022: gdb-6.3-bz140532-ppc-unwinding-test.patch
# Testcase for exec() from threaded program (BZ 202689).
#=fedoratest
Patch024: gdb-6.3-bz202689-exec-from-pthread-test.patch
Patch023: gdb-6.3-bz202689-exec-from-pthread-test.patch
# Testcase for PPC Power6/DFP instructions disassembly (BZ 230000).
#=fedoratest
Patch025: gdb-6.6-bz230000-power6-disassembly-test.patch
Patch024: gdb-6.6-bz230000-power6-disassembly-test.patch
# Allow running `/usr/bin/gcore' with provided but inaccessible tty (BZ 229517).
#=fedoratest
Patch026: gdb-6.6-bz229517-gcore-without-terminal.patch
Patch025: gdb-6.6-bz229517-gcore-without-terminal.patch
# Avoid too long timeouts on failing cases of "annota1.exp annota3.exp".
#=fedoratest
Patch027: gdb-6.6-testsuite-timeouts.patch
Patch026: gdb-6.6-testsuite-timeouts.patch
# Support for stepping over PPC atomic instruction sequences (BZ 237572).
#=fedoratest
Patch028: gdb-6.6-bz237572-ppc-atomic-sequence-test.patch
Patch027: gdb-6.6-bz237572-ppc-atomic-sequence-test.patch
# Make upstream `set scheduler-locking step' as default.
#=push+jan: How much is scheduler-locking relevant after non-stop?
Patch029: gdb-6.6-scheduler_locking-step-is-default.patch
Patch028: gdb-6.6-scheduler_locking-step-is-default.patch
# Test kernel VDSO decoding while attaching to an i386 process.
#=fedoratest
Patch030: gdb-6.3-attach-see-vdso-test.patch
Patch029: gdb-6.3-attach-see-vdso-test.patch
# Test leftover zombie process (BZ 243845).
#=fedoratest
Patch031: gdb-6.5-bz243845-stale-testing-zombie-test.patch
Patch030: gdb-6.5-bz243845-stale-testing-zombie-test.patch
# New locating of the matching binaries from the pure core file (build-id).
#=push+jan
Patch032: gdb-6.6-buildid-locate.patch
Patch031: gdb-6.6-buildid-locate.patch
# Fix loading of core files without build-ids but with build-ids in executables.
# Load strictly build-id-checked core files only if no executable is specified
# (Jan Kratochvil, RH BZ 1339862).
#=push+jan
Patch033: gdb-6.6-buildid-locate-solib-missing-ids.patch
Patch032: gdb-6.6-buildid-locate-solib-missing-ids.patch
#=push+jan
Patch034: gdb-6.6-buildid-locate-rpm.patch
Patch033: gdb-6.6-buildid-locate-rpm.patch
# Fix displaying of numeric char arrays as strings (BZ 224128).
#=fedoratest: But it is failing anyway, one should check the behavior more.
Patch035: gdb-6.7-charsign-test.patch
Patch034: gdb-6.7-charsign-test.patch
# Test PPC hiding of call-volatile parameter register.
#=fedoratest
Patch036: gdb-6.7-ppc-clobbered-registers-O2-test.patch
Patch035: gdb-6.7-ppc-clobbered-registers-O2-test.patch
# Testsuite fixes for more stable/comparable results.
#=fedoratest
Patch037: gdb-6.7-testsuite-stable-results.patch
Patch036: gdb-6.7-testsuite-stable-results.patch
# Test ia64 memory leaks of the code using libunwind.
#=fedoratest
Patch038: gdb-6.5-ia64-libunwind-leak-test.patch
Patch037: gdb-6.5-ia64-libunwind-leak-test.patch
# Test hiding unexpected breakpoints on intentional step commands.
#=fedoratest
Patch039: gdb-6.5-missed-trap-on-step-test.patch
Patch038: gdb-6.5-missed-trap-on-step-test.patch
# Test gcore memory and time requirements for large inferiors.
#=fedoratest
Patch040: gdb-6.5-gcore-buffer-limit-test.patch
Patch039: gdb-6.5-gcore-buffer-limit-test.patch
# Test GCORE for shmid 0 shared memory mappings.
#=fedoratest: But it is broken anyway, sometimes the case being tested is not reproducible.
Patch041: gdb-6.3-mapping-zero-inode-test.patch
Patch040: gdb-6.3-mapping-zero-inode-test.patch
# Test a crash on `focus cmd', `focus prev' commands.
#=fedoratest
Patch042: gdb-6.3-focus-cmd-prev-test.patch
Patch041: gdb-6.3-focus-cmd-prev-test.patch
# Test various forms of threads tracking across exec() (BZ 442765).
#=fedoratest
Patch043: gdb-6.8-bz442765-threaded-exec-test.patch
Patch042: gdb-6.8-bz442765-threaded-exec-test.patch
# Test a crash on libraries missing the .text section.
#=fedoratest
Patch044: gdb-6.5-section-num-fixup-test.patch
Patch043: gdb-6.5-section-num-fixup-test.patch
# Fix register assignments with no GDB stack frames (BZ 436037).
#=push+jan: This fix is incorrect.
Patch045: gdb-6.8-bz436037-reg-no-longer-active.patch
Patch044: gdb-6.8-bz436037-reg-no-longer-active.patch
# Fix resolving of variables at locations lists in prelinked libs (BZ 466901).
#=fedoratest
Patch046: gdb-6.8-bz466901-backtrace-full-prelinked.patch
Patch045: gdb-6.8-bz466901-backtrace-full-prelinked.patch
# New test for step-resume breakpoint placed in multiple threads at once.
#=fedoratest
Patch047: gdb-simultaneous-step-resume-breakpoint-test.patch
Patch046: gdb-simultaneous-step-resume-breakpoint-test.patch
# Fix GNU/Linux core open: Can't read pathname for load map: Input/output error.
# Fix regression of undisplayed missing shared libraries caused by a fix for.
#=fedoratest: It should be in glibc: libc-alpha: <20091004161706.GA27450@.*>
Patch048: gdb-core-open-vdso-warning.patch
Patch047: gdb-core-open-vdso-warning.patch
# Fix syscall restarts for amd64->i386 biarch.
#=push+jan
Patch049: gdb-x86_64-i386-syscall-restart.patch
Patch048: gdb-x86_64-i386-syscall-restart.patch
# Fix stepping with OMP parallel Fortran sections (BZ 533176).
#=push+jan: It requires some better DWARF annotations.
Patch050: gdb-bz533176-fortran-omp-step.patch
Patch049: gdb-bz533176-fortran-omp-step.patch
# Fix regression by python on ia64 due to stale current frame.
#=push+jan
Patch051: gdb-follow-child-stale-parent.patch
Patch050: gdb-follow-child-stale-parent.patch
# Workaround ccache making lineno non-zero for command-line definitions.
#=fedoratest: ccache is rarely used and it is even fixed now.
Patch052: gdb-ccache-workaround.patch
Patch051: gdb-ccache-workaround.patch
#=push+jan: May get obsoleted by Tom's unrelocated objfiles patch.
Patch053: gdb-archer-pie-addons.patch
Patch052: gdb-archer-pie-addons.patch
#=push+jan: Breakpoints disabling matching should not be based on address.
Patch054: gdb-archer-pie-addons-keep-disabled.patch
Patch053: gdb-archer-pie-addons-keep-disabled.patch
# Testcase for "Do not make up line information" fix by Daniel Jacobowitz.
#=fedoratest
Patch055: gdb-lineno-makeup-test.patch
Patch054: gdb-lineno-makeup-test.patch
# Test power7 ppc disassembly.
#=fedoratest
Patch056: gdb-ppc-power7-test.patch
Patch055: gdb-ppc-power7-test.patch
# Fix i386+x86_64 rwatch+awatch before run, regression against 6.8 (BZ 541866).
# Fix i386 rwatch+awatch before run (BZ 688788, on top of BZ 541866).
#=push+jan: It should be fixed properly instead.
Patch057: gdb-bz541866-rwatch-before-run.patch
Patch056: gdb-bz541866-rwatch-before-run.patch
# Workaround non-stop moribund locations exploited by kernel utrace (BZ 590623).
#=push+jan: Currently it is still not fully safe.
Patch058: gdb-moribund-utrace-workaround.patch
Patch057: gdb-moribund-utrace-workaround.patch
# Fix follow-exec for C++ programs (bugreported by Martin Stransky).
#=fedoratest
Patch059: gdb-archer-next-over-throw-cxx-exec.patch
Patch058: gdb-archer-next-over-throw-cxx-exec.patch
# Backport DWARF-4 support (BZ 601887, Tom Tromey).
#=fedoratest
Patch060: gdb-bz601887-dwarf4-rh-test.patch
Patch059: gdb-bz601887-dwarf4-rh-test.patch
#=push+jan
Patch061: gdb-6.6-buildid-locate-core-as-arg.patch
Patch060: gdb-6.6-buildid-locate-core-as-arg.patch
# Workaround librpm BZ 643031 due to its unexpected exit() calls (BZ 642879).
#=push+jan
Patch062: gdb-6.6-buildid-locate-rpm-librpm-workaround.patch
Patch061: gdb-6.6-buildid-locate-rpm-librpm-workaround.patch
# [delayed-symfile] Test a backtrace regression on CFIs without DIE (BZ 614604).
#=fedoratest
Patch063: gdb-test-bt-cfi-without-die.patch
Patch062: gdb-test-bt-cfi-without-die.patch
# Out of memory is just an error, not fatal (uninitialized VLS vars, BZ 568248).
#=push+jan: Inferior objects should be read in parts, then this patch gets obsoleted.
Patch064: gdb-bz568248-oom-is-error.patch
Patch063: gdb-bz568248-oom-is-error.patch
# Verify GDB Python built-in function gdb.solib_address exists (BZ # 634108).
#=fedoratest
Patch065: gdb-bz634108-solib_address.patch
Patch064: gdb-bz634108-solib_address.patch
# New test gdb.arch/x86_64-pid0-core.exp for kernel PID 0 cores (BZ 611435).
#=fedoratest
Patch066: gdb-test-pid0-core.patch
Patch065: gdb-test-pid0-core.patch
# [archer-tromey-delayed-symfile] New test gdb.dwarf2/dw2-aranges.exp.
#=fedoratest
Patch067: gdb-test-dw2-aranges.patch
Patch066: gdb-test-dw2-aranges.patch
# [archer-keiths-expr-cumulative+upstream] Import C++ testcases.
#=fedoratest
Patch068: gdb-test-expr-cumulative-archer.patch
Patch067: gdb-test-expr-cumulative-archer.patch
# Fix regressions on C++ names resolving (PR 11734, PR 12273, Keith Seitz).
#=fedoratest
Patch069: gdb-physname-pr11734-test.patch
Patch068: gdb-physname-pr11734-test.patch
# Fix regressions on C++ names resolving (PR 11734, PR 12273, Keith Seitz).
#=fedoratest
Patch070: gdb-physname-pr12273-test.patch
Patch069: gdb-physname-pr12273-test.patch
# Test GDB opcodes/ disassembly of Intel Ivy Bridge instructions (BZ 696890).
#=fedoratest
Patch071: gdb-test-ivy-bridge.patch
Patch070: gdb-test-ivy-bridge.patch
# Hack for proper PIE run of the testsuite.
#=fedoratest
Patch072: gdb-runtest-pie-override.patch
Patch071: gdb-runtest-pie-override.patch
# Print reasons for failed attach/spawn incl. SELinux deny_ptrace (BZ 786878).
#=push+jan
Patch073: gdb-attach-fail-reasons-5of5.patch
Patch072: gdb-attach-fail-reasons-5of5.patch
# Workaround PR libc/14166 for inferior calls of strstr.
#=fedoratest: Compatibility with RHELs (unchecked which ones).
Patch074: gdb-glibc-strstr-workaround.patch
Patch073: gdb-glibc-strstr-workaround.patch
# Include testcase for `Unable to see a variable inside a module (XLF)' (BZ 823789).
#=fedoratest
Patch075: gdb-rhel5.9-testcase-xlf-var-inside-mod.patch
Patch074: gdb-rhel5.9-testcase-xlf-var-inside-mod.patch
# Testcase for `Setting solib-absolute-prefix breaks vDSO' (BZ 818343).
#=fedoratest
Patch076: gdb-rhbz-818343-set-solib-absolute-prefix-testcase.patch
Patch075: gdb-rhbz-818343-set-solib-absolute-prefix-testcase.patch
# Fix `GDB cannot access struct member whose offset is larger than 256MB'
# (RH BZ 795424).
#=push
Patch077: gdb-rhbz795424-bitpos-20of25.patch
Patch076: gdb-rhbz795424-bitpos-20of25.patch
# Fix `GDB cannot access struct member whose offset is larger than 256MB'
# (RH BZ 795424).
#=push
Patch078: gdb-rhbz795424-bitpos-21of25.patch
Patch077: gdb-rhbz795424-bitpos-21of25.patch
# Fix `GDB cannot access struct member whose offset is larger than 256MB'
# (RH BZ 795424).
#=push
Patch079: gdb-rhbz795424-bitpos-22of25.patch
Patch078: gdb-rhbz795424-bitpos-22of25.patch
# Fix `GDB cannot access struct member whose offset is larger than 256MB'
# (RH BZ 795424).
#=push
Patch080: gdb-rhbz795424-bitpos-23of25.patch
Patch079: gdb-rhbz795424-bitpos-23of25.patch
# Fix `GDB cannot access struct member whose offset is larger than 256MB'
# (RH BZ 795424).
#=push
Patch081: gdb-rhbz795424-bitpos-25of25.patch
Patch080: gdb-rhbz795424-bitpos-25of25.patch
# Fix `GDB cannot access struct member whose offset is larger than 256MB'
# (RH BZ 795424).
#=push
Patch082: gdb-rhbz795424-bitpos-25of25-test.patch
Patch081: gdb-rhbz795424-bitpos-25of25-test.patch
# Fix `GDB cannot access struct member whose offset is larger than 256MB'
# (RH BZ 795424).
#=push
Patch083: gdb-rhbz795424-bitpos-lazyvalue.patch
Patch082: gdb-rhbz795424-bitpos-lazyvalue.patch
# Import regression test for `gdb/findvar.c:417: internal-error:
# read_var_value: Assertion `frame' failed.' (RH BZ 947564) from RHEL 6.5.
#=fedoratest
Patch084: gdb-rhbz947564-findvar-assertion-frame-failed-testcase.patch
Patch083: gdb-rhbz947564-findvar-assertion-frame-failed-testcase.patch
# Fix crash of -readnow /usr/lib/debug/usr/bin/gnatbind.debug (BZ 1069211).
#=push+jan
Patch085: gdb-gnat-dwarf-crash-3of3.patch
Patch084: gdb-gnat-dwarf-crash-3of3.patch
# Fix 'memory leak in infpy_read_memory()' (RH BZ 1007614)
#=fedoratest
Patch086: gdb-rhbz1007614-memleak-infpy_read_memory-test.patch
Patch085: gdb-rhbz1007614-memleak-infpy_read_memory-test.patch
# Fix 'gdb gives highly misleading error when debuginfo pkg is present,
# but not corresponding binary pkg' (RH BZ 981154).
#=push+jan
Patch087: gdb-6.6-buildid-locate-misleading-warning-missing-debuginfo-rhbz981154.patch
Patch086: gdb-6.6-buildid-locate-misleading-warning-missing-debuginfo-rhbz981154.patch
#=fedoratest
Patch088: gdb-archer-vla-tests.patch
Patch087: gdb-archer-vla-tests.patch
#=fedoratest
Patch089: gdb-vla-intel-tests.patch
Patch088: gdb-vla-intel-tests.patch
# Continue backtrace even if a frame filter throws an exception (Phil Muldoon).
#=push
Patch090: gdb-btrobust.patch
Patch089: gdb-btrobust.patch
# Display Fortran strings in backtraces.
#=fedoratest
Patch091: gdb-fortran-frame-string.patch
# Fix Python GIL with gdb.execute("continue") (Phil Muldoon, BZ 1116957).
#=push
Patch092: gdb-python-gil.patch
Patch090: gdb-fortran-frame-string.patch
# Testcase for '[SAP] Recursive dlopen causes SAP HANA installer to
# crash.' (RH BZ 1156192).
#=fedoratest
Patch093: gdb-rhbz1156192-recursive-dlopen-test.patch
Patch091: gdb-rhbz1156192-recursive-dlopen-test.patch
# Fix jit-reader.h for multi-lib.
#=push+jan
Patch094: gdb-jit-reader-multilib.patch
Patch092: gdb-jit-reader-multilib.patch
# Fix '`catch syscall' doesn't work for parent after `fork' is called'
# (Philippe Waroquiers, RH BZ 1149205).
#=fedoratest
Patch095: gdb-rhbz1149205-catch-syscall-after-fork-test.patch
Patch093: gdb-rhbz1149205-catch-syscall-after-fork-test.patch
# Fix 'backport GDB 7.4 fix to RHEL 6.6 GDB' [Original Sourceware bug
# description: 'C++ (and objc): Internal error on unqualified name
# re-set', PR 11657] (RH BZ 1186476).
#=fedoratest
Patch096: gdb-rhbz1186476-internal-error-unqualified-name-re-set-test.patch
Patch094: gdb-rhbz1186476-internal-error-unqualified-name-re-set-test.patch
# Test 'info type-printers' Python error (RH BZ 1350436).
#=fedoratest
Patch097: gdb-rhbz1350436-type-printers-error.patch
Patch095: gdb-rhbz1350436-type-printers-error.patch
# Fix '[ppc64] and [s390x] wrong prologue skip on -O2 -g code' (Jan
# Kratochvil, RH BZ 1084404).
#=fedoratest
Patch098: gdb-rhbz1084404-ppc64-s390x-wrong-prologue-skip-O2-g-3of3.patch
Patch096: gdb-rhbz1084404-ppc64-s390x-wrong-prologue-skip-O2-g-3of3.patch
# Never kill PID on: gdb exec PID (Jan Kratochvil, RH BZ 1219747).
#=push+jan
Patch099: gdb-bz1219747-attach-kills.patch
Patch097: gdb-bz1219747-attach-kills.patch
# Force libncursesw over libncurses to match the includes (RH BZ 1270534).
#=push+jan
Patch100: gdb-fedora-libncursesw.patch
Patch098: gdb-fedora-libncursesw.patch
# Test clflushopt instruction decode (for RH BZ 1262471).
#=fedoratest
Patch101: gdb-opcodes-clflushopt-test.patch
Patch099: gdb-opcodes-clflushopt-test.patch
# [rhel6] DTS backward Python compatibility API (BZ 1020004, Phil Muldoon).
#=fedora
Patch102: gdb-dts-rhel6-python-compat.patch
Patch100: gdb-dts-rhel6-python-compat.patch
# [SCL] Skip deprecated .gdb_index warning for Red Hat built files (BZ 953585).
#=push+jan
Patch103: gdb-6.6-buildid-locate-rpm-scl.patch
Patch101: gdb-6.6-buildid-locate-rpm-scl.patch
# Work around readline-6.2 incompatibility not asking for --more-- (BZ 701131).
#=fedora
Patch104: gdb-readline62-ask-more-rh.patch
Patch102: gdb-readline62-ask-more-rh.patch
# Make the GDB quit processing non-abortable to cleanup everything properly.
#=fedora: It was useful only after gdb-6.8-attach-signalled-detach-stopped.patch .
Patch105: gdb-6.8-quit-never-aborts.patch
Patch103: gdb-6.8-quit-never-aborts.patch
# [aarch64] Fix hardware watchpoints (RH BZ 1261564).
#=fedoratest
Patch106: gdb-rhbz1261564-aarch64-hw-watchpoint-test.patch
Patch104: gdb-rhbz1261564-aarch64-hw-watchpoint-test.patch
# Add messages suggesting more recent RHEL gdbserver (RH BZ 1321114).
#=fedora
Patch107: gdb-container-rh-pkg.patch
Patch105: gdb-container-rh-pkg.patch
# New test for Python "Cannot locate object file for block" (for RH BZ 1325795).
#=fedoratest
Patch108: gdb-rhbz1325795-framefilters-test.patch
Patch106: gdb-rhbz1325795-framefilters-test.patch
# [dts+el7] [x86*] Bundle linux_perf.h for libipt (RH BZ 1256513).
#=fedora
Patch109: gdb-linux_perf-bundle.patch
Patch107: gdb-linux_perf-bundle.patch
# Fix gdb-headless /usr/bin/ executables (BZ 1390251).
#=fedora
Patch110: gdb-libexec-add-index.patch
Patch108: gdb-libexec-add-index.patch
# New testcase for: Fix <tab>-completion crash (Gary Benson, RH BZ 1398387).
#=fedoratest
Patch111: gdb-rhbz1398387-tab-crash-test.patch
Patch109: gdb-rhbz1398387-tab-crash-test.patch
# [testsuite] Fix false selftest.exp FAIL from system readline-6.3+ (Patrick Palka).
#=fedoratest
Patch112: gdb-testsuite-readline63-sigint.patch
Patch110: gdb-testsuite-readline63-sigint.patch
# Python patches of: http://sourceware.org/gdb/wiki/ProjectArcher
#=push
Patch113: gdb-archer.patch
Patch111: gdb-archer.patch
# Revert upstream commit 469412dd9ccc4de5874fd3299b105833f36b34cd
Patch114: gdb-vla-intel-fix-print-char-array.patch
Patch112: gdb-vla-intel-fix-print-char-array.patch
# [s390x] Backport arch12 instructions decoding (RH BZ 1553104).
# =fedoratest
Patch115: gdb-rhbz1553104-s390x-arch12-test.patch
Patch113: gdb-rhbz1553104-s390x-arch12-test.patch
# This patch is needed to compile GDB after -Werror=narrowing has
# been enabled by default.
# Author: Sergio Durigan Junior.
Patch116: gdb-rhbz795424-bitpos-arrayview.patch
Patch114: gdb-rhbz795424-bitpos-arrayview.patch
# Same as gdb-rhbz795424-bitpos-20of25, but for RISC-V
# (which was added alter on)

View File

@ -112,6 +112,4 @@
%patch112 -p1
%patch113 -p1
%patch114 -p1
%patch115 -p1
%patch116 -p1
%patch130 -p1

View File

@ -1 +1 @@
c72e75a64030b0f6535a80481f37968ad55c333a
cc00a5d100973549bf5e4840937529633f4de1fa

View File

@ -10,7 +10,6 @@ gdb-6.3-test-movedir-20050125.patch
gdb-6.3-threaded-watchpoints2-20050225.patch
gdb-6.3-inferior-notification-20050721.patch
gdb-6.3-inheritancetest-20050726.patch
gdb-6.3-readnever-20050907.patch
gdb-6.5-bz185337-resolve-tls-without-debuginfo-v2.patch
gdb-6.5-sharedlibrary-path.patch
gdb-6.5-BEA-testsuite.patch
@ -89,7 +88,6 @@ gdb-archer-vla-tests.patch
gdb-vla-intel-tests.patch
gdb-btrobust.patch
gdb-fortran-frame-string.patch
gdb-python-gil.patch
gdb-rhbz1156192-recursive-dlopen-test.patch
gdb-jit-reader-multilib.patch
gdb-rhbz1149205-catch-syscall-after-fork-test.patch

View File

@ -1,35 +0,0 @@
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
From: Andrew Cagney <cagney@gnu.org>
Date: Fri, 27 Oct 2017 21:07:50 +0200
Subject: gdb-6.3-readnever-20050907.patch
;; Add readnever option
;;=push
2004-11-18 Andrew Cagney <cagney@gnu.org>
* dwarf2read.c: Include "top.c".
(dwarf2_has_info): Check for readnever_symbol_files.
* symfile.c (readnever_symbol_files): Define.
* top.h (readnever_symbol_files): Declare.
* main.c (captured_main): Add --readnever option.
(print_gdb_help): Ditto.
2004-11-18 Andrew Cagney <cagney@gnu.org>
* gdb.texinfo (File Options): Document --readnever.
Pushed upstream: https://sourceware.org/ml/gdb-cvs/2017-12/msg00007.html
diff --git a/gdb/gcore.in b/gdb/gcore.in
--- a/gdb/gcore.in
+++ b/gdb/gcore.in
@@ -97,7 +97,7 @@ for pid in "$@"
do
# `</dev/null' to avoid touching interactive terminal if it is
# available but not accessible as GDB would get stopped on SIGTTIN.
- "$binary_path/@GDB_TRANSFORM_NAME@" </dev/null --nx --batch \
+ "$binary_path/@GDB_TRANSFORM_NAME@" </dev/null --nx --batch --readnever \
-ex "set pagination off" -ex "set height 0" -ex "set width 0" \
"${dump_all_cmds[@]}" \
-ex "attach $pid" -ex "gcore $prefix.$pid" -ex detach -ex quit

View File

@ -44,7 +44,7 @@ glibc-debuginfo-2.7-2.x86_64: /usr/lib/debug/lib64/libc.so.6.debug:
diff --git a/gdb/printcmd.c b/gdb/printcmd.c
--- a/gdb/printcmd.c
+++ b/gdb/printcmd.c
@@ -1183,6 +1183,10 @@ print_command_1 (const char *exp, int voidprint)
@@ -1182,6 +1182,10 @@ print_command_1 (const char *exp, int voidprint)
if (exp && *exp)
{

View File

@ -169,7 +169,7 @@ diff --git a/gdb/amd64-tdep.c b/gdb/amd64-tdep.c
diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c
--- a/gdb/i386-tdep.c
+++ b/gdb/i386-tdep.c
@@ -8407,6 +8407,9 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
@@ -8420,6 +8420,9 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
tdep->xsave_xcr0_offset = -1;
@ -182,7 +182,7 @@ diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c
diff --git a/gdb/i386-tdep.h b/gdb/i386-tdep.h
--- a/gdb/i386-tdep.h
+++ b/gdb/i386-tdep.h
@@ -251,6 +251,9 @@ struct gdbarch_tdep
@@ -255,6 +255,9 @@ struct gdbarch_tdep
/* Regsets. */
const struct regset *fpregset;

View File

@ -119,7 +119,7 @@ diff --git a/gdb/exec.c b/gdb/exec.c
diff --git a/gdb/main.c b/gdb/main.c
--- a/gdb/main.c
+++ b/gdb/main.c
@@ -447,6 +447,35 @@ struct cmdarg
@@ -440,6 +440,35 @@ struct cmdarg
char *string;
};
@ -155,7 +155,7 @@ diff --git a/gdb/main.c b/gdb/main.c
static void
captured_main_1 (struct captured_main_args *context)
{
@@ -887,6 +916,8 @@ captured_main_1 (struct captured_main_args *context)
@@ -885,6 +914,8 @@ captured_main_1 (struct captured_main_args *context)
{
symarg = argv[optind];
execarg = argv[optind];
@ -164,7 +164,7 @@ diff --git a/gdb/main.c b/gdb/main.c
optind++;
}
@@ -1037,12 +1068,25 @@ captured_main_1 (struct captured_main_args *context)
@@ -1035,12 +1066,25 @@ captured_main_1 (struct captured_main_args *context)
&& symarg != NULL
&& strcmp (execarg, symarg) == 0)
{

View File

@ -25,17 +25,6 @@ Comments by Sergio Durigan Junior <sergiodj@redhat.com>:
NULL after it is free'd, otherwise the code below thinks that it is still
valid and doesn't print the necessary warning ("Try: yum install ...").
diff --git a/gdb/build-id.c b/gdb/build-id.c
--- a/gdb/build-id.c
+++ b/gdb/build-id.c
@@ -590,6 +590,7 @@ build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id,
if (separate_debug_file_debug)
printf_unfiltered (_(" no, unable to open.\n"));
+ filename.reset (nullptr);
continue;
}
diff --git a/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-install-warning.exp b/gdb/testsuite/gdb.base/rhbz981154-misleading-yum-install-warning.exp
new file mode 100644
--- /dev/null

View File

@ -9,7 +9,7 @@ Subject: gdb-6.6-buildid-locate-rpm-librpm-workaround.patch
diff --git a/gdb/build-id.c b/gdb/build-id.c
--- a/gdb/build-id.c
+++ b/gdb/build-id.c
@@ -672,6 +672,19 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return)
@@ -711,6 +711,19 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return)
#include <dlfcn.h>
#endif

View File

@ -12,7 +12,7 @@ https://bugzilla.redhat.com/show_bug.cgi?id=953585
diff --git a/gdb/build-id.c b/gdb/build-id.c
--- a/gdb/build-id.c
+++ b/gdb/build-id.c
@@ -707,7 +707,11 @@ static int missing_rpm_list_entries;
@@ -745,7 +745,11 @@ static int missing_rpm_list_entries;
/* Returns the count of newly added rpms. */
static int
@ -24,7 +24,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
{
static int rpm_init_done = 0;
rpmts ts;
@@ -814,7 +818,11 @@ missing_rpm_enlist (const char *filename)
@@ -852,7 +856,11 @@ missing_rpm_enlist (const char *filename)
mi = rpmtsInitIterator_p (ts, RPMTAG_BASENAMES, filename, 0);
if (mi != NULL)
{
@ -36,7 +36,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
{
Header h;
char *debuginfo, **slot, *s, *s2;
@@ -932,6 +940,37 @@ missing_rpm_enlist (const char *filename)
@@ -970,6 +978,37 @@ missing_rpm_enlist (const char *filename)
xfree (debuginfo);
count++;
}
@ -74,10 +74,10 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
rpmdbFreeIterator_p (mi);
}
@@ -942,6 +981,21 @@ missing_rpm_enlist (const char *filename)
@@ -979,6 +1018,20 @@ missing_rpm_enlist (const char *filename)
return count;
}
static int
+#ifdef GDB_INDEX_VERIFY_VENDOR
+missing_rpm_enlist (const char *filename)
+{
@ -90,16 +90,15 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+{
+ return missing_rpm_enlist_1 (filename, 1);
+}
+
+static int
+#endif
missing_rpm_list_compar (const char *const *ap, const char *const *bp)
+
static bool
missing_rpm_list_compar (const char *ap, const char *bp)
{
return strcoll (*ap, *bp);
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -3501,6 +3501,16 @@ read_gdb_index_from_buffer (struct objfile *objfile,
@@ -3500,6 +3500,16 @@ read_gdb_index_from_buffer (struct objfile *objfile,
"set use-deprecated-index-sections on". */
if (version < 6 && !deprecated_ok)
{
@ -116,7 +115,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
static int warning_printed = 0;
if (!warning_printed)
{
@@ -3512,6 +3522,10 @@ to use the section anyway."),
@@ -3511,6 +3521,10 @@ to use the section anyway."),
warning_printed = 1;
}
return 0;

View File

@ -244,7 +244,11 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
#define BUILD_ID_VERBOSE_NONE 0
#define BUILD_ID_VERBOSE_FILENAMES 1
@@ -660,8 +662,366 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return)
@@ -696,12 +698,362 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return)
return NULL;
result = xstrdup (bfd_get_filename (abfd));
- abfd.release ();
return result;
}
@ -513,10 +517,10 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+ return count;
+}
+
+static int
+missing_rpm_list_compar (const char *const *ap, const char *const *bp)
+static bool
+missing_rpm_list_compar (const char *ap, const char *bp)
+{
+ return strcoll (*ap, *bp);
+ return strcoll (ap, bp) < 0;
+}
+
+/* It returns a NULL-terminated array of strings needing to be FREEd. It may
@ -525,37 +529,32 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+static void
+missing_rpm_list_print (void)
+{
+ char **array, **array_iter;
+ struct missing_rpm *list_iter;
+ struct cleanup *cleanups;
+
+ if (missing_rpm_list_entries == 0)
+ return;
+
+ array = (char **) xmalloc (sizeof (*array) * missing_rpm_list_entries);
+ cleanups = make_cleanup (xfree, array);
+ std::vector<const char *> array (missing_rpm_list_entries);
+ size_t idx = 0;
+
+ array_iter = array;
+ for (list_iter = missing_rpm_list; list_iter != NULL;
+ list_iter = list_iter->next)
+ {
+ *array_iter++ = list_iter->rpm;
+ array[idx++] = list_iter->rpm;
+ }
+ gdb_assert (array_iter == array + missing_rpm_list_entries);
+ gdb_assert (idx == missing_rpm_list_entries);
+
+ qsort (array, missing_rpm_list_entries, sizeof (*array),
+ (int (*) (const void *, const void *)) missing_rpm_list_compar);
+ std::sort (array.begin (), array.end (), missing_rpm_list_compar);
+
+ printf_unfiltered (_("Missing separate debuginfos, use: %s"),
+#ifdef DNF_DEBUGINFO_INSTALL
+ "dnf "
+#endif
+ "debuginfo-install");
+ for (array_iter = array; array_iter < array + missing_rpm_list_entries;
+ array_iter++)
+ for (const char *el : array)
+ {
+ putchar_unfiltered (' ');
+ puts_unfiltered (*array_iter);
+ puts_unfiltered (el);
+ }
+ putchar_unfiltered ('\n');
+
@ -566,8 +565,6 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+ xfree (list_iter);
+ }
+ missing_rpm_list_entries = 0;
+
+ do_cleanups (cleanups);
+}
+
+static void
@ -612,7 +609,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
avoidance. */
struct missing_filepair
@@ -715,11 +1075,17 @@ missing_filepair_change (void)
@@ -755,11 +1107,17 @@ missing_filepair_change (void)
/* All their memory came just from missing_filepair_OBSTACK. */
missing_filepair_hash = NULL;
}
@ -630,7 +627,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
missing_filepair_change ();
}
@@ -786,14 +1152,39 @@ debug_print_missing (const char *binary, const char *debug)
@@ -826,14 +1184,39 @@ debug_print_missing (const char *binary, const char *debug)
*slot = missing_filepair;
@ -690,7 +687,7 @@ diff --git a/gdb/config.in b/gdb/config.in
/* Define to 1 if translation of program messages to the user's native
language is requested. */
#undef ENABLE_NLS
@@ -261,6 +264,9 @@
@@ -255,6 +258,9 @@
/* Define if Python 2.7 is being used. */
#undef HAVE_LIBPYTHON2_7
@ -1459,15 +1456,59 @@ diff --git a/gdb/configure.ac b/gdb/configure.ac
diff --git a/gdb/corelow.c b/gdb/corelow.c
--- a/gdb/corelow.c
+++ b/gdb/corelow.c
@@ -365,7 +365,7 @@ build_id_locate_exec (int from_tty)
@@ -330,10 +330,9 @@ static void
build_id_locate_exec (int from_tty)
{
CORE_ADDR at_entry;
- struct bfd_build_id *build_id;
- char *execfilename;
+ gdb::unique_xmalloc_ptr<struct bfd_build_id> build_id;
+ gdb::unique_xmalloc_ptr<char> execfilename;
char *build_id_filename;
- struct cleanup *back_to;
if (exec_bfd != NULL || symfile_objfile != NULL)
return;
@@ -341,10 +340,9 @@ build_id_locate_exec (int from_tty)
if (target_auxv_search (current_top_target (), AT_ENTRY, &at_entry) <= 0)
return;
- build_id = build_id_addr_get (at_entry);
+ build_id.reset (build_id_addr_get (at_entry));
if (build_id == NULL)
return;
- back_to = make_cleanup (xfree, build_id);
/* SYMFILE_OBJFILE should refer to the main executable (not only to its
separate debug info file). gcc44+ keeps .eh_frame only in the main
@@ -352,22 +350,19 @@ build_id_locate_exec (int from_tty)
file - such .eh_frame would not be found if SYMFILE_OBJFILE would refer
directly to the separate debug info file. */
- execfilename = build_id_to_filename (build_id, &build_id_filename);
- make_cleanup (xfree, build_id_filename);
+ execfilename.reset (build_id_to_filename (build_id.get (),
+ &build_id_filename));
if (execfilename != NULL)
{
- make_cleanup (xfree, execfilename);
- exec_file_attach (execfilename, from_tty);
- symbol_file_add_main (execfilename,
+ exec_file_attach (execfilename.get (), from_tty);
+ symbol_file_add_main (execfilename.get (),
symfile_add_flag (!from_tty ? 0 : SYMFILE_VERBOSE));
if (symfile_objfile != NULL)
symfile_objfile->flags |= OBJF_BUILD_ID_CORE_LOADED;
}
else
- debug_print_missing (_("the main executable file"), build_id_filename);
-
- do_cleanups (back_to);
+ debug_print_missing (BUILD_ID_MAIN_EXECUTABLE_FILENAME, build_id_filename);
do_cleanups (back_to);
/* No automatic SOLIB_ADD as the libraries would get read twice. */
}
diff --git a/gdb/event-top.c b/gdb/event-top.c
--- a/gdb/event-top.c
+++ b/gdb/event-top.c

View File

@ -14,7 +14,7 @@ https://bugzilla.redhat.com/show_bug.cgi?id=1339862
diff --git a/gdb/solib-svr4.c b/gdb/solib-svr4.c
--- a/gdb/solib-svr4.c
+++ b/gdb/solib-svr4.c
@@ -1347,14 +1347,27 @@ svr4_read_so_list (CORE_ADDR lm, CORE_ADDR prev_lm,
@@ -1348,14 +1348,27 @@ svr4_read_so_list (CORE_ADDR lm, CORE_ADDR prev_lm,
}
{
@ -44,7 +44,7 @@ diff --git a/gdb/solib-svr4.c b/gdb/solib-svr4.c
if (build_id != NULL)
{
char *name, *build_id_filename;
@@ -1369,23 +1382,7 @@ svr4_read_so_list (CORE_ADDR lm, CORE_ADDR prev_lm,
@@ -1370,23 +1383,7 @@ svr4_read_so_list (CORE_ADDR lm, CORE_ADDR prev_lm,
xfree (name);
}
else

View File

@ -436,7 +436,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
if (found == NULL)
warning (_("File \"%s\" has no build-id, file skipped"),
@@ -65,11 +463,47 @@ build_id_verify (bfd *abfd, size_t check_len, const bfd_byte *check)
@@ -65,62 +463,173 @@ build_id_verify (bfd *abfd, size_t check_len, const bfd_byte *check)
return retval;
}
@ -474,6 +474,160 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+ return retval;
+}
+
/* Helper for build_id_to_debug_bfd. LINK is a path to a potential
build-id-based separate debug file, potentially a symlink to the real file.
If the file exists and matches BUILD_ID, return a BFD reference to it. */
static gdb_bfd_ref_ptr
-build_id_to_debug_bfd_1 (const std::string &link, size_t build_id_len,
- const bfd_byte *build_id)
+build_id_to_debug_bfd_1 (const std::string &orig_link, size_t build_id_len,
+ const bfd_byte *build_id, char **link_return,
+ int add_debug_suffix)
{
+ gdb_bfd_ref_ptr ret_bfd = {};
+ std::string ret_link;
+
if (separate_debug_file_debug)
{
- printf_unfiltered (_(" Trying %s..."), link.c_str ());
+ printf_unfiltered (_(" Trying %s..."), orig_link.c_str ());
gdb_flush (gdb_stdout);
}
- /* lrealpath() is expensive even for the usually non-existent files. */
- gdb::unique_xmalloc_ptr<char> filename;
- if (access (link.c_str (), F_OK) == 0)
- filename.reset (lrealpath (link.c_str ()));
-
- if (filename == NULL)
+ for (unsigned seqno = 0;; seqno++)
{
- if (separate_debug_file_debug)
- printf_unfiltered (_(" no, unable to compute real path\n"));
+ std::string link = orig_link;
- return {};
- }
+ if (seqno > 0)
+ {
+ /* There can be multiple build-id symlinks pointing to real files
+ with the same build-id (such as hard links). Some of the real
+ files may not be installed. */
- /* We expect to be silent on the non-existing files. */
- gdb_bfd_ref_ptr debug_bfd = gdb_bfd_open (filename.get (), gnutarget, -1);
+ string_appendf (link, ".%u", seqno);
+ }
- if (debug_bfd == NULL)
- {
- if (separate_debug_file_debug)
- printf_unfiltered (_(" no, unable to open.\n"));
+ if (add_debug_suffix)
+ link += ".debug";
+
+ ret_link = link;
+
+ struct stat statbuf_trash;
+
+ /* `access' automatically dereferences LINK. */
+ if (lstat (link.c_str (), &statbuf_trash) != 0)
+ {
+ /* Stop increasing SEQNO. */
+ break;
+ }
+
+ /* lrealpath() is expensive even for the usually non-existent files. */
+ gdb::unique_xmalloc_ptr<char> filename;
+
+ if (access (link.c_str (), F_OK) == 0)
+ filename.reset (lrealpath (link.c_str ()));
+
+ if (filename == NULL)
+ {
+ if (separate_debug_file_debug)
+ printf_unfiltered (_(" no, unable to compute real path\n"));
+
+ continue;
+ }
+
+ /* We expect to be silent on the non-existing files. */
+ gdb_bfd_ref_ptr debug_bfd = gdb_bfd_open (filename.get (), gnutarget, -1);
+
+ if (debug_bfd == NULL)
+ {
+ if (separate_debug_file_debug)
+ printf_unfiltered (_(" no, unable to open.\n"));
+
+ continue;
+ }
+
+ if (!build_id_verify (debug_bfd.get(), build_id_len, build_id))
+ {
+ if (separate_debug_file_debug)
+ printf_unfiltered (_(" no, build-id does not match.\n"));
+
+ continue;
+ }
- return {};
+ ret_bfd = debug_bfd;
+ break;
}
- if (!build_id_verify (debug_bfd.get(), build_id_len, build_id))
+ std::string link_all;
+
+ if (ret_bfd != NULL)
{
if (separate_debug_file_debug)
- printf_unfiltered (_(" no, build-id does not match.\n"));
+ printf_unfiltered (_(" yes!\n"));
+ }
+ else
+ {
+ /* If none of the real files is found report as missing file
+ always the non-.%u-suffixed file. */
+ std::string link0 = orig_link;
+
+ if (add_debug_suffix)
+ link0 += ".debug";
+
+ /* If the symlink has target request to install the target.
+ BASE-debuginfo.rpm contains the symlink but BASE.rpm may be missing.
+ https://bugzilla.redhat.com/show_bug.cgi?id=981154 */
+ std::string link0_resolved (link_resolve (link0.c_str (), 0));
- return {};
+ if (link_all.empty ())
+ link_all = link0_resolved;
+ else
+ {
+ /* Use whitespace instead of DIRNAME_SEPARATOR to be compatible with
+ its possible use as an argument for installation command. */
+ link_all += " " + link0_resolved;
+ }
}
- if (separate_debug_file_debug)
- printf_unfiltered (_(" yes!\n"));
+ if (link_return != NULL)
+ {
+ if (ret_bfd != NULL)
+ {
+ *link_return = xstrdup (ret_link.c_str ());
+ }
+ else
+ {
+ *link_return = xstrdup (link_all.c_str ());
+ }
+ }
- return debug_bfd;
+ return ret_bfd;
}
/* See build-id.h. */
gdb_bfd_ref_ptr
@ -481,23 +635,9 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id,
+ char **link_return, int add_debug_suffix)
{
+ std::string link, link_all;
gdb_bfd_ref_ptr abfd;
/* Keep backward compatibility so that DEBUG_FILE_DIRECTORY being "" will
@@ -82,86 +516,319 @@ build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id)
{
const gdb_byte *data = build_id;
size_t size = build_id_len;
+ unsigned seqno;
+ struct stat statbuf_trash;
+ std::string link0;
+ gdb::unique_xmalloc_ptr<char> filename;
- std::string link = debugdir.get ();
+ link = debugdir.get ();
link += "/.build-id/";
cause "/.build-id/..." lookups. */
@@ -143,16 +652,16 @@ build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id)
if (size > 0)
{
size--;
@ -512,140 +652,25 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
- link += ".debug";
-
if (separate_debug_file_debug)
gdb_bfd_ref_ptr debug_bfd
- = build_id_to_debug_bfd_1 (link, build_id_len, build_id);
+ = build_id_to_debug_bfd_1 (link, build_id_len, build_id,
+ link_return, add_debug_suffix);
if (debug_bfd != NULL)
return debug_bfd;
@@ -166,7 +675,8 @@ build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id)
if (strcmp (gdb_sysroot, TARGET_SYSROOT_PREFIX) != 0)
{
printf_unfiltered (_(" Trying %s..."), link.c_str ());
gdb_flush (gdb_stdout);
link = gdb_sysroot + link;
- debug_bfd = build_id_to_debug_bfd_1 (link, build_id_len, build_id);
+ debug_bfd = build_id_to_debug_bfd_1 (link, build_id_len, build_id,
+ link_return, add_debug_suffix);
if (debug_bfd != NULL)
return debug_bfd;
}
- /* lrealpath() is expensive even for the usually non-existent files. */
- gdb::unique_xmalloc_ptr<char> filename;
- if (access (link.c_str (), F_OK) == 0)
- filename.reset (lrealpath (link.c_str ()));
-
- if (filename == NULL)
+ for (seqno = 0;; seqno++)
{
- if (separate_debug_file_debug)
- printf_unfiltered (_(" no, unable to compute real path\n"));
+ if (seqno)
+ {
+ /* There can be multiple build-id symlinks pointing to real files
+ with the same build-id (such as hard links). Some of the real
+ files may not be installed. */
+
+ string_appendf (link, ".%u", seqno);
+ }
+
+ if (add_debug_suffix)
+ link += ".debug";
+
+ if (!seqno)
+ {
+ /* If none of the real files is found report as missing file
+ always the non-.%u-suffixed file. */
+ link0 = link;
+ }
+
+ /* `access' automatically dereferences LINK. */
+ if (lstat (link.c_str (), &statbuf_trash) != 0)
+ {
+ /* Stop increasing SEQNO. */
+ break;
+ }
+
+ /* lrealpath() is expensive even for the usually non-existent files. */
+ if (access (link.c_str (), F_OK) == 0)
+ filename.reset (lrealpath (link.c_str ()));
+
+ if (filename == NULL)
+ {
+ if (separate_debug_file_debug)
+ printf_unfiltered (_(" no, unable to compute real path\n"));
+
+ continue;
+ }
+
+ /* We expect to be silent on the non-existing files. */
+ abfd = gdb_bfd_open (filename.get (), gnutarget, -1);
+
+ if (abfd == NULL)
+ {
+ if (separate_debug_file_debug)
+ printf_unfiltered (_(" no, unable to open.\n"));
+
+ continue;
+ }
+
+ if (build_id_verify (abfd.get(), build_id_len, build_id))
+ {
+ if (separate_debug_file_debug)
+ printf_unfiltered (_(" yes!\n"));
+
+ break;
+ }
+ else
+ {
+ if (separate_debug_file_debug)
+ printf_unfiltered (_(" no, build-id does not match.\n"));
+ }
+
+ abfd.release ();
+
+ filename.reset (nullptr);
+ }
- continue;
+ if (filename != NULL)
+ {
+ /* LINK_ALL is not used below in this non-NULL FILENAME case. */
+ break;
}
- /* We expect to be silent on the non-existing files. */
- abfd = gdb_bfd_open (filename.get (), gnutarget, -1);
+ /* If the symlink has target request to install the target.
+ BASE-debuginfo.rpm contains the symlink but BASE.rpm may be missing.
+ https://bugzilla.redhat.com/show_bug.cgi?id=981154 */
+ std::string link0_resolved (link_resolve (link0.c_str (), 0));
- if (abfd == NULL)
+ if (link_all.empty ())
+ link_all = link0_resolved;
+ else
{
- if (separate_debug_file_debug)
- printf_unfiltered (_(" no, unable to open.\n"));
-
- continue;
+ /* Use whitespace instead of DIRNAME_SEPARATOR to be compatible with
+ its possible use as an argument for installation command. */
+ link_all += " " + link0_resolved;
}
+ }
- if (build_id_verify (abfd.get(), build_id_len, build_id))
+ if (link_return != NULL)
+ {
+ if (abfd != NULL)
{
- if (separate_debug_file_debug)
- printf_unfiltered (_(" yes!\n"));
-
- break;
+ *link_return = xstrdup (link.c_str ());
}
else
{
- if (separate_debug_file_debug)
- printf_unfiltered (_(" no, build-id does not match.\n"));
+ *link_return = xstrdup (link_all.c_str ());
}
-
- abfd.release ();
}
return abfd;
@@ -175,22 +685,190 @@ build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id)
return {};
}
+char *
@ -838,7 +863,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
/* Prevent looping on a stripped .debug file. */
if (abfd != NULL
&& filename_cmp (bfd_get_filename (abfd.get ()),
@@ -174,3 +841,21 @@ find_separate_debug_file_by_buildid (struct objfile *objfile)
@@ -203,3 +881,21 @@ find_separate_debug_file_by_buildid (struct objfile *objfile)
return std::string ();
}
@ -902,7 +927,7 @@ diff --git a/gdb/build-id.h b/gdb/build-id.h
diff --git a/gdb/coffread.c b/gdb/coffread.c
--- a/gdb/coffread.c
+++ b/gdb/coffread.c
@@ -732,7 +732,8 @@ coff_symfile_read (struct objfile *objfile, symfile_add_flags symfile_flags)
@@ -720,7 +720,8 @@ coff_symfile_read (struct objfile *objfile, symfile_add_flags symfile_flags)
/* Try to add separate debug file if no symbols table found. */
if (!objfile_has_partial_symbols (objfile))
{
@ -996,7 +1021,7 @@ diff --git a/gdb/corelow.c b/gdb/corelow.c
post_create_inferior (target, from_tty);
/* Now go through the target stack looking for threads since there
@@ -1063,4 +1123,11 @@ void
@@ -1061,4 +1121,11 @@ void
_initialize_corelow (void)
{
add_target (core_target_info, core_target_open, filename_completer);
@ -1054,7 +1079,7 @@ diff --git a/gdb/dwarf-index-cache.c b/gdb/dwarf-index-cache.c
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -2727,7 +2727,7 @@ dwarf2_get_dwz_file (struct dwarf2_per_objfile *dwarf2_per_objfile)
@@ -2726,7 +2726,7 @@ dwarf2_get_dwz_file (struct dwarf2_per_objfile *dwarf2_per_objfile)
}
if (dwz_bfd == NULL)
@ -1063,7 +1088,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
if (dwz_bfd == NULL)
error (_("could not find '.gnu_debugaltlink' file for %s"),
@@ -6237,7 +6237,7 @@ get_gdb_index_contents_from_section (objfile *obj, T *section_owner)
@@ -6236,7 +6236,7 @@ get_gdb_index_contents_from_section (objfile *obj, T *section_owner)
static gdb::array_view<const gdb_byte>
get_gdb_index_contents_from_cache (objfile *obj, dwarf2_per_objfile *dwarf2_obj)
{
@ -1072,7 +1097,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
if (build_id == nullptr)
return {};
@@ -6250,7 +6250,7 @@ get_gdb_index_contents_from_cache (objfile *obj, dwarf2_per_objfile *dwarf2_obj)
@@ -6249,7 +6249,7 @@ get_gdb_index_contents_from_cache (objfile *obj, dwarf2_per_objfile *dwarf2_obj)
static gdb::array_view<const gdb_byte>
get_gdb_index_contents_from_cache_dwz (objfile *obj, dwz_file *dwz)
{
@ -1109,7 +1134,7 @@ diff --git a/gdb/elfread.c b/gdb/elfread.c
diff --git a/gdb/objfiles.h b/gdb/objfiles.h
--- a/gdb/objfiles.h
+++ b/gdb/objfiles.h
@@ -554,6 +554,10 @@ struct objfile
@@ -553,6 +553,10 @@ struct objfile
htab_t static_links {};
};
@ -1152,7 +1177,7 @@ diff --git a/gdb/solib-svr4.c b/gdb/solib-svr4.c
static struct link_map_offsets *svr4_fetch_link_map_offsets (void);
static int svr4_have_link_map_offsets (void);
@@ -1345,9 +1346,51 @@ svr4_read_so_list (CORE_ADDR lm, CORE_ADDR prev_lm,
@@ -1346,9 +1347,51 @@ svr4_read_so_list (CORE_ADDR lm, CORE_ADDR prev_lm,
continue;
}

View File

@ -9,7 +9,7 @@ Subject: gdb-6.6-scheduler_locking-step-is-default.patch
diff --git a/gdb/infrun.c b/gdb/infrun.c
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -2075,7 +2075,7 @@ static const char *const scheduler_enums[] = {
@@ -2065,7 +2065,7 @@ static const char *const scheduler_enums[] = {
schedlock_replay,
NULL
};

View File

@ -8,7 +8,7 @@ Subject: gdb-archer-pie-addons-keep-disabled.patch
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -15441,6 +15441,50 @@ static struct cmd_list_element *enablebreaklist = NULL;
@@ -15451,6 +15451,50 @@ static struct cmd_list_element *enablebreaklist = NULL;
cmd_list_element *commands_cmd_element = nullptr;
@ -75,7 +75,7 @@ diff --git a/gdb/breakpoint.h b/gdb/breakpoint.h
diff --git a/gdb/objfiles.c b/gdb/objfiles.c
--- a/gdb/objfiles.c
+++ b/gdb/objfiles.c
@@ -875,6 +875,11 @@ objfile_relocate1 (struct objfile *objfile,
@@ -849,6 +849,11 @@ objfile_relocate1 (struct objfile *objfile,
obj_section_addr (s));
}

View File

@ -112,7 +112,7 @@ diff --git a/gdb/main.c b/gdb/main.c
#include "source.h"
#include "cli/cli-cmds.h"
#include "objfiles.h"
@@ -477,7 +478,7 @@ exec_or_core_file_attach (const char *filename, int from_tty)
@@ -470,7 +471,7 @@ exec_or_core_file_attach (const char *filename, int from_tty)
}
static void
@ -121,7 +121,7 @@ diff --git a/gdb/main.c b/gdb/main.c
{
int argc = context->argc;
char **argv = context->argv;
@@ -697,10 +698,14 @@ captured_main_1 (struct captured_main_args *context)
@@ -690,10 +691,14 @@ captured_main_1 (struct captured_main_args *context)
{"args", no_argument, &set_args, 1},
{"l", required_argument, 0, 'l'},
{"return-child-result", no_argument, &return_child_result, 1},
@ -137,7 +137,7 @@ diff --git a/gdb/main.c b/gdb/main.c
{
int option_index;
@@ -718,6 +723,9 @@ captured_main_1 (struct captured_main_args *context)
@@ -711,6 +716,9 @@ captured_main_1 (struct captured_main_args *context)
case 0:
/* Long option that just sets a flag. */
break;
@ -147,7 +147,7 @@ diff --git a/gdb/main.c b/gdb/main.c
case OPT_SE:
symarg = optarg;
execarg = optarg;
@@ -892,7 +900,31 @@ captured_main_1 (struct captured_main_args *context)
@@ -890,7 +898,31 @@ captured_main_1 (struct captured_main_args *context)
/* Now that gdb_init has created the initial inferior, we're in
position to set args for that inferior. */
@ -180,7 +180,7 @@ diff --git a/gdb/main.c b/gdb/main.c
{
/* The remaining options are the command-line options for the
inferior. The first one is the sym/exec file, and the rest
@@ -1193,7 +1225,8 @@ captured_main_1 (struct captured_main_args *context)
@@ -1191,7 +1223,8 @@ captured_main_1 (struct captured_main_args *context)
/* Read in the old history after all the command files have been
read. */
@ -190,7 +190,7 @@ diff --git a/gdb/main.c b/gdb/main.c
if (batch_flag)
{
@@ -1209,24 +1242,37 @@ static void
@@ -1207,24 +1240,37 @@ static void
captured_main (void *data)
{
struct captured_main_args *context = (struct captured_main_args *) data;
@ -241,7 +241,7 @@ diff --git a/gdb/main.c b/gdb/main.c
}
/* No exit -- exit is through quit_command. */
}
@@ -1269,6 +1315,12 @@ print_gdb_help (struct ui_file *stream)
@@ -1267,6 +1313,12 @@ print_gdb_help (struct ui_file *stream)
fputs_unfiltered (_("\
This is the GNU debugger. Usage:\n\n\
gdb [options] [executable-file [core-file or process-id]]\n\
@ -254,7 +254,7 @@ diff --git a/gdb/main.c b/gdb/main.c
gdb [options] --args executable-file [inferior-arguments ...]\n\n\
"), stream);
fputs_unfiltered (_("\
@@ -1314,6 +1366,13 @@ Output and user interface control:\n\n\
@@ -1312,6 +1364,13 @@ Output and user interface control:\n\n\
#endif
fputs_unfiltered (_("\
--dbx DBX compatibility mode.\n\
@ -362,19 +362,6 @@ new file mode 100644
+ return wanted == found
+
+InScope ()
diff --git a/gdb/python/python-internal.h b/gdb/python/python-internal.h
--- a/gdb/python/python-internal.h
+++ b/gdb/python/python-internal.h
@@ -711,6 +711,9 @@ private:
PyThreadState *m_save;
};
+struct cleanup *ensure_python_env (struct gdbarch *gdbarch,
+ const struct language_defn *language);
+
extern struct gdbarch *python_gdbarch;
extern const struct language_defn *python_language;
diff --git a/gdb/python/python.c b/gdb/python/python.c
--- a/gdb/python/python.c
+++ b/gdb/python/python.c
@ -387,37 +374,7 @@ diff --git a/gdb/python/python.c b/gdb/python/python.c
#include "target.h"
#include "gdbthread.h"
#include "interps.h"
@@ -235,6 +237,29 @@ gdbpy_enter::~gdbpy_enter ()
restore_active_ext_lang (m_previous_active);
}
+static void
+restore_python_env (void *p)
+{
+ gdbpy_enter *env = (gdbpy_enter *) p;
+
+ delete env;
+}
+
+/* Called before entering the Python interpreter to install the
+ current language and architecture to be used for Python values.
+ Also set the active extension language for GDB so that SIGINT's
+ are directed our way, and if necessary install the right SIGINT
+ handler. */
+
+struct cleanup *
+ensure_python_env (struct gdbarch *gdbarch,
+ const struct language_defn *language)
+{
+ gdbpy_enter *env = new gdbpy_enter (gdbarch, language);
+
+ return make_cleanup (restore_python_env, env);
+}
+
/* Set the quit flag. */
static void
@@ -1315,6 +1340,92 @@ gdbpy_print_stack_or_quit ()
@@ -1283,6 +1285,94 @@ gdbpy_print_stack_or_quit ()
@ -461,7 +418,9 @@ diff --git a/gdb/python/python.c b/gdb/python/python.c
+ FILE *input;
+
+ /* We never free this, since we plan to exit at the end. */
+ ensure_python_env (get_current_arch (), current_language);
+ gdbpy_enter *env = new gdbpy_enter (get_current_arch (), current_language);
+ /* "Use" env, to suppress GCC warnings. */
+ (void) env;
+
+ running_python_script = 1;
+
@ -510,7 +469,7 @@ diff --git a/gdb/python/python.c b/gdb/python/python.c
/* Return a sequence holding all the Progspaces. */
static PyObject *
@@ -1969,6 +2080,8 @@ PyMethodDef python_GdbMethods[] =
@@ -1935,6 +2025,8 @@ PyMethodDef python_GdbMethods[] =
Evaluate command, a string, as a gdb CLI command. Optionally returns\n\
a Python String containing the output of the command if to_string is\n\
set to True." },
@ -564,8 +523,8 @@ diff --git a/gdb/testsuite/gdb.python/py-value.exp b/gdb/testsuite/gdb.python/py
# Regression test for invalid subscript operations. The bug was that
# the type of the value was not being checked before allowing a
# subscript operation to proceed.
@@ -540,6 +549,7 @@ if ![runto_main] then {
test_value_in_inferior
@@ -585,6 +594,7 @@ test_value_in_inferior
test_value_from_buffer
test_inferior_function_call
test_value_after_death
+test_cast_regression
@ -575,30 +534,11 @@ diff --git a/gdb/testsuite/gdb.python/py-value.exp b/gdb/testsuite/gdb.python/py
diff --git a/gdb/varobj.c b/gdb/varobj.c
--- a/gdb/varobj.c
+++ b/gdb/varobj.c
@@ -217,6 +217,14 @@ is_root_p (const struct varobj *var)
@@ -217,7 +217,6 @@ is_root_p (const struct varobj *var)
}
#ifdef HAVE_PYTHON
+/* Helper function to install a Python environment suitable for
+ use during operations on VAR. */
+struct cleanup *
+varobj_ensure_python_env (const struct varobj *var)
+{
+ return ensure_python_env (var->root->exp->gdbarch,
+ var->root->exp->language_defn);
+}
-
/* See python-internal.h. */
gdbpy_enter_varobj::gdbpy_enter_varobj (const struct varobj *var)
diff --git a/gdb/varobj.h b/gdb/varobj.h
--- a/gdb/varobj.h
+++ b/gdb/varobj.h
@@ -328,6 +328,8 @@ extern bool varobj_has_more (const struct varobj *var, int to);
extern bool varobj_is_dynamic_p (const struct varobj *var);
+extern struct cleanup *varobj_ensure_python_env (const struct varobj *var);
+
extern bool varobj_default_value_is_changeable_p (const struct varobj *var);
extern bool varobj_value_is_changeable_p (const struct varobj *var);
: gdbpy_enter (var->root->exp->gdbarch, var->root->exp->language_defn)

View File

@ -45,7 +45,7 @@ gdb/gdbserver/
diff --git a/gdb/config.in b/gdb/config.in
--- a/gdb/config.in
+++ b/gdb/config.in
@@ -267,6 +267,9 @@
@@ -261,6 +261,9 @@
/* Define if librpm library is being used. */
#undef HAVE_LIBRPM
@ -55,7 +55,7 @@ diff --git a/gdb/config.in b/gdb/config.in
/* Define to 1 if you have the <libunwind-ia64.h> header file. */
#undef HAVE_LIBUNWIND_IA64_H
@@ -390,6 +393,9 @@
@@ -384,6 +387,9 @@
/* Define to 1 if you have the `scm_new_smob' function. */
#undef HAVE_SCM_NEW_SMOB
@ -68,7 +68,7 @@ diff --git a/gdb/config.in b/gdb/config.in
diff --git a/gdb/configure b/gdb/configure
--- a/gdb/configure
+++ b/gdb/configure
@@ -15874,6 +15874,64 @@ cat >>confdefs.h <<_ACEOF
@@ -15790,6 +15790,64 @@ cat >>confdefs.h <<_ACEOF
_ACEOF
@ -136,7 +136,7 @@ diff --git a/gdb/configure b/gdb/configure
diff --git a/gdb/configure.ac b/gdb/configure.ac
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -2032,6 +2032,10 @@ case $host_os in
@@ -2020,6 +2020,10 @@ case $host_os in
esac
AC_DEFINE_UNQUOTED(GDBINIT,"$gdbinit",[The .gdbinit filename.])
@ -276,7 +276,7 @@ diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
--- a/gdb/linux-nat.c
+++ b/gdb/linux-nat.c
@@ -1099,7 +1099,17 @@ linux_nat_target::create_inferior (const char *exec_file,
@@ -1098,7 +1098,17 @@ linux_nat_target::create_inferior (const char *exec_file,
/* Make sure we report all signals during startup. */
pass_signals ({});

View File

@ -80,7 +80,7 @@ gdb/testsuite/ChangeLog
diff --git a/gdb/main.c b/gdb/main.c
--- a/gdb/main.c
+++ b/gdb/main.c
@@ -1123,7 +1123,10 @@ captured_main_1 (struct captured_main_args *context)
@@ -1121,7 +1121,10 @@ captured_main_1 (struct captured_main_args *context)
{
ret = catch_command_errors (attach_command, pid_or_core_arg,
!batch_flag);

View File

@ -30,7 +30,7 @@ debugging problem of GOMP outside of the scope of this Bug.
diff --git a/gdb/infrun.c b/gdb/infrun.c
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -6510,6 +6510,16 @@ process_event_stop_test (struct execution_control_state *ecs)
@@ -6492,6 +6492,16 @@ process_event_stop_test (struct execution_control_state *ecs)
if (ecs->event_thread->control.step_over_calls == STEP_OVER_ALL)
{
@ -47,7 +47,7 @@ diff --git a/gdb/infrun.c b/gdb/infrun.c
/* We're doing a "next".
Normal (forward) execution: set a breakpoint at the
@@ -6543,6 +6553,7 @@ process_event_stop_test (struct execution_control_state *ecs)
@@ -6525,6 +6535,7 @@ process_event_stop_test (struct execution_control_state *ecs)
keep_going (ecs);
return;

View File

@ -10,7 +10,7 @@ Subject: gdb-bz541866-rwatch-before-run.patch
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -8773,7 +8773,7 @@ init_breakpoint_sal (struct breakpoint *b, struct gdbarch *gdbarch,
@@ -8783,7 +8783,7 @@ init_breakpoint_sal (struct breakpoint *b, struct gdbarch *gdbarch,
int enabled, int internal, unsigned flags,
int display_canonical)
{
@ -19,7 +19,7 @@ diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
if (type == bp_hardware_breakpoint)
{
@@ -14271,7 +14271,7 @@ enable_breakpoint_disp (struct breakpoint *bpt, enum bpdisp disposition,
@@ -14281,7 +14281,7 @@ enable_breakpoint_disp (struct breakpoint *bpt, enum bpdisp disposition,
if (bpt->type == bp_hardware_breakpoint)
{

View File

@ -53,7 +53,7 @@ gdb/
diff --git a/gdb/utils.c b/gdb/utils.c
--- a/gdb/utils.c
+++ b/gdb/utils.c
@@ -721,13 +721,11 @@ malloc_failure (long size)
@@ -692,13 +692,11 @@ malloc_failure (long size)
{
if (size > 0)
{

View File

@ -9,7 +9,7 @@ Subject: gdb-container-rh-pkg.patch
diff --git a/gdb/remote.c b/gdb/remote.c
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -13966,7 +13966,17 @@ remote_target::pid_to_exec_file (int pid)
@@ -13922,7 +13922,17 @@ remote_target::pid_to_exec_file (int pid)
char *annex = NULL;
if (packet_support (PACKET_qXfer_exec_file) != PACKET_ENABLE)

View File

@ -24,7 +24,7 @@ unwinders try to access it, breaking:
diff --git a/gdb/infrun.c b/gdb/infrun.c
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -754,6 +754,9 @@ follow_fork (void)
@@ -755,6 +755,9 @@ follow_fork (void)
}
else
{

View File

@ -42,7 +42,7 @@ gdb/
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -10588,6 +10588,13 @@ private:
@@ -10587,6 +10587,13 @@ private:
static void
process_die (struct die_info *die, struct dwarf2_cu *cu)
{
@ -59,8 +59,8 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
diff --git a/gdb/infrun.c b/gdb/infrun.c
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -609,6 +609,13 @@ holding the child stopped. Try \"set detach-on-fork\" or \
target_pid_to_str (process_ptid));
@@ -610,6 +610,13 @@ holding the child stopped. Try \"set detach-on-fork\" or \
target_pid_to_str (process_ptid).c_str ());
}
+#ifdef NEED_DETACH_SIGSTOP
@ -89,7 +89,7 @@ diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
static unsigned int debug_linux_nat;
static void
show_debug_linux_nat (struct ui_file *file, int from_tty,
@@ -1037,6 +1043,9 @@ linux_nat_post_attach_wait (ptid_t ptid, int *signalled)
@@ -1036,6 +1042,9 @@ linux_nat_post_attach_wait (ptid_t ptid, int *signalled)
if (debug_linux_nat)
fprintf_unfiltered (gdb_stdlog,
"LNPAW: Attaching to a stopped process\n");
@ -99,7 +99,7 @@ diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
/* The process is definitely stopped. It is in a job control
stop, unless the kernel predates the TASK_STOPPED /
@@ -1369,6 +1378,25 @@ get_detach_signal (struct lwp_info *lp)
@@ -1368,6 +1377,25 @@ get_detach_signal (struct lwp_info *lp)
return gdb_signal_to_host (signo);
}
@ -151,9 +151,9 @@ diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
+
+#endif
if (resume_many)
iterate_over_lwps (ptid, linux_nat_resume_callback, lp);
@@ -3763,6 +3805,10 @@ linux_nat_target::mourn_inferior ()
iterate_over_lwps (ptid, [=] (struct lwp_info *info)
{
@@ -3777,6 +3819,10 @@ linux_nat_target::mourn_inferior ()
/* Let the arch-specific native code know this process is gone. */
linux_target->low_forget_process (pid);

View File

@ -9,7 +9,7 @@ Subject: gdb-linux_perf-bundle.patch
diff --git a/gdb/configure b/gdb/configure
--- a/gdb/configure
+++ b/gdb/configure
@@ -12113,7 +12113,7 @@ else
@@ -12029,7 +12029,7 @@ else
#include <linux/perf_event.h>
#ifndef PERF_ATTR_SIZE_VER5
@ -21,7 +21,7 @@ diff --git a/gdb/configure b/gdb/configure
diff --git a/gdb/configure.ac b/gdb/configure.ac
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -1481,7 +1481,7 @@ else
@@ -1469,7 +1469,7 @@ else
AC_PREPROC_IFELSE([AC_LANG_SOURCE([[
#include <linux/perf_event.h>
#ifndef PERF_ATTR_SIZE_VER5

View File

@ -14,7 +14,7 @@ Bug in FSF GDB exploited by the ptrace-on-utrace interaction.
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -11929,6 +11929,8 @@ update_global_location_list (enum ugll_insert_mode insert_mode)
@@ -11939,6 +11939,8 @@ update_global_location_list (enum ugll_insert_mode insert_mode)
traps we can no longer explain. */
old_loc->events_till_retirement = 3 * (thread_count () + 1);

View File

@ -1,243 +0,0 @@
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
From: Fedora GDB patches <invalid@email.com>
Date: Fri, 27 Oct 2017 21:07:50 +0200
Subject: gdb-python-gil.patch
;; Fix Python GIL with gdb.execute("continue") (Phil Muldoon, BZ 1116957).
;;=push
diff --git a/gdb/doc/python.texi b/gdb/doc/python.texi
--- a/gdb/doc/python.texi
+++ b/gdb/doc/python.texi
@@ -234,6 +234,14 @@ returned as a string. The default is @code{False}, in which case the
return value is @code{None}. If @var{to_string} is @code{True}, the
@value{GDBN} virtual terminal will be temporarily set to unlimited width
and height, and its pagination will be disabled; @pxref{Screen Size}.
+
+The @var{release_gil} flag specifies whether @value{GDBN} ought to
+release the Python GIL before executing the command. This is useful
+in multi-threaded Python programs where by default the Python
+interpreter will acquire the GIL and lock other threads from
+executing. After the command has completed executing in @value{GDBN}
+the Python GIL is reacquired. This flag must be a boolean value. If
+omitted, it defaults to @code{False}.
@end defun
@findex gdb.breakpoints
diff --git a/gdb/python/python-internal.h b/gdb/python/python-internal.h
--- a/gdb/python/python-internal.h
+++ b/gdb/python/python-internal.h
@@ -137,6 +137,8 @@ typedef int Py_ssize_t;
#define PyGILState_Release(ARG) ((void)(ARG))
#define PyEval_InitThreads()
#define PyThreadState_Swap(ARG) ((void)(ARG))
+#define PyEval_SaveThread() ((void)(ARG))
+#define PyEval_RestoreThread(ARG) ((void)(ARG))
#define PyEval_ReleaseLock()
#endif
diff --git a/gdb/python/python.c b/gdb/python/python.c
--- a/gdb/python/python.c
+++ b/gdb/python/python.c
@@ -544,12 +544,16 @@ execute_gdb_command (PyObject *self, PyObject *args, PyObject *kw)
{
const char *arg;
PyObject *from_tty_obj = NULL, *to_string_obj = NULL;
- int from_tty, to_string;
- static const char *keywords[] = { "command", "from_tty", "to_string", NULL };
+ int from_tty, to_string, release_gil;
+ static const char *keywords[] = {"command", "from_tty", "to_string", "release_gil", NULL };
+ PyObject *release_gil_obj = NULL;
+ /* Initialize it just to avoid a GCC false warning. */
+ PyThreadState *state = NULL;
- if (!gdb_PyArg_ParseTupleAndKeywords (args, kw, "s|O!O!", keywords, &arg,
+ if (!gdb_PyArg_ParseTupleAndKeywords (args, kw, "s|O!O!O!", keywords, &arg,
&PyBool_Type, &from_tty_obj,
- &PyBool_Type, &to_string_obj))
+ &PyBool_Type, &to_string_obj,
+ &PyBool_Type, &release_gil_obj))
return NULL;
from_tty = 0;
@@ -570,6 +574,15 @@ execute_gdb_command (PyObject *self, PyObject *args, PyObject *kw)
to_string = cmp;
}
+ release_gil = 0;
+ if (release_gil_obj)
+ {
+ int cmp = PyObject_IsTrue (release_gil_obj);
+ if (cmp < 0)
+ return NULL;
+ release_gil = cmp;
+ }
+
std::string to_string_res;
scoped_restore preventer = prevent_dont_repeat ();
@@ -594,6 +607,13 @@ execute_gdb_command (PyObject *self, PyObject *args, PyObject *kw)
counted_command_line lines = read_command_lines_1 (reader, 1, nullptr);
+ /* In the case of long running GDB commands, allow the user to
+ release the Python GIL acquired by Python. Restore the GIL
+ after the command has completed before handing back to
+ Python. */
+ if (release_gil)
+ state = PyEval_SaveThread();
+
{
scoped_restore save_async = make_scoped_restore (&current_ui->async,
0);
@@ -612,12 +632,24 @@ execute_gdb_command (PyObject *self, PyObject *args, PyObject *kw)
execute_control_commands (lines.get (), from_tty);
}
+ /* Reacquire the GIL if it was released earlier. */
+ if (release_gil)
+ PyEval_RestoreThread (state);
+
/* Do any commands attached to breakpoint we stopped at. */
bpstat_do_actions ();
}
CATCH (except, RETURN_MASK_ALL)
{
- GDB_PY_HANDLE_EXCEPTION (except);
+ if (except.reason < 0)
+ {
+ /* Reacquire the GIL if it was released earlier. */
+ if (release_gil)
+ PyEval_RestoreThread (state);
+
+ gdbpy_convert_exception (except);
+ return NULL;
+ }
}
END_CATCH
diff --git a/gdb/testsuite/gdb.python/py-gil-mthread.c b/gdb/testsuite/gdb.python/py-gil-mthread.c
new file mode 100644
--- /dev/null
+++ b/gdb/testsuite/gdb.python/py-gil-mthread.c
@@ -0,0 +1,13 @@
+#include <stdio.h>
+#include <unistd.h>
+
+int
+main (void)
+{
+ int i;
+ for (i = 0; i < 10; i++)
+ {
+ sleep (1); /* break-here */
+ printf ("Sleeping %d\n", i);
+ }
+}
diff --git a/gdb/testsuite/gdb.python/py-gil-mthread.exp b/gdb/testsuite/gdb.python/py-gil-mthread.exp
new file mode 100644
--- /dev/null
+++ b/gdb/testsuite/gdb.python/py-gil-mthread.exp
@@ -0,0 +1,69 @@
+# Copyright (C) 2014 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+standard_testfile .c .py
+set executable $testfile
+
+if { [prepare_for_testing $testfile.exp $executable $srcfile] } {
+ return -1
+}
+
+# Skip all tests if Python scripting is not enabled.
+if { [skip_python_tests] } { continue }
+
+if ![runto_main] {
+ return -1
+}
+
+gdb_breakpoint $srcfile:[gdb_get_line_number "break-here"] temporary
+gdb_continue_to_breakpoint "break-here" ".* break-here .*"
+
+set test "response"
+set timeout 60
+set sleeping_last -1
+set hello_last 0
+set minimal 5
+gdb_test_multiple "python exec (open ('$srcdir/$subdir/$srcfile2').read ())" $test {
+ -re "Error: unable to start thread\r\n" {
+ fail $test
+ # Not $gdb_prompt-synced!
+ }
+ -re "Sleeping (\[0-9\]+)\r\n" {
+ set n $expect_out(1,string)
+ if { $sleeping_last + 1 != $n } {
+ fail $test
+ } else {
+ set sleeping_last $n
+ if { $sleeping_last >= $minimal && $hello_last >= $minimal } {
+ pass $test
+ } else {
+ exp_continue
+ }
+ }
+ }
+ -re "Hello \\( (\[0-9\]+) \\)\r\n" {
+ set n $expect_out(1,string)
+ if { $hello_last + 1 != $n } {
+ fail $test
+ } else {
+ set hello_last $n
+ if { $sleeping_last >= $minimal && $hello_last >= $minimal } {
+ pass $test
+ } else {
+ exp_continue
+ }
+ }
+ }
+}
diff --git a/gdb/testsuite/gdb.python/py-gil-mthread.py b/gdb/testsuite/gdb.python/py-gil-mthread.py
new file mode 100644
--- /dev/null
+++ b/gdb/testsuite/gdb.python/py-gil-mthread.py
@@ -0,0 +1,28 @@
+try:
+ import thread
+except:
+ import _thread
+import time
+import gdb
+
+# Define a function for the thread
+def print_thread_hello():
+ count = 0
+ while count < 10:
+ time.sleep(1)
+ count += 1
+ print ("Hello ( %d )" % count)
+
+# Create a threads a continue
+try:
+ thread.start_new_thread (print_thread_hello, ())
+ gdb.execute ("continue", release_gil=True)
+except:
+ try:
+ _thread.start_new_thread (print_thread_hello, ())
+ gdb.execute ("continue", release_gil=True)
+ except:
+ print ("Error: unable to start thread")
+
+while 1:
+ pass

View File

@ -665,7 +665,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
val = value_cast (value_type (component), val);
@@ -4445,7 +4446,7 @@ ensure_lval (struct value *val)
@@ -4447,7 +4448,7 @@ ensure_lval (struct value *val)
if (VALUE_LVAL (val) == not_lval
|| VALUE_LVAL (val) == lval_internalvar)
{
@ -674,7 +674,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
const CORE_ADDR addr =
value_as_long (value_allocate_space_in_inferior (len));
@@ -4529,7 +4530,7 @@ static CORE_ADDR
@@ -4531,7 +4532,7 @@ static CORE_ADDR
value_pointer (struct value *value, struct type *type)
{
struct gdbarch *gdbarch = get_type_arch (type);
@ -683,7 +683,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
gdb_byte *buf = (gdb_byte *) alloca (len);
CORE_ADDR addr;
@@ -6642,7 +6643,7 @@ value_tag_from_contents_and_address (struct type *type,
@@ -6644,7 +6645,7 @@ value_tag_from_contents_and_address (struct type *type,
const gdb_byte *valaddr,
CORE_ADDR address)
{
@ -692,7 +692,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
struct type *tag_type;
if (find_struct_field ("_tag", type, 0, &tag_type, &tag_byte_offset,
@@ -7135,7 +7136,7 @@ ada_in_variant (LONGEST val, struct type *type, int field_num)
@@ -7137,7 +7138,7 @@ ada_in_variant (LONGEST val, struct type *type, int field_num)
only in that it can handle packed values of arbitrary type. */
static struct value *
@ -701,7 +701,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
struct type *arg_type)
{
struct type *type;
@@ -7147,7 +7148,7 @@ ada_value_primitive_field (struct value *arg1, int offset, int fieldno,
@@ -7149,7 +7150,7 @@ ada_value_primitive_field (struct value *arg1, int offset, int fieldno,
if (TYPE_FIELD_BITSIZE (arg_type, fieldno) != 0)
{
@ -710,7 +710,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
int bit_size = TYPE_FIELD_BITSIZE (arg_type, fieldno);
return ada_value_primitive_packed_val (arg1, value_contents (arg1),
@@ -7224,9 +7225,9 @@ ada_value_primitive_field (struct value *arg1, int offset, int fieldno,
@@ -7226,9 +7227,9 @@ ada_value_primitive_field (struct value *arg1, int offset, int fieldno,
Returns 1 if found, 0 otherwise. */
static int
@ -722,7 +722,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
int *index_p)
{
int i;
@@ -7245,8 +7246,8 @@ find_struct_field (const char *name, struct type *type, int offset,
@@ -7247,8 +7248,8 @@ find_struct_field (const char *name, struct type *type, int offset,
for (i = 0; i < TYPE_NFIELDS (type); i += 1)
{
@ -733,7 +733,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
const char *t_field_name = TYPE_FIELD_NAME (type, i);
if (t_field_name == NULL)
@@ -7348,7 +7349,7 @@ num_visible_fields (struct type *type)
@@ -7350,7 +7351,7 @@ num_visible_fields (struct type *type)
long explanation in find_struct_field's function documentation. */
static struct value *
@ -742,7 +742,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
struct type *type)
{
int i;
@@ -7396,7 +7397,7 @@ ada_search_struct_field (const char *name, struct value *arg, int offset,
@@ -7398,7 +7399,7 @@ ada_search_struct_field (const char *name, struct value *arg, int offset,
int j;
struct type *field_type = ada_check_typedef (TYPE_FIELD_TYPE (type,
i));
@ -751,7 +751,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
for (j = 0; j < TYPE_NFIELDS (field_type); j += 1)
{
@@ -7428,8 +7429,8 @@ ada_search_struct_field (const char *name, struct value *arg, int offset,
@@ -7430,8 +7431,8 @@ ada_search_struct_field (const char *name, struct value *arg, int offset,
return NULL;
}
@ -762,7 +762,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
/* Return field #INDEX in ARG, where the index is that returned by
@@ -7438,7 +7439,7 @@ static struct value *ada_index_struct_field_1 (int *, struct value *,
@@ -7440,7 +7441,7 @@ static struct value *ada_index_struct_field_1 (int *, struct value *,
* If found, return value, else return NULL. */
static struct value *
@ -771,7 +771,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
struct type *type)
{
return ada_index_struct_field_1 (&index, arg, offset, type);
@@ -7450,7 +7451,7 @@ ada_index_struct_field (int index, struct value *arg, int offset,
@@ -7452,7 +7453,7 @@ ada_index_struct_field (int index, struct value *arg, int offset,
* *INDEX_P. */
static struct value *
@ -780,7 +780,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
struct type *type)
{
int i;
@@ -7541,7 +7542,8 @@ ada_value_struct_elt (struct value *arg, const char *name, int no_err)
@@ -7543,7 +7544,8 @@ ada_value_struct_elt (struct value *arg, const char *name, int no_err)
v = ada_search_struct_field (name, arg, 0, t);
else
{
@ -790,7 +790,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
struct type *field_type;
CORE_ADDR address;
@@ -7890,8 +7892,8 @@ ada_coerce_ref (struct value *val0)
@@ -7892,8 +7894,8 @@ ada_coerce_ref (struct value *val0)
/* Return OFF rounded upward if necessary to a multiple of
ALIGNMENT (a power of 2). */
@ -801,7 +801,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
{
return (off + alignment - 1) & ~(alignment - 1);
}
@@ -8281,10 +8283,9 @@ ada_template_to_fixed_record_type_1 (struct type *type,
@@ -8283,10 +8285,9 @@ ada_template_to_fixed_record_type_1 (struct type *type,
struct value *mark = value_mark ();
struct value *dval;
struct type *rtype;
@ -814,7 +814,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
int f;
/* Compute the number of fields in this record type that are going
@@ -8361,7 +8362,7 @@ ada_template_to_fixed_record_type_1 (struct type *type,
@@ -8363,7 +8364,7 @@ ada_template_to_fixed_record_type_1 (struct type *type,
that follow this one. */
if (ada_is_aligner_type (field_type))
{
@ -823,7 +823,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
field_valaddr = cond_offset_host (field_valaddr, field_offset);
field_address = cond_offset_target (field_address, field_offset);
@@ -8497,11 +8498,11 @@ ada_template_to_fixed_record_type_1 (struct type *type,
@@ -8499,11 +8500,11 @@ ada_template_to_fixed_record_type_1 (struct type *type,
if (TYPE_LENGTH (type) <= 0)
{
if (TYPE_NAME (rtype))
@ -839,7 +839,7 @@ diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c
}
else
{
@@ -8965,7 +8966,8 @@ to_fixed_array_type (struct type *type0, struct value *dval,
@@ -8967,7 +8968,8 @@ to_fixed_array_type (struct type *type0, struct value *dval,
type was a regular (non-packed) array type. As a result, the
bitsize of the array elements needs to be set again, and the array
length needs to be recomputed based on that bitsize. */
@ -929,7 +929,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
enum bfd_endian byte_order)
{
if (type_len == 1)
@@ -476,11 +476,11 @@ ada_print_scalar (struct type *type, LONGEST val, struct ui_file *stream)
@@ -475,11 +475,11 @@ ada_print_scalar (struct type *type, LONGEST val, struct ui_file *stream)
static void
printstr (struct ui_file *stream, struct type *elttype, const gdb_byte *string,
@ -943,7 +943,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
unsigned int things_printed = 0;
int in_quotes = 0;
int need_comma = 0;
@@ -495,9 +495,9 @@ printstr (struct ui_file *stream, struct type *elttype, const gdb_byte *string,
@@ -494,9 +494,9 @@ printstr (struct ui_file *stream, struct type *elttype, const gdb_byte *string,
{
/* Position of the character we are examining
to see whether it is repeated. */
@ -955,7 +955,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
QUIT;
@@ -528,7 +528,8 @@ printstr (struct ui_file *stream, struct type *elttype, const gdb_byte *string,
@@ -527,7 +527,8 @@ printstr (struct ui_file *stream, struct type *elttype, const gdb_byte *string,
ada_emit_char (char_at (string, i, type_len, byte_order),
elttype, stream, '\'', type_len);
fputs_filtered ("'", stream);
@ -965,7 +965,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
i = rep1 - 1;
things_printed += options->repeat_count_threshold;
need_comma = 1;
@@ -556,7 +557,7 @@ printstr (struct ui_file *stream, struct type *elttype, const gdb_byte *string,
@@ -555,7 +556,7 @@ printstr (struct ui_file *stream, struct type *elttype, const gdb_byte *string,
void
ada_printstr (struct ui_file *stream, struct type *type,
@ -974,7 +974,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
const char *encoding, int force_ellipses,
const struct value_print_options *options)
{
@@ -566,12 +567,12 @@ ada_printstr (struct ui_file *stream, struct type *type,
@@ -565,12 +566,12 @@ ada_printstr (struct ui_file *stream, struct type *type,
static int
print_variant_part (struct type *type, int field_num,
@ -989,7 +989,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
const struct language_defn *language)
{
struct type *var_type = TYPE_FIELD_TYPE (type, field_num);
@@ -607,11 +608,11 @@ print_variant_part (struct type *type, int field_num,
@@ -606,11 +607,11 @@ print_variant_part (struct type *type, int field_num,
static int
print_field_values (struct type *type, const gdb_byte *valaddr,
@ -1003,7 +1003,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
const struct language_defn *language)
{
int i, len;
@@ -677,7 +678,7 @@ print_field_values (struct type *type, const gdb_byte *valaddr,
@@ -676,7 +677,7 @@ print_field_values (struct type *type, const gdb_byte *valaddr,
else
{
struct value *v;
@ -1012,7 +1012,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
int bit_size = TYPE_FIELD_BITSIZE (type, i);
struct value_print_options opts;
@@ -722,8 +723,8 @@ ada_val_print_string (struct type *type, const gdb_byte *valaddr,
@@ -721,8 +722,8 @@ ada_val_print_string (struct type *type, const gdb_byte *valaddr,
{
enum bfd_endian byte_order = gdbarch_byte_order (get_type_arch (type));
struct type *elttype = TYPE_TARGET_TYPE (type);
@ -1023,7 +1023,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
/* We know that ELTTYPE cannot possibly be null, because we assume
that we're called only when TYPE is a string-like type.
@@ -742,7 +743,7 @@ ada_val_print_string (struct type *type, const gdb_byte *valaddr,
@@ -741,7 +742,7 @@ ada_val_print_string (struct type *type, const gdb_byte *valaddr,
elements up to it. */
if (options->stop_print_at_null)
{
@ -1032,7 +1032,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
/* Look for a NULL char. */
for (temp_len = 0;
@@ -1115,7 +1116,7 @@ ada_val_print_ref (struct type *type, const gdb_byte *valaddr,
@@ -1114,7 +1115,7 @@ ada_val_print_ref (struct type *type, const gdb_byte *valaddr,
static void
ada_val_print_1 (struct type *type,
@ -1041,7 +1041,7 @@ diff --git a/gdb/ada-valprint.c b/gdb/ada-valprint.c
struct ui_file *stream, int recurse,
struct value *original_value,
const struct value_print_options *options,
@@ -1199,7 +1200,7 @@ ada_val_print_1 (struct type *type,
@@ -1198,7 +1199,7 @@ ada_val_print_1 (struct type *type,
void
ada_val_print (struct type *type,
@ -1145,7 +1145,7 @@ diff --git a/gdb/arch-utils.h b/gdb/arch-utils.h
diff --git a/gdb/arm-linux-nat.c b/gdb/arm-linux-nat.c
--- a/gdb/arm-linux-nat.c
+++ b/gdb/arm-linux-nat.c
@@ -1096,7 +1096,7 @@ arm_linux_nat_target::remove_hw_breakpoint (struct gdbarch *gdbarch,
@@ -1092,7 +1092,7 @@ arm_linux_nat_target::remove_hw_breakpoint (struct gdbarch *gdbarch,
/* Are we able to use a hardware watchpoint for the LEN bytes starting at
ADDR? */
int
@ -1280,7 +1280,7 @@ diff --git a/gdb/ax.h b/gdb/ax.h
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
--- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c
@@ -2056,9 +2056,9 @@ should_be_inserted (struct bp_location *bl)
@@ -2057,9 +2057,9 @@ should_be_inserted (struct bp_location *bl)
{
fprintf_unfiltered (gdb_stdlog,
"infrun: stepping past non-steppable watchpoint. "
@ -1292,7 +1292,7 @@ diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
}
return 0;
}
@@ -6793,7 +6793,7 @@ breakpoint_address_match (const address_space *aspace1, CORE_ADDR addr1,
@@ -6803,7 +6803,7 @@ breakpoint_address_match (const address_space *aspace1, CORE_ADDR addr1,
static int
breakpoint_address_match_range (const address_space *aspace1,
CORE_ADDR addr1,
@ -1301,7 +1301,7 @@ diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
CORE_ADDR addr2)
{
return ((gdbarch_has_global_breakpoints (target_gdbarch ())
@@ -10859,7 +10859,7 @@ can_use_hardware_watchpoint (const std::vector<value_ref_ptr> &vals)
@@ -10869,7 +10869,7 @@ can_use_hardware_watchpoint (const std::vector<value_ref_ptr> &vals)
&& TYPE_CODE (vtype) != TYPE_CODE_ARRAY))
{
CORE_ADDR vaddr = value_address (v);
@ -1552,7 +1552,7 @@ diff --git a/gdb/d-valprint.c b/gdb/d-valprint.c
diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
--- a/gdb/dwarf2loc.c
+++ b/gdb/dwarf2loc.c
@@ -1625,7 +1625,7 @@ rw_pieced_value (struct value *v, struct value *from)
@@ -1624,7 +1624,7 @@ rw_pieced_value (struct value *v, struct value *from)
for (; i < c->pieces.size () && offset < max_offset; i++)
{
struct dwarf_expr_piece *p = &c->pieces[i];
@ -1561,7 +1561,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
this_size_bits = p->size - bits_to_skip;
if (this_size_bits > max_offset - offset)
@@ -1872,7 +1872,7 @@ write_pieced_value (struct value *to, struct value *from)
@@ -1871,7 +1871,7 @@ write_pieced_value (struct value *to, struct value *from)
static int
check_pieced_synthetic_pointer (const struct value *value, LONGEST bit_offset,
@ -1570,7 +1570,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
{
struct piece_closure *c
= (struct piece_closure *) value_computed_closure (value);
@@ -1885,7 +1885,7 @@ check_pieced_synthetic_pointer (const struct value *value, LONGEST bit_offset,
@@ -1884,7 +1884,7 @@ check_pieced_synthetic_pointer (const struct value *value, LONGEST bit_offset,
for (i = 0; i < c->pieces.size () && bit_length > 0; i++)
{
struct dwarf_expr_piece *p = &c->pieces[i];
@ -1579,7 +1579,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
if (bit_offset > 0)
{
@@ -1989,8 +1989,8 @@ indirect_pieced_value (struct value *value)
@@ -1988,8 +1988,8 @@ indirect_pieced_value (struct value *value)
= (struct piece_closure *) value_computed_closure (value);
struct type *type;
struct frame_info *frame;
@ -1590,7 +1590,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
struct dwarf_expr_piece *piece = NULL;
LONGEST byte_offset;
enum bfd_endian byte_order;
@@ -2007,7 +2007,7 @@ indirect_pieced_value (struct value *value)
@@ -2006,7 +2006,7 @@ indirect_pieced_value (struct value *value)
for (i = 0; i < c->pieces.size () && bit_length > 0; i++)
{
struct dwarf_expr_piece *p = &c->pieces[i];
@ -1599,7 +1599,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
if (bit_offset > 0)
{
@@ -2296,9 +2296,9 @@ if (frame != NULL) select_frame (frame);
@@ -2295,9 +2295,9 @@ if (frame != NULL) select_frame (frame);
case DWARF_VALUE_STACK:
{
struct value *value = ctx.fetch (0);
@ -1615,7 +1615,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -2065,11 +2065,11 @@ dwarf2_complex_location_expr_complaint (void)
@@ -2064,11 +2064,11 @@ dwarf2_complex_location_expr_complaint (void)
}
static void
@ -1631,7 +1631,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
}
static void
@@ -15105,8 +15105,8 @@ dwarf2_add_field (struct field_info *fip, struct die_info *die,
@@ -15103,8 +15103,8 @@ dwarf2_add_field (struct field_info *fip, struct die_info *die,
object, and then subtract off the number of bits of
the field itself. The result is the bit offset of
the LSB of the field. */
@ -1700,7 +1700,7 @@ diff --git a/gdb/eval.c b/gdb/eval.c
diff --git a/gdb/f-lang.c b/gdb/f-lang.c
--- a/gdb/f-lang.c
+++ b/gdb/f-lang.c
@@ -101,7 +101,7 @@ f_printchar (int c, struct type *type, struct ui_file *stream)
@@ -104,7 +104,7 @@ f_printchar (int c, struct type *type, struct ui_file *stream)
static void
f_printstr (struct ui_file *stream, struct type *type, const gdb_byte *string,
@ -1846,7 +1846,7 @@ diff --git a/gdb/frame.h b/gdb/frame.h
diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c
--- a/gdb/gdbarch.c
+++ b/gdb/gdbarch.c
@@ -1795,7 +1795,7 @@ set_gdbarch_wchar_signed (struct gdbarch *gdbarch,
@@ -1803,7 +1803,7 @@ set_gdbarch_wchar_signed (struct gdbarch *gdbarch,
}
const struct floatformat **
@ -1884,7 +1884,7 @@ diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
--- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c
@@ -2889,7 +2889,7 @@ floatformat_from_type (const struct type *type)
@@ -2873,7 +2873,7 @@ floatformat_from_type (const struct type *type)
least as long as OBJFILE. */
struct type *
@ -1893,7 +1893,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
const char *name)
{
struct type *type;
@@ -3340,8 +3340,8 @@ is_public_ancestor (struct type *base, struct type *dclass)
@@ -3330,8 +3330,8 @@ is_public_ancestor (struct type *base, struct type *dclass)
static int
is_unique_ancestor_worker (struct type *base, struct type *dclass,
@ -1904,7 +1904,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
CORE_ADDR address, struct value *val)
{
int i, count = 0;
@@ -3352,7 +3352,7 @@ is_unique_ancestor_worker (struct type *base, struct type *dclass,
@@ -3342,7 +3342,7 @@ is_unique_ancestor_worker (struct type *base, struct type *dclass,
for (i = 0; i < TYPE_N_BASECLASSES (dclass) && count < 2; ++i)
{
struct type *iter;
@ -1913,7 +1913,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
iter = check_typedef (TYPE_BASECLASS (dclass, i));
@@ -3393,7 +3393,7 @@ is_unique_ancestor_worker (struct type *base, struct type *dclass,
@@ -3383,7 +3383,7 @@ is_unique_ancestor_worker (struct type *base, struct type *dclass,
int
is_unique_ancestor (struct type *base, struct value *val)
{
@ -1922,7 +1922,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
return is_unique_ancestor_worker (base, value_type (val), &offset,
value_contents_for_printing (val),
@@ -4620,7 +4620,7 @@ recursive_dump_type (struct type *type, int spaces)
@@ -4643,7 +4643,7 @@ recursive_dump_type (struct type *type, int spaces)
break;
}
puts_filtered ("\n");
@ -1931,7 +1931,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
if (TYPE_OBJFILE_OWNED (type))
{
printfi_filtered (spaces, "objfile ");
@@ -5065,7 +5065,7 @@ copy_type (const struct type *type)
@@ -5088,7 +5088,7 @@ copy_type (const struct type *type)
struct type *
arch_type (struct gdbarch *gdbarch,
@ -2285,7 +2285,7 @@ diff --git a/gdb/m2-valprint.c b/gdb/m2-valprint.c
/* Look for a NULL char. */
for (temp_len = 0;
@@ -415,7 +415,7 @@ m2_val_print (struct type *type, int embedded_offset,
@@ -414,7 +414,7 @@ m2_val_print (struct type *type, int embedded_offset,
{
struct type *range = elttype;
LONGEST low_bound, high_bound;
@ -2603,7 +2603,7 @@ diff --git a/gdb/printcmd.c b/gdb/printcmd.c
diff --git a/gdb/procfs.c b/gdb/procfs.c
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -3369,7 +3369,7 @@ procfs_target::remove_watchpoint (CORE_ADDR addr, int len,
@@ -3368,7 +3368,7 @@ procfs_target::remove_watchpoint (CORE_ADDR addr, int len,
}
int
@ -2730,7 +2730,7 @@ diff --git a/gdb/regcache.h b/gdb/regcache.h
diff --git a/gdb/remote.c b/gdb/remote.c
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -458,7 +458,7 @@ public:
@@ -448,7 +448,7 @@ public:
int remove_hw_breakpoint (struct gdbarch *, struct bp_target_info *) override;
@ -2739,7 +2739,7 @@ diff --git a/gdb/remote.c b/gdb/remote.c
int insert_watchpoint (CORE_ADDR, int, enum target_hw_bp_type,
struct expression *) override;
@@ -10406,7 +10406,7 @@ int remote_hw_watchpoint_length_limit = -1;
@@ -10369,7 +10369,7 @@ int remote_hw_watchpoint_length_limit = -1;
int remote_hw_breakpoint_limit = -1;
int
@ -2847,7 +2847,7 @@ diff --git a/gdb/stack.c b/gdb/stack.c
diff --git a/gdb/symmisc.c b/gdb/symmisc.c
--- a/gdb/symmisc.c
+++ b/gdb/symmisc.c
@@ -587,11 +587,11 @@ print_symbol (struct gdbarch *gdbarch, struct symbol *symbol,
@@ -584,11 +584,11 @@ print_symbol (struct gdbarch *gdbarch, struct symbol *symbol,
case LOC_CONST_BYTES:
{
@ -2927,7 +2927,7 @@ diff --git a/gdb/target.c b/gdb/target.c
static void default_rcmd (struct target_ops *, const char *, struct ui_file *);
@@ -3103,7 +3103,7 @@ target_fileio_read_stralloc (struct inferior *inf, const char *filename)
@@ -3117,7 +3117,7 @@ target_fileio_read_stralloc (struct inferior *inf, const char *filename)
static int
default_region_ok_for_hw_watchpoint (struct target_ops *self,
@ -3218,7 +3218,7 @@ diff --git a/gdb/valprint.c b/gdb/valprint.c
struct ui_file *stream, int recurse,
struct value *original_value,
const struct value_print_options *options,
@@ -1774,7 +1774,7 @@ print_decimal_chars (struct ui_file *stream, const gdb_byte *valaddr,
@@ -1772,7 +1772,7 @@ print_decimal_chars (struct ui_file *stream, const gdb_byte *valaddr,
void
print_hex_chars (struct ui_file *stream, const gdb_byte *valaddr,
@ -3227,7 +3227,7 @@ diff --git a/gdb/valprint.c b/gdb/valprint.c
bool zero_pad)
{
const gdb_byte *p;
@@ -1927,17 +1927,17 @@ val_print_array_elements (struct type *type,
@@ -1925,17 +1925,17 @@ val_print_array_elements (struct type *type,
int recurse,
struct value *val,
const struct value_print_options *options,
@ -3250,7 +3250,7 @@ diff --git a/gdb/valprint.c b/gdb/valprint.c
LONGEST low_bound, high_bound;
LONGEST low_pos, high_pos;
@@ -2027,7 +2027,7 @@ val_print_array_elements (struct type *type,
@@ -2025,7 +2025,7 @@ val_print_array_elements (struct type *type,
address, stream, recurse + 1, val, options,
current_language);
annotate_elt_rep (reps);
@ -3259,7 +3259,7 @@ diff --git a/gdb/valprint.c b/gdb/valprint.c
annotate_elt_rep_end ();
i = rep1 - 1;
@@ -2669,7 +2669,7 @@ print_converted_chars_to_obstack (struct obstack *obstack,
@@ -2667,7 +2667,7 @@ print_converted_chars_to_obstack (struct obstack *obstack,
void
generic_printstr (struct ui_file *stream, struct type *type,
@ -3372,7 +3372,7 @@ diff --git a/gdb/value.h b/gdb/value.h
/* Mark VALUE's content bits starting at OFFSET and extending for
LENGTH bits as optimized out. */
@@ -849,12 +850,11 @@ extern struct value *value_primitive_field (struct value *arg1, LONGEST offset,
@@ -850,12 +851,11 @@ extern struct value *value_primitive_field (struct value *arg1, LONGEST offset,
int fieldno,
struct type *arg_type);
@ -3386,7 +3386,7 @@ diff --git a/gdb/value.h b/gdb/value.h
extern struct value *value_cast_pointers (struct type *, struct value *, int);
@@ -1147,10 +1147,11 @@ extern struct value *value_literal_complex (struct value *, struct value *,
@@ -1148,10 +1148,11 @@ extern struct value *value_literal_complex (struct value *, struct value *,
extern struct value *find_function_in_inferior (const char *,
struct objfile **);

View File

@ -100,7 +100,7 @@ diff --git a/gdb/defs.h b/gdb/defs.h
diff --git a/gdb/p-valprint.c b/gdb/p-valprint.c
--- a/gdb/p-valprint.c
+++ b/gdb/p-valprint.c
@@ -775,6 +775,7 @@ pascal_object_print_value (struct type *type, const gdb_byte *valaddr,
@@ -773,6 +773,7 @@ pascal_object_print_value (struct type *type, const gdb_byte *valaddr,
if (boffset < 0 || boffset >= TYPE_LENGTH (type))
{
@ -111,7 +111,7 @@ diff --git a/gdb/p-valprint.c b/gdb/p-valprint.c
diff --git a/gdb/utils.c b/gdb/utils.c
--- a/gdb/utils.c
+++ b/gdb/utils.c
@@ -2933,6 +2933,17 @@ string_to_core_addr (const char *my_string)
@@ -2932,6 +2932,17 @@ string_to_core_addr (const char *my_string)
return addr;
}

View File

@ -154,7 +154,7 @@ diff --git a/gdb/arm-linux-nat.c b/gdb/arm-linux-nat.c
const struct target_desc *read_description () override;
@@ -1203,7 +1203,7 @@ arm_linux_nat_target::stopped_by_watchpoint ()
@@ -1199,7 +1199,7 @@ arm_linux_nat_target::stopped_by_watchpoint ()
bool
arm_linux_nat_target::watchpoint_addr_within_range (CORE_ADDR addr,
CORE_ADDR start,
@ -188,7 +188,7 @@ diff --git a/gdb/nat/aarch64-linux-hw-point.c b/gdb/nat/aarch64-linux-hw-point.c
CORE_ADDR *next_addr_orig_p)
{
int aligned_len;
@@ -611,7 +612,7 @@ aarch64_handle_aligned_watchpoint (enum target_hw_bp_type type,
@@ -602,7 +603,7 @@ aarch64_handle_aligned_watchpoint (enum target_hw_bp_type type,
static int
aarch64_handle_unaligned_watchpoint (enum target_hw_bp_type type,
@ -197,7 +197,7 @@ diff --git a/gdb/nat/aarch64-linux-hw-point.c b/gdb/nat/aarch64-linux-hw-point.c
struct aarch64_debug_reg_state *state)
{
CORE_ADDR addr_orig = addr;
@@ -641,12 +642,12 @@ aarch64_handle_unaligned_watchpoint (enum target_hw_bp_type type,
@@ -632,12 +633,12 @@ aarch64_handle_unaligned_watchpoint (enum target_hw_bp_type type,
" "
"addr_orig: %s\n"
" "
@ -212,7 +212,7 @@ diff --git a/gdb/nat/aarch64-linux-hw-point.c b/gdb/nat/aarch64-linux-hw-point.c
core_addr_to_string_nz (addr_orig_next));
addr_orig = addr_orig_next;
@@ -660,7 +661,7 @@ aarch64_handle_unaligned_watchpoint (enum target_hw_bp_type type,
@@ -651,7 +652,7 @@ aarch64_handle_unaligned_watchpoint (enum target_hw_bp_type type,
int
aarch64_handle_watchpoint (enum target_hw_bp_type type, CORE_ADDR addr,
@ -221,7 +221,7 @@ diff --git a/gdb/nat/aarch64-linux-hw-point.c b/gdb/nat/aarch64-linux-hw-point.c
struct aarch64_debug_reg_state *state)
{
if (aarch64_point_is_aligned (1 /* is_watchpoint */ , addr, len))
@@ -742,14 +743,14 @@ aarch64_linux_any_set_debug_regs_state (aarch64_debug_reg_state *state,
@@ -733,14 +734,14 @@ aarch64_linux_any_set_debug_regs_state (aarch64_debug_reg_state *state,
void
aarch64_show_debug_reg_state (struct aarch64_debug_reg_state *state,
const char *func, CORE_ADDR addr,
@ -239,7 +239,7 @@ diff --git a/gdb/nat/aarch64-linux-hw-point.c b/gdb/nat/aarch64-linux-hw-point.c
type == hw_write ? "hw-write-watchpoint"
: (type == hw_read ? "hw-read-watchpoint"
: (type == hw_access ? "hw-access-watchpoint"
@@ -832,7 +833,7 @@ aarch64_linux_get_debug_reg_capacity (int tid)
@@ -823,7 +824,7 @@ aarch64_linux_get_debug_reg_capacity (int tid)
ADDR and whose length is LEN in bytes. */
int
@ -354,7 +354,7 @@ diff --git a/gdb/ppc-linux-nat.c b/gdb/ppc-linux-nat.c
diff --git a/gdb/procfs.c b/gdb/procfs.c
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -1541,7 +1541,7 @@ procfs_address_to_host_pointer (CORE_ADDR addr)
@@ -1546,7 +1546,7 @@ procfs_address_to_host_pointer (CORE_ADDR addr)
}
static int
@ -363,7 +363,7 @@ diff --git a/gdb/procfs.c b/gdb/procfs.c
{
struct {
procfs_ctl_t cmd;
@@ -3233,7 +3233,7 @@ procfs_target::pid_to_exec_file (int pid)
@@ -3232,7 +3232,7 @@ procfs_target::pid_to_exec_file (int pid)
/* Insert a watchpoint. */
static int
@ -375,7 +375,7 @@ diff --git a/gdb/procfs.c b/gdb/procfs.c
diff --git a/gdb/remote.c b/gdb/remote.c
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -450,7 +450,7 @@ public:
@@ -440,7 +440,7 @@ public:
bool stopped_data_address (CORE_ADDR *) override;
@ -384,7 +384,7 @@ diff --git a/gdb/remote.c b/gdb/remote.c
int can_use_hw_breakpoint (enum bptype, int, int) override;
@@ -10335,7 +10335,7 @@ remote_target::insert_watchpoint (CORE_ADDR addr, int len,
@@ -10298,7 +10298,7 @@ remote_target::insert_watchpoint (CORE_ADDR addr, int len,
p = strchr (rs->buf.data (), '\0');
addr = remote_address_masked (addr);
p += hexnumstr (p, (ULONGEST) addr);
@ -393,7 +393,7 @@ diff --git a/gdb/remote.c b/gdb/remote.c
putpkt (rs->buf);
getpkt (&rs->buf, 0);
@@ -10355,7 +10355,7 @@ remote_target::insert_watchpoint (CORE_ADDR addr, int len,
@@ -10318,7 +10318,7 @@ remote_target::insert_watchpoint (CORE_ADDR addr, int len,
bool
remote_target::watchpoint_addr_within_range (CORE_ADDR addr,
@ -402,7 +402,7 @@ diff --git a/gdb/remote.c b/gdb/remote.c
{
CORE_ADDR diff = remote_address_masked (addr - start);
@@ -10384,7 +10384,7 @@ remote_target::remove_watchpoint (CORE_ADDR addr, int len,
@@ -10347,7 +10347,7 @@ remote_target::remove_watchpoint (CORE_ADDR addr, int len,
p = strchr (rs->buf.data (), '\0');
addr = remote_address_masked (addr);
p += hexnumstr (p, (ULONGEST) addr);
@ -526,7 +526,7 @@ diff --git a/gdb/target.c b/gdb/target.c
static int default_region_ok_for_hw_watchpoint (struct target_ops *,
CORE_ADDR, LONGEST);
@@ -3111,7 +3111,7 @@ default_region_ok_for_hw_watchpoint (struct target_ops *self,
@@ -3125,7 +3125,7 @@ default_region_ok_for_hw_watchpoint (struct target_ops *self,
static int
default_watchpoint_addr_within_range (struct target_ops *target,
CORE_ADDR addr,

View File

@ -236,7 +236,7 @@ diff --git a/gdb/amd64-windows-tdep.c b/gdb/amd64-windows-tdep.c
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -3472,7 +3472,7 @@ arm_vfp_cprc_reg_char (enum arm_vfp_cprc_base_type b)
@@ -3440,7 +3440,7 @@ arm_vfp_cprc_reg_char (enum arm_vfp_cprc_base_type b)
array). Vector types are not currently supported, matching the
generic AAPCS support. */
@ -245,7 +245,7 @@ diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
arm_vfp_cprc_sub_candidate (struct type *t,
enum arm_vfp_cprc_base_type *base_type)
{
@@ -3555,7 +3555,7 @@ arm_vfp_cprc_sub_candidate (struct type *t,
@@ -3523,7 +3523,7 @@ arm_vfp_cprc_sub_candidate (struct type *t,
}
else
{
@ -254,7 +254,7 @@ diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
unsigned unitlen;
count = arm_vfp_cprc_sub_candidate (TYPE_TARGET_TYPE (t),
@@ -3578,12 +3578,12 @@ arm_vfp_cprc_sub_candidate (struct type *t,
@@ -3546,12 +3546,12 @@ arm_vfp_cprc_sub_candidate (struct type *t,
case TYPE_CODE_STRUCT:
{
@ -269,7 +269,7 @@ diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
if (!field_is_static (&TYPE_FIELD (t, i)))
sub_count = arm_vfp_cprc_sub_candidate (TYPE_FIELD_TYPE (t, i),
@@ -3607,13 +3607,15 @@ arm_vfp_cprc_sub_candidate (struct type *t,
@@ -3575,13 +3575,15 @@ arm_vfp_cprc_sub_candidate (struct type *t,
case TYPE_CODE_UNION:
{
@ -288,7 +288,7 @@ diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
if (sub_count == -1)
return -1;
count = (count > sub_count ? count : sub_count);
@@ -3649,7 +3651,7 @@ arm_vfp_call_candidate (struct type *t, enum arm_vfp_cprc_base_type *base_type,
@@ -3617,7 +3619,7 @@ arm_vfp_call_candidate (struct type *t, enum arm_vfp_cprc_base_type *base_type,
int *count)
{
enum arm_vfp_cprc_base_type b = VFP_CPRC_UNKNOWN;
@ -297,7 +297,7 @@ diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
if (c <= 0 || c > 4)
return 0;
*base_type = b;
@@ -3731,7 +3733,7 @@ arm_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
@@ -3699,7 +3701,7 @@ arm_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
for (argnum = 0; argnum < nargs; argnum++)
{
@ -365,7 +365,7 @@ diff --git a/gdb/bfin-tdep.c b/gdb/bfin-tdep.c
diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c
--- a/gdb/cris-tdep.c
+++ b/gdb/cris-tdep.c
@@ -663,13 +663,13 @@ static CORE_ADDR cris_unwind_sp (struct gdbarch *gdbarch,
@@ -657,13 +657,13 @@ static CORE_ADDR crisv32_scan_prologue (CORE_ADDR pc,
struct stack_item
{
@ -381,7 +381,7 @@ diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c
{
struct stack_item *si = XNEW (struct stack_item);
si->data = (gdb_byte *) xmalloc (len);
@@ -832,13 +832,13 @@ cris_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
@@ -814,13 +814,13 @@ cris_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
for (argnum = 0; argnum < nargs; argnum++)
{
@ -402,7 +402,7 @@ diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c
diff --git a/gdb/h8300-tdep.c b/gdb/h8300-tdep.c
--- a/gdb/h8300-tdep.c
+++ b/gdb/h8300-tdep.c
@@ -638,7 +638,7 @@ h8300_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
@@ -619,7 +619,7 @@ h8300_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
CORE_ADDR struct_addr)
{
enum bfd_endian byte_order = gdbarch_byte_order (gdbarch);
@ -411,7 +411,7 @@ diff --git a/gdb/h8300-tdep.c b/gdb/h8300-tdep.c
int wordsize = BINWORD (gdbarch);
int reg = E_ARG0_REGNUM;
int argument;
@@ -664,11 +664,11 @@ h8300_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
@@ -645,11 +645,11 @@ h8300_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
for (argument = 0; argument < nargs; argument++)
{
struct type *type = value_type (args[argument]);
@ -425,7 +425,7 @@ diff --git a/gdb/h8300-tdep.c b/gdb/h8300-tdep.c
/* Use std::vector here to get zero initialization. */
std::vector<gdb_byte> padded (padded_len);
@@ -697,7 +697,7 @@ h8300_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
@@ -678,7 +678,7 @@ h8300_push_dummy_call (struct gdbarch *gdbarch, struct value *function,
/* Heavens to Betsy --- it's really going in registers!
Note that on the h8/300s, there are gaps between the
registers in the register file. */
@ -982,7 +982,7 @@ diff --git a/gdb/sh-tdep.c b/gdb/sh-tdep.c
diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
--- a/gdb/sparc64-tdep.c
+++ b/gdb/sparc64-tdep.c
@@ -1206,7 +1206,7 @@ sparc64_16_byte_align_p (struct type *type)
@@ -1205,7 +1205,7 @@ sparc64_16_byte_align_p (struct type *type)
static void
sparc64_store_floating_fields (struct regcache *regcache, struct type *type,
@ -991,7 +991,7 @@ diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
{
struct gdbarch *gdbarch = regcache->arch ();
int len = TYPE_LENGTH (type);
@@ -1266,7 +1266,7 @@ sparc64_store_floating_fields (struct regcache *regcache, struct type *type,
@@ -1265,7 +1265,7 @@ sparc64_store_floating_fields (struct regcache *regcache, struct type *type,
for (i = 0; i < TYPE_NFIELDS (type); i++)
{
struct type *subtype = check_typedef (TYPE_FIELD_TYPE (type, i));
@ -1000,7 +1000,7 @@ diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
sparc64_store_floating_fields (regcache, subtype, valbuf,
element, subpos);
@@ -1298,7 +1298,7 @@ sparc64_store_floating_fields (struct regcache *regcache, struct type *type,
@@ -1297,7 +1297,7 @@ sparc64_store_floating_fields (struct regcache *regcache, struct type *type,
static void
sparc64_extract_floating_fields (struct regcache *regcache, struct type *type,
@ -1009,7 +1009,7 @@ diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
{
struct gdbarch *gdbarch = regcache->arch ();
@@ -1354,7 +1354,7 @@ sparc64_extract_floating_fields (struct regcache *regcache, struct type *type,
@@ -1353,7 +1353,7 @@ sparc64_extract_floating_fields (struct regcache *regcache, struct type *type,
for (i = 0; i < TYPE_NFIELDS (type); i++)
{
struct type *subtype = check_typedef (TYPE_FIELD_TYPE (type, i));
@ -1018,7 +1018,7 @@ diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
sparc64_extract_floating_fields (regcache, subtype, valbuf, subpos);
}
@@ -1388,7 +1388,7 @@ sparc64_store_arguments (struct regcache *regcache, int nargs,
@@ -1387,7 +1387,7 @@ sparc64_store_arguments (struct regcache *regcache, int nargs,
for (i = 0; i < nargs; i++)
{
struct type *type = value_type (args[i]);
@ -1027,7 +1027,7 @@ diff --git a/gdb/sparc64-tdep.c b/gdb/sparc64-tdep.c
if (sparc64_structure_or_union_p (type)
|| (sparc64_complex_floating_p (type) && len == 32))
@@ -1488,7 +1488,7 @@ sparc64_store_arguments (struct regcache *regcache, int nargs,
@@ -1487,7 +1487,7 @@ sparc64_store_arguments (struct regcache *regcache, int nargs,
{
const gdb_byte *valbuf = value_contents (args[i]);
struct type *type = value_type (args[i]);

View File

@ -37,7 +37,7 @@ dbfd7140bf4c0500d1f5d192be781f83f78f7922
diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
--- a/gdb/dwarf2loc.c
+++ b/gdb/dwarf2loc.c
@@ -2429,11 +2429,14 @@ dwarf2_locexpr_baton_eval (const struct dwarf2_locexpr_baton *dlbaton,
@@ -2428,11 +2428,14 @@ dwarf2_locexpr_baton_eval (const struct dwarf2_locexpr_baton *dlbaton,
/* See dwarf2loc.h. */
int
@ -54,7 +54,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
if (prop == NULL)
return 0;
@@ -2457,7 +2460,7 @@ dwarf2_evaluate_property (const struct dynamic_prop *prop,
@@ -2456,7 +2459,7 @@ dwarf2_evaluate_property (const struct dynamic_prop *prop,
*value = value_as_address (val);
}
@ -63,7 +63,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
}
}
break;
@@ -2479,7 +2482,7 @@ dwarf2_evaluate_property (const struct dynamic_prop *prop,
@@ -2478,7 +2481,7 @@ dwarf2_evaluate_property (const struct dynamic_prop *prop,
if (!value_optimized_out (val))
{
*value = value_as_address (val);
@ -72,7 +72,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
}
}
}
@@ -2487,8 +2490,8 @@ dwarf2_evaluate_property (const struct dynamic_prop *prop,
@@ -2486,8 +2489,8 @@ dwarf2_evaluate_property (const struct dynamic_prop *prop,
case PROP_CONST:
*value = prop->data.const_val;
@ -83,7 +83,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
case PROP_ADDR_OFFSET:
{
struct dwarf2_property_baton *baton
@@ -2509,11 +2512,38 @@ dwarf2_evaluate_property (const struct dynamic_prop *prop,
@@ -2508,11 +2511,38 @@ dwarf2_evaluate_property (const struct dynamic_prop *prop,
val = value_at (baton->offset_info.type,
pinfo->addr + baton->offset_info.offset);
*value = value_as_address (val);
@ -143,7 +143,7 @@ diff --git a/gdb/dwarf2loc.h b/gdb/dwarf2loc.h
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -17753,7 +17753,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17751,7 +17751,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
struct type *base_type, *orig_base_type;
struct type *range_type;
struct attribute *attr;
@ -152,7 +152,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
int low_default_is_valid;
int high_bound_is_count = 0;
const char *name;
@@ -17773,7 +17773,9 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17771,7 +17771,9 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
low.kind = PROP_CONST;
high.kind = PROP_CONST;
@ -162,7 +162,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
/* Set LOW_DEFAULT_IS_VALID if current language and DWARF version allow
omitting DW_AT_lower_bound. */
@@ -17806,6 +17808,14 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17804,6 +17806,14 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
break;
}
@ -177,7 +177,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
attr = dwarf2_attr (die, DW_AT_lower_bound, cu);
if (attr)
attr_to_dynamic_prop (attr, die, cu, &low);
@@ -17898,7 +17908,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17896,7 +17906,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
&& !TYPE_UNSIGNED (base_type) && (high.data.const_val & negative_mask))
high.data.const_val |= negative_mask;
@ -588,7 +588,7 @@ diff --git a/gdb/eval.c b/gdb/eval.c
case TYPE_CODE_PTR:
case TYPE_CODE_FUNC:
@@ -2372,49 +2629,6 @@ evaluate_subexp_standard (struct type *expect_type,
@@ -2385,49 +2642,6 @@ evaluate_subexp_standard (struct type *expect_type,
}
return (arg1);
@ -638,7 +638,7 @@ diff --git a/gdb/eval.c b/gdb/eval.c
case BINOP_LOGICAL_AND:
arg1 = evaluate_subexp (NULL_TYPE, exp, pos, noside);
if (noside == EVAL_SKIP)
@@ -3334,6 +3548,9 @@ calc_f77_array_dims (struct type *array_type)
@@ -3347,6 +3561,9 @@ calc_f77_array_dims (struct type *array_type)
int ndimen = 1;
struct type *tmp_type;
@ -673,7 +673,7 @@ diff --git a/gdb/expprint.c b/gdb/expprint.c
print_subexp (exp, pos, stream, PREC_ABOVE_COMMA);
fputs_filtered (")", stream);
return;
@@ -1105,22 +1102,24 @@ dump_subexp_body_standard (struct expression *exp,
@@ -1106,22 +1103,24 @@ dump_subexp_body_standard (struct expression *exp,
switch (range_type)
{
@ -706,7 +706,7 @@ diff --git a/gdb/expprint.c b/gdb/expprint.c
fputs_filtered ("ExclusiveRange 'EXP..EXP'", stream);
break;
default:
@@ -1128,11 +1127,9 @@ dump_subexp_body_standard (struct expression *exp,
@@ -1129,11 +1128,9 @@ dump_subexp_body_standard (struct expression *exp,
break;
}
@ -775,7 +775,7 @@ diff --git a/gdb/expression.h b/gdb/expression.h
diff --git a/gdb/f-exp.y b/gdb/f-exp.y
--- a/gdb/f-exp.y
+++ b/gdb/f-exp.y
@@ -257,31 +257,63 @@ arglist : subrange
@@ -270,31 +270,63 @@ arglist : subrange
arglist : arglist ',' exp %prec ABOVE_COMMA
{ arglist_len++; }
@ -928,7 +928,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
else if (bit_stride > 0)
TYPE_LENGTH (result_type) =
(bit_stride * (high_bound - low_bound + 1) + 7) / 8;
@@ -1990,12 +2000,12 @@ resolve_dynamic_range (struct type *dyn_range_type,
@@ -1974,12 +1984,12 @@ resolve_dynamic_range (struct type *dyn_range_type,
CORE_ADDR value;
struct type *static_range_type, *static_target_type;
const struct dynamic_prop *prop;
@ -943,7 +943,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
{
low_bound.kind = PROP_CONST;
low_bound.data.const_val = value;
@@ -2007,7 +2017,7 @@ resolve_dynamic_range (struct type *dyn_range_type,
@@ -1991,7 +2001,7 @@ resolve_dynamic_range (struct type *dyn_range_type,
}
prop = &TYPE_RANGE_DATA (dyn_range_type)->high;
@ -952,7 +952,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
{
high_bound.kind = PROP_CONST;
high_bound.data.const_val = value;
@@ -2022,12 +2032,20 @@ resolve_dynamic_range (struct type *dyn_range_type,
@@ -2006,12 +2016,20 @@ resolve_dynamic_range (struct type *dyn_range_type,
high_bound.data.const_val = 0;
}
@ -1022,7 +1022,7 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
#define TYPE_ARRAY_UPPER_BOUND_VALUE(arraytype) \
(TYPE_HIGH_BOUND(TYPE_INDEX_TYPE((arraytype))))
@@ -1896,6 +1911,7 @@ extern struct type *create_array_type_with_stride
@@ -1934,6 +1949,7 @@ extern struct type *create_array_type_with_stride
struct dynamic_prop *, unsigned int);
extern struct type *create_range_type (struct type *, struct type *,
@ -1033,7 +1033,7 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
diff --git a/gdb/parse.c b/gdb/parse.c
--- a/gdb/parse.c
+++ b/gdb/parse.c
@@ -989,24 +989,20 @@ operator_length_standard (const struct expression *expr, int endpos,
@@ -990,24 +990,20 @@ operator_length_standard (const struct expression *expr, int endpos,
case OP_RANGE:
oplen = 3;
@ -2047,7 +2047,7 @@ diff --git a/gdb/valops.c b/gdb/valops.c
diff --git a/gdb/value.h b/gdb/value.h
--- a/gdb/value.h
+++ b/gdb/value.h
@@ -1139,6 +1139,8 @@ extern struct value *varying_to_slice (struct value *);
@@ -1140,6 +1140,8 @@ extern struct value *varying_to_slice (struct value *);
extern struct value *value_slice (struct value *, int, int);

View File

@ -33,7 +33,7 @@ git diff --stat -p gdb/master...gdb/users/bheckel/fortran-vla-strings
diff --git a/gdb/NEWS b/gdb/NEWS
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -323,6 +323,8 @@ SH-5/SH64 running OpenBSD SH-5/SH64 support in sh*-*-openbsd*
@@ -352,6 +352,8 @@ SH-5/SH64 running OpenBSD SH-5/SH64 support in sh*-*-openbsd*
*** Changes in GDB 8.1
@ -45,7 +45,7 @@ diff --git a/gdb/NEWS b/gdb/NEWS
diff --git a/gdb/c-valprint.c b/gdb/c-valprint.c
--- a/gdb/c-valprint.c
+++ b/gdb/c-valprint.c
@@ -653,6 +653,28 @@ c_value_print (struct value *val, struct ui_file *stream,
@@ -652,6 +652,28 @@ c_value_print (struct value *val, struct ui_file *stream,
else
{
/* normal case */
@ -77,7 +77,7 @@ diff --git a/gdb/c-valprint.c b/gdb/c-valprint.c
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -1833,7 +1833,8 @@ static void read_signatured_type (struct signatured_type *);
@@ -1832,7 +1832,8 @@ static void read_signatured_type (struct signatured_type *);
static int attr_to_dynamic_prop (const struct attribute *attr,
struct die_info *die, struct dwarf2_cu *cu,
@ -87,7 +87,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
/* memory allocation interface */
@@ -13758,7 +13759,7 @@ read_func_scope (struct die_info *die, struct dwarf2_cu *cu)
@@ -13756,7 +13757,7 @@ read_func_scope (struct die_info *die, struct dwarf2_cu *cu)
{
newobj->static_link
= XOBNEW (&objfile->objfile_obstack, struct dynamic_prop);
@ -96,7 +96,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
}
cu->list_in_scope = cu->get_builder ()->get_local_symbols ();
@@ -16496,7 +16497,8 @@ read_array_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -16494,7 +16495,8 @@ read_array_type (struct die_info *die, struct dwarf2_cu *cu)
byte_stride_prop
= (struct dynamic_prop *) alloca (sizeof (struct dynamic_prop));
@ -106,7 +106,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
if (!stride_ok)
{
complaint (_("unable to read array DW_AT_byte_stride "
@@ -17257,29 +17259,90 @@ read_tag_string_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17255,29 +17257,90 @@ read_tag_string_type (struct die_info *die, struct dwarf2_cu *cu)
struct gdbarch *gdbarch = get_objfile_arch (objfile);
struct type *type, *range_type, *index_type, *char_type;
struct attribute *attr;
@ -208,7 +208,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
char_type = language_string_char_type (cu->language_defn, gdbarch);
type = create_string_type (NULL, char_type, range_type);
@@ -17647,7 +17710,8 @@ read_base_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17645,7 +17708,8 @@ read_base_type (struct die_info *die, struct dwarf2_cu *cu)
static int
attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die,
@ -218,7 +218,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
{
struct dwarf2_property_baton *baton;
struct obstack *obstack
@@ -17658,14 +17722,33 @@ attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die,
@@ -17656,14 +17720,33 @@ attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die,
if (attr_form_is_block (attr))
{
@ -256,7 +256,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
}
else if (attr_form_is_ref (attr))
{
@@ -17698,8 +17781,28 @@ attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die,
@@ -17696,8 +17779,28 @@ attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die,
baton = XOBNEW (obstack, struct dwarf2_property_baton);
baton->referenced_type = die_type (target_die, target_cu);
baton->locexpr.per_cu = cu->per_cu;
@ -287,7 +287,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
prop->data.baton = baton;
prop->kind = PROP_LOCEXPR;
gdb_assert (prop->data.baton != NULL);
@@ -17810,7 +17913,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17808,7 +17911,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
attr = dwarf2_attr (die, DW_AT_byte_stride, cu);
if (attr)
@ -296,7 +296,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
complaint (_("Missing DW_AT_byte_stride "
"- DIE at 0x%s [in module %s]"),
sect_offset_str (die->sect_off),
@@ -17818,7 +17921,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17816,7 +17919,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
attr = dwarf2_attr (die, DW_AT_lower_bound, cu);
if (attr)
@ -305,7 +305,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
else if (!low_default_is_valid)
complaint (_("Missing DW_AT_lower_bound "
"- DIE at %s [in module %s]"),
@@ -17827,10 +17930,10 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
@@ -17825,10 +17928,10 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
struct attribute *attr_ub, *attr_count;
attr = attr_ub = dwarf2_attr (die, DW_AT_upper_bound, cu);
@ -318,7 +318,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
{
/* If bounds are constant do the final calculation here. */
if (low.kind == PROP_CONST && high.kind == PROP_CONST)
@@ -25397,7 +25500,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
@@ -25394,7 +25497,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
attr = dwarf2_attr (die, DW_AT_allocated, cu);
if (attr_form_is_block (attr))
{
@ -327,7 +327,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
add_dyn_prop (DYN_PROP_ALLOCATED, prop, type);
}
else if (attr != NULL)
@@ -25411,7 +25514,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
@@ -25408,7 +25511,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
attr = dwarf2_attr (die, DW_AT_associated, cu);
if (attr_form_is_block (attr))
{
@ -336,7 +336,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
add_dyn_prop (DYN_PROP_ASSOCIATED, prop, type);
}
else if (attr != NULL)
@@ -25423,7 +25526,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
@@ -25420,7 +25523,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
/* Read DW_AT_data_location and set in type. */
attr = dwarf2_attr (die, DW_AT_data_location, cu);
@ -500,7 +500,7 @@ diff --git a/gdb/f-typeprint.c b/gdb/f-typeprint.c
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
--- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c
@@ -1913,7 +1913,8 @@ is_dynamic_type_internal (struct type *type, int top_level)
@@ -1897,7 +1897,8 @@ is_dynamic_type_internal (struct type *type, int top_level)
type = check_typedef (type);
/* We only want to recognize references at the outermost level. */
@ -510,7 +510,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
type = check_typedef (TYPE_TARGET_TYPE (type));
/* Types that have a dynamic TYPE_DATA_LOCATION are considered
@@ -1947,6 +1948,7 @@ is_dynamic_type_internal (struct type *type, int top_level)
@@ -1931,6 +1932,7 @@ is_dynamic_type_internal (struct type *type, int top_level)
}
case TYPE_CODE_ARRAY:
@ -518,7 +518,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
{
gdb_assert (TYPE_NFIELDS (type) == 1);
@@ -2065,7 +2067,8 @@ resolve_dynamic_array (struct type *type,
@@ -2049,7 +2051,8 @@ resolve_dynamic_array (struct type *type,
struct dynamic_prop *prop;
unsigned int bit_stride = 0;
@ -528,7 +528,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
type = copy_type (type);
@@ -2090,11 +2093,15 @@ resolve_dynamic_array (struct type *type,
@@ -2074,11 +2077,15 @@ resolve_dynamic_array (struct type *type,
ary_dim = check_typedef (TYPE_TARGET_TYPE (elt_type));
@ -545,7 +545,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
prop = get_dyn_prop (DYN_PROP_BYTE_STRIDE, type);
if (prop != NULL)
{
@@ -2249,6 +2256,28 @@ resolve_dynamic_struct (struct type *type,
@@ -2233,6 +2240,28 @@ resolve_dynamic_struct (struct type *type,
return resolved_type;
}
@ -574,7 +574,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
/* Worker for resolved_dynamic_type. */
static struct type *
@@ -2297,7 +2326,12 @@ resolve_dynamic_type_internal (struct type *type,
@@ -2281,7 +2310,12 @@ resolve_dynamic_type_internal (struct type *type,
break;
}
@ -1339,7 +1339,7 @@ diff --git a/gdb/valops.c b/gdb/valops.c
diff --git a/gdb/valprint.c b/gdb/valprint.c
--- a/gdb/valprint.c
+++ b/gdb/valprint.c
@@ -1108,12 +1108,6 @@ value_check_printable (struct value *val, struct ui_file *stream,
@@ -1106,12 +1106,6 @@ value_check_printable (struct value *val, struct ui_file *stream,
return 0;
}

View File

@ -38,7 +38,7 @@ diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
#include "common/underlying.h"
#include "common/byte-vector.h"
@@ -2158,6 +2159,20 @@ dwarf2_evaluate_loc_desc_full (struct type *type, struct frame_info *frame,
@@ -2157,6 +2158,20 @@ dwarf2_evaluate_loc_desc_full (struct type *type, struct frame_info *frame,
ctx.per_cu = per_cu;
ctx.obj_address = 0;

View File

@ -22,15 +22,15 @@
Name: %{?scl_prefix}gdb
# Freeze it when GDB gets branched
%global snapsrc 20190219
%global snapsrc 20190321
# See timestamp of source gnulib installed into gdb/gnulib/ .
%global snapgnulib 20161115
%global tarname gdb-%{version}
Version: 8.2.50.%{snapsrc}
Version: 8.3.50.%{snapsrc}
# The release always contains a leading reserved number, start it at 1.
# `upstream' is not a part of `name' to stay fully rpm dependencies compatible for the testing.
Release: 18.0.riscv64%{?dist}
Release: 4.0.riscv64%{?dist}
License: GPLv3+ and GPLv3+ with exceptions and GPLv2+ and GPLv2+ with exceptions and GPL+ and LGPLv2+ and LGPLv3+ and BSD and Public Domain and GFDL
# Do not provide URL for snapshots as the file lasts there only for 2 days.
@ -1030,9 +1030,30 @@ fi
%endif
%changelog
* Wed Feb 20 2019 David Abdurachmanov <david.abdurachmanov@gmail.com> - 8.2.50.20190219-18.0.riscv64.fc30
* Fri Apr 12 2019 David Abdurachmanov <david.abdurachmanov@gmail.com> - 8.3.50.20190321-4.0.riscv64
- Add support for RISC-V (riscv64)
* Fri Mar 29 2019 Sergio Durigan Junior <sergiodj@fedoraproject.org> - 8.3.50.20190321-4
- Fix 'gdb-8.3.50.20190321-3.fc31.x86_64: crashing' (by fixing
gdb-6.6-buildid-locate-rpm.patch) (RH BZ 1694091).
* Thu Mar 21 2019 Sergio Durigan Junior <sergiodj@redhat.com> - 8.3.50.20190321-3
- Rebase to FSF GDB 8.3.50.20190321 (8.4pre).
- Remove gdb-temporary-fix-arm-build-error.patch.
- Fix "GDB crashes when using Python xmethods" (RH BZ 1690120).
* Tue Mar 19 2019 Sergio Durigan Junior <sergiodj@redhat.com> - 8.3.50.20190319-2
- Rebase to FSF GDB 8.3.50.20190319 (8.4pre).
- Temporarily add gdb-temporary-fix-arm-build-error.patch.
* Mon Mar 4 2019 Sergio Durigan Junior <sergiodj@redhat.com> - 8.3.50.20190304-1
- Rebase to FSF GDB 8.3.50.20190304 (8.4pre).
- Rewrite gdb-6.6-buildid-locate.patch.
- Remove gdb-python-gil.patch.
* Fri Feb 22 2019 Sergio Durigan Junior <sergiodj@redhat.com> - 8.2.50.20190222-19
- Rebase to FSF GDB 8.2.50.20190222 (8.3pre).
* Tue Feb 19 2019 Sergio Durigan Junior <sergiodj@redhat.com> - 8.2.50.20190219-18
- Rebase to FSF GDB 8.2.50.20190219 (8.3pre).
- BuildRequire on 'source-highlight-devel' and enable styled output.

View File

@ -1,3 +1,3 @@
SHA512 (gdb-libstdc++-v3-python-8.1.1-20180626.tar.xz) = a8b1c54dd348cfeb37da73f968742896be3dd13a4215f8d8519870c2abea915f5176c3fa6989ddd10f20020a16f0fab20cbae68ee8d58a82234d8778023520f8
SHA512 (v2.0.tar.gz) = ec63151e842c81cc73ea11ba560b63e005cefbe19d98de24ae5c8caa4de7c9c1d71d1ec5b6214a347592eac675b75a3d2b26d4691ca86f91020ebfea8e912939
SHA512 (gdb-8.2.50.20190219.tar.xz) = 8c95b02681d3a996f3745d0a838f3837f4dcfad043b61ae24cececd029bbaa392b605841bb8a96f5d4a09d3412480edd8d3f6de5572074692cb5244c697a6358
SHA512 (gdb-8.3.50.20190321.tar.xz) = 4ab37571398418a3b5bc43cfe103ee585330bc3b076b113e3bf6c6c3ce5266b6e6b5040c1303ad0de62b8f4211df27e75795d7fce4fd1d9a96ec0308ace2fcf8