| Index: gdb/s390-tdep.c
|
| diff --git a/gdb/s390-tdep.c b/gdb/s390-tdep.c
|
| index ac0c526636f66ea32ceb177f56a36494ca490536..620eaea7d58b925408d1f519e3c365d62c6210df 100644
|
| --- a/gdb/s390-tdep.c
|
| +++ b/gdb/s390-tdep.c
|
| @@ -45,6 +45,13 @@
|
| #include "linux-tdep.h"
|
| #include "s390-tdep.h"
|
|
|
| +#include "stap-probe.h"
|
| +#include "ax.h"
|
| +#include "ax-gdb.h"
|
| +#include "user-regs.h"
|
| +#include "cli/cli-utils.h"
|
| +#include <ctype.h>
|
| +
|
| #include "features/s390-linux32.c"
|
| #include "features/s390-linux32v1.c"
|
| #include "features/s390-linux32v2.c"
|
| @@ -55,7 +62,6 @@
|
| #include "features/s390x-linux64v1.c"
|
| #include "features/s390x-linux64v2.c"
|
|
|
| -
|
| /* The tdep structure. */
|
|
|
| struct gdbarch_tdep
|
| @@ -1160,7 +1166,6 @@ s390_load (struct s390_prologue_data *data,
|
|
|
| {
|
| pv_t addr = s390_addr (data, d2, x2, b2);
|
| - pv_t offset;
|
|
|
| /* If it's a load from an in-line constant pool, then we can
|
| simulate that, under the assumption that the code isn't
|
| @@ -2812,7 +2817,7 @@ s390_return_value_convention (struct gdbarch *gdbarch, struct type *type)
|
| }
|
|
|
| static enum return_value_convention
|
| -s390_return_value (struct gdbarch *gdbarch, struct type *func_type,
|
| +s390_return_value (struct gdbarch *gdbarch, struct value *function,
|
| struct type *type, struct regcache *regcache,
|
| gdb_byte *out, const gdb_byte *in)
|
| {
|
| @@ -2953,6 +2958,18 @@ s390_address_class_name_to_type_flags (struct gdbarch *gdbarch,
|
| return 0;
|
| }
|
|
|
| +/* Implementation of `gdbarch_stap_is_single_operand', as defined in
|
| + gdbarch.h. */
|
| +
|
| +static int
|
| +s390_stap_is_single_operand (struct gdbarch *gdbarch, const char *s)
|
| +{
|
| + return ((isdigit (*s) && s[1] == '(' && s[2] == '%') /* Displacement
|
| + or indirection. */
|
| + || *s == '%' /* Register access. */
|
| + || isdigit (*s)); /* Literal number. */
|
| +}
|
| +
|
| /* Set up gdbarch struct. */
|
|
|
| static struct gdbarch *
|
| @@ -3283,6 +3300,12 @@ s390_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
|
|
|
| set_gdbarch_get_siginfo_type (gdbarch, linux_get_siginfo_type);
|
|
|
| + /* SystemTap functions. */
|
| + set_gdbarch_stap_register_prefix (gdbarch, "%");
|
| + set_gdbarch_stap_register_indirection_prefix (gdbarch, "(");
|
| + set_gdbarch_stap_register_indirection_suffix (gdbarch, ")");
|
| + set_gdbarch_stap_is_single_operand (gdbarch, s390_stap_is_single_operand);
|
| +
|
| return gdbarch;
|
| }
|
|
|
|
|