Rebase to FSF GDB 9.0.90.20200203 (9.1pre).

Bump 'snapgnulib' date.
Update URL to 'https'.
Adjust build-id patchset.
Adjust VLA patchset.
Drop 'gdb-6.8-bz436037-reg-no-longer-active.patch'.
Drop 'gdb-6.6-scheduler_locking-step-is-default.patch'.
This commit is contained in:
Sergio Durigan Junior 2020-02-04 15:06:34 -05:00
parent f258b03b2f
commit a5d2c85367
34 changed files with 396 additions and 655 deletions

2
.gitignore vendored
View File

@ -1,3 +1,3 @@
/gdb-libstdc++-v3-python-8.1.1-20180626.tar.xz /gdb-libstdc++-v3-python-8.1.1-20180626.tar.xz
/v2.0.1.tar.gz /v2.0.1.tar.gz
/gdb-9.0.50.20191119.tar.xz /gdb-9.0.90.20200203.tar.xz

View File

@ -102,281 +102,273 @@ Patch025: gdb-6.6-testsuite-timeouts.patch
#=fedoratest #=fedoratest
Patch026: gdb-6.6-bz237572-ppc-atomic-sequence-test.patch Patch026: 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?
Patch027: gdb-6.6-scheduler_locking-step-is-default.patch
# Test kernel VDSO decoding while attaching to an i386 process. # Test kernel VDSO decoding while attaching to an i386 process.
#=fedoratest #=fedoratest
Patch028: gdb-6.3-attach-see-vdso-test.patch Patch027: gdb-6.3-attach-see-vdso-test.patch
# Test leftover zombie process (BZ 243845). # Test leftover zombie process (BZ 243845).
#=fedoratest #=fedoratest
Patch029: gdb-6.5-bz243845-stale-testing-zombie-test.patch Patch028: gdb-6.5-bz243845-stale-testing-zombie-test.patch
# New locating of the matching binaries from the pure core file (build-id). # New locating of the matching binaries from the pure core file (build-id).
#=push+jan #=push+jan
Patch030: gdb-6.6-buildid-locate.patch Patch029: gdb-6.6-buildid-locate.patch
# Fix loading of core files without build-ids but with build-ids in executables. # 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 # Load strictly build-id-checked core files only if no executable is specified
# (Jan Kratochvil, RH BZ 1339862). # (Jan Kratochvil, RH BZ 1339862).
#=push+jan #=push+jan
Patch031: gdb-6.6-buildid-locate-solib-missing-ids.patch Patch030: gdb-6.6-buildid-locate-solib-missing-ids.patch
#=push+jan #=push+jan
Patch032: gdb-6.6-buildid-locate-rpm.patch Patch031: gdb-6.6-buildid-locate-rpm.patch
# Fix displaying of numeric char arrays as strings (BZ 224128). # Fix displaying of numeric char arrays as strings (BZ 224128).
#=fedoratest: But it is failing anyway, one should check the behavior more. #=fedoratest: But it is failing anyway, one should check the behavior more.
Patch033: gdb-6.7-charsign-test.patch Patch032: gdb-6.7-charsign-test.patch
# Test PPC hiding of call-volatile parameter register. # Test PPC hiding of call-volatile parameter register.
#=fedoratest #=fedoratest
Patch034: gdb-6.7-ppc-clobbered-registers-O2-test.patch Patch033: gdb-6.7-ppc-clobbered-registers-O2-test.patch
# Testsuite fixes for more stable/comparable results. # Testsuite fixes for more stable/comparable results.
#=fedoratest #=fedoratest
Patch035: gdb-6.7-testsuite-stable-results.patch Patch034: gdb-6.7-testsuite-stable-results.patch
# Test ia64 memory leaks of the code using libunwind. # Test ia64 memory leaks of the code using libunwind.
#=fedoratest #=fedoratest
Patch036: gdb-6.5-ia64-libunwind-leak-test.patch Patch035: gdb-6.5-ia64-libunwind-leak-test.patch
# Test hiding unexpected breakpoints on intentional step commands. # Test hiding unexpected breakpoints on intentional step commands.
#=fedoratest #=fedoratest
Patch037: gdb-6.5-missed-trap-on-step-test.patch Patch036: gdb-6.5-missed-trap-on-step-test.patch
# Test gcore memory and time requirements for large inferiors. # Test gcore memory and time requirements for large inferiors.
#=fedoratest #=fedoratest
Patch038: gdb-6.5-gcore-buffer-limit-test.patch Patch037: gdb-6.5-gcore-buffer-limit-test.patch
# Test GCORE for shmid 0 shared memory mappings. # Test GCORE for shmid 0 shared memory mappings.
#=fedoratest: But it is broken anyway, sometimes the case being tested is not reproducible. #=fedoratest: But it is broken anyway, sometimes the case being tested is not reproducible.
Patch039: gdb-6.3-mapping-zero-inode-test.patch Patch038: gdb-6.3-mapping-zero-inode-test.patch
# Test a crash on `focus cmd', `focus prev' commands. # Test a crash on `focus cmd', `focus prev' commands.
#=fedoratest #=fedoratest
Patch040: gdb-6.3-focus-cmd-prev-test.patch Patch039: gdb-6.3-focus-cmd-prev-test.patch
# Test various forms of threads tracking across exec() (BZ 442765). # Test various forms of threads tracking across exec() (BZ 442765).
#=fedoratest #=fedoratest
Patch041: gdb-6.8-bz442765-threaded-exec-test.patch Patch040: gdb-6.8-bz442765-threaded-exec-test.patch
# Test a crash on libraries missing the .text section. # Test a crash on libraries missing the .text section.
#=fedoratest #=fedoratest
Patch042: gdb-6.5-section-num-fixup-test.patch Patch041: gdb-6.5-section-num-fixup-test.patch
# Fix register assignments with no GDB stack frames (BZ 436037).
#=push+jan: This fix is incorrect.
Patch043: gdb-6.8-bz436037-reg-no-longer-active.patch
# Fix resolving of variables at locations lists in prelinked libs (BZ 466901). # Fix resolving of variables at locations lists in prelinked libs (BZ 466901).
#=fedoratest #=fedoratest
Patch044: gdb-6.8-bz466901-backtrace-full-prelinked.patch Patch042: gdb-6.8-bz466901-backtrace-full-prelinked.patch
# New test for step-resume breakpoint placed in multiple threads at once. # New test for step-resume breakpoint placed in multiple threads at once.
#=fedoratest #=fedoratest
Patch045: gdb-simultaneous-step-resume-breakpoint-test.patch Patch043: gdb-simultaneous-step-resume-breakpoint-test.patch
# Fix GNU/Linux core open: Can't read pathname for load map: Input/output error. # 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. # Fix regression of undisplayed missing shared libraries caused by a fix for.
#=fedoratest: It should be in glibc: libc-alpha: <20091004161706.GA27450@.*> #=fedoratest: It should be in glibc: libc-alpha: <20091004161706.GA27450@.*>
Patch046: gdb-core-open-vdso-warning.patch Patch044: gdb-core-open-vdso-warning.patch
# Fix stepping with OMP parallel Fortran sections (BZ 533176). # Fix stepping with OMP parallel Fortran sections (BZ 533176).
#=push+jan: It requires some better DWARF annotations. #=push+jan: It requires some better DWARF annotations.
Patch047: gdb-bz533176-fortran-omp-step.patch Patch045: gdb-bz533176-fortran-omp-step.patch
# Workaround ccache making lineno non-zero for command-line definitions. # Workaround ccache making lineno non-zero for command-line definitions.
#=fedoratest: ccache is rarely used and it is even fixed now. #=fedoratest: ccache is rarely used and it is even fixed now.
Patch048: gdb-ccache-workaround.patch Patch046: gdb-ccache-workaround.patch
#=push+jan: May get obsoleted by Tom's unrelocated objfiles patch. #=push+jan: May get obsoleted by Tom's unrelocated objfiles patch.
Patch049: gdb-archer-pie-addons.patch Patch047: gdb-archer-pie-addons.patch
#=push+jan: Breakpoints disabling matching should not be based on address. #=push+jan: Breakpoints disabling matching should not be based on address.
Patch050: gdb-archer-pie-addons-keep-disabled.patch Patch048: gdb-archer-pie-addons-keep-disabled.patch
# Testcase for "Do not make up line information" fix by Daniel Jacobowitz. # Testcase for "Do not make up line information" fix by Daniel Jacobowitz.
#=fedoratest #=fedoratest
Patch051: gdb-lineno-makeup-test.patch Patch049: gdb-lineno-makeup-test.patch
# Test power7 ppc disassembly. # Test power7 ppc disassembly.
#=fedoratest #=fedoratest
Patch052: gdb-ppc-power7-test.patch Patch050: gdb-ppc-power7-test.patch
# Workaround non-stop moribund locations exploited by kernel utrace (BZ 590623). # Workaround non-stop moribund locations exploited by kernel utrace (BZ 590623).
#=push+jan: Currently it is still not fully safe. #=push+jan: Currently it is still not fully safe.
Patch053: gdb-moribund-utrace-workaround.patch Patch051: gdb-moribund-utrace-workaround.patch
# Fix follow-exec for C++ programs (bugreported by Martin Stransky). # Fix follow-exec for C++ programs (bugreported by Martin Stransky).
#=fedoratest #=fedoratest
Patch054: gdb-archer-next-over-throw-cxx-exec.patch Patch052: gdb-archer-next-over-throw-cxx-exec.patch
# Backport DWARF-4 support (BZ 601887, Tom Tromey). # Backport DWARF-4 support (BZ 601887, Tom Tromey).
#=fedoratest #=fedoratest
Patch055: gdb-bz601887-dwarf4-rh-test.patch Patch053: gdb-bz601887-dwarf4-rh-test.patch
#=push+jan #=push+jan
Patch056: gdb-6.6-buildid-locate-core-as-arg.patch Patch054: gdb-6.6-buildid-locate-core-as-arg.patch
# Workaround librpm BZ 643031 due to its unexpected exit() calls (BZ 642879). # Workaround librpm BZ 643031 due to its unexpected exit() calls (BZ 642879).
#=push+jan #=push+jan
Patch057: gdb-6.6-buildid-locate-rpm-librpm-workaround.patch Patch055: gdb-6.6-buildid-locate-rpm-librpm-workaround.patch
# [delayed-symfile] Test a backtrace regression on CFIs without DIE (BZ 614604). # [delayed-symfile] Test a backtrace regression on CFIs without DIE (BZ 614604).
#=fedoratest #=fedoratest
Patch058: gdb-test-bt-cfi-without-die.patch Patch056: gdb-test-bt-cfi-without-die.patch
# Verify GDB Python built-in function gdb.solib_address exists (BZ # 634108). # Verify GDB Python built-in function gdb.solib_address exists (BZ # 634108).
#=fedoratest #=fedoratest
Patch059: gdb-bz634108-solib_address.patch Patch057: gdb-bz634108-solib_address.patch
# New test gdb.arch/x86_64-pid0-core.exp for kernel PID 0 cores (BZ 611435). # New test gdb.arch/x86_64-pid0-core.exp for kernel PID 0 cores (BZ 611435).
#=fedoratest #=fedoratest
Patch060: gdb-test-pid0-core.patch Patch058: gdb-test-pid0-core.patch
# [archer-tromey-delayed-symfile] New test gdb.dwarf2/dw2-aranges.exp. # [archer-tromey-delayed-symfile] New test gdb.dwarf2/dw2-aranges.exp.
#=fedoratest #=fedoratest
Patch061: gdb-test-dw2-aranges.patch Patch059: gdb-test-dw2-aranges.patch
# [archer-keiths-expr-cumulative+upstream] Import C++ testcases. # [archer-keiths-expr-cumulative+upstream] Import C++ testcases.
#=fedoratest #=fedoratest
Patch062: gdb-test-expr-cumulative-archer.patch Patch060: gdb-test-expr-cumulative-archer.patch
# Fix regressions on C++ names resolving (PR 11734, PR 12273, Keith Seitz). # Fix regressions on C++ names resolving (PR 11734, PR 12273, Keith Seitz).
#=fedoratest #=fedoratest
Patch063: gdb-physname-pr11734-test.patch Patch061: gdb-physname-pr11734-test.patch
# Fix regressions on C++ names resolving (PR 11734, PR 12273, Keith Seitz). # Fix regressions on C++ names resolving (PR 11734, PR 12273, Keith Seitz).
#=fedoratest #=fedoratest
Patch064: gdb-physname-pr12273-test.patch Patch062: gdb-physname-pr12273-test.patch
# Test GDB opcodes/ disassembly of Intel Ivy Bridge instructions (BZ 696890). # Test GDB opcodes/ disassembly of Intel Ivy Bridge instructions (BZ 696890).
#=fedoratest #=fedoratest
Patch065: gdb-test-ivy-bridge.patch Patch063: gdb-test-ivy-bridge.patch
# Hack for proper PIE run of the testsuite. # Hack for proper PIE run of the testsuite.
#=fedoratest #=fedoratest
Patch066: gdb-runtest-pie-override.patch Patch064: gdb-runtest-pie-override.patch
# Print reasons for failed attach/spawn incl. SELinux deny_ptrace (BZ 786878). # Print reasons for failed attach/spawn incl. SELinux deny_ptrace (BZ 786878).
#=push+jan #=push+jan
Patch067: gdb-attach-fail-reasons-5of5.patch Patch065: gdb-attach-fail-reasons-5of5.patch
# Workaround PR libc/14166 for inferior calls of strstr. # Workaround PR libc/14166 for inferior calls of strstr.
#=fedoratest: Compatibility with RHELs (unchecked which ones). #=fedoratest: Compatibility with RHELs (unchecked which ones).
Patch068: gdb-glibc-strstr-workaround.patch Patch066: gdb-glibc-strstr-workaround.patch
# Include testcase for `Unable to see a variable inside a module (XLF)' (BZ 823789). # Include testcase for `Unable to see a variable inside a module (XLF)' (BZ 823789).
#=fedoratest #=fedoratest
Patch069: gdb-rhel5.9-testcase-xlf-var-inside-mod.patch Patch067: gdb-rhel5.9-testcase-xlf-var-inside-mod.patch
# Testcase for `Setting solib-absolute-prefix breaks vDSO' (BZ 818343). # Testcase for `Setting solib-absolute-prefix breaks vDSO' (BZ 818343).
#=fedoratest #=fedoratest
Patch070: gdb-rhbz-818343-set-solib-absolute-prefix-testcase.patch Patch068: gdb-rhbz-818343-set-solib-absolute-prefix-testcase.patch
# Import regression test for `gdb/findvar.c:417: internal-error: # Import regression test for `gdb/findvar.c:417: internal-error:
# read_var_value: Assertion `frame' failed.' (RH BZ 947564) from RHEL 6.5. # read_var_value: Assertion `frame' failed.' (RH BZ 947564) from RHEL 6.5.
#=fedoratest #=fedoratest
Patch071: gdb-rhbz947564-findvar-assertion-frame-failed-testcase.patch Patch069: gdb-rhbz947564-findvar-assertion-frame-failed-testcase.patch
# Fix crash of -readnow /usr/lib/debug/usr/bin/gnatbind.debug (BZ 1069211). # Fix crash of -readnow /usr/lib/debug/usr/bin/gnatbind.debug (BZ 1069211).
#=push+jan #=push+jan
Patch072: gdb-gnat-dwarf-crash-3of3.patch Patch070: gdb-gnat-dwarf-crash-3of3.patch
# Fix 'memory leak in infpy_read_memory()' (RH BZ 1007614) # Fix 'memory leak in infpy_read_memory()' (RH BZ 1007614)
#=fedoratest #=fedoratest
Patch073: gdb-rhbz1007614-memleak-infpy_read_memory-test.patch Patch071: gdb-rhbz1007614-memleak-infpy_read_memory-test.patch
# Fix 'gdb gives highly misleading error when debuginfo pkg is present, # Fix 'gdb gives highly misleading error when debuginfo pkg is present,
# but not corresponding binary pkg' (RH BZ 981154). # but not corresponding binary pkg' (RH BZ 981154).
#=push+jan #=push+jan
Patch074: gdb-6.6-buildid-locate-misleading-warning-missing-debuginfo-rhbz981154.patch Patch072: gdb-6.6-buildid-locate-misleading-warning-missing-debuginfo-rhbz981154.patch
#=fedoratest #=fedoratest
Patch075: gdb-archer-vla-tests.patch Patch073: gdb-archer-vla-tests.patch
#=fedoratest #=fedoratest
Patch076: gdb-vla-intel-tests.patch Patch074: gdb-vla-intel-tests.patch
# Continue backtrace even if a frame filter throws an exception (Phil Muldoon). # Continue backtrace even if a frame filter throws an exception (Phil Muldoon).
#=push #=push
Patch077: gdb-btrobust.patch Patch075: gdb-btrobust.patch
# Display Fortran strings in backtraces. # Display Fortran strings in backtraces.
#=fedoratest #=fedoratest
Patch078: gdb-fortran-frame-string.patch Patch076: gdb-fortran-frame-string.patch
# Testcase for '[SAP] Recursive dlopen causes SAP HANA installer to # Testcase for '[SAP] Recursive dlopen causes SAP HANA installer to
# crash.' (RH BZ 1156192). # crash.' (RH BZ 1156192).
#=fedoratest #=fedoratest
Patch079: gdb-rhbz1156192-recursive-dlopen-test.patch Patch077: gdb-rhbz1156192-recursive-dlopen-test.patch
# Fix jit-reader.h for multi-lib. # Fix jit-reader.h for multi-lib.
#=push+jan #=push+jan
Patch080: gdb-jit-reader-multilib.patch Patch078: gdb-jit-reader-multilib.patch
# Fix '`catch syscall' doesn't work for parent after `fork' is called' # Fix '`catch syscall' doesn't work for parent after `fork' is called'
# (Philippe Waroquiers, RH BZ 1149205). # (Philippe Waroquiers, RH BZ 1149205).
#=fedoratest #=fedoratest
Patch081: gdb-rhbz1149205-catch-syscall-after-fork-test.patch Patch079: gdb-rhbz1149205-catch-syscall-after-fork-test.patch
# Fix 'backport GDB 7.4 fix to RHEL 6.6 GDB' [Original Sourceware bug # Fix 'backport GDB 7.4 fix to RHEL 6.6 GDB' [Original Sourceware bug
# description: 'C++ (and objc): Internal error on unqualified name # description: 'C++ (and objc): Internal error on unqualified name
# re-set', PR 11657] (RH BZ 1186476). # re-set', PR 11657] (RH BZ 1186476).
#=fedoratest #=fedoratest
Patch082: gdb-rhbz1186476-internal-error-unqualified-name-re-set-test.patch Patch080: gdb-rhbz1186476-internal-error-unqualified-name-re-set-test.patch
# Test 'info type-printers' Python error (RH BZ 1350436). # Test 'info type-printers' Python error (RH BZ 1350436).
#=fedoratest #=fedoratest
Patch083: gdb-rhbz1350436-type-printers-error.patch Patch081: gdb-rhbz1350436-type-printers-error.patch
# Fix '[ppc64] and [s390x] wrong prologue skip on -O2 -g code' (Jan # Fix '[ppc64] and [s390x] wrong prologue skip on -O2 -g code' (Jan
# Kratochvil, RH BZ 1084404). # Kratochvil, RH BZ 1084404).
#=fedoratest #=fedoratest
Patch084: gdb-rhbz1084404-ppc64-s390x-wrong-prologue-skip-O2-g-3of3.patch Patch082: gdb-rhbz1084404-ppc64-s390x-wrong-prologue-skip-O2-g-3of3.patch
# Never kill PID on: gdb exec PID (Jan Kratochvil, RH BZ 1219747). # Never kill PID on: gdb exec PID (Jan Kratochvil, RH BZ 1219747).
#=push+jan #=push+jan
Patch085: gdb-bz1219747-attach-kills.patch Patch083: gdb-bz1219747-attach-kills.patch
# Force libncursesw over libncurses to match the includes (RH BZ 1270534). # Force libncursesw over libncurses to match the includes (RH BZ 1270534).
#=push+jan #=push+jan
Patch086: gdb-fedora-libncursesw.patch Patch084: gdb-fedora-libncursesw.patch
# Test clflushopt instruction decode (for RH BZ 1262471). # Test clflushopt instruction decode (for RH BZ 1262471).
#=fedoratest #=fedoratest
Patch087: gdb-opcodes-clflushopt-test.patch Patch085: gdb-opcodes-clflushopt-test.patch
# [rhel6] DTS backward Python compatibility API (BZ 1020004, Phil Muldoon). # [rhel6] DTS backward Python compatibility API (BZ 1020004, Phil Muldoon).
#=fedora #=fedora
Patch088: gdb-dts-rhel6-python-compat.patch Patch086: gdb-dts-rhel6-python-compat.patch
# [SCL] Skip deprecated .gdb_index warning for Red Hat built files (BZ 953585). # [SCL] Skip deprecated .gdb_index warning for Red Hat built files (BZ 953585).
#=push+jan #=push+jan
Patch089: gdb-6.6-buildid-locate-rpm-scl.patch Patch087: gdb-6.6-buildid-locate-rpm-scl.patch
# Make the GDB quit processing non-abortable to cleanup everything properly. # 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 . #=fedora: It was useful only after gdb-6.8-attach-signalled-detach-stopped.patch .
Patch090: gdb-6.8-quit-never-aborts.patch Patch088: gdb-6.8-quit-never-aborts.patch
# [aarch64] Fix hardware watchpoints (RH BZ 1261564). # [aarch64] Fix hardware watchpoints (RH BZ 1261564).
#=fedoratest #=fedoratest
Patch091: gdb-rhbz1261564-aarch64-hw-watchpoint-test.patch Patch089: gdb-rhbz1261564-aarch64-hw-watchpoint-test.patch
# Add messages suggesting more recent RHEL gdbserver (RH BZ 1321114). # Add messages suggesting more recent RHEL gdbserver (RH BZ 1321114).
#=fedora #=fedora
Patch092: gdb-container-rh-pkg.patch Patch090: gdb-container-rh-pkg.patch
# New test for Python "Cannot locate object file for block" (for RH BZ 1325795). # New test for Python "Cannot locate object file for block" (for RH BZ 1325795).
#=fedoratest #=fedoratest
Patch093: gdb-rhbz1325795-framefilters-test.patch Patch091: gdb-rhbz1325795-framefilters-test.patch
# [dts+el7] [x86*] Bundle linux_perf.h for libipt (RH BZ 1256513). # [dts+el7] [x86*] Bundle linux_perf.h for libipt (RH BZ 1256513).
#=fedora #=fedora
Patch094: gdb-linux_perf-bundle.patch Patch092: gdb-linux_perf-bundle.patch
# Fix gdb-headless /usr/bin/ executables (BZ 1390251). # Fix gdb-headless /usr/bin/ executables (BZ 1390251).
# #
@ -385,20 +377,20 @@ Patch094: gdb-linux_perf-bundle.patch
# #
# https://fedoraproject.org/wiki/Changes/Minimal_GDB_in_buildroot # https://fedoraproject.org/wiki/Changes/Minimal_GDB_in_buildroot
#=fedora #=fedora
Patch095: gdb-libexec-add-index.patch Patch093: gdb-libexec-add-index.patch
# New testcase for: Fix <tab>-completion crash (Gary Benson, RH BZ 1398387). # New testcase for: Fix <tab>-completion crash (Gary Benson, RH BZ 1398387).
#=fedoratest #=fedoratest
Patch096: gdb-rhbz1398387-tab-crash-test.patch Patch094: gdb-rhbz1398387-tab-crash-test.patch
# Python patches of: http://sourceware.org/gdb/wiki/ProjectArcher # Python patches of: http://sourceware.org/gdb/wiki/ProjectArcher
#=push #=push
Patch097: gdb-archer.patch Patch095: gdb-archer.patch
# Revert upstream commit 469412dd9ccc4de5874fd3299b105833f36b34cd # Revert upstream commit 469412dd9ccc4de5874fd3299b105833f36b34cd
Patch098: gdb-vla-intel-fix-print-char-array.patch Patch096: gdb-vla-intel-fix-print-char-array.patch
# [s390x] Backport arch12 instructions decoding (RH BZ 1553104). # [s390x] Backport arch12 instructions decoding (RH BZ 1553104).
# =fedoratest # =fedoratest
Patch099: gdb-rhbz1553104-s390x-arch12-test.patch Patch097: gdb-rhbz1553104-s390x-arch12-test.patch

View File

@ -95,5 +95,3 @@
%patch095 -p1 %patch095 -p1
%patch096 -p1 %patch096 -p1
%patch097 -p1 %patch097 -p1
%patch098 -p1
%patch099 -p1

View File

@ -1 +1 @@
58bd3702d7aad95e08bcd05efc4ef4f1585305a9 4d37e9a90bbc62dbef44dc1f32c7334fc842590d

View File

@ -24,7 +24,6 @@ gdb-6.6-bz230000-power6-disassembly-test.patch
gdb-6.6-bz229517-gcore-without-terminal.patch gdb-6.6-bz229517-gcore-without-terminal.patch
gdb-6.6-testsuite-timeouts.patch gdb-6.6-testsuite-timeouts.patch
gdb-6.6-bz237572-ppc-atomic-sequence-test.patch gdb-6.6-bz237572-ppc-atomic-sequence-test.patch
gdb-6.6-scheduler_locking-step-is-default.patch
gdb-6.3-attach-see-vdso-test.patch gdb-6.3-attach-see-vdso-test.patch
gdb-6.5-bz243845-stale-testing-zombie-test.patch gdb-6.5-bz243845-stale-testing-zombie-test.patch
gdb-6.6-buildid-locate.patch gdb-6.6-buildid-locate.patch
@ -40,7 +39,6 @@ gdb-6.3-mapping-zero-inode-test.patch
gdb-6.3-focus-cmd-prev-test.patch gdb-6.3-focus-cmd-prev-test.patch
gdb-6.8-bz442765-threaded-exec-test.patch gdb-6.8-bz442765-threaded-exec-test.patch
gdb-6.5-section-num-fixup-test.patch gdb-6.5-section-num-fixup-test.patch
gdb-6.8-bz436037-reg-no-longer-active.patch
gdb-6.8-bz466901-backtrace-full-prelinked.patch gdb-6.8-bz466901-backtrace-full-prelinked.patch
gdb-simultaneous-step-resume-breakpoint-test.patch gdb-simultaneous-step-resume-breakpoint-test.patch
gdb-core-open-vdso-warning.patch gdb-core-open-vdso-warning.patch

View File

@ -16,7 +16,7 @@ Subject: gdb-6.3-gstack-20050411.patch
diff --git a/gdb/Makefile.in b/gdb/Makefile.in diff --git a/gdb/Makefile.in b/gdb/Makefile.in
--- a/gdb/Makefile.in --- a/gdb/Makefile.in
+++ b/gdb/Makefile.in +++ b/gdb/Makefile.in
@@ -1756,7 +1756,7 @@ info install-info clean-info dvi pdf install-pdf html install-html: force @@ -1768,7 +1768,7 @@ info install-info clean-info dvi pdf install-pdf html install-html: force
install: all install: all
@$(MAKE) $(FLAGS_TO_PASS) install-only @$(MAKE) $(FLAGS_TO_PASS) install-only
@ -25,7 +25,7 @@ diff --git a/gdb/Makefile.in b/gdb/Makefile.in
transformed_name=`t='$(program_transform_name)'; \ transformed_name=`t='$(program_transform_name)'; \
echo gdb | sed -e "$$t"` ; \ echo gdb | sed -e "$$t"` ; \
if test "x$$transformed_name" = x; then \ if test "x$$transformed_name" = x; then \
@@ -1805,7 +1805,25 @@ install-guile: @@ -1817,7 +1817,25 @@ install-guile:
install-python: install-python:
$(SHELL) $(srcdir)/../mkinstalldirs $(DESTDIR)$(GDB_DATADIR)/python/gdb $(SHELL) $(srcdir)/../mkinstalldirs $(DESTDIR)$(GDB_DATADIR)/python/gdb
@ -52,7 +52,7 @@ diff --git a/gdb/Makefile.in b/gdb/Makefile.in
transformed_name=`t='$(program_transform_name)'; \ transformed_name=`t='$(program_transform_name)'; \
echo gdb | sed -e $$t` ; \ echo gdb | sed -e $$t` ; \
if test "x$$transformed_name" = x; then \ if test "x$$transformed_name" = x; then \
@@ -1828,6 +1846,18 @@ uninstall: force $(CONFIG_UNINSTALL) @@ -1840,6 +1858,18 @@ uninstall: force $(CONFIG_UNINSTALL)
fi fi
@$(MAKE) DO=uninstall "DODIRS=$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do @$(MAKE) DO=uninstall "DODIRS=$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do

View File

@ -27,7 +27,7 @@ diff --git a/gdb/testsuite/gdb.gdb/selftest.exp b/gdb/testsuite/gdb.gdb/selftest
diff --git a/gdb/top.c b/gdb/top.c diff --git a/gdb/top.c b/gdb/top.c
--- a/gdb/top.c --- a/gdb/top.c
+++ b/gdb/top.c +++ b/gdb/top.c
@@ -2061,7 +2061,7 @@ init_gdb_version_vars (void) @@ -2096,7 +2096,7 @@ init_gdb_version_vars (void)
struct internalvar *major_version_var = create_internalvar ("_gdb_major"); struct internalvar *major_version_var = create_internalvar ("_gdb_major");
struct internalvar *minor_version_var = create_internalvar ("_gdb_minor"); struct internalvar *minor_version_var = create_internalvar ("_gdb_minor");
int vmajor = 0, vminor = 0, vrevision = 0; int vmajor = 0, vminor = 0, vrevision = 0;

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 diff --git a/gdb/printcmd.c b/gdb/printcmd.c
--- a/gdb/printcmd.c --- a/gdb/printcmd.c
+++ b/gdb/printcmd.c +++ b/gdb/printcmd.c
@@ -1212,6 +1212,10 @@ print_command_1 (const char *args, int voidprint) @@ -1214,6 +1214,10 @@ print_command_1 (const char *args, int voidprint)
if (exp != nullptr && *exp) if (exp != nullptr && *exp)
{ {

View File

@ -11,8 +11,8 @@ https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=218379
diff --git a/gdb/symtab.c b/gdb/symtab.c diff --git a/gdb/symtab.c b/gdb/symtab.c
--- a/gdb/symtab.c --- a/gdb/symtab.c
+++ b/gdb/symtab.c +++ b/gdb/symtab.c
@@ -3142,6 +3142,13 @@ find_pc_sect_line (CORE_ADDR pc, struct obj_section *section, int notcurrent) @@ -3166,6 +3166,13 @@ find_pc_sect_line (CORE_ADDR pc, struct obj_section *section, int notcurrent)
SYMBOL_LINKAGE_NAME (msymbol)); */ msymbol->linkage_name ()); */
; ;
/* fall through */ /* fall through */
+ /* `msymbol' trampoline may be located before its .text symbol + /* `msymbol' trampoline may be located before its .text symbol
@ -20,7 +20,7 @@ diff --git a/gdb/symtab.c b/gdb/symtab.c
+ Avoid `find_pc_sect_line'<->`find_pc_line' infinite loop. + Avoid `find_pc_sect_line'<->`find_pc_line' infinite loop.
+ Red Hat Bug 218379. */ + Red Hat Bug 218379. */
+ else if (BMSYMBOL_VALUE_ADDRESS (mfunsym) == pc) + else if (BMSYMBOL_VALUE_ADDRESS (mfunsym) == pc)
+ warning ("In stub for %s (0x%s); interlocked, please submit the binary to http://bugzilla.redhat.com", MSYMBOL_LINKAGE_NAME (msymbol.minsym), paddress (target_gdbarch (), pc)); + warning ("In stub for %s (0x%s); interlocked, please submit the binary to http://bugzilla.redhat.com", msymbol.minsym->linkage_name (), paddress (target_gdbarch (), pc));
+ /* fall through */ + /* fall through */
else else
return find_pc_line (BMSYMBOL_VALUE_ADDRESS (mfunsym), 0); return find_pc_line (BMSYMBOL_VALUE_ADDRESS (mfunsym), 0);

View File

@ -94,11 +94,11 @@ diff --git a/gdb/exec.c b/gdb/exec.c
+ +
+ if (is_core != 0) + if (is_core != 0)
+ throw_error (IS_CORE_ERROR, + throw_error (IS_CORE_ERROR,
+ _("\"%s\" is a core file.\n" + _("\"%s\" is a core file.\n"
+ "Please specify an executable to debug."), + "Please specify an executable to debug."),
+ scratch_pathname); + scratch_pathname);
+ else + else
+ error (_("\"%s\": not in executable format: %s"), + error (_("\"%ss\": not in executable format: %s"),
+ scratch_pathname, + scratch_pathname,
+ gdb_bfd_errmsg (bfd_get_error (), matching).c_str ()); + gdb_bfd_errmsg (bfd_get_error (), matching).c_str ());
} }
@ -120,7 +120,7 @@ diff --git a/gdb/gdbsupport/common-exceptions.h b/gdb/gdbsupport/common-exceptio
diff --git a/gdb/main.c b/gdb/main.c diff --git a/gdb/main.c b/gdb/main.c
--- a/gdb/main.c --- a/gdb/main.c
+++ b/gdb/main.c +++ b/gdb/main.c
@@ -489,6 +489,34 @@ struct cmdarg @@ -467,6 +467,34 @@ struct cmdarg
char *string; char *string;
}; };
@ -155,7 +155,7 @@ diff --git a/gdb/main.c b/gdb/main.c
static void static void
captured_main_1 (struct captured_main_args *context) captured_main_1 (struct captured_main_args *context)
{ {
@@ -929,6 +957,8 @@ captured_main_1 (struct captured_main_args *context) @@ -907,6 +935,8 @@ captured_main_1 (struct captured_main_args *context)
{ {
symarg = argv[optind]; symarg = argv[optind];
execarg = argv[optind]; execarg = argv[optind];
@ -164,7 +164,7 @@ diff --git a/gdb/main.c b/gdb/main.c
optind++; optind++;
} }
@@ -1085,12 +1115,25 @@ captured_main_1 (struct captured_main_args *context) @@ -1063,12 +1093,25 @@ captured_main_1 (struct captured_main_args *context)
&& symarg != NULL && symarg != NULL
&& strcmp (execarg, symarg) == 0) && strcmp (execarg, symarg) == 0)
{ {

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 diff --git a/gdb/build-id.c b/gdb/build-id.c
--- a/gdb/build-id.c --- a/gdb/build-id.c
+++ b/gdb/build-id.c +++ b/gdb/build-id.c
@@ -712,6 +712,19 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return) @@ -709,6 +709,19 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return)
#include <dlfcn.h> #include <dlfcn.h>
#endif #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 diff --git a/gdb/build-id.c b/gdb/build-id.c
--- a/gdb/build-id.c --- a/gdb/build-id.c
+++ b/gdb/build-id.c +++ b/gdb/build-id.c
@@ -746,7 +746,11 @@ static int missing_rpm_list_entries; @@ -743,7 +743,11 @@ static int missing_rpm_list_entries;
/* Returns the count of newly added rpms. */ /* Returns the count of newly added rpms. */
static int static int
@ -24,7 +24,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
{ {
static int rpm_init_done = 0; static int rpm_init_done = 0;
rpmts ts; rpmts ts;
@@ -853,7 +857,11 @@ missing_rpm_enlist (const char *filename) @@ -850,7 +854,11 @@ missing_rpm_enlist (const char *filename)
mi = rpmtsInitIterator_p (ts, RPMTAG_BASENAMES, filename, 0); mi = rpmtsInitIterator_p (ts, RPMTAG_BASENAMES, filename, 0);
if (mi != NULL) if (mi != NULL)
{ {
@ -36,7 +36,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
{ {
Header h; Header h;
char *debuginfo, **slot, *s, *s2; char *debuginfo, **slot, *s, *s2;
@@ -971,6 +979,37 @@ missing_rpm_enlist (const char *filename) @@ -968,6 +976,37 @@ missing_rpm_enlist (const char *filename)
xfree (debuginfo); xfree (debuginfo);
count++; count++;
} }
@ -74,7 +74,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
rpmdbFreeIterator_p (mi); rpmdbFreeIterator_p (mi);
} }
@@ -980,6 +1019,20 @@ missing_rpm_enlist (const char *filename) @@ -977,6 +1016,20 @@ missing_rpm_enlist (const char *filename)
return count; return count;
} }
@ -98,7 +98,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c --- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c
@@ -3494,6 +3494,16 @@ read_gdb_index_from_buffer (struct objfile *objfile, @@ -3497,6 +3497,16 @@ read_gdb_index_from_buffer (struct objfile *objfile,
"set use-deprecated-index-sections on". */ "set use-deprecated-index-sections on". */
if (version < 6 && !deprecated_ok) if (version < 6 && !deprecated_ok)
{ {
@ -115,7 +115,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
static int warning_printed = 0; static int warning_printed = 0;
if (!warning_printed) if (!warning_printed)
{ {
@@ -3505,6 +3515,10 @@ to use the section anyway."), @@ -3508,6 +3518,10 @@ to use the section anyway."),
warning_printed = 1; warning_printed = 1;
} }
return 0; return 0;

View File

@ -243,7 +243,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
#include "libbfd.h" #include "libbfd.h"
#include "objfiles.h" #include "objfiles.h"
#include "observable.h" #include "observable.h"
@@ -701,8 +702,359 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return) @@ -698,8 +699,359 @@ build_id_to_filename (const struct bfd_build_id *build_id, char **link_return)
return result; return result;
} }
@ -604,7 +604,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
avoidance. */ avoidance. */
struct missing_filepair struct missing_filepair
@@ -756,11 +1108,17 @@ missing_filepair_change (void) @@ -753,11 +1105,17 @@ missing_filepair_change (void)
/* All their memory came just from missing_filepair_OBSTACK. */ /* All their memory came just from missing_filepair_OBSTACK. */
missing_filepair_hash = NULL; missing_filepair_hash = NULL;
} }
@ -622,7 +622,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
missing_filepair_change (); missing_filepair_change ();
} }
@@ -827,14 +1185,39 @@ debug_print_missing (const char *binary, const char *debug) @@ -824,14 +1182,38 @@ debug_print_missing (const char *binary, const char *debug)
*slot = missing_filepair; *slot = missing_filepair;
@ -631,14 +631,13 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+#ifdef HAVE_LIBRPM +#ifdef HAVE_LIBRPM
+ if (missing_exec == MISSING_EXEC_NOT_TRIED) + if (missing_exec == MISSING_EXEC_NOT_TRIED)
+ { + {
+ char *execfilename; + const char *execfilename = get_exec_file (0);
- fprintf_unfiltered (gdb_stdlog, - fprintf_unfiltered (gdb_stdlog,
- _("Missing separate debuginfo for %s\n"), binary); - _("Missing separate debuginfo for %s\n"), binary);
- if (debug != NULL) - if (debug != NULL)
- fprintf_unfiltered (gdb_stdlog, _("Try to install the hash file %s\n"), - fprintf_unfiltered (gdb_stdlog, _("Try to install the hash file %s\n"),
- debug); - debug);
+ execfilename = get_exec_file (0);
+ if (execfilename != NULL) + if (execfilename != NULL)
+ { + {
+ if (missing_rpm_enlist (execfilename) == 0) + if (missing_rpm_enlist (execfilename) == 0)
@ -672,7 +671,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
diff --git a/gdb/config.in b/gdb/config.in diff --git a/gdb/config.in b/gdb/config.in
--- a/gdb/config.in --- a/gdb/config.in
+++ b/gdb/config.in +++ b/gdb/config.in
@@ -33,6 +33,9 @@ @@ -36,6 +36,9 @@
/* Define to BFD's default target vector. */ /* Define to BFD's default target vector. */
#undef DEFAULT_BFD_VEC #undef DEFAULT_BFD_VEC
@ -682,7 +681,7 @@ diff --git a/gdb/config.in b/gdb/config.in
/* Define to 1 if translation of program messages to the user's native /* Define to 1 if translation of program messages to the user's native
language is requested. */ language is requested. */
#undef ENABLE_NLS #undef ENABLE_NLS
@@ -246,6 +249,9 @@ @@ -245,6 +248,9 @@
/* Define if you have the mpfr library. */ /* Define if you have the mpfr library. */
#undef HAVE_LIBMPFR #undef HAVE_LIBMPFR
@ -695,7 +694,7 @@ diff --git a/gdb/config.in b/gdb/config.in
diff --git a/gdb/configure b/gdb/configure diff --git a/gdb/configure b/gdb/configure
--- a/gdb/configure --- a/gdb/configure
+++ b/gdb/configure +++ b/gdb/configure
@@ -756,6 +756,11 @@ CODESIGN_CERT @@ -761,6 +761,11 @@ CODESIGN_CERT
HAVE_NATIVE_GCORE_TARGET HAVE_NATIVE_GCORE_TARGET
TARGET_OBS TARGET_OBS
subdirs subdirs
@ -707,7 +706,7 @@ diff --git a/gdb/configure b/gdb/configure
GDB_DATADIR GDB_DATADIR
DEBUGDIR DEBUGDIR
MAKEINFO_EXTRA_FLAGS MAKEINFO_EXTRA_FLAGS
@@ -859,6 +864,7 @@ with_gdb_datadir @@ -864,6 +869,7 @@ with_gdb_datadir
with_relocated_sources with_relocated_sources
with_auto_load_dir with_auto_load_dir
with_auto_load_safe_path with_auto_load_safe_path
@ -715,7 +714,7 @@ diff --git a/gdb/configure b/gdb/configure
enable_targets enable_targets
enable_64_bit_bfd enable_64_bit_bfd
enable_gdbmi enable_gdbmi
@@ -921,6 +927,11 @@ CCC @@ -926,6 +932,11 @@ CCC
CPP CPP
MAKEINFO MAKEINFO
MAKEINFOFLAGS MAKEINFOFLAGS
@ -727,7 +726,7 @@ diff --git a/gdb/configure b/gdb/configure
YACC YACC
YFLAGS YFLAGS
XMKMF' XMKMF'
@@ -1593,6 +1604,8 @@ Optional Packages: @@ -1598,6 +1609,8 @@ Optional Packages:
[--with-auto-load-dir] [--with-auto-load-dir]
--without-auto-load-safe-path --without-auto-load-safe-path
do not restrict auto-loaded files locations do not restrict auto-loaded files locations
@ -736,7 +735,7 @@ diff --git a/gdb/configure b/gdb/configure
--with-libunwind-ia64 use libunwind frame unwinding for ia64 targets --with-libunwind-ia64 use libunwind frame unwinding for ia64 targets
--with-curses use the curses library instead of the termcap --with-curses use the curses library instead of the termcap
library library
@@ -1656,6 +1669,13 @@ Some influential environment variables: @@ -1661,6 +1674,13 @@ Some influential environment variables:
MAKEINFO Parent configure detects if it is of sufficient version. MAKEINFO Parent configure detects if it is of sufficient version.
MAKEINFOFLAGS MAKEINFOFLAGS
Parameters for MAKEINFO. Parameters for MAKEINFO.
@ -750,7 +749,7 @@ diff --git a/gdb/configure b/gdb/configure
YACC The `Yet Another Compiler Compiler' implementation to use. YACC The `Yet Another Compiler Compiler' implementation to use.
Defaults to the first program found out of: `bison -y', `byacc', Defaults to the first program found out of: `bison -y', `byacc',
`yacc'. `yacc'.
@@ -6515,6 +6535,494 @@ _ACEOF @@ -6587,6 +6607,494 @@ _ACEOF
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_auto_load_safe_path" >&5
$as_echo "$with_auto_load_safe_path" >&6; } $as_echo "$with_auto_load_safe_path" >&6; }
@ -1448,30 +1447,18 @@ diff --git a/gdb/configure.ac b/gdb/configure.ac
AC_CONFIG_SUBDIRS(testsuite) AC_CONFIG_SUBDIRS(testsuite)
# Check whether to support alternative target configurations # Check whether to support alternative target configurations
diff --git a/gdb/corelow.c b/gdb/corelow.c
--- a/gdb/corelow.c
+++ b/gdb/corelow.c
@@ -363,7 +363,7 @@ build_id_locate_exec (int from_tty)
symfile_objfile->flags |= OBJF_BUILD_ID_CORE_LOADED;
}
else
- debug_print_missing (_("the main executable file"), build_id_filename);
+ debug_print_missing (BUILD_ID_MAIN_EXECUTABLE_FILENAME, build_id_filename);
/* No automatic SOLIB_ADD as the libraries would get read twice. */
}
diff --git a/gdb/event-top.c b/gdb/event-top.c diff --git a/gdb/event-top.c b/gdb/event-top.c
--- a/gdb/event-top.c --- a/gdb/event-top.c
+++ b/gdb/event-top.c +++ b/gdb/event-top.c
@@ -40,6 +40,7 @@ @@ -41,6 +41,7 @@
#include "gdbsupport/buffer.h"
#include "ser-event.h" #include "ser-event.h"
#include "gdb_select.h" #include "gdb_select.h"
#include "gdbsupport/gdb-sigmask.h"
+#include "symfile.h" +#include "symfile.h"
/* readline include files. */ /* readline include files. */
#include "readline/readline.h" #include "readline/readline.h"
@@ -362,6 +363,8 @@ display_gdb_prompt (const char *new_prompt) @@ -363,6 +364,8 @@ display_gdb_prompt (const char *new_prompt)
/* Reset the nesting depth used when trace-commands is set. */ /* Reset the nesting depth used when trace-commands is set. */
reset_command_nest_depth (); reset_command_nest_depth ();
@ -1480,7 +1467,7 @@ diff --git a/gdb/event-top.c b/gdb/event-top.c
/* Do not call the python hook on an explicit prompt change as /* Do not call the python hook on an explicit prompt change as
passed to this function, as this forms a secondary/local prompt, passed to this function, as this forms a secondary/local prompt,
IE, displayed but not set. */ IE, displayed but not set. */
@@ -771,7 +774,10 @@ command_line_handler (gdb::unique_xmalloc_ptr<char> &&rl) @@ -772,7 +775,10 @@ command_line_handler (gdb::unique_xmalloc_ptr<char> &&rl)
command_handler (cmd); command_handler (cmd);
if (ui->prompt_state != PROMPTED) if (ui->prompt_state != PROMPTED)

View File

@ -104,9 +104,9 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
-build_id_bfd_get (bfd *abfd) -build_id_bfd_get (bfd *abfd)
+build_id_bfd_shdr_get (bfd *abfd) +build_id_bfd_shdr_get (bfd *abfd)
{ {
if (!bfd_check_format (abfd, bfd_object)) if (!bfd_check_format (abfd, bfd_object)
return NULL; && !bfd_check_format (abfd, bfd_core))
@@ -42,6 +100,348 @@ build_id_bfd_get (bfd *abfd) @@ -43,6 +101,348 @@ build_id_bfd_get (bfd *abfd)
return NULL; return NULL;
} }
@ -455,7 +455,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
/* See build-id.h. */ /* See build-id.h. */
int int
@@ -50,7 +450,7 @@ build_id_verify (bfd *abfd, size_t check_len, const bfd_byte *check) @@ -51,7 +451,7 @@ build_id_verify (bfd *abfd, size_t check_len, const bfd_byte *check)
const struct bfd_build_id *found; const struct bfd_build_id *found;
int retval = 0; int retval = 0;
@ -464,7 +464,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
if (found == NULL) if (found == NULL)
warning (_("File \"%s\" has no build-id, file skipped"), warning (_("File \"%s\" has no build-id, file skipped"),
@@ -65,62 +465,173 @@ build_id_verify (bfd *abfd, size_t check_len, const bfd_byte *check) @@ -66,56 +466,159 @@ build_id_verify (bfd *abfd, size_t check_len, const bfd_byte *check)
return retval; return retval;
} }
@ -510,8 +510,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
-build_id_to_debug_bfd_1 (const std::string &link, size_t build_id_len, -build_id_to_debug_bfd_1 (const std::string &link, size_t build_id_len,
- const bfd_byte *build_id) - const bfd_byte *build_id)
+build_id_to_debug_bfd_1 (const std::string &orig_link, size_t build_id_len, +build_id_to_debug_bfd_1 (const std::string &orig_link, size_t build_id_len,
+ const bfd_byte *build_id, char **link_return, + const bfd_byte *build_id, char **link_return)
+ int add_debug_suffix)
{ {
+ gdb_bfd_ref_ptr ret_bfd = {}; + gdb_bfd_ref_ptr ret_bfd = {};
+ std::string ret_link; + std::string ret_link;
@ -552,10 +551,6 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
- { - {
- if (separate_debug_file_debug) - if (separate_debug_file_debug)
- printf_unfiltered (_(" no, unable to open.\n")); - printf_unfiltered (_(" no, unable to open.\n"));
+ if (add_debug_suffix)
+ link += ".debug";
- return {};
+ ret_link = link; + ret_link = link;
+ +
+ struct stat statbuf_trash; + struct stat statbuf_trash;
@ -580,7 +575,8 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+ +
+ continue; + continue;
+ } + }
+
- return {};
+ /* We expect to be silent on the non-existing files. */ + /* We expect to be silent on the non-existing files. */
+ gdb_bfd_ref_ptr debug_bfd = gdb_bfd_open (filename.get (), gnutarget, -1); + gdb_bfd_ref_ptr debug_bfd = gdb_bfd_open (filename.get (), gnutarget, -1);
+ +
@ -611,6 +607,8 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
{ {
if (separate_debug_file_debug) if (separate_debug_file_debug)
- printf_unfiltered (_(" no, build-id does not match.\n")); - printf_unfiltered (_(" no, build-id does not match.\n"));
-
- return {};
+ printf_unfiltered (_(" yes!\n")); + printf_unfiltered (_(" yes!\n"));
+ } + }
+ else + else
@ -619,15 +617,11 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+ always the non-.%u-suffixed file. */ + always the non-.%u-suffixed file. */
+ std::string link0 = orig_link; + std::string link0 = orig_link;
+ +
+ if (add_debug_suffix)
+ link0 += ".debug";
+
+ /* If the symlink has target request to install the target. + /* If the symlink has target request to install the target.
+ BASE-debuginfo.rpm contains the symlink but BASE.rpm may be missing. + BASE-debuginfo.rpm contains the symlink but BASE.rpm may be missing.
+ https://bugzilla.redhat.com/show_bug.cgi?id=981154 */ + https://bugzilla.redhat.com/show_bug.cgi?id=981154 */
+ std::string link0_resolved (link_resolve (link0.c_str (), 0)); + std::string link0_resolved (link_resolve (link0.c_str (), 0));
+
- return {};
+ if (link_all.empty ()) + if (link_all.empty ())
+ link_all = link0_resolved; + link_all = link0_resolved;
+ else + else
@ -656,16 +650,17 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+ return ret_bfd; + return ret_bfd;
} }
/* See build-id.h. */ /* Common code for finding BFDs of a given build-id. This function
@@ -124,7 +627,7 @@ build_id_to_debug_bfd_1 (const std::string &link, size_t build_id_len,
gdb_bfd_ref_ptr static gdb_bfd_ref_ptr
-build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id) build_id_to_bfd_suffix (size_t build_id_len, const bfd_byte *build_id,
+build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id, - const char *suffix)
+ char **link_return, int add_debug_suffix) + const char *suffix, char **link_return)
{ {
/* Keep backward compatibility so that DEBUG_FILE_DIRECTORY being "" will /* Keep backward compatibility so that DEBUG_FILE_DIRECTORY being "" will
cause "/.build-id/..." lookups. */ cause "/.build-id/..." lookups. */
@@ -143,16 +654,16 @@ build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id) @@ -147,16 +650,17 @@ build_id_to_bfd_suffix (size_t build_id_len, const bfd_byte *build_id,
if (size > 0) if (size > 0)
{ {
size--; size--;
@ -678,26 +673,25 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
while (size-- > 0) while (size-- > 0)
string_appendf (link, "%02x", (unsigned) *data++); string_appendf (link, "%02x", (unsigned) *data++);
- link += ".debug"; link += suffix;
-
gdb_bfd_ref_ptr debug_bfd 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);
+ = 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);
+ link_return, add_debug_suffix);
if (debug_bfd != NULL) if (debug_bfd != NULL)
return debug_bfd; return debug_bfd;
@@ -166,7 +677,8 @@ build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id) @@ -170,7 +674,8 @@ build_id_to_bfd_suffix (size_t build_id_len, const bfd_byte *build_id,
if (strcmp (gdb_sysroot, TARGET_SYSROOT_PREFIX) != 0) if (strcmp (gdb_sysroot, TARGET_SYSROOT_PREFIX) != 0)
{ {
link = gdb_sysroot + link; 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);
+ 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); + link_return);
if (debug_bfd != NULL) if (debug_bfd != NULL)
return debug_bfd; return debug_bfd;
} }
@@ -175,22 +687,189 @@ build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id) @@ -179,38 +684,208 @@ build_id_to_bfd_suffix (size_t build_id_len, const bfd_byte *build_id,
return {}; return {};
} }
@ -707,7 +701,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+ gdb_bfd_ref_ptr abfd; + gdb_bfd_ref_ptr abfd;
+ char *result; + char *result;
+ +
+ abfd = build_id_to_debug_bfd (build_id->size, build_id->data, link_return, 0); + abfd = build_id_to_exec_bfd (build_id->size, build_id->data, link_return);
+ if (abfd == NULL) + if (abfd == NULL)
+ return NULL; + return NULL;
+ +
@ -853,6 +847,29 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
+ +
/* See build-id.h. */ /* See build-id.h. */
gdb_bfd_ref_ptr
-build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id)
+build_id_to_debug_bfd (size_t build_id_len, const bfd_byte *build_id,
+ char **link_return)
{
- return build_id_to_bfd_suffix (build_id_len, build_id, ".debug");
+ return build_id_to_bfd_suffix (build_id_len, build_id, ".debug",
+ link_return);
}
/* See build-id.h. */
gdb_bfd_ref_ptr
-build_id_to_exec_bfd (size_t build_id_len, const bfd_byte *build_id)
+build_id_to_exec_bfd (size_t build_id_len, const bfd_byte *build_id,
+ char **link_return)
{
- return build_id_to_bfd_suffix (build_id_len, build_id, "");
+ return build_id_to_bfd_suffix (build_id_len, build_id, "", link_return);
}
/* See build-id.h. */
std::string std::string
-find_separate_debug_file_by_buildid (struct objfile *objfile) -find_separate_debug_file_by_buildid (struct objfile *objfile)
+find_separate_debug_file_by_buildid (struct objfile *objfile, +find_separate_debug_file_by_buildid (struct objfile *objfile,
@ -875,7 +892,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
gdb_bfd_ref_ptr abfd (build_id_to_debug_bfd (build_id->size, gdb_bfd_ref_ptr abfd (build_id_to_debug_bfd (build_id->size,
- build_id->data)); - build_id->data));
+ build_id->data, + build_id->data,
+ (!build_id_filename_return ? NULL : &build_id_filename_cstr), 1)); + (!build_id_filename_return ? NULL : &build_id_filename_cstr)));
+ if (build_id_filename_return) + if (build_id_filename_return)
+ { + {
+ if (!build_id_filename_cstr) + if (!build_id_filename_cstr)
@ -890,7 +907,7 @@ diff --git a/gdb/build-id.c b/gdb/build-id.c
/* Prevent looping on a stripped .debug file. */ /* Prevent looping on a stripped .debug file. */
if (abfd != NULL if (abfd != NULL
&& filename_cmp (bfd_get_filename (abfd.get ()), && filename_cmp (bfd_get_filename (abfd.get ()),
@@ -203,3 +882,21 @@ find_separate_debug_file_by_buildid (struct objfile *objfile) @@ -223,3 +898,21 @@ find_separate_debug_file_by_buildid (struct objfile *objfile)
return std::string (); return std::string ();
} }
@ -928,18 +945,26 @@ diff --git a/gdb/build-id.h b/gdb/build-id.h
/* Return true if ABFD has NT_GNU_BUILD_ID matching the CHECK value. /* Return true if ABFD has NT_GNU_BUILD_ID matching the CHECK value.
Otherwise, issue a warning and return false. */ Otherwise, issue a warning and return false. */
@@ -39,14 +40,19 @@ extern int build_id_verify (bfd *abfd, @@ -38,21 +39,26 @@ extern int build_id_verify (bfd *abfd,
the caller. */ can be found, return NULL. */
extern gdb_bfd_ref_ptr build_id_to_debug_bfd (size_t build_id_len, extern gdb_bfd_ref_ptr build_id_to_debug_bfd (size_t build_id_len,
- const bfd_byte *build_id); - const bfd_byte *build_id);
+ const bfd_byte *build_id, + const bfd_byte *build_id,
+ char **link_return, + char **link_return);
+ int add_debug_suffix);
+ +
+extern char *build_id_to_filename (const struct bfd_build_id *build_id, +extern char *build_id_to_filename (const struct bfd_build_id *build_id,
+ char **link_return); + char **link_return);
/* Find and open a BFD for an executable file given a build-id. If no BFD
can be found, return NULL. The returned reference to the BFD must be
released by the caller. */
extern gdb_bfd_ref_ptr build_id_to_exec_bfd (size_t build_id_len,
- const bfd_byte *build_id);
+ const bfd_byte *build_id,
+ char **link_return);
/* Find the separate debug file for OBJFILE, by using the build-id /* Find the separate debug file for OBJFILE, by using the build-id
associated with OBJFILE's BFD. If successful, returns the file name for the associated with OBJFILE's BFD. If successful, returns the file name for the
separate debug file, otherwise, return an empty string. */ separate debug file, otherwise, return an empty string. */
@ -978,72 +1003,44 @@ diff --git a/gdb/corelow.c b/gdb/corelow.c
#include "inferior.h" #include "inferior.h"
#include "infrun.h" #include "infrun.h"
#include "symtab.h" #include "symtab.h"
@@ -321,6 +325,49 @@ add_to_thread_list (bfd *abfd, asection *asect, void *reg_sect_arg) @@ -322,6 +326,8 @@ add_to_thread_list (bfd *abfd, asection *asect, void *reg_sect_arg)
inferior_ptid = ptid; /* Yes, make it current. */ inferior_ptid = ptid; /* Yes, make it current. */
} }
+static bool build_id_core_loads = true; +static bool build_id_core_loads = true;
+
+static void
+build_id_locate_exec (int from_tty)
+{
+ CORE_ADDR at_entry;
+ gdb::unique_xmalloc_ptr<struct bfd_build_id> build_id;
+ gdb::unique_xmalloc_ptr<char> execfilename;
+ char *build_id_filename;
+
+ if (exec_bfd != NULL || symfile_objfile != NULL)
+ return;
+
+ if (target_auxv_search (current_top_target (), AT_ENTRY, &at_entry) <= 0)
+ return;
+
+ build_id.reset (build_id_addr_get (at_entry));
+ if (build_id == NULL)
+ return;
+
+ /* SYMFILE_OBJFILE should refer to the main executable (not only to its
+ separate debug info file). gcc44+ keeps .eh_frame only in the main
+ executable without its duplicate .debug_frame in the separate debug info
+ file - such .eh_frame would not be found if SYMFILE_OBJFILE would refer
+ directly to the separate debug info file. */
+
+ execfilename.reset (build_id_to_filename (build_id.get (),
+ &build_id_filename));
+
+ if (execfilename != NULL)
+ {
+ 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);
+
+ /* No automatic SOLIB_ADD as the libraries would get read twice. */
+}
+ +
/* Issue a message saying we have no core to debug, if FROM_TTY. */ /* Issue a message saying we have no core to debug, if FROM_TTY. */
static void static void
@@ -456,6 +503,14 @@ core_target_open (const char *arg, int from_tty) @@ -358,19 +364,25 @@ core_file_command (const char *filename, int from_tty)
switch_to_thread (thread); static void
locate_exec_from_corefile_build_id (bfd *abfd, int from_tty)
{
- const bfd_build_id *build_id = build_id_bfd_get (abfd);
+ const bfd_build_id *build_id = build_id_bfd_shdr_get (abfd);
if (build_id == nullptr)
return;
+ char *build_id_filename;
gdb_bfd_ref_ptr execbfd
- = build_id_to_exec_bfd (build_id->size, build_id->data);
+ = build_id_to_exec_bfd (build_id->size, build_id->data,
+ &build_id_filename);
if (execbfd != nullptr)
{
exec_file_attach (bfd_get_filename (execbfd.get ()), from_tty);
symbol_file_add_main (bfd_get_filename (execbfd.get ()),
symfile_add_flag (from_tty ? SYMFILE_VERBOSE : 0));
+ if (symfile_objfile != NULL)
+ symfile_objfile->flags |= OBJF_BUILD_ID_CORE_LOADED;
} }
+ else
+ debug_print_missing (BUILD_ID_MAIN_EXECUTABLE_FILENAME, build_id_filename);
}
+ /* Find the build_id identifiers. If it gets executed after /* See gdbcore.h. */
+ POST_CREATE_INFERIOR we would clash with asking to discard the already @@ -998,4 +1010,11 @@ void
+ loaded VDSO symbols. If it gets executed before bfd_map_over_sections
+ INFERIOR_PTID is still not set and libthread_db initialization crashes on
+ PID == 0 in ps_pglobal_lookup. */
+ if (build_id_core_loads != false)
+ build_id_locate_exec (from_tty);
+
post_create_inferior (target, from_tty);
/* Now go through the target stack looking for threads since there
@@ -973,4 +1028,11 @@ void
_initialize_corelow (void) _initialize_corelow (void)
{ {
add_target (core_target_info, core_target_open, filename_completer); add_target (core_target_info, core_target_open, filename_completer);
@ -1058,7 +1055,7 @@ diff --git a/gdb/corelow.c b/gdb/corelow.c
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
--- a/gdb/doc/gdb.texinfo --- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo
@@ -20830,6 +20830,27 @@ information files. @@ -20862,6 +20862,27 @@ information files.
@end table @end table
@ -1111,16 +1108,16 @@ diff --git a/gdb/dwarf-index-cache.c b/gdb/dwarf-index-cache.c
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c --- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c
@@ -2715,7 +2715,7 @@ dwarf2_get_dwz_file (struct dwarf2_per_objfile *dwarf2_per_objfile) @@ -2718,7 +2718,7 @@ dwarf2_get_dwz_file (struct dwarf2_per_objfile *dwarf2_per_objfile)
} }
if (dwz_bfd == NULL) if (dwz_bfd == NULL)
- dwz_bfd = build_id_to_debug_bfd (buildid_len, buildid); - dwz_bfd = build_id_to_debug_bfd (buildid_len, buildid);
+ dwz_bfd = build_id_to_debug_bfd (buildid_len, buildid, NULL, 1); + dwz_bfd = build_id_to_debug_bfd (buildid_len, buildid, NULL);
if (dwz_bfd == NULL) if (dwz_bfd == NULL)
error (_("could not find '.gnu_debugaltlink' file for %s"), error (_("could not find '.gnu_debugaltlink' file for %s"),
@@ -6273,7 +6273,7 @@ get_gdb_index_contents_from_section (objfile *obj, T *section_owner) @@ -6276,7 +6276,7 @@ get_gdb_index_contents_from_section (objfile *obj, T *section_owner)
static gdb::array_view<const gdb_byte> static gdb::array_view<const gdb_byte>
get_gdb_index_contents_from_cache (objfile *obj, dwarf2_per_objfile *dwarf2_obj) get_gdb_index_contents_from_cache (objfile *obj, dwarf2_per_objfile *dwarf2_obj)
{ {
@ -1129,7 +1126,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
if (build_id == nullptr) if (build_id == nullptr)
return {}; return {};
@@ -6286,7 +6286,7 @@ get_gdb_index_contents_from_cache (objfile *obj, dwarf2_per_objfile *dwarf2_obj) @@ -6289,7 +6289,7 @@ get_gdb_index_contents_from_cache (objfile *obj, dwarf2_per_objfile *dwarf2_obj)
static gdb::array_view<const gdb_byte> static gdb::array_view<const gdb_byte>
get_gdb_index_contents_from_cache_dwz (objfile *obj, dwz_file *dwz) get_gdb_index_contents_from_cache_dwz (objfile *obj, dwz_file *dwz)
{ {

View File

@ -1,78 +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-6.6-scheduler_locking-step-is-default.patch
;; Make upstream `set scheduler-locking step' as default.
;;=push+jan: How much is scheduler-locking relevant after non-stop?
diff --git a/gdb/infrun.c b/gdb/infrun.c
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -2057,7 +2057,7 @@ static const char *const scheduler_enums[] = {
schedlock_replay,
NULL
};
-static const char *scheduler_mode = schedlock_replay;
+static const char *scheduler_mode = schedlock_step;
static void
show_scheduler_mode (struct ui_file *file, int from_tty,
struct cmd_list_element *c, const char *value)
diff --git a/gdb/testsuite/gdb.mi/mi-cli.exp b/gdb/testsuite/gdb.mi/mi-cli.exp
--- a/gdb/testsuite/gdb.mi/mi-cli.exp
+++ b/gdb/testsuite/gdb.mi/mi-cli.exp
@@ -199,7 +199,7 @@ mi_expect_stop "breakpoint-hit" "main" "" ".*basics.c" \
# Test that the token is output even for CLI commands
# Also test that *stopped includes frame information.
mi_gdb_test "34 next" \
- ".*34\\\^running.*\\*running,thread-id=\"all\"" \
+ ".*34\\\^running.*\\*running,thread-id=\"1\"" \
"34 next: run"
# Test that the new current source line is output to the console
diff --git a/gdb/testsuite/gdb.mi/mi-console.exp b/gdb/testsuite/gdb.mi/mi-console.exp
--- a/gdb/testsuite/gdb.mi/mi-console.exp
+++ b/gdb/testsuite/gdb.mi/mi-console.exp
@@ -60,6 +60,9 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
mi_run_to_main
+# thread-id=\"all\" vs. thread-id=\"1\" below:
+mi_gdb_test "210-gdb-set scheduler-locking off" "210\\^done" "set scheduler-locking off"
+
# The output we get from the target depends on how it is hosted. If
# we are semihosted (e.g., the sim or a remote target that supports
# the File I/O remote protocol extension), we see the target I/O
diff --git a/gdb/testsuite/gdb.mi/mi-logging.exp b/gdb/testsuite/gdb.mi/mi-logging.exp
--- a/gdb/testsuite/gdb.mi/mi-logging.exp
+++ b/gdb/testsuite/gdb.mi/mi-logging.exp
@@ -53,7 +53,7 @@ close $chan
set mi_log_prompt "\[(\]gdb\[)\] \[\r\n\]+"
-if [regexp "\\^done\[\r\n\]+$mi_log_prompt\\^running\[\r\n\]+\\*running,thread-id=\"all\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt\\^running\[\r\n\]+\\*running,thread-id=\"all\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt" $logcontent] {
+if [regexp "\\^done\[\r\n\]+$mi_log_prompt\\^running\[\r\n\]+\\*running,thread-id=\"1\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt\\^running\[\r\n\]+\\*running,thread-id=\"1\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt" $logcontent] {
pass "log file contents"
} else {
fail "log file contents"
@@ -76,7 +76,7 @@ set chan [open $milogfile]
set logcontent [read $chan]
close $chan
-if [regexp "1001\\^done\[\r\n\]+$mi_log_prompt.*1002\\^running\[\r\n\]+\\*running,thread-id=\"all\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt.*1003\\^running\[\r\n\]+\\*running,thread-id=\"all\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt" $logcontent] {
+if [regexp "1001\\^done\[\r\n\]+$mi_log_prompt.*1002\\^running\[\r\n\]+\\*running,thread-id=\"1\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt.*1003\\^running\[\r\n\]+\\*running,thread-id=\"1\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt" $logcontent] {
pass "redirect log file contents"
} else {
fail "redirect log file contents"
diff --git a/gdb/testsuite/gdb.opt/inline-cmds.exp b/gdb/testsuite/gdb.opt/inline-cmds.exp
--- a/gdb/testsuite/gdb.opt/inline-cmds.exp
+++ b/gdb/testsuite/gdb.opt/inline-cmds.exp
@@ -331,7 +331,7 @@ proc mi_cli_step {cli_output_re message} {
send_gdb "interpreter-exec console \"step\"\n"
gdb_expect {
- -re "\\^running\r\n\\*running,thread-id=\"all\"\r\n${mi_gdb_prompt}${cli_output_re}" {
+ -re "\\^running\r\n\\*running,thread-id=\"1\"\r\n${mi_gdb_prompt}${cli_output_re}" {
pass $message
}
timeout {

View File

@ -1,37 +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-6.8-bz436037-reg-no-longer-active.patch
;; Fix register assignments with no GDB stack frames (BZ 436037).
;;=push+jan: This fix is incorrect.
diff --git a/gdb/valops.c b/gdb/valops.c
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -1093,6 +1093,8 @@ value_assign (struct value *toval, struct value *fromval)
struct gdbarch *gdbarch;
int value_reg;
+ value_reg = VALUE_REGNUM (toval);
+
/* Figure out which frame this is in currently.
We use VALUE_FRAME_ID for obtaining the value's frame id instead of
@@ -1102,8 +1104,14 @@ value_assign (struct value *toval, struct value *fromval)
frame. */
frame = frame_find_by_id (VALUE_FRAME_ID (toval));
- value_reg = VALUE_REGNUM (toval);
-
+ /* "set $reg+=1" should work on programs with no debug info,
+ but frame_find_by_id returns NULL here (RH bug 436037).
+ Use current frame, it represents CPU state in this case.
+ If frame_find_by_id is changed to do it internally
+ (it is contemplated there), remove this. */
+ if (!frame)
+ frame = get_current_frame ();
+ /* Probably never happens. */
if (!frame)
error (_("Value being assigned to is no longer active."));

View File

@ -45,7 +45,7 @@ diff --git a/gdb/extension.c b/gdb/extension.c
diff --git a/gdb/top.c b/gdb/top.c diff --git a/gdb/top.c b/gdb/top.c
--- a/gdb/top.c --- a/gdb/top.c
+++ b/gdb/top.c +++ b/gdb/top.c
@@ -1668,7 +1668,13 @@ quit_force (int *exit_arg, int from_tty) @@ -1703,7 +1703,13 @@ quit_force (int *exit_arg, int from_tty)
qt.from_tty = from_tty; qt.from_tty = from_tty;

View File

@ -8,7 +8,7 @@ Subject: gdb-archer-pie-addons-keep-disabled.patch
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
--- a/gdb/breakpoint.c --- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c +++ b/gdb/breakpoint.c
@@ -15372,6 +15372,50 @@ static struct cmd_list_element *enablebreaklist = NULL; @@ -15396,6 +15396,51 @@ static struct cmd_list_element *enablebreaklist = NULL;
cmd_list_element *commands_cmd_element = nullptr; cmd_list_element *commands_cmd_element = nullptr;
@ -56,13 +56,14 @@ diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
+ bp_location_is_less_than); + bp_location_is_less_than);
+} +}
+ +
+void _initialize_breakpoint (void);
void void
_initialize_breakpoint (void) _initialize_breakpoint (void)
{ {
diff --git a/gdb/breakpoint.h b/gdb/breakpoint.h diff --git a/gdb/breakpoint.h b/gdb/breakpoint.h
--- a/gdb/breakpoint.h --- a/gdb/breakpoint.h
+++ b/gdb/breakpoint.h +++ b/gdb/breakpoint.h
@@ -1690,6 +1690,9 @@ extern const char *ep_parse_optional_if_clause (const char **arg); @@ -1696,6 +1696,9 @@ extern const char *ep_parse_optional_if_clause (const char **arg);
UIOUT iff debugging multiple threads. */ UIOUT iff debugging multiple threads. */
extern void maybe_print_thread_hit_breakpoint (struct ui_out *uiout); extern void maybe_print_thread_hit_breakpoint (struct ui_out *uiout);
@ -87,3 +88,15 @@ diff --git a/gdb/objfiles.c b/gdb/objfiles.c
/* Data changed. */ /* Data changed. */
return 1; return 1;
} }
diff --git a/gdb/value.c b/gdb/value.c
--- a/gdb/value.c
+++ b/gdb/value.c
@@ -2840,7 +2840,7 @@ value_static_field (struct type *type, int fieldno)
case FIELD_LOC_KIND_PHYSADDR:
retval = value_at_lazy (TYPE_FIELD_TYPE (type, fieldno),
TYPE_FIELD_STATIC_PHYSADDR (type, fieldno)
- + (TYPE_OBJFILE (type) == NULL ? 0 : TYPE_OBJFILE (type)->section_offsets[SECT_OFF_TEXT (TYPE_OBJFILE (type))]));
+ + (TYPE_OBJFILE (type) == NULL ? 0 : ANOFFSET (TYPE_OBJFILE (type)->section_offsets, SECT_OFF_TEXT (TYPE_OBJFILE (type)))));
break;
case FIELD_LOC_KIND_PHYSNAME:
{

View File

@ -8,7 +8,7 @@ Subject: gdb-archer-pie-addons.patch
diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
--- a/gdb/gdbtypes.h --- a/gdb/gdbtypes.h
+++ b/gdb/gdbtypes.h +++ b/gdb/gdbtypes.h
@@ -510,6 +510,7 @@ enum field_loc_kind @@ -516,6 +516,7 @@ enum field_loc_kind
{ {
FIELD_LOC_KIND_BITPOS, /**< bitpos */ FIELD_LOC_KIND_BITPOS, /**< bitpos */
FIELD_LOC_KIND_ENUMVAL, /**< enumval */ FIELD_LOC_KIND_ENUMVAL, /**< enumval */
@ -16,7 +16,7 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
FIELD_LOC_KIND_PHYSADDR, /**< physaddr */ FIELD_LOC_KIND_PHYSADDR, /**< physaddr */
FIELD_LOC_KIND_PHYSNAME, /**< physname */ FIELD_LOC_KIND_PHYSNAME, /**< physname */
FIELD_LOC_KIND_DWARF_BLOCK /**< dwarf_block */ FIELD_LOC_KIND_DWARF_BLOCK /**< dwarf_block */
@@ -561,6 +562,7 @@ union field_location @@ -566,6 +567,7 @@ union field_location
field. Otherwise, physname is the mangled label of the field. Otherwise, physname is the mangled label of the
static field. */ static field. */
@ -24,7 +24,7 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
CORE_ADDR physaddr; CORE_ADDR physaddr;
const char *physname; const char *physname;
@@ -1455,6 +1457,7 @@ extern void set_type_vptr_basetype (struct type *, struct type *); @@ -1474,6 +1476,7 @@ extern void set_type_vptr_basetype (struct type *, struct type *);
#define FIELD_ENUMVAL_LVAL(thisfld) ((thisfld).loc.enumval) #define FIELD_ENUMVAL_LVAL(thisfld) ((thisfld).loc.enumval)
#define FIELD_ENUMVAL(thisfld) (FIELD_ENUMVAL_LVAL (thisfld) + 0) #define FIELD_ENUMVAL(thisfld) (FIELD_ENUMVAL_LVAL (thisfld) + 0)
#define FIELD_STATIC_PHYSNAME(thisfld) ((thisfld).loc.physname) #define FIELD_STATIC_PHYSNAME(thisfld) ((thisfld).loc.physname)
@ -32,7 +32,7 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
#define FIELD_STATIC_PHYSADDR(thisfld) ((thisfld).loc.physaddr) #define FIELD_STATIC_PHYSADDR(thisfld) ((thisfld).loc.physaddr)
#define FIELD_DWARF_BLOCK(thisfld) ((thisfld).loc.dwarf_block) #define FIELD_DWARF_BLOCK(thisfld) ((thisfld).loc.dwarf_block)
#define SET_FIELD_BITPOS(thisfld, bitpos) \ #define SET_FIELD_BITPOS(thisfld, bitpos) \
@@ -1466,6 +1469,7 @@ extern void set_type_vptr_basetype (struct type *, struct type *); @@ -1485,6 +1488,7 @@ extern void set_type_vptr_basetype (struct type *, struct type *);
#define SET_FIELD_PHYSNAME(thisfld, name) \ #define SET_FIELD_PHYSNAME(thisfld, name) \
(FIELD_LOC_KIND (thisfld) = FIELD_LOC_KIND_PHYSNAME, \ (FIELD_LOC_KIND (thisfld) = FIELD_LOC_KIND_PHYSNAME, \
FIELD_STATIC_PHYSNAME (thisfld) = (name)) FIELD_STATIC_PHYSNAME (thisfld) = (name))
@ -40,7 +40,7 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
#define SET_FIELD_PHYSADDR(thisfld, addr) \ #define SET_FIELD_PHYSADDR(thisfld, addr) \
(FIELD_LOC_KIND (thisfld) = FIELD_LOC_KIND_PHYSADDR, \ (FIELD_LOC_KIND (thisfld) = FIELD_LOC_KIND_PHYSADDR, \
FIELD_STATIC_PHYSADDR (thisfld) = (addr)) FIELD_STATIC_PHYSADDR (thisfld) = (addr))
@@ -1482,6 +1486,7 @@ extern void set_type_vptr_basetype (struct type *, struct type *); @@ -1501,6 +1505,7 @@ extern void set_type_vptr_basetype (struct type *, struct type *);
#define TYPE_FIELD_BITPOS(thistype, n) FIELD_BITPOS (TYPE_FIELD (thistype, n)) #define TYPE_FIELD_BITPOS(thistype, n) FIELD_BITPOS (TYPE_FIELD (thistype, n))
#define TYPE_FIELD_ENUMVAL(thistype, n) FIELD_ENUMVAL (TYPE_FIELD (thistype, n)) #define TYPE_FIELD_ENUMVAL(thistype, n) FIELD_ENUMVAL (TYPE_FIELD (thistype, n))
#define TYPE_FIELD_STATIC_PHYSNAME(thistype, n) FIELD_STATIC_PHYSNAME (TYPE_FIELD (thistype, n)) #define TYPE_FIELD_STATIC_PHYSNAME(thistype, n) FIELD_STATIC_PHYSNAME (TYPE_FIELD (thistype, n))
@ -51,13 +51,13 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
diff --git a/gdb/value.c b/gdb/value.c diff --git a/gdb/value.c b/gdb/value.c
--- a/gdb/value.c --- a/gdb/value.c
+++ b/gdb/value.c +++ b/gdb/value.c
@@ -2829,7 +2829,8 @@ value_static_field (struct type *type, int fieldno) @@ -2839,7 +2839,8 @@ value_static_field (struct type *type, int fieldno)
{ {
case FIELD_LOC_KIND_PHYSADDR: case FIELD_LOC_KIND_PHYSADDR:
retval = value_at_lazy (TYPE_FIELD_TYPE (type, fieldno), retval = value_at_lazy (TYPE_FIELD_TYPE (type, fieldno),
- TYPE_FIELD_STATIC_PHYSADDR (type, fieldno)); - TYPE_FIELD_STATIC_PHYSADDR (type, fieldno));
+ TYPE_FIELD_STATIC_PHYSADDR (type, fieldno) + TYPE_FIELD_STATIC_PHYSADDR (type, fieldno)
+ + (TYPE_OBJFILE (type) == NULL ? 0 : ANOFFSET (TYPE_OBJFILE (type)->section_offsets, SECT_OFF_TEXT (TYPE_OBJFILE (type))))); + + (TYPE_OBJFILE (type) == NULL ? 0 : TYPE_OBJFILE (type)->section_offsets[SECT_OFF_TEXT (TYPE_OBJFILE (type))]));
break; break;
case FIELD_LOC_KIND_PHYSNAME: case FIELD_LOC_KIND_PHYSNAME:
{ {

View File

@ -45,7 +45,7 @@ gdb/gdbserver/
diff --git a/gdb/config.in b/gdb/config.in diff --git a/gdb/config.in b/gdb/config.in
--- a/gdb/config.in --- a/gdb/config.in
+++ b/gdb/config.in +++ b/gdb/config.in
@@ -252,6 +252,9 @@ @@ -251,6 +251,9 @@
/* Define if librpm library is being used. */ /* Define if librpm library is being used. */
#undef HAVE_LIBRPM #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. */ /* Define to 1 if you have the <libunwind-ia64.h> header file. */
#undef HAVE_LIBUNWIND_IA64_H #undef HAVE_LIBUNWIND_IA64_H
@@ -378,6 +381,9 @@ @@ -386,6 +389,9 @@
/* Define to 1 if you have the `scm_new_smob' function. */ /* Define to 1 if you have the `scm_new_smob' function. */
#undef HAVE_SCM_NEW_SMOB #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 diff --git a/gdb/configure b/gdb/configure
--- a/gdb/configure --- a/gdb/configure
+++ b/gdb/configure +++ b/gdb/configure
@@ -15594,6 +15594,64 @@ cat >>confdefs.h <<_ACEOF @@ -16434,6 +16434,64 @@ cat >>confdefs.h <<_ACEOF
_ACEOF _ACEOF
@ -150,7 +150,7 @@ diff --git a/gdb/configure.ac b/gdb/configure.ac
diff --git a/gdb/gdbserver/config.in b/gdb/gdbserver/config.in diff --git a/gdb/gdbserver/config.in b/gdb/gdbserver/config.in
--- a/gdb/gdbserver/config.in --- a/gdb/gdbserver/config.in
+++ b/gdb/gdbserver/config.in +++ b/gdb/gdbserver/config.in
@@ -126,6 +126,9 @@ @@ -125,6 +125,9 @@
/* Define to 1 if you have the `dl' library (-ldl). */ /* Define to 1 if you have the `dl' library (-ldl). */
#undef HAVE_LIBDL #undef HAVE_LIBDL
@ -160,7 +160,7 @@ diff --git a/gdb/gdbserver/config.in b/gdb/gdbserver/config.in
/* Define if the target supports branch tracing. */ /* Define if the target supports branch tracing. */
#undef HAVE_LINUX_BTRACE #undef HAVE_LINUX_BTRACE
@@ -202,6 +205,9 @@ @@ -210,6 +213,9 @@
/* Define to 1 if you have the `pwrite' function. */ /* Define to 1 if you have the `pwrite' function. */
#undef HAVE_PWRITE #undef HAVE_PWRITE
@ -173,7 +173,7 @@ diff --git a/gdb/gdbserver/config.in b/gdb/gdbserver/config.in
diff --git a/gdb/gdbserver/configure b/gdb/gdbserver/configure diff --git a/gdb/gdbserver/configure b/gdb/gdbserver/configure
--- a/gdb/gdbserver/configure --- a/gdb/gdbserver/configure
+++ b/gdb/gdbserver/configure +++ b/gdb/gdbserver/configure
@@ -8522,6 +8522,64 @@ if $want_ipa ; then @@ -9398,6 +9398,64 @@ if $want_ipa ; then
fi fi
fi fi
@ -255,7 +255,7 @@ diff --git a/gdb/gdbserver/configure.ac b/gdb/gdbserver/configure.ac
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
--- a/gdb/gdbserver/linux-low.c --- a/gdb/gdbserver/linux-low.c
+++ b/gdb/gdbserver/linux-low.c +++ b/gdb/gdbserver/linux-low.c
@@ -967,7 +967,16 @@ linux_ptrace_fun () @@ -968,7 +968,16 @@ linux_ptrace_fun ()
{ {
if (ptrace (PTRACE_TRACEME, 0, (PTRACE_TYPE_ARG3) 0, if (ptrace (PTRACE_TRACEME, 0, (PTRACE_TYPE_ARG3) 0,
(PTRACE_TYPE_ARG4) 0) < 0) (PTRACE_TYPE_ARG4) 0) < 0)
@ -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 diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
--- a/gdb/linux-nat.c --- a/gdb/linux-nat.c
+++ b/gdb/linux-nat.c +++ b/gdb/linux-nat.c
@@ -1091,7 +1091,16 @@ linux_nat_target::create_inferior (const char *exec_file, @@ -1092,7 +1092,16 @@ linux_nat_target::create_inferior (const char *exec_file,
/* Make sure we report all signals during startup. */ /* Make sure we report all signals during startup. */
pass_signals ({}); pass_signals ({});

View File

@ -80,7 +80,7 @@ gdb/testsuite/ChangeLog
diff --git a/gdb/main.c b/gdb/main.c diff --git a/gdb/main.c b/gdb/main.c
--- a/gdb/main.c --- a/gdb/main.c
+++ b/gdb/main.c +++ b/gdb/main.c
@@ -1170,7 +1170,10 @@ captured_main_1 (struct captured_main_args *context) @@ -1148,7 +1148,10 @@ captured_main_1 (struct captured_main_args *context)
{ {
ret = catch_command_errors (attach_command, pid_or_core_arg, ret = catch_command_errors (attach_command, pid_or_core_arg,
!batch_flag); !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 diff --git a/gdb/infrun.c b/gdb/infrun.c
--- a/gdb/infrun.c --- a/gdb/infrun.c
+++ b/gdb/infrun.c +++ b/gdb/infrun.c
@@ -6454,6 +6454,16 @@ process_event_stop_test (struct execution_control_state *ecs) @@ -6453,6 +6453,16 @@ process_event_stop_test (struct execution_control_state *ecs)
if (ecs->event_thread->control.step_over_calls == STEP_OVER_ALL) if (ecs->event_thread->control.step_over_calls == STEP_OVER_ALL)
{ {
@ -38,16 +38,16 @@ diff --git a/gdb/infrun.c b/gdb/infrun.c
+ struct minimal_symbol *stopf = lookup_minimal_symbol_by_pc (stop_pc).minsym; + struct minimal_symbol *stopf = lookup_minimal_symbol_by_pc (stop_pc).minsym;
+ +
+ if ((stop_fn == NULL + if ((stop_fn == NULL
+ || strstr (SYMBOL_LINKAGE_NAME (stop_fn), ".omp_fn.") == NULL) + || strstr (stop_fn->linkage_name (), ".omp_fn.") == NULL)
+ /* gcc-4.7.2-9.fc19.x86_64 uses a new format. */ + /* gcc-4.7.2-9.fc19.x86_64 uses a new format. */
+ && (stopf == NULL + && (stopf == NULL
+ || strstr (MSYMBOL_LINKAGE_NAME (stopf), "._omp_fn.") == NULL)) + || strstr (stopf->linkage_name (), "._omp_fn.") == NULL))
+{ /* ".omp_fn." */ +{ /* ".omp_fn." */
+ +
/* We're doing a "next". /* We're doing a "next".
Normal (forward) execution: set a breakpoint at the Normal (forward) execution: set a breakpoint at the
@@ -6487,6 +6497,7 @@ process_event_stop_test (struct execution_control_state *ecs) @@ -6486,6 +6496,7 @@ process_event_stop_test (struct execution_control_state *ecs)
keep_going (ecs); keep_going (ecs);
return; return;

View File

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

View File

@ -12,7 +12,7 @@ https://bugzilla.redhat.com/show_bug.cgi?id=1270534
diff --git a/gdb/configure b/gdb/configure diff --git a/gdb/configure b/gdb/configure
--- a/gdb/configure --- a/gdb/configure
+++ b/gdb/configure +++ b/gdb/configure
@@ -9303,6 +9303,7 @@ if test x"$prefer_curses" = xyes; then @@ -9375,6 +9375,7 @@ if test x"$prefer_curses" = xyes; then
# search /usr/local/include, if ncurses is installed in /usr/local. A # search /usr/local/include, if ncurses is installed in /usr/local. A
# default installation of ncurses on alpha*-dec-osf* will lead to such # default installation of ncurses on alpha*-dec-osf* will lead to such
# a situation. # a situation.
@ -20,7 +20,7 @@ diff --git a/gdb/configure b/gdb/configure
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing waddstr" >&5
$as_echo_n "checking for library containing waddstr... " >&6; } $as_echo_n "checking for library containing waddstr... " >&6; }
if ${ac_cv_search_waddstr+:} false; then : if ${ac_cv_search_waddstr+:} false; then :
@@ -9327,7 +9328,7 @@ return waddstr (); @@ -9399,7 +9400,7 @@ return waddstr ();
return 0; return 0;
} }
_ACEOF _ACEOF
@ -29,7 +29,7 @@ diff --git a/gdb/configure b/gdb/configure
if test -z "$ac_lib"; then if test -z "$ac_lib"; then
ac_res="none required" ac_res="none required"
else else
@@ -9401,6 +9402,7 @@ case $host_os in @@ -9473,6 +9474,7 @@ case $host_os in
esac esac
# These are the libraries checked by Readline. # These are the libraries checked by Readline.
@ -37,7 +37,7 @@ diff --git a/gdb/configure b/gdb/configure
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
$as_echo_n "checking for library containing tgetent... " >&6; } $as_echo_n "checking for library containing tgetent... " >&6; }
if ${ac_cv_search_tgetent+:} false; then : if ${ac_cv_search_tgetent+:} false; then :
@@ -9425,7 +9427,7 @@ return tgetent (); @@ -9497,7 +9499,7 @@ return tgetent ();
return 0; return 0;
} }
_ACEOF _ACEOF

View File

@ -42,7 +42,7 @@ gdb/
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c --- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c
@@ -10654,6 +10654,13 @@ private: @@ -10657,6 +10657,13 @@ private:
static void static void
process_die (struct die_info *die, struct dwarf2_cu *cu) process_die (struct die_info *die, struct dwarf2_cu *cu)
{ {
@ -59,7 +59,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
diff --git a/gdb/infrun.c b/gdb/infrun.c diff --git a/gdb/infrun.c b/gdb/infrun.c
--- a/gdb/infrun.c --- a/gdb/infrun.c
+++ b/gdb/infrun.c +++ b/gdb/infrun.c
@@ -602,6 +602,13 @@ holding the child stopped. Try \"set detach-on-fork\" or \ @@ -601,6 +601,13 @@ holding the child stopped. Try \"set detach-on-fork\" or \
target_pid_to_str (process_ptid).c_str ()); target_pid_to_str (process_ptid).c_str ());
} }
@ -76,7 +76,7 @@ diff --git a/gdb/infrun.c b/gdb/infrun.c
diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
--- a/gdb/linux-nat.c --- a/gdb/linux-nat.c
+++ b/gdb/linux-nat.c +++ b/gdb/linux-nat.c
@@ -188,6 +188,12 @@ struct linux_nat_target *linux_target; @@ -189,6 +189,12 @@ struct linux_nat_target *linux_target;
/* Does the current host support PTRACE_GETREGSET? */ /* Does the current host support PTRACE_GETREGSET? */
enum tribool have_ptrace_getregset = TRIBOOL_UNKNOWN; enum tribool have_ptrace_getregset = TRIBOOL_UNKNOWN;
@ -89,7 +89,7 @@ diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
static unsigned int debug_linux_nat; static unsigned int debug_linux_nat;
static void static void
show_debug_linux_nat (struct ui_file *file, int from_tty, show_debug_linux_nat (struct ui_file *file, int from_tty,
@@ -1029,6 +1035,9 @@ linux_nat_post_attach_wait (ptid_t ptid, int *signalled) @@ -1030,6 +1036,9 @@ linux_nat_post_attach_wait (ptid_t ptid, int *signalled)
if (debug_linux_nat) if (debug_linux_nat)
fprintf_unfiltered (gdb_stdlog, fprintf_unfiltered (gdb_stdlog,
"LNPAW: Attaching to a stopped process\n"); "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 /* The process is definitely stopped. It is in a job control
stop, unless the kernel predates the TASK_STOPPED / stop, unless the kernel predates the TASK_STOPPED /
@@ -1360,6 +1369,25 @@ get_detach_signal (struct lwp_info *lp) @@ -1361,6 +1370,25 @@ get_detach_signal (struct lwp_info *lp)
return gdb_signal_to_host (signo); return gdb_signal_to_host (signo);
} }
@ -125,7 +125,7 @@ diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
return 0; return 0;
} }
@@ -1508,6 +1536,10 @@ linux_nat_target::detach (inferior *inf, int from_tty) @@ -1509,6 +1537,10 @@ linux_nat_target::detach (inferior *inf, int from_tty)
detach_one_lwp (main_lwp, &signo); detach_one_lwp (main_lwp, &signo);
detach_success (inf); detach_success (inf);
@ -136,7 +136,7 @@ diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
} }
} }
@@ -1765,6 +1797,16 @@ linux_nat_target::resume (ptid_t ptid, int step, enum gdb_signal signo) @@ -1766,6 +1798,16 @@ linux_nat_target::resume (ptid_t ptid, int step, enum gdb_signal signo)
return; return;
} }
@ -153,7 +153,7 @@ diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c
if (resume_many) if (resume_many)
iterate_over_lwps (ptid, [=] (struct lwp_info *info) iterate_over_lwps (ptid, [=] (struct lwp_info *info)
{ {
@@ -3769,6 +3811,10 @@ linux_nat_target::mourn_inferior () @@ -3770,6 +3812,10 @@ linux_nat_target::mourn_inferior ()
/* Let the arch-specific native code know this process is gone. */ /* Let the arch-specific native code know this process is gone. */
linux_target->low_forget_process (pid); linux_target->low_forget_process (pid);

View File

@ -9,7 +9,7 @@ Subject: gdb-jit-reader-multilib.patch
diff --git a/gdb/configure b/gdb/configure diff --git a/gdb/configure b/gdb/configure
--- a/gdb/configure --- a/gdb/configure
+++ b/gdb/configure +++ b/gdb/configure
@@ -9622,10 +9622,12 @@ _ACEOF @@ -9694,10 +9694,12 @@ _ACEOF

View File

@ -9,7 +9,7 @@ Subject: gdb-linux_perf-bundle.patch
diff --git a/gdb/configure b/gdb/configure diff --git a/gdb/configure b/gdb/configure
--- a/gdb/configure --- a/gdb/configure
+++ b/gdb/configure +++ b/gdb/configure
@@ -11833,7 +11833,7 @@ else @@ -11905,7 +11905,7 @@ else
#include <linux/perf_event.h> #include <linux/perf_event.h>
#ifndef PERF_ATTR_SIZE_VER5 #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 diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
--- a/gdb/breakpoint.c --- a/gdb/breakpoint.c
+++ b/gdb/breakpoint.c +++ b/gdb/breakpoint.c
@@ -11872,6 +11872,8 @@ update_global_location_list (enum ugll_insert_mode insert_mode) @@ -11904,6 +11904,8 @@ update_global_location_list (enum ugll_insert_mode insert_mode)
traps we can no longer explain. */ traps we can no longer explain. */
old_loc->events_till_retirement = 3 * (thread_count () + 1); old_loc->events_till_retirement = 3 * (thread_count () + 1);

View File

@ -22,7 +22,7 @@ And adjust its testcase.
diff --git a/gdb/f-valprint.c b/gdb/f-valprint.c diff --git a/gdb/f-valprint.c b/gdb/f-valprint.c
--- a/gdb/f-valprint.c --- a/gdb/f-valprint.c
+++ b/gdb/f-valprint.c +++ b/gdb/f-valprint.c
@@ -314,8 +314,22 @@ f_val_print (struct type *type, int embedded_offset, @@ -319,8 +319,22 @@ f_val_print (struct type *type, int embedded_offset,
original_value, &opts, 0, stream); original_value, &opts, 0, stream);
} }
else else

View File

@ -34,53 +34,6 @@ dbfd7140bf4c0500d1f5d192be781f83f78f7922
gdb/value.h | 2 + gdb/value.h | 2 +
23 files changed, 1242 insertions(+), 183 deletions(-) 23 files changed, 1242 insertions(+), 183 deletions(-)
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
--- a/gdb/dwarf2read.c
+++ b/gdb/dwarf2read.c
@@ -17935,7 +17935,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;
- struct dynamic_prop low, high;
+ struct dynamic_prop low, high, stride;
int low_default_is_valid;
int high_bound_is_count = 0;
const char *name;
@@ -17956,7 +17956,9 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
low.kind = PROP_CONST;
high.kind = PROP_CONST;
+ stride.kind = PROP_CONST;
high.data.const_val = 0;
+ stride.data.const_val = 0;
/* Set LOW_DEFAULT_IS_VALID if current language and DWARF version allow
omitting DW_AT_lower_bound. */
@@ -17989,6 +17991,14 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
break;
}
+ attr = dwarf2_attr (die, DW_AT_byte_stride, cu);
+ if (attr)
+ if (!attr_to_dynamic_prop (attr, die, cu, &stride, base_type))
+ complaint (_("Missing DW_AT_byte_stride "
+ "- DIE at 0x%s [in module %s]"),
+ sect_offset_str (die->sect_off),
+ objfile_name (cu->per_cu->dwarf2_per_objfile->objfile));
+
attr = dwarf2_attr (die, DW_AT_lower_bound, cu);
if (attr)
attr_to_dynamic_prop (attr, die, cu, &low, base_type);
@@ -18047,7 +18057,8 @@ 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;
- range_type = create_range_type (NULL, orig_base_type, &low, &high, bias);
+ range_type = create_range_type (NULL, orig_base_type, &low, &high, bias,
+ &stride);
if (high_bound_is_count)
TYPE_RANGE_DATA (range_type)->flag_upper_bound_is_count = 1;
diff --git a/gdb/eval.c b/gdb/eval.c diff --git a/gdb/eval.c b/gdb/eval.c
--- a/gdb/eval.c --- a/gdb/eval.c
+++ b/gdb/eval.c +++ b/gdb/eval.c
@ -670,7 +623,7 @@ diff --git a/gdb/expression.h b/gdb/expression.h
diff --git a/gdb/f-exp.y b/gdb/f-exp.y diff --git a/gdb/f-exp.y b/gdb/f-exp.y
--- a/gdb/f-exp.y --- a/gdb/f-exp.y
+++ b/gdb/f-exp.y +++ b/gdb/f-exp.y
@@ -280,31 +280,63 @@ arglist : subrange @@ -282,31 +282,63 @@ arglist : subrange
arglist : arglist ',' exp %prec ABOVE_COMMA arglist : arglist ',' exp %prec ABOVE_COMMA
{ pstate->arglist_len++; } { pstate->arglist_len++; }
@ -742,134 +695,52 @@ diff --git a/gdb/f-exp.y b/gdb/f-exp.y
diff --git a/gdb/f-valprint.c b/gdb/f-valprint.c diff --git a/gdb/f-valprint.c b/gdb/f-valprint.c
--- a/gdb/f-valprint.c --- a/gdb/f-valprint.c
+++ b/gdb/f-valprint.c +++ b/gdb/f-valprint.c
@@ -120,8 +120,14 @@ f77_print_array_1 (int nss, int ndimensions, struct type *type, @@ -129,6 +129,11 @@ f77_print_array_1 (int nss, int ndimensions, struct type *type,
byte_stride = dim_size;
if (nss != ndimensions)
{
- size_t dim_size = TYPE_LENGTH (TYPE_TARGET_TYPE (type));
+ size_t dim_size;
size_t offs = 0; size_t offs = 0;
+ LONGEST byte_stride = abs (TYPE_BYTE_STRIDE (range_type));
+
+ if (byte_stride) + if (byte_stride)
+ dim_size = byte_stride; + dim_size = byte_stride;
+ else + else
+ dim_size = TYPE_LENGTH (TYPE_TARGET_TYPE (type)); + dim_size = TYPE_LENGTH (TYPE_TARGET_TYPE (type));
+
for (i = lowerbound; for (i = lowerbound;
(i < upperbound + 1 && (*elts) < options->print_max); (i < upperbound + 1 && (*elts) < options->print_max);
i++)
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
--- a/gdb/gdbtypes.c --- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c +++ b/gdb/gdbtypes.c
@@ -913,7 +913,8 @@ struct type * @@ -936,7 +936,7 @@ create_range_type (struct type *result_type, struct type *index_type,
create_range_type (struct type *result_type, struct type *index_type,
const struct dynamic_prop *low_bound,
const struct dynamic_prop *high_bound,
- LONGEST bias)
+ LONGEST bias,
+ const struct dynamic_prop *stride)
{
/* The INDEX_TYPE should be a type capable of holding the upper and lower
bounds, as such a zero sized, or void type makes no sense. */
@@ -934,6 +935,7 @@ create_range_type (struct type *result_type, struct type *index_type,
TYPE_RANGE_DATA (result_type)->low = *low_bound;
TYPE_RANGE_DATA (result_type)->high = *high_bound; TYPE_RANGE_DATA (result_type)->high = *high_bound;
TYPE_RANGE_DATA (result_type)->bias = bias; TYPE_RANGE_DATA (result_type)->bias = bias;
+ TYPE_RANGE_DATA (result_type)->stride = *stride;
if (low_bound->kind == PROP_CONST && low_bound->data.const_val >= 0) - /* Initialize the stride to be a constant, the value will already be zero
TYPE_UNSIGNED (result_type) = 1; + /* bias the stride to be a constant, the value will already be zero
@@ -962,7 +964,7 @@ struct type * thanks to the use of TYPE_ZALLOC above. */
create_static_range_type (struct type *result_type, struct type *index_type, TYPE_RANGE_DATA (result_type)->stride.kind = PROP_CONST;
LONGEST low_bound, LONGEST high_bound)
{
- struct dynamic_prop low, high;
+ struct dynamic_prop low, high, stride;
low.kind = PROP_CONST; @@ -1001,7 +1001,8 @@ create_static_range_type (struct type *result_type, struct type *index_type,
low.data.const_val = low_bound;
@@ -970,7 +972,11 @@ create_static_range_type (struct type *result_type, struct type *index_type,
high.kind = PROP_CONST; high.kind = PROP_CONST;
high.data.const_val = high_bound; high.data.const_val = high_bound;
- result_type = create_range_type (result_type, index_type, &low, &high, 0); - result_type = create_range_type (result_type, index_type, &low, &high, 0);
+ stride.kind = PROP_CONST;
+ stride.data.const_val = 0;
+
+ result_type = create_range_type (result_type, index_type, + result_type = create_range_type (result_type, index_type,
+ &low, &high, 0, &stride); + &low, &high, 0);
return result_type; return result_type;
} }
@@ -1188,16 +1194,20 @@ create_array_type_with_stride (struct type *result_type, @@ -1236,6 +1237,7 @@ create_array_type_with_stride (struct type *result_type,
&& (!type_not_associated (result_type)
&& !type_not_allocated (result_type)))
{
- LONGEST low_bound, high_bound;
+ LONGEST low_bound, high_bound, byte_stride;
if (get_discrete_bounds (range_type, &low_bound, &high_bound) < 0) if (get_discrete_bounds (range_type, &low_bound, &high_bound) < 0)
low_bound = high_bound = 0; low_bound = high_bound = 0;
element_type = check_typedef (element_type); element_type = check_typedef (element_type);
+ byte_stride = abs (TYPE_BYTE_STRIDE (range_type));
+ +
/* Be careful when setting the array length. Ada arrays can be /* Be careful when setting the array length. Ada arrays can be
empty arrays with the high_bound being smaller than the low_bound. empty arrays with the high_bound being smaller than the low_bound.
In such cases, the array length should be zero. */ In such cases, the array length should be zero. */
if (high_bound < low_bound)
TYPE_LENGTH (result_type) = 0;
+ else if (byte_stride > 0)
+ TYPE_LENGTH (result_type) = byte_stride * (high_bound - low_bound + 1);
else if (bit_stride > 0)
TYPE_LENGTH (result_type) =
(bit_stride * (high_bound - low_bound + 1) + 7) / 8;
@@ -1982,7 +1992,7 @@ resolve_dynamic_range (struct type *dyn_range_type,
CORE_ADDR value;
struct type *static_range_type, *static_target_type;
const struct dynamic_prop *prop;
- struct dynamic_prop low_bound, high_bound;
+ struct dynamic_prop low_bound, high_bound, stride;
gdb_assert (TYPE_CODE (dyn_range_type) == TYPE_CODE_RANGE);
@@ -2014,13 +2024,21 @@ resolve_dynamic_range (struct type *dyn_range_type,
high_bound.data.const_val = 0;
}
+ prop = &TYPE_RANGE_DATA (dyn_range_type)->stride;
+ if (dwarf2_evaluate_property (prop, NULL, addr_stack, &value))
+ {
+ stride.kind = PROP_CONST;
+ stride.data.const_val = value;
+ }
+
static_target_type
= resolve_dynamic_type_internal (TYPE_TARGET_TYPE (dyn_range_type),
addr_stack, 0);
LONGEST bias = TYPE_RANGE_DATA (dyn_range_type)->bias;
static_range_type = create_range_type (copy_type (dyn_range_type),
static_target_type,
- &low_bound, &high_bound, bias);
+ &low_bound, &high_bound, bias,
+ &stride);
TYPE_RANGE_DATA (static_range_type)->flag_bound_evaluated = 1;
return static_range_type;
}
diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
--- a/gdb/gdbtypes.h --- a/gdb/gdbtypes.h
+++ b/gdb/gdbtypes.h +++ b/gdb/gdbtypes.h
@@ -622,6 +622,10 @@ struct range_bounds @@ -803,7 +803,6 @@ struct main_type
LONGEST bias;
+ /* * Stride of range. */
+
+ struct dynamic_prop stride;
+
/* True if HIGH range bound contains the number of elements in the
subrange. This affects how the final high bound is computed. */
@@ -786,7 +790,6 @@ struct main_type
/* * Union member used for range types. */ /* * Union member used for range types. */
struct range_bounds *bounds; struct range_bounds *bounds;
@ -877,10 +748,10 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
} flds_bnds; } flds_bnds;
/* * Slot to point to additional language-specific fields of this /* * Slot to point to additional language-specific fields of this
@@ -1345,6 +1348,15 @@ extern bool set_type_align (struct type *, ULONGEST); @@ -1365,6 +1364,15 @@ extern bool set_type_align (struct type *, ULONGEST);
TYPE_RANGE_DATA(range_type)->high.kind #define TYPE_BIT_STRIDE(range_type) \
#define TYPE_LOW_BOUND_KIND(range_type) \ (TYPE_RANGE_DATA(range_type)->stride.data.const_val \
TYPE_RANGE_DATA(range_type)->low.kind * (TYPE_RANGE_DATA(range_type)->flag_is_byte_stride ? 8 : 1))
+#define TYPE_BYTE_STRIDE(range_type) \ +#define TYPE_BYTE_STRIDE(range_type) \
+ TYPE_RANGE_DATA(range_type)->stride.data.const_val + TYPE_RANGE_DATA(range_type)->stride.data.const_val
+#define TYPE_BYTE_STRIDE_BLOCK(range_type) \ +#define TYPE_BYTE_STRIDE_BLOCK(range_type) \
@ -893,7 +764,7 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
/* Property accessors for the type data location. */ /* Property accessors for the type data location. */
#define TYPE_DATA_LOCATION(thistype) \ #define TYPE_DATA_LOCATION(thistype) \
@@ -1380,6 +1392,9 @@ extern bool set_type_align (struct type *, ULONGEST); @@ -1400,6 +1408,9 @@ extern bool set_type_align (struct type *, ULONGEST);
TYPE_HIGH_BOUND_UNDEFINED(TYPE_INDEX_TYPE(arraytype)) TYPE_HIGH_BOUND_UNDEFINED(TYPE_INDEX_TYPE(arraytype))
#define TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED(arraytype) \ #define TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED(arraytype) \
TYPE_LOW_BOUND_UNDEFINED(TYPE_INDEX_TYPE(arraytype)) TYPE_LOW_BOUND_UNDEFINED(TYPE_INDEX_TYPE(arraytype))
@ -903,16 +774,6 @@ diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h
#define TYPE_ARRAY_UPPER_BOUND_VALUE(arraytype) \ #define TYPE_ARRAY_UPPER_BOUND_VALUE(arraytype) \
(TYPE_HIGH_BOUND(TYPE_INDEX_TYPE((arraytype)))) (TYPE_HIGH_BOUND(TYPE_INDEX_TYPE((arraytype))))
@@ -1957,7 +1972,8 @@ extern struct type *create_array_type_with_stride
extern struct type *create_range_type (struct type *, struct type *,
const struct dynamic_prop *,
const struct dynamic_prop *,
- LONGEST);
+ LONGEST,
+ const struct dynamic_prop *);
extern struct type *create_array_type (struct type *, struct type *,
struct type *);
diff --git a/gdb/parse.c b/gdb/parse.c diff --git a/gdb/parse.c b/gdb/parse.c
--- a/gdb/parse.c --- a/gdb/parse.c
+++ b/gdb/parse.c +++ b/gdb/parse.c
@ -1598,7 +1459,7 @@ diff --git a/gdb/testsuite/gdb.fortran/vla-stride.exp b/gdb/testsuite/gdb.fortra
new file mode 100644 new file mode 100644
--- /dev/null --- /dev/null
+++ b/gdb/testsuite/gdb.fortran/vla-stride.exp +++ b/gdb/testsuite/gdb.fortran/vla-stride.exp
@@ -0,0 +1,44 @@ @@ -0,0 +1,47 @@
+# Copyright 2016 Free Software Foundation, Inc. +# Copyright 2016 Free Software Foundation, Inc.
+ +
+# This program is free software; you can redistribute it and/or modify +# This program is free software; you can redistribute it and/or modify
@ -1626,6 +1487,9 @@ new file mode 100644
+ continue + continue
+} +}
+ +
+gdb_test_no_output "set max-value-size unlimited" \
+ "set max-value-size to unlimited"
+
+gdb_breakpoint [gdb_get_line_number "re-reverse-elements"] +gdb_breakpoint [gdb_get_line_number "re-reverse-elements"]
+gdb_continue_to_breakpoint "re-reverse-elements" +gdb_continue_to_breakpoint "re-reverse-elements"
+gdb_test "print pvla" " = \\\(1, 2, 3, 4, 5, 6, 7, 8, 9, 10\\\)" \ +gdb_test "print pvla" " = \\\(1, 2, 3, 4, 5, 6, 7, 8, 9, 10\\\)" \
@ -1677,33 +1541,10 @@ new file mode 100644
+ +
+ pvla => null() ! single-element + pvla => null() ! single-element
+end program vla_stride +end program vla_stride
diff --git a/gdb/valarith.c b/gdb/valarith.c
--- a/gdb/valarith.c
+++ b/gdb/valarith.c
@@ -188,11 +188,17 @@ value_subscripted_rvalue (struct value *array, LONGEST index, LONGEST lowerbound
struct type *array_type = check_typedef (value_type (array));
struct type *elt_type = check_typedef (TYPE_TARGET_TYPE (array_type));
ULONGEST elt_size = type_length_units (elt_type);
- ULONGEST elt_offs = elt_size * (index - lowerbound);
+ LONGEST elt_offs = index - lowerbound;
+ LONGEST elt_stride = TYPE_BYTE_STRIDE (TYPE_INDEX_TYPE (array_type));
+
+ if (elt_stride != 0)
+ elt_offs *= elt_stride;
+ else
+ elt_offs *= elt_size;
if (index < lowerbound
|| (!TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED (array_type)
- && elt_offs >= type_length_units (array_type))
+ && abs (elt_offs) >= type_length_units (array_type))
|| (VALUE_LVAL (array) != lval_memory
&& TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED (array_type)))
{
diff --git a/gdb/valops.c b/gdb/valops.c diff --git a/gdb/valops.c b/gdb/valops.c
--- a/gdb/valops.c --- a/gdb/valops.c
+++ b/gdb/valops.c +++ b/gdb/valops.c
@@ -3790,13 +3790,42 @@ value_of_this_silent (const struct language_defn *lang) @@ -3797,13 +3797,42 @@ value_of_this_silent (const struct language_defn *lang)
struct value * struct value *
value_slice (struct value *array, int lowbound, int length) value_slice (struct value *array, int lowbound, int length)
@ -1750,7 +1591,7 @@ diff --git a/gdb/valops.c b/gdb/valops.c
if (TYPE_CODE (array_type) != TYPE_CODE_ARRAY if (TYPE_CODE (array_type) != TYPE_CODE_ARRAY
&& TYPE_CODE (array_type) != TYPE_CODE_STRING) && TYPE_CODE (array_type) != TYPE_CODE_STRING)
error (_("cannot take slice of non-array")); error (_("cannot take slice of non-array"));
@@ -3806,45 +3835,155 @@ value_slice (struct value *array, int lowbound, int length) @@ -3813,45 +3842,155 @@ value_slice (struct value *array, int lowbound, int length)
if (type_not_associated (array_type)) if (type_not_associated (array_type))
error (_("array not associated")); error (_("array not associated"));

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 diff --git a/gdb/NEWS b/gdb/NEWS
--- a/gdb/NEWS --- a/gdb/NEWS
+++ b/gdb/NEWS +++ b/gdb/NEWS
@@ -745,6 +745,8 @@ SH-5/SH64 running OpenBSD SH-5/SH64 support in sh*-*-openbsd* @@ -805,6 +805,8 @@ SH-5/SH64 running OpenBSD SH-5/SH64 support in sh*-*-openbsd*
*** Changes in GDB 8.1 *** 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 diff --git a/gdb/c-valprint.c b/gdb/c-valprint.c
--- a/gdb/c-valprint.c --- a/gdb/c-valprint.c
+++ b/gdb/c-valprint.c +++ b/gdb/c-valprint.c
@@ -651,6 +651,28 @@ c_value_print (struct value *val, struct ui_file *stream, @@ -649,6 +649,28 @@ c_value_print (struct value *val, struct ui_file *stream,
else else
{ {
/* normal case */ /* normal case */
@ -89,7 +89,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
/* memory allocation interface */ /* memory allocation interface */
@@ -13793,7 +13796,7 @@ read_func_scope (struct die_info *die, struct dwarf2_cu *cu) @@ -13799,7 +13802,7 @@ read_func_scope (struct die_info *die, struct dwarf2_cu *cu)
newobj->static_link newobj->static_link
= XOBNEW (&objfile->objfile_obstack, struct dynamic_prop); = XOBNEW (&objfile->objfile_obstack, struct dynamic_prop);
attr_to_dynamic_prop (attr, die, cu, newobj->static_link, attr_to_dynamic_prop (attr, die, cu, newobj->static_link,
@ -98,7 +98,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
} }
cu->list_in_scope = cu->get_builder ()->get_local_symbols (); cu->list_in_scope = cu->get_builder ()->get_local_symbols ();
@@ -16554,7 +16557,7 @@ read_array_type (struct die_info *die, struct dwarf2_cu *cu) @@ -16565,7 +16568,7 @@ read_array_type (struct die_info *die, struct dwarf2_cu *cu)
byte_stride_prop byte_stride_prop
= (struct dynamic_prop *) alloca (sizeof (struct dynamic_prop)); = (struct dynamic_prop *) alloca (sizeof (struct dynamic_prop));
stride_ok = attr_to_dynamic_prop (attr, die, cu, byte_stride_prop, stride_ok = attr_to_dynamic_prop (attr, die, cu, byte_stride_prop,
@ -107,21 +107,38 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
if (!stride_ok) if (!stride_ok)
{ {
complaint (_("unable to read array DW_AT_byte_stride " complaint (_("unable to read array DW_AT_byte_stride "
@@ -17312,29 +17315,90 @@ read_tag_string_type (struct die_info *die, struct dwarf2_cu *cu) @@ -17325,7 +17328,7 @@ 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; struct attribute *attr;
- unsigned int length; struct dynamic_prop prop;
+ unsigned int length = UINT_MAX; bool length_is_constant = true;
+ - LONGEST length;
+ ULONGEST length = UINT_MAX;
/* There are a couple of places where bit sizes might be made use of
when parsing a DW_TAG_string_type, however, no producer that we know
@@ -17346,6 +17349,10 @@ read_tag_string_type (struct die_info *die, struct dwarf2_cu *cu)
}
}
+ index_type = objfile_type (objfile)->builtin_int; + index_type = objfile_type (objfile)->builtin_int;
+ range_type = create_static_range_type (NULL, index_type, 1, length); + range_type = create_static_range_type (NULL, index_type, 1, length);
+
+ /* If DW_AT_string_length is defined, the length is stored in memory. */ + /* If DW_AT_string_length is defined, the length is stored in memory. */
attr = dwarf2_attr (die, DW_AT_string_length, cu); attr = dwarf2_attr (die, DW_AT_string_length, cu);
if (attr) if (attr != nullptr && !attr_form_is_constant (attr))
{
@@ -17372,13 +17379,71 @@ read_tag_string_type (struct die_info *die, struct dwarf2_cu *cu)
}
/* Convert the attribute into a dynamic property. */
- if (!attr_to_dynamic_prop (attr, die, cu, &prop, prop_type))
+ if (!attr_to_dynamic_prop (attr, die, cu, &prop, prop_type, NULL, 0))
length = 1;
else
length_is_constant = false;
}
else if (attr != nullptr)
{ {
- length = DW_UNSND (attr);
+ if (attr_form_is_block (attr)) + if (attr_form_is_block (attr))
+ { + {
+ struct attribute *byte_size, *bit_size; + struct attribute *byte_size, *bit_size;
@ -179,37 +196,40 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
+ TYPE_HIGH_BOUND (range_type) = DW_UNSND(attr); + TYPE_HIGH_BOUND (range_type) = DW_UNSND(attr);
+ TYPE_HIGH_BOUND_KIND (range_type) = PROP_CONST; + TYPE_HIGH_BOUND_KIND (range_type) = PROP_CONST;
+ } + }
+
/* This DW_AT_string_length just contains the length with no
indirection. There's no need to create a dynamic property in this
case. Pass 0 for the default value as we know it will not be
@@ -17392,6 +17457,20 @@ read_tag_string_type (struct die_info *die, struct dwarf2_cu *cu)
} }
else else
{ {
- /* Check for the DW_AT_byte_size attribute. */
+ /* Check for the DW_AT_byte_size attribute, which represents the length + /* Check for the DW_AT_byte_size attribute, which represents the length
+ in this case. */ + in this case. */
attr = dwarf2_attr (die, DW_AT_byte_size, cu); + attr = dwarf2_attr (die, DW_AT_byte_size, cu);
if (attr) + if (attr)
- {
- length = DW_UNSND (attr);
- }
+ { + {
+ TYPE_HIGH_BOUND (range_type) = DW_UNSND(attr); + TYPE_HIGH_BOUND (range_type) = DW_UNSND(attr);
+ TYPE_HIGH_BOUND_KIND (range_type) = PROP_CONST; + TYPE_HIGH_BOUND_KIND (range_type) = PROP_CONST;
+ } + }
else + else
- {
- length = 1;
- }
+ { + {
+ TYPE_HIGH_BOUND (range_type) = 1; + TYPE_HIGH_BOUND (range_type) = 1;
+ TYPE_HIGH_BOUND_KIND (range_type) = PROP_CONST; + TYPE_HIGH_BOUND_KIND (range_type) = PROP_CONST;
+ } + }
+
/* Use 1 as a fallback length if we have nothing else. */
length = 1;
} }
@@ -17407,6 +17486,7 @@ read_tag_string_type (struct die_info *die, struct dwarf2_cu *cu)
- index_type = objfile_type (objfile)->builtin_int; low_bound.data.const_val = 1;
- range_type = create_static_range_type (NULL, index_type, 1, length); range_type = create_range_type (NULL, index_type, &low_bound, &prop, 0);
}
+
char_type = language_string_char_type (cu->language_defn, gdbarch); char_type = language_string_char_type (cu->language_defn, gdbarch);
type = create_string_type (NULL, char_type, range_type); type = create_string_type (NULL, char_type, range_type);
@@ -17767,7 +17831,8 @@ read_base_type (struct die_info *die, struct dwarf2_cu *cu) @@ -17858,7 +17938,8 @@ read_base_type (struct die_info *die, struct dwarf2_cu *cu)
static int static int
attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die, attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die,
struct dwarf2_cu *cu, struct dynamic_prop *prop, struct dwarf2_cu *cu, struct dynamic_prop *prop,
@ -219,10 +239,10 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
{ {
struct dwarf2_property_baton *baton; struct dwarf2_property_baton *baton;
struct obstack *obstack struct obstack *obstack
@@ -17786,9 +17851,30 @@ attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die, @@ -17885,9 +17966,30 @@ attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die,
baton->locexpr.size = DW_BLOCK (attr)->size; baton->locexpr.is_reference = false;
baton->locexpr.data = DW_BLOCK (attr)->data; break;
baton->locexpr.is_reference = false; }
+ +
+ if (additional_data != NULL && additional_data_size > 0) + if (additional_data != NULL && additional_data_size > 0)
+ { + {
@ -251,7 +271,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
} }
else if (attr_form_is_ref (attr)) else if (attr_form_is_ref (attr))
{ {
@@ -17821,9 +17907,29 @@ attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die, @@ -17920,9 +18022,29 @@ attr_to_dynamic_prop (const struct attribute *attr, struct die_info *die,
baton = XOBNEW (obstack, struct dwarf2_property_baton); baton = XOBNEW (obstack, struct dwarf2_property_baton);
baton->property_type = die_type (target_die, target_cu); baton->property_type = die_type (target_die, target_cu);
baton->locexpr.per_cu = cu->per_cu; baton->locexpr.per_cu = cu->per_cu;
@ -283,26 +303,18 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
prop->data.baton = baton; prop->data.baton = baton;
prop->kind = PROP_LOCEXPR; prop->kind = PROP_LOCEXPR;
gdb_assert (prop->data.baton != NULL); gdb_assert (prop->data.baton != NULL);
@@ -17993,7 +18099,8 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu) @@ -18099,8 +18221,8 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
}
attr = dwarf2_attr (die, DW_AT_byte_stride, cu);
if (attr)
- if (!attr_to_dynamic_prop (attr, die, cu, &stride, base_type))
+ if (!attr_to_dynamic_prop (attr, die, cu, &stride, base_type,
+ NULL, 0))
complaint (_("Missing DW_AT_byte_stride "
"- DIE at 0x%s [in module %s]"),
sect_offset_str (die->sect_off),
@@ -18001,7 +18108,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
attr = dwarf2_attr (die, DW_AT_lower_bound, cu); attr = dwarf2_attr (die, DW_AT_lower_bound, cu);
if (attr) - if (attr != nullptr)
- attr_to_dynamic_prop (attr, die, cu, &low, base_type); - attr_to_dynamic_prop (attr, die, cu, &low, base_type);
+ if (attr)
+ attr_to_dynamic_prop (attr, die, cu, &low, base_type, NULL, 0); + attr_to_dynamic_prop (attr, die, cu, &low, base_type, NULL, 0);
else if (!low_default_is_valid) else if (!low_default_is_valid)
complaint (_("Missing DW_AT_lower_bound " complaint (_("Missing DW_AT_lower_bound "
"- DIE at %s [in module %s]"), "- DIE at %s [in module %s]"),
@@ -18010,10 +18117,10 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu) @@ -18109,10 +18231,10 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
struct attribute *attr_ub, *attr_count; struct attribute *attr_ub, *attr_count;
attr = attr_ub = dwarf2_attr (die, DW_AT_upper_bound, cu); attr = attr_ub = dwarf2_attr (die, DW_AT_upper_bound, cu);
@ -315,7 +327,25 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
{ {
/* If bounds are constant do the final calculation here. */ /* If bounds are constant do the final calculation here. */
if (low.kind == PROP_CONST && high.kind == PROP_CONST) if (low.kind == PROP_CONST && high.kind == PROP_CONST)
@@ -25736,7 +25843,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu) @@ -18164,7 +18286,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
struct type *prop_type
= dwarf2_per_cu_addr_sized_int_type (cu->per_cu, false);
attr_to_dynamic_prop (attr_byte_stride, die, cu, &byte_stride_prop,
- prop_type);
+ prop_type, NULL, 0);
}
struct dynamic_prop bit_stride_prop;
@@ -18185,7 +18307,7 @@ read_subrange_type (struct die_info *die, struct dwarf2_cu *cu)
struct type *prop_type
= dwarf2_per_cu_addr_sized_int_type (cu->per_cu, false);
attr_to_dynamic_prop (attr_bit_stride, die, cu, &bit_stride_prop,
- prop_type);
+ prop_type, NULL, 0);
}
}
@@ -25879,7 +26001,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
{ {
struct type *prop_type struct type *prop_type
= dwarf2_per_cu_addr_sized_int_type (cu->per_cu, false); = dwarf2_per_cu_addr_sized_int_type (cu->per_cu, false);
@ -324,7 +354,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
add_dyn_prop (DYN_PROP_ALLOCATED, prop, type); add_dyn_prop (DYN_PROP_ALLOCATED, prop, type);
} }
else if (attr != NULL) else if (attr != NULL)
@@ -25752,7 +25859,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu) @@ -25895,7 +26017,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
{ {
struct type *prop_type struct type *prop_type
= dwarf2_per_cu_addr_sized_int_type (cu->per_cu, false); = dwarf2_per_cu_addr_sized_int_type (cu->per_cu, false);
@ -333,7 +363,7 @@ diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c
add_dyn_prop (DYN_PROP_ASSOCIATED, prop, type); add_dyn_prop (DYN_PROP_ASSOCIATED, prop, type);
} }
else if (attr != NULL) else if (attr != NULL)
@@ -25765,7 +25872,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu) @@ -25908,7 +26030,7 @@ set_die_type (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
/* Read DW_AT_data_location and set in type. */ /* Read DW_AT_data_location and set in type. */
attr = dwarf2_attr (die, DW_AT_data_location, cu); attr = dwarf2_attr (die, DW_AT_data_location, cu);
if (attr_to_dynamic_prop (attr, die, cu, &prop, if (attr_to_dynamic_prop (attr, die, cu, &prop,
@ -401,7 +431,7 @@ diff --git a/gdb/f-typeprint.c b/gdb/f-typeprint.c
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
--- a/gdb/gdbtypes.c --- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c +++ b/gdb/gdbtypes.c
@@ -1905,7 +1905,8 @@ is_dynamic_type_internal (struct type *type, int top_level) @@ -1939,7 +1939,8 @@ is_dynamic_type_internal (struct type *type, int top_level)
type = check_typedef (type); type = check_typedef (type);
/* We only want to recognize references at the outermost level. */ /* We only want to recognize references at the outermost level. */
@ -411,32 +441,26 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
type = check_typedef (TYPE_TARGET_TYPE (type)); type = check_typedef (TYPE_TARGET_TYPE (type));
/* Types that have a dynamic TYPE_DATA_LOCATION are considered /* Types that have a dynamic TYPE_DATA_LOCATION are considered
@@ -1939,6 +1940,7 @@ is_dynamic_type_internal (struct type *type, int top_level) @@ -1972,10 +1973,10 @@ is_dynamic_type_internal (struct type *type, int top_level)
|| is_dynamic_type_internal (TYPE_TARGET_TYPE (type), 0));
} }
- case TYPE_CODE_STRING:
/* Strings are very much like an array of characters, and can be
treated as one here. */
case TYPE_CODE_ARRAY: case TYPE_CODE_ARRAY:
+ case TYPE_CODE_STRING: + case TYPE_CODE_STRING:
{ {
gdb_assert (TYPE_NFIELDS (type) == 1); gdb_assert (TYPE_NFIELDS (type) == 1);
@@ -2058,7 +2060,8 @@ resolve_dynamic_array (struct type *type, @@ -2139,11 +2140,15 @@ resolve_dynamic_array_or_string (struct type *type,
struct dynamic_prop *prop;
unsigned int bit_stride = 0;
- gdb_assert (TYPE_CODE (type) == TYPE_CODE_ARRAY);
+ gdb_assert (TYPE_CODE (type) == TYPE_CODE_ARRAY
+ || TYPE_CODE (type) == TYPE_CODE_STRING);
type = copy_type (type);
@@ -2083,11 +2086,15 @@ resolve_dynamic_array (struct type *type,
ary_dim = check_typedef (TYPE_TARGET_TYPE (elt_type)); ary_dim = check_typedef (TYPE_TARGET_TYPE (elt_type));
- if (ary_dim != NULL && TYPE_CODE (ary_dim) == TYPE_CODE_ARRAY) - if (ary_dim != NULL && TYPE_CODE (ary_dim) == TYPE_CODE_ARRAY)
+ if (ary_dim != NULL && (TYPE_CODE (ary_dim) == TYPE_CODE_ARRAY + if (ary_dim != NULL && (TYPE_CODE (ary_dim) == TYPE_CODE_ARRAY
+ || TYPE_CODE (ary_dim) == TYPE_CODE_STRING)) + || TYPE_CODE (ary_dim) == TYPE_CODE_STRING))
elt_type = resolve_dynamic_array (ary_dim, addr_stack); elt_type = resolve_dynamic_array_or_string (ary_dim, addr_stack);
else else
elt_type = TYPE_TARGET_TYPE (type); elt_type = TYPE_TARGET_TYPE (type);
@ -446,7 +470,7 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
prop = get_dyn_prop (DYN_PROP_BYTE_STRIDE, type); prop = get_dyn_prop (DYN_PROP_BYTE_STRIDE, type);
if (prop != NULL) if (prop != NULL)
{ {
@@ -2239,6 +2246,28 @@ resolve_dynamic_struct (struct type *type, @@ -2295,6 +2300,28 @@ resolve_dynamic_struct (struct type *type,
return resolved_type; return resolved_type;
} }
@ -475,19 +499,16 @@ diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
/* Worker for resolved_dynamic_type. */ /* Worker for resolved_dynamic_type. */
static struct type * static struct type *
@@ -2287,7 +2316,12 @@ resolve_dynamic_type_internal (struct type *type, @@ -2349,6 +2376,9 @@ resolve_dynamic_type_internal (struct type *type,
break; case TYPE_CODE_ARRAY:
} resolved_type = resolve_dynamic_array_or_string (type, addr_stack);
break;
+ case TYPE_CODE_PTR: + case TYPE_CODE_PTR:
+ resolved_type = resolve_dynamic_pointer (type, addr_stack); + resolved_type = resolve_dynamic_pointer (type, addr_stack);
+ break; + break;
+
case TYPE_CODE_ARRAY:
+ case TYPE_CODE_STRING:
resolved_type = resolve_dynamic_array (type, addr_stack);
break;
case TYPE_CODE_RANGE:
resolved_type = resolve_dynamic_range (type, addr_stack);
diff --git a/gdb/testsuite/gdb.cp/vla-cxx.cc b/gdb/testsuite/gdb.cp/vla-cxx.cc diff --git a/gdb/testsuite/gdb.cp/vla-cxx.cc b/gdb/testsuite/gdb.cp/vla-cxx.cc
--- a/gdb/testsuite/gdb.cp/vla-cxx.cc --- a/gdb/testsuite/gdb.cp/vla-cxx.cc
+++ b/gdb/testsuite/gdb.cp/vla-cxx.cc +++ b/gdb/testsuite/gdb.cp/vla-cxx.cc
@ -777,7 +798,7 @@ diff --git a/gdb/testsuite/gdb.fortran/print_type.exp b/gdb/testsuite/gdb.fortra
--- a/gdb/testsuite/gdb.fortran/print_type.exp --- a/gdb/testsuite/gdb.fortran/print_type.exp
+++ b/gdb/testsuite/gdb.fortran/print_type.exp +++ b/gdb/testsuite/gdb.fortran/print_type.exp
@@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
# Copyright 2019 Free Software Foundation, Inc. # Copyright 2019-2020 Free Software Foundation, Inc.
# #
+ +
# This program is free software; you can redistribute it and/or modify # This program is free software; you can redistribute it and/or modify

View File

@ -30,7 +30,7 @@ Jan
diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
--- a/gdb/dwarf2loc.c --- a/gdb/dwarf2loc.c
+++ b/gdb/dwarf2loc.c +++ b/gdb/dwarf2loc.c
@@ -2155,6 +2155,20 @@ dwarf2_evaluate_loc_desc_full (struct type *type, struct frame_info *frame, @@ -2154,6 +2154,20 @@ dwarf2_evaluate_loc_desc_full (struct type *type, struct frame_info *frame,
ctx.per_cu = per_cu; ctx.per_cu = per_cu;
ctx.obj_address = 0; ctx.obj_address = 0;

View File

@ -27,22 +27,22 @@
Name: %{?scl_prefix}gdb Name: %{?scl_prefix}gdb
# Freeze it when GDB gets branched # Freeze it when GDB gets branched
%global snapsrc 20191119 %global snapsrc 20200203
# See timestamp of source gnulib installed into gdb/gnulib/ . # See timestamp of source gnulib installed into gnulib/ .
%global snapgnulib 20161115 %global snapgnulib 20191216
%global tarname gdb-%{version} %global tarname gdb-%{version}
Version: 9.0.50.%{snapsrc} Version: 9.0.90.%{snapsrc}
# The release always contains a leading reserved number, start it at 1. # 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. # `upstream' is not a part of `name' to stay fully rpm dependencies compatible for the testing.
Release: 3%{?dist} Release: 4%{?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 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. # Do not provide URL for snapshots as the file lasts there only for 2 days.
# ftp://sourceware.org/pub/gdb/releases/FIXME{tarname}.tar.xz # ftp://sourceware.org/pub/gdb/releases/FIXME{tarname}.tar.xz
Source: %{tarname}.tar.xz Source: %{tarname}.tar.xz
#Source: ftp://sourceware.org/pub/gdb/releases/%{tarname}.tar.xz #Source: ftp://sourceware.org/pub/gdb/releases/%{tarname}.tar.xz
URL: http://gnu.org/software/gdb/ URL: https://gnu.org/software/gdb/
# For our convenience # For our convenience
%global gdb_src %{tarname} %global gdb_src %{tarname}
@ -1146,6 +1146,15 @@ fi
%endif %endif
%changelog %changelog
* Mon Feb 3 2020 Sergio Durigan Junior <sergiodj@redhat.com> - 9.0.90.20200203-4
- Rebase to FSF GDB 9.0.90.20200203 (9.1pre).
- Bump 'snapgnulib' date.
- Update URL to 'https'.
- Adjust build-id patchset.
- Adjust VLA patchset.
- Drop 'gdb-6.8-bz436037-reg-no-longer-active.patch'.
- Drop 'gdb-6.6-scheduler_locking-step-is-default.patch'.
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> * Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org>
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild

View File

@ -1,3 +1,3 @@
SHA512 (gdb-libstdc++-v3-python-8.1.1-20180626.tar.xz) = a8b1c54dd348cfeb37da73f968742896be3dd13a4215f8d8519870c2abea915f5176c3fa6989ddd10f20020a16f0fab20cbae68ee8d58a82234d8778023520f8 SHA512 (gdb-libstdc++-v3-python-8.1.1-20180626.tar.xz) = a8b1c54dd348cfeb37da73f968742896be3dd13a4215f8d8519870c2abea915f5176c3fa6989ddd10f20020a16f0fab20cbae68ee8d58a82234d8778023520f8
SHA512 (v2.0.1.tar.gz) = e38e93908c3fbf1f2384cfca381eaf4bf667033de678041bd440adac8bbce4757b77304868896256ed72c202ee22ba1646aada90125029f14f5bffaf828a7df4 SHA512 (v2.0.1.tar.gz) = e38e93908c3fbf1f2384cfca381eaf4bf667033de678041bd440adac8bbce4757b77304868896256ed72c202ee22ba1646aada90125029f14f5bffaf828a7df4
SHA512 (gdb-9.0.50.20191119.tar.xz) = 1163bc264580fcb3896ad2868da1e1e715e9b1fbfd03e007168e173d50f76e9592a65d3f1bd11957cdd41d87587c9db8c5681cdce989a2257d4cb61f9b4587d4 SHA512 (gdb-9.0.90.20200203.tar.xz) = d713e3f385004bdeab4ce7875b647f5010c311488373e2de90f88f4cf3a5954feede0fdaf0315e6a6cdd2613161e6391937542bffbd5a1a9c757161150b909a3