From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 418B7A057B; Tue, 14 Apr 2020 14:45:49 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id ABD101C205; Tue, 14 Apr 2020 14:45:47 +0200 (CEST) Received: from mail-io1-f68.google.com (mail-io1-f68.google.com [209.85.166.68]) by dpdk.org (Postfix) with ESMTP id EBF781C1F6; Tue, 14 Apr 2020 14:45:45 +0200 (CEST) Received: by mail-io1-f68.google.com with SMTP id i19so12995053ioh.12; Tue, 14 Apr 2020 05:45:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=NG8c1TyQhxl8m3436jjdExU8vnaip+xuM5cW0GPbCgk=; b=AbqV7pMkADbMmEcOXHviJTPMe8iLDS0XmVQfxjNGim0bF1gPSgZDusgFlLgAard6t9 6f4ev0EARPn0tYU0MV8Km6ppcfpDtZZW/y3yjHUzFx+7MjH7M9UcNsBhBCZjqN0YSWlI WSe9joBtNFUoOY3CqSKNGv1a9uVrbetfClgwo5yoavxBuI0ttsddfHHTWcAKo5tDjocH xgJIPQ1SmkoyaBi9HDbYRtEnklD1up/XCF3ufHb3yYzuJT5Dez7UKCjZtOLiOtDPZcz8 uMqncVJr61nLvi7ILu9f0qzSwqii27Owx7MrbdTjAGavJM395RKi6JwHV+PKO78vEOpq Jj5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=NG8c1TyQhxl8m3436jjdExU8vnaip+xuM5cW0GPbCgk=; b=CAURZxZijvdRFH4i9MyGz59rU4AtvPbCmG2Orj2Hh9Cu3jLq9ZoyJMxFjfA8zIDDdJ dSXkCNQYoRBLeRuhK8NBU6+ukNaxDsbyrofOsYRFbtb9xkeJL25HC+hoDHgVQGewI/hJ 7CY1omnndUans9+d4as1vHzuWEKj4+HtXZwtnFoyslznC1wmyX/xlcdqWnEQrKV5qE2D E76xMQfqXr11MCzgW+XFfYEMY1u8aAzE7k0s2w4x47pzjucaB9+9pcrCsc2IRF0uaEdn gQtkT+TIWWUq4GFA2V641IMBaS+fSblfngY+AqX+8tQMKll678e07qlrF3TOhTQ9xXVe Jb+Q== X-Gm-Message-State: AGi0Puai/AqgizXOFJRoHv2bTMK809vo66PeP5H8t9V1hqdkEXUO0o/C 7LtZwB4jsixq+/efnteyHmuiXaCcKF+yy7N53Vc= X-Google-Smtp-Source: APiQypIXvAWTiWZgiP4WdEr3mlcc8B3ju0IyDfPvT4aew/YtsdQjaMCAaYz68nzffg3ESBMERYex0VhiButNLkExlQY= X-Received: by 2002:a5e:8815:: with SMTP id l21mr630058ioj.59.1586868345291; Tue, 14 Apr 2020 05:45:45 -0700 (PDT) MIME-Version: 1.0 References: <20200305104651.25456-1-mattias.ronnblom@ericsson.com> In-Reply-To: From: Jerin Jacob Date: Tue, 14 Apr 2020 18:15:29 +0530 Message-ID: To: Venky Venkatesh Cc: =?UTF-8?Q?Mattias_R=C3=B6nnblom?= , Jerin Jacob , dpdk-dev , dpdk stable Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Subject: Re: [dpdk-dev] [PATCH] event/dsw: avoid reusing previously recorded events X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Sat, Apr 4, 2020 at 6:05 PM Jerin Jacob wrote: > > On Fri, Mar 6, 2020 at 11:35 AM Venky Venkatesh > wrote: > > > > Hi Mattias, > > Have a question on this fix. I understand you wanting a certain number = of > > events before making a decision to migrate (in the above fix). > > However, suppose there are fewer events over a few flows (even if not m= any) > > and yet your core is heavily loaded -- indicating may be they are one o= r > > more very CPU intensive flows. Often in DPI situations depending on the > > complexity of the policy you can get delayed longer. It might still be > > worthwhile to migrate if the other cores are really lightly loaded. I t= hink > > that case will be missed out in this approach. > > > > Fundamentally, the number of packets being a proxy-metric for the load = of > > that flow on the cpu is simplistic at times. Very CPU intensive > > medium/lower bandwidth flows can be picked up in this heuristic. If the= re > > is a way that at the time of DSW init we can have a way of tuning it > > depending on the application scenario it might be more flexible. > > Hi Venky and Mattias, > > Is this patch to good to merge? Please mark the patch as "Not applicable" if the patch is not required. > > > > > Thanks > > -Venky > > > > > > On Thu, Mar 5, 2020 at 2:47 AM Mattias R=C3=B6nnblom < > > mattias.ronnblom@ericsson.com> wrote: > > > > > Avoid reusing recorded events when performing a migration, since this > > > may make the migration selection logic pick an already-moved flow. > > > > > > Fixes: f6257b22e767 ("event/dsw: add load balancing") > > > Cc: stable@dpdk.org > > > > > > Reported-by: Venky Venkatesh > > > Signed-off-by: Mattias R=C3=B6nnblom > > > --- > > > drivers/event/dsw/dsw_event.c | 3 +++ > > > 1 file changed, 3 insertions(+) > > > > > > diff --git a/drivers/event/dsw/dsw_event.c b/drivers/event/dsw/dsw_ev= ent.c > > > index d68b71b98..296adea18 100644 > > > --- a/drivers/event/dsw/dsw_event.c > > > +++ b/drivers/event/dsw/dsw_event.c > > > @@ -646,6 +646,9 @@ dsw_port_consider_migration(struct dsw_evdev *dsw= , > > > if (dsw->num_ports =3D=3D 1) > > > return; > > > > > > + if (seen_events_len < DSW_MAX_EVENTS_RECORDED) > > > + return; > > > + > > > DSW_LOG_DP_PORT(DEBUG, source_port->id, "Considering > > > migration.\n"); > > > > > > /* Randomize interval to avoid having all threads considering > > > -- > > > 2.17.1 > > > > > >