From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by sourceware.org (Postfix) with ESMTP id CDCF4393FC3D for ; Wed, 1 Apr 2020 21:13:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org CDCF4393FC3D Received: from mail-ed1-f69.google.com (mail-ed1-f69.google.com [209.85.208.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-108-DiBUQu0rM-K8t8y0Hb-kuA-1; Wed, 01 Apr 2020 17:13:21 -0400 X-MC-Unique: DiBUQu0rM-K8t8y0Hb-kuA-1 Received: by mail-ed1-f69.google.com with SMTP id g7so1006138edm.20 for ; Wed, 01 Apr 2020 14:13:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=AO0Og+ujW5PjbzMKUE9MmmVAEih+ZSIn3hzIZqeOMb4=; b=T0elregbur5X3csacE/EOJLf7K7KxWygdHlTcjZF4sUB0O4gO296iR2qM4whfiFgMw fFRM5Fj3TkoyZL+9b16mvvZiv/dTV/IGV5GCJ3xUqGXtiO0rmhnCbTSrS9rSBMweg8V1 ZPICkJmrofiNv9rGDAt9i1ATD1v5pqLt7xuj1LKUYjsVvTcRdhMg+yzmOr2ysybFOAtC rl9xrBc6YbFzrCH/lHZoZryAxY3MsUJxzQ81Eo2lODdONUPwh4xpduhoAjWbyPayZ3GR E+1It9h5+ML3hC+ZWz6Rnq1+DN3SD2YAMwoKyRRiJ6xapiDCDWWPGZb2qSjGOBh9CEGj XepA== X-Gm-Message-State: AGi0Puafk8/Aih1W66NJRpRK1MKCzP9TUl+wJGCz+4dvNSWM5P3hv0wI JdomQUPgTi8QNQheoAqJLSTQYC1I64TggIuto9yKQHQAGCIjNeayQvd9+VufTRYMunGdh72edHr 3YSKgE1GT0oVhA3WoXkiv4Q== X-Received: by 2002:a17:906:3712:: with SMTP id d18mr99239ejc.122.1585775599933; Wed, 01 Apr 2020 14:13:19 -0700 (PDT) X-Google-Smtp-Source: APiQypINksJptabrrMk9h9MdAYJ5NnSlutqBjmb+tTTmZtvbYvuD+bTPb6byGIMDsi3wxMs90ci9/w== X-Received: by 2002:a17:906:3712:: with SMTP id d18mr99206ejc.122.1585775599402; Wed, 01 Apr 2020 14:13:19 -0700 (PDT) Received: from ?IPv6:2001:8a0:f909:7b00:56ee:75ff:fe8d:232b? ([2001:8a0:f909:7b00:56ee:75ff:fe8d:232b]) by smtp.gmail.com with ESMTPSA id r21sm648797edc.29.2020.04.01.14.13.17 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 01 Apr 2020 14:13:18 -0700 (PDT) Subject: Re: [PATCH 13/31] gdbserver/linux-low: move 'decr_pc_after_break' into linux_process_target To: Tankut Baris Aktemur , gdb-patches@sourceware.org References: <348df510a72e111a2ce21892a50dc7ec506e2834.1583529167.git.tankut.baris.aktemur@intel.com> From: Pedro Alves Message-ID: <8e5a2130-315a-0351-2688-534ef4fa7a46@redhat.com> Date: Wed, 1 Apr 2020 22:13:17 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 In-Reply-To: <348df510a72e111a2ce21892a50dc7ec506e2834.1583529167.git.tankut.baris.aktemur@intel.com> Content-Language: en-US X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-19.3 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Apr 2020 21:13:30 -0000 I think a method would be better than a data field here. I think ctors with data fields like that just make it for harder to read code. (Plus, it's not like pedantically multiple objects of the same linux_target_ops subclass type would need different values for this field.) Thanks, Pedro Alves On 3/6/20 9:31 PM, Tankut Baris Aktemur wrote: > gdbserver/ChangeLog: > 2020-03-06 Tankut Baris Aktemur > > Move the 'decr_pc_after_break' linux_target_ops field into > linux_process_target. > > * linux-low.h (struct linux_target_ops) > : Remove. > (class linux_process_target): Declare a constructor that takes > 'decr_pc_after_break' as parameter. > (class linux_process_target) : New field. > * linux-low.cc (linux_process_target::linux_process_target): > Constructor implementation. > > Update the users below. > > (linux_process_target::save_stop_reason) > (linux_process_target::wait_1) > * linux-x86-low.cc (class x86_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-aarch64-low.cc (class aarch64_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-arm-low.cc (class arm_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-bfin-low.cc (class bfin_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-cris-low.cc (class cris_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-crisv32-low.cc (class crisv32_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-ia64-low.cc (class ia64_target): > Define a zero-arg constructor. > * linux-m32r-low.cc (class m32r_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-m68k-low.cc (class m68k_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-mips-low.cc (class mips_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-nios2-low.cc (class nios2_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-ppc-low.cc (class ppc_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-riscv-low.cc (class riscv_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-s390-low.cc (class s390_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-sh-low.cc (class sh_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-sparc-low.cc (class sparc_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-tic6x-low.cc (class tic6x_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-tile-low.cc (class tile_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > * linux-xtensa-low.cc (class xtensa_target): > Define a zero-arg constructor. > (the_low_target): Remove the field. > --- > gdbserver/linux-aarch64-low.cc | 2 +- > gdbserver/linux-arm-low.cc | 3 ++- > gdbserver/linux-bfin-low.cc | 3 ++- > gdbserver/linux-cris-low.cc | 3 ++- > gdbserver/linux-crisv32-low.cc | 3 ++- > gdbserver/linux-ia64-low.cc | 2 ++ > gdbserver/linux-low.cc | 10 ++++++++-- > gdbserver/linux-low.h | 6 +++++- > gdbserver/linux-m32r-low.cc | 3 ++- > gdbserver/linux-m68k-low.cc | 3 ++- > gdbserver/linux-mips-low.cc | 3 ++- > gdbserver/linux-nios2-low.cc | 3 ++- > gdbserver/linux-ppc-low.cc | 3 ++- > gdbserver/linux-riscv-low.cc | 3 ++- > gdbserver/linux-s390-low.cc | 9 +++++---- > gdbserver/linux-sh-low.cc | 3 ++- > gdbserver/linux-sparc-low.cc | 3 ++- > gdbserver/linux-tic6x-low.cc | 3 ++- > gdbserver/linux-tile-low.cc | 3 ++- > gdbserver/linux-x86-low.cc | 3 ++- > gdbserver/linux-xtensa-low.cc | 3 ++- > 21 files changed, 53 insertions(+), 24 deletions(-) > > diff --git a/gdbserver/linux-aarch64-low.cc b/gdbserver/linux-aarch64-low.cc > index 11c3296eb6b..d8b2402bd6b 100644 > --- a/gdbserver/linux-aarch64-low.cc > +++ b/gdbserver/linux-aarch64-low.cc > @@ -54,6 +54,7 @@ > class aarch64_target : public linux_process_target > { > public: > + aarch64_target () : linux_process_target (0) { } > > const regs_info *get_regs_info () override; > > @@ -3103,7 +3104,6 @@ aarch64_supports_hardware_single_step (void) > > struct linux_target_ops the_low_target = > { > - 0, /* decr_pc_after_break */ > aarch64_breakpoint_at, > aarch64_supports_z_point_type, > aarch64_insert_point, > diff --git a/gdbserver/linux-arm-low.cc b/gdbserver/linux-arm-low.cc > index bd42feba1c4..0dca30fb58d 100644 > --- a/gdbserver/linux-arm-low.cc > +++ b/gdbserver/linux-arm-low.cc > @@ -60,6 +60,8 @@ class arm_target : public linux_process_target > { > public: > > + arm_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > int breakpoint_kind_from_pc (CORE_ADDR *pcptr) override; > @@ -1085,7 +1087,6 @@ arm_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 0, > arm_breakpoint_at, > arm_supports_z_point_type, > arm_insert_point, > diff --git a/gdbserver/linux-bfin-low.cc b/gdbserver/linux-bfin-low.cc > index 17948ed16f0..48373ccb178 100644 > --- a/gdbserver/linux-bfin-low.cc > +++ b/gdbserver/linux-bfin-low.cc > @@ -29,6 +29,8 @@ class bfin_target : public linux_process_target > { > public: > > + bfin_target () : linux_process_target (2) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -161,7 +163,6 @@ bfin_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 2, > bfin_breakpoint_at, > NULL, /* supports_z_point_type */ > NULL, /* insert_point */ > diff --git a/gdbserver/linux-cris-low.cc b/gdbserver/linux-cris-low.cc > index 99060de1765..e7e389d049d 100644 > --- a/gdbserver/linux-cris-low.cc > +++ b/gdbserver/linux-cris-low.cc > @@ -26,6 +26,8 @@ class cris_target : public linux_process_target > { > public: > > + cris_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -158,7 +160,6 @@ cris_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 0, > cris_breakpoint_at, > }; > > diff --git a/gdbserver/linux-crisv32-low.cc b/gdbserver/linux-crisv32-low.cc > index c75e428885e..ad22ac0f9cc 100644 > --- a/gdbserver/linux-crisv32-low.cc > +++ b/gdbserver/linux-crisv32-low.cc > @@ -26,6 +26,8 @@ class crisv32_target : public linux_process_target > { > public: > > + crisv32_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -455,7 +457,6 @@ crisv32_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 0, > cris_breakpoint_at, > cris_supports_z_point_type, > cris_insert_point, > diff --git a/gdbserver/linux-ia64-low.cc b/gdbserver/linux-ia64-low.cc > index 493c7e4f93d..0eb0ac53453 100644 > --- a/gdbserver/linux-ia64-low.cc > +++ b/gdbserver/linux-ia64-low.cc > @@ -29,6 +29,8 @@ class ia64_target : public linux_process_target > { > public: > > + ia64_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > diff --git a/gdbserver/linux-low.cc b/gdbserver/linux-low.cc > index 8eca077180e..2747c9f6b43 100644 > --- a/gdbserver/linux-low.cc > +++ b/gdbserver/linux-low.cc > @@ -281,6 +281,12 @@ static int check_ptrace_stopped_lwp_gone (struct lwp_info *lp); > being stepped. */ > ptid_t step_over_bkpt; > > +linux_process_target::linux_process_target (int decr_pc_after_break) > + : m_decr_pc_after_break {decr_pc_after_break} > +{ > + /* Nop. */ > +} > + > /* True if the low target can hardware single-step. */ > > static int > @@ -796,7 +802,7 @@ linux_process_target::save_stop_reason (lwp_info *lwp) > return false; > > pc = get_pc (lwp); > - sw_breakpoint_pc = pc - the_low_target.decr_pc_after_break; > + sw_breakpoint_pc = pc - this->m_decr_pc_after_break; > > /* breakpoint_at reads from the current thread. */ > saved_thread = current_thread; > @@ -3694,7 +3700,7 @@ linux_process_target::wait_1 (ptid_t ptid, target_waitstatus *ourstatus, > if (event_child->stop_reason == TARGET_STOPPED_BY_SW_BREAKPOINT > && !cs.swbreak_feature) > { > - int decr_pc = the_low_target.decr_pc_after_break; > + int decr_pc = this->m_decr_pc_after_break; > > if (decr_pc != 0) > { > diff --git a/gdbserver/linux-low.h b/gdbserver/linux-low.h > index 2202a658225..e289d5d06a0 100644 > --- a/gdbserver/linux-low.h > +++ b/gdbserver/linux-low.h > @@ -131,7 +131,6 @@ struct lwp_info; > > struct linux_target_ops > { > - int decr_pc_after_break; > int (*breakpoint_at) (CORE_ADDR pc); > > /* Breakpoint and watchpoint related functions. See target.h for > @@ -237,6 +236,8 @@ class linux_process_target : public process_stratum_target > { > public: > > + linux_process_target (int decr_pc_after_break); > + > int create_inferior (const char *program, > const std::vector &program_args) override; > > @@ -666,6 +667,9 @@ class linux_process_target : public process_stratum_target > Targets that override this method should also override > 'supports_software_single_step' to return true. */ > virtual std::vector low_get_next_pcs (regcache *regcache); > + > + /* How many bytes the PC should be decremented after a break. */ > + int m_decr_pc_after_break; > }; > > extern linux_process_target *the_linux_target; > diff --git a/gdbserver/linux-m32r-low.cc b/gdbserver/linux-m32r-low.cc > index 78e002dfb24..4422951c342 100644 > --- a/gdbserver/linux-m32r-low.cc > +++ b/gdbserver/linux-m32r-low.cc > @@ -29,6 +29,8 @@ class m32r_target : public linux_process_target > { > public: > > + m32r_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -160,7 +162,6 @@ m32r_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 0, > m32r_breakpoint_at, > NULL, /* supports_z_point_type */ > NULL, /* insert_point */ > diff --git a/gdbserver/linux-m68k-low.cc b/gdbserver/linux-m68k-low.cc > index 00851af5f02..5b6a1e391db 100644 > --- a/gdbserver/linux-m68k-low.cc > +++ b/gdbserver/linux-m68k-low.cc > @@ -25,6 +25,8 @@ class m68k_target : public linux_process_target > { > public: > > + m68k_target () : linux_process_target (2) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -255,7 +257,6 @@ m68k_supports_hardware_single_step (void) > } > > struct linux_target_ops the_low_target = { > - 2, > m68k_breakpoint_at, > NULL, /* supports_z_point_type */ > NULL, /* insert_point */ > diff --git a/gdbserver/linux-mips-low.cc b/gdbserver/linux-mips-low.cc > index 710245c1610..b02c9272764 100644 > --- a/gdbserver/linux-mips-low.cc > +++ b/gdbserver/linux-mips-low.cc > @@ -31,6 +31,8 @@ class mips_target : public linux_process_target > { > public: > > + mips_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -966,7 +968,6 @@ mips_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 0, > mips_breakpoint_at, > mips_supports_z_point_type, > mips_insert_point, > diff --git a/gdbserver/linux-nios2-low.cc b/gdbserver/linux-nios2-low.cc > index 3cae8dac285..4fa80cd751b 100644 > --- a/gdbserver/linux-nios2-low.cc > +++ b/gdbserver/linux-nios2-low.cc > @@ -37,6 +37,8 @@ class nios2_target : public linux_process_target > { > public: > > + nios2_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -277,7 +279,6 @@ nios2_target::get_regs_info () > > struct linux_target_ops the_low_target = > { > - 0, > nios2_breakpoint_at, > }; > > diff --git a/gdbserver/linux-ppc-low.cc b/gdbserver/linux-ppc-low.cc > index af9dc0b2adf..66b5f9bc565 100644 > --- a/gdbserver/linux-ppc-low.cc > +++ b/gdbserver/linux-ppc-low.cc > @@ -50,6 +50,8 @@ class ppc_target : public linux_process_target > { > public: > > + ppc_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -3406,7 +3408,6 @@ ppc_get_ipa_tdesc_idx (void) > } > > struct linux_target_ops the_low_target = { > - 0, > ppc_breakpoint_at, > ppc_supports_z_point_type, > ppc_insert_point, > diff --git a/gdbserver/linux-riscv-low.cc b/gdbserver/linux-riscv-low.cc > index 31401dbdbbe..701c4370a32 100644 > --- a/gdbserver/linux-riscv-low.cc > +++ b/gdbserver/linux-riscv-low.cc > @@ -36,6 +36,8 @@ class riscv_target : public linux_process_target > { > public: > > + riscv_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > int breakpoint_kind_from_pc (CORE_ADDR *pcptr) override; > @@ -309,7 +311,6 @@ riscv_breakpoint_at (CORE_ADDR pc) > /* RISC-V/Linux target operations. */ > struct linux_target_ops the_low_target = > { > - 0, /* decr_pc_after_break */ > riscv_breakpoint_at, > }; > > diff --git a/gdbserver/linux-s390-low.cc b/gdbserver/linux-s390-low.cc > index 4c4b877bb75..68ab1ef7273 100644 > --- a/gdbserver/linux-s390-low.cc > +++ b/gdbserver/linux-s390-low.cc > @@ -51,12 +51,17 @@ > > #define s390_num_regs 52 > > +static const gdb_byte s390_breakpoint[] = { 0, 1 }; > +#define s390_breakpoint_len 2 > + > /* Linux target op definitions for the S/390 architecture. */ > > class s390_target : public linux_process_target > { > public: > > + s390_target () : linux_process_target (s390_breakpoint_len) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -450,9 +455,6 @@ static struct regset_info s390_regsets[] = { > }; > > > -static const gdb_byte s390_breakpoint[] = { 0, 1 }; > -#define s390_breakpoint_len 2 > - > /* Implementation of target ops method "sw_breakpoint_from_kind". */ > > const gdb_byte * > @@ -2826,7 +2828,6 @@ s390_emit_ops (void) > } > > struct linux_target_ops the_low_target = { > - s390_breakpoint_len, > s390_breakpoint_at, > s390_supports_z_point_type, > NULL, > diff --git a/gdbserver/linux-sh-low.cc b/gdbserver/linux-sh-low.cc > index 47242dafe94..7f55f34a0bc 100644 > --- a/gdbserver/linux-sh-low.cc > +++ b/gdbserver/linux-sh-low.cc > @@ -25,6 +25,8 @@ class sh_target : public linux_process_target > { > public: > > + sh_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -190,7 +192,6 @@ sh_target::low_arch_setup () > } > > struct linux_target_ops the_low_target = { > - 0, > sh_breakpoint_at, > NULL, /* supports_z_point_type */ > NULL, /* insert_point */ > diff --git a/gdbserver/linux-sparc-low.cc b/gdbserver/linux-sparc-low.cc > index f724cb88b71..1998267196d 100644 > --- a/gdbserver/linux-sparc-low.cc > +++ b/gdbserver/linux-sparc-low.cc > @@ -48,6 +48,8 @@ class sparc_target : public linux_process_target > { > public: > > + sparc_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -339,7 +341,6 @@ sparc_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 0, > sparc_breakpoint_at, > NULL, /* supports_z_point_type */ > NULL, NULL, NULL, NULL, > diff --git a/gdbserver/linux-tic6x-low.cc b/gdbserver/linux-tic6x-low.cc > index 347b79e6519..596177e0b20 100644 > --- a/gdbserver/linux-tic6x-low.cc > +++ b/gdbserver/linux-tic6x-low.cc > @@ -44,6 +44,8 @@ class tic6x_target : public linux_process_target > { > public: > > + tic6x_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -421,7 +423,6 @@ tic6x_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 0, > tic6x_breakpoint_at, > NULL, /* supports_z_point_type */ > NULL, /* insert_point */ > diff --git a/gdbserver/linux-tile-low.cc b/gdbserver/linux-tile-low.cc > index 86191b9bb1c..40350e026c8 100644 > --- a/gdbserver/linux-tile-low.cc > +++ b/gdbserver/linux-tile-low.cc > @@ -29,6 +29,8 @@ class tile_target : public linux_process_target > { > public: > > + tile_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -222,7 +224,6 @@ tile_supports_hardware_single_step (void) > > struct linux_target_ops the_low_target = > { > - 0, > tile_breakpoint_at, > NULL, /* supports_z_point_type */ > NULL, /* insert_point */ > diff --git a/gdbserver/linux-x86-low.cc b/gdbserver/linux-x86-low.cc > index 59c6b386d11..121b367e5fc 100644 > --- a/gdbserver/linux-x86-low.cc > +++ b/gdbserver/linux-x86-low.cc > @@ -100,6 +100,8 @@ class x86_target : public linux_process_target > { > public: > > + x86_target () : linux_process_target (1) { } > + > /* Update all the target description of all processes; a new GDB > connected, and it may or not support xml target descriptions. */ > void update_xmltarget (); > @@ -2899,7 +2901,6 @@ x86_get_ipa_tdesc_idx (void) > > struct linux_target_ops the_low_target = > { > - 1, > x86_breakpoint_at, > x86_supports_z_point_type, > x86_insert_point, > diff --git a/gdbserver/linux-xtensa-low.cc b/gdbserver/linux-xtensa-low.cc > index 320ac92968d..d4d0780d894 100644 > --- a/gdbserver/linux-xtensa-low.cc > +++ b/gdbserver/linux-xtensa-low.cc > @@ -26,6 +26,8 @@ class xtensa_target : public linux_process_target > { > public: > > + xtensa_target () : linux_process_target (0) { } > + > const regs_info *get_regs_info () override; > > const gdb_byte *sw_breakpoint_from_kind (int kind, int *size) override; > @@ -328,7 +330,6 @@ xtensa_target::get_regs_info () > } > > struct linux_target_ops the_low_target = { > - 0, > xtensa_breakpoint_at, > NULL, /* supports_z_point_type */ > NULL, /* insert_point */ >