DPDK patches and discussions
 help / color / mirror / Atom feed
From: Kevin Traynor <ktraynor@redhat.com>
To: Ferruh Yigit <ferruh.yigit@intel.com>,
	David Marchand <david.marchand@redhat.com>
Cc: dpdk-dev <dev@dpdk.org>, Thomas Monjalon <thomas@monjalon.net>,
	Yipeng Wang <yipeng1.wang@intel.com>,
	Sameh Gobriel <sameh.gobriel@intel.com>,
	Bruce Richardson <bruce.richardson@intel.com>,
	Honnappa Nagarahalli <Honnappa.Nagarahalli@arm.com>
Subject: Re: [dpdk-dev] DPDK Release Status Meeting 14/05/2020
Date: Fri, 15 May 2020 15:31:21 +0100	[thread overview]
Message-ID: <8322f4f8-ed95-7edb-322d-920a4bc7106e@redhat.com> (raw)
In-Reply-To: <f4a3b8e7-9aa1-cbc6-e05f-55d636031a09@intel.com>

On 14/05/2020 12:17, Ferruh Yigit wrote:
> On 5/14/2020 12:13 PM, Ferruh Yigit wrote:
>> Minutes 14 May 2020
>> -------------------
> 
> <...>
> 
>>   * gcc10
>>     * Akhil's fix for crypto looks good, can replace temporary solution
>>     * Gavin has patch for mbuf, but this stage can be late/risky for complex fix
>>       * At this stage we can go with disabling warning as temporary solution
>>     * Ferruh is getting a warning on hash too, will share it
> 
> Hi David,
> 
> Following is what I am getting [1] with compiler version:
> gcc (GCC) 10.1.1 20200511
> 
> 
> [1]
> .../dpdk/lib/librte_hash/rte_cuckoo_hash.c: In function
> ‘__rte_hash_add_key_with_hash’:
> .../dpdk/lib/librte_hash/rte_cuckoo_hash.c:1104:29:
>     error: ‘ext_bkt_id’ may be used uninitialized in this function
> [-Werror=maybe-uninitialized]
>  1104 |  (h->buckets_ext[ext_bkt_id - 1]).sig_current[0] = short_sig;
>       |                  ~~~~~~~~~~~^~~
> 

The return value of rte_ring_sc_dequeue_elem() is checked, but gcc
seems to find some possibility of ext_bkt_id not being initialized.

It was introduced with commit [1], but I guess the tools wouldn't have
found it at time of commit.

zero is an invalid value for ext_bkt_id, so we can just initialize to
that and check it is overwritten. Sent patch
https://patchwork.dpdk.org/patch/70333/

[1]
commit fbfe568103b046a3c6c69c9ecd6c914b391c6b82
Author: Honnappa Nagarahalli <honnappa.nagarahalli@arm.com>
Date:   Sat Jan 18 13:32:46 2020 -0600

    hash: use 32-bit elements rings to save memory


  parent reply	other threads:[~2020-05-15 14:31 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-14 11:13 Ferruh Yigit
2020-05-14 11:17 ` Ferruh Yigit
2020-05-14 11:49   ` David Marchand
2020-05-15 14:31   ` Kevin Traynor [this message]
2020-05-14 13:44 ` Ferruh Yigit
2020-05-15 16:14 ` Thomas Monjalon
2020-05-21  5:47   ` Ajit Khaparde
2020-05-21  8:28   ` Iremonger, Bernard

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=8322f4f8-ed95-7edb-322d-920a4bc7106e@redhat.com \
    --to=ktraynor@redhat.com \
    --cc=Honnappa.Nagarahalli@arm.com \
    --cc=bruce.richardson@intel.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=sameh.gobriel@intel.com \
    --cc=thomas@monjalon.net \
    --cc=yipeng1.wang@intel.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;
as well as URLs for NNTP newsgroup(s).