Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: "Jose E. Marchesi" <jemarch@gnu.org>
To: Simon Marchi <simon.marchi@efficios.com>
Cc: binutils@sourceware.org,  gdb-patches@sourceware.org
Subject: Re: [PATCH 09/18] sim/bpf: remove unused bpf_program_section variable
Date: Tue, 20 Oct 2026 12:59:50 +0200	[thread overview]
Message-ID: <8733u0d4d5.fsf@gnu.org> (raw)
In-Reply-To: <d7deeb1b-f509-48fb-ba06-4d538b06b87f@efficios.com>


Hi Simon.

FWIW the change LGTM.
Thanks.

> Adding gdb-patches@.
>
> On 10/19/26 3:28 PM, Simon Marchi wrote:
>> Building the BPF simulator with a recent clang fails with:
>> 
>>     /home/smarchi/src/binutils-gdb/sim/bpf/bpf-sim.c:367:14: error: variable 'bpf_program_section' set but not used [-Werror,-Wunused-but-set-global]
>> 
>> The --bpf-set-program option stores its argument in this variable, but
>> nothing ever reads it, the feature was never implemented.  Remove the
>> variable.
>> 
>> Change-Id: I71edbed055a82fb65a2acecbc38477e3ded80d6a
>> ---
>>  sim/bpf/bpf-sim.c | 5 -----
>>  1 file changed, 5 deletions(-)
>> 
>> diff --git a/sim/bpf/bpf-sim.c b/sim/bpf/bpf-sim.c
>> index 9cb272a240e5..34f78c91bc30 100644
>> --- a/sim/bpf/bpf-sim.c
>> +++ b/sim/bpf/bpf-sim.c
>> @@ -362,10 +362,6 @@ bpf_pc_set (sim_cpu *cpu, sim_cia pc)
>>  
>>  static int64_t skb_data_offset;
>>  
>> -/* String with the name of the section containing the BPF program to
>> -   run.  */
>> -static char *bpf_program_section = NULL;
>> -
>>  \f
>>  /***** Handle BPF-specific command line options.  *****/
>>  
>> @@ -416,7 +412,6 @@ bpf_option_handler (SIM_DESC sd, sim_cpu *cpu ATTRIBUTE_UNUSED, int opt,
>>      case OPTION_BPF_SET_PROGRAM:
>>        /* XXX: check that the section exists and tell the user about a
>>           new start_address.  */
>> -      bpf_program_section = xstrdup (arg);
>>        break;
>>  
>>      case OPTION_BPF_SKB_DATA_OFFSET:
>> -- 
>> 2.56.0
>> 

  reply	other threads:[~2026-10-21 10:39 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20261019193231.1708375-1-simon.marchi@efficios.com>
     [not found] ` <20261019193231.1708375-10-simon.marchi@efficios.com>
2026-10-19 19:35   ` Simon Marchi
2026-10-20 10:59     ` Jose E. Marchesi [this message]
2026-10-21 13:30       ` Simon Marchi
     [not found] ` <20261019193231.1708375-11-simon.marchi@efficios.com>
2026-10-19 19:36   ` [PATCH 10/18] sim/erc32: fix -Wunused-but-set-global errors Simon Marchi
     [not found] ` <20261019193231.1708375-12-simon.marchi@efficios.com>
2026-10-19 19:36   ` [PATCH 11/18] sim/m68hc11: remove unused current_insn_size variable Simon Marchi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8733u0d4d5.fsf@gnu.org \
    --to=jemarch@gnu.org \
    --cc=binutils@sourceware.org \
    --cc=gdb-patches@sourceware.org \
    --cc=simon.marchi@efficios.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox