gdb: don't require displaced step copy_insn to be implemented in prepare/finish are
authorSimon Marchi <simon.marchi@efficios.com>
Tue, 7 Apr 2020 15:01:38 +0000 (11:01 -0400)
committerSimon Marchi <simon.marchi@efficios.com>
Wed, 10 Jun 2020 21:26:05 +0000 (17:26 -0400)
commitcdc624cad2871d2dcd44ad44d729f63fbdc9965e
tree83b71f4cf36cc8dcfd6c43f7fa264c54549372c4
parent4805c5636c82368d3807aeab11cf1f2248b03a35
gdb: don't require displaced step copy_insn to be implemented in prepare/finish are

The gdbarch verification currently requires that the gdbarch
displaced_step_prepare and displaced_step_finish methods are provided if
displaced_step_copy_insn is (and not provided if it isn't).

displaced_step_copy_insn is used by the
multiple_displaced_buffer_manager class, but a gdbarch could very well
decide to implement prepare and finish without that, and without
requiring copy_insn.

Remove the dependency in the gdbarch verification between prepare/finish
and copy_insn.  Now, prepare and finish must be both provided or both
not-provided.

Since multiple_displaced_buffer_manager uses the `copy_insn` and `fixup`
gdbarch methods, it now asserts that they are present for the thread
architecture in its `prepare` method.
gdb/displaced-stepping.c
gdb/gdbarch.c
gdb/gdbarch.h
gdb/gdbarch.sh
gdb/infrun.c
This page took 0.024924 seconds and 4 git commands to generate.