From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id BE24B42BCC; Mon, 29 May 2023 08:32:22 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id F1AA7427F2; Mon, 29 May 2023 08:32:21 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by mails.dpdk.org (Postfix) with ESMTP id 47C024111C for ; Mon, 29 May 2023 08:32:20 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1685341940; x=1716877940; h=from:to:subject:date:message-id:references:in-reply-to: content-transfer-encoding:mime-version; bh=Kgh39e/cBW/gesuMfUeAg+rwsY8a49kumr8sg/GV37k=; b=LmDgwlG6eLKalYtvj2o/JFkQU6ZyfcZmw0rS1gvFIUxZ1+lBV/Lyc+Rl QnBHBTSmMfaj2uoA4Qf/hCfx2ovY8BIRG+9Eem1j2PPe/foXrhCoa5Iaz wKTv/TOU9hi9acX/IlMC70sEo4NwPxG3WjcVFhGYyvAIKTivvElqx58+p dMRFZN9R5IRhT8bVKPFfW/r32GVUvkVKU2t9iCVmNDPdSs79PkpgtoTNT qp8gCiwcO8MlV5WLmhP+KFUUqivUFHtXVM5EP/f7tUT+/kB7w2qu9+jm5 iZc1/BO3dHAoLMNzilIy91bQlf9Nh2Pnt3BrPFtLBebV/Z5r0g8SMDT7i w==; X-IronPort-AV: E=McAfee;i="6600,9927,10724"; a="334988797" X-IronPort-AV: E=Sophos;i="6.00,200,1681196400"; d="scan'208";a="334988797" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 May 2023 23:32:19 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10724"; a="709141331" X-IronPort-AV: E=Sophos;i="6.00,200,1681196400"; d="scan'208";a="709141331" Received: from orsmsx601.amr.corp.intel.com ([10.22.229.14]) by fmsmga007.fm.intel.com with ESMTP; 28 May 2023 23:32:18 -0700 Received: from orsmsx610.amr.corp.intel.com (10.22.229.23) by ORSMSX601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Sun, 28 May 2023 23:32:18 -0700 Received: from orsmsx611.amr.corp.intel.com (10.22.229.24) by ORSMSX610.amr.corp.intel.com (10.22.229.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Sun, 28 May 2023 23:32:17 -0700 Received: from ORSEDG602.ED.cps.intel.com (10.7.248.7) by orsmsx611.amr.corp.intel.com (10.22.229.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23 via Frontend Transport; Sun, 28 May 2023 23:32:17 -0700 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (104.47.59.168) by edgegateway.intel.com (134.134.137.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.23; Sun, 28 May 2023 23:32:17 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ROIBZk4R5nAY0bByhZTL0yXHztGJ/A/GpX3qSDxLYQxyuOgFp+egNLG6UhJ4czW7/q4XSzMrPMGBQabAaiwbLuy1eff7Bs6zq5pMkfAsnn7CL6xcyyzc2pNcQEJf3aQbCDhyYay0vOBBTuLCxKepP5rMIavBK7CZnQi84H5pxWCO8hU6boW7Q7ckd8OukHgrpmGtWHYknWYYGKtv7qBYJM2wUPzhTTB1GP4WFPCYHHZ+IHgo0cFOAyjXUIOgPFaUmc2uVktdLOdElBRQzMiKPUsctmDNhfbWQt4f59dOsYCS2oUGsrGiIFEtwo1RjykIWUMqmzSDvfzaj20Z3c/L8A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=aCTJxSgJdBGph6EYnnV2WCIQCuRJy63XNxlf7cKVCeA=; b=US32osRKJ4p3xrOxtP3KoXz6bvQT/otnMSPcKC1TrXYVjSvKpbqFHaRp8VJfmHc3mV6P2GUBLNRJCeSruceRdLV1QYuXGox47pdzoh5xXWqHDG2zuJJ+GYzY3Rm7Je512r0tKPdBWUHU+TbNpY8G8lswQy/ETXqopT2kMBMmillcfM5YY1wqWEnO2SMmguLK5pUBeJ2OXf24YV5GGxN/38v3ueLR4lROKLyBJ1lRcy56Q0OU8OqbRD2tBn7r5cHuGPgPtncwopiA3xAi0yGc17i6aY8akvOK998ypDJaE7A8hQiV273uRo19B6SxPJ35mF6x1OC1xfYT7klXVB6Wng== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from SN6PR11MB3504.namprd11.prod.outlook.com (2603:10b6:805:d0::17) by SJ0PR11MB4816.namprd11.prod.outlook.com (2603:10b6:a03:2ad::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6433.22; Mon, 29 May 2023 06:32:16 +0000 Received: from SN6PR11MB3504.namprd11.prod.outlook.com ([fe80::e427:f0a6:8472:d0f6]) by SN6PR11MB3504.namprd11.prod.outlook.com ([fe80::e427:f0a6:8472:d0f6%7]) with mapi id 15.20.6433.020; Mon, 29 May 2023 06:32:15 +0000 From: "Xia, Chenbo" To: Maxime Coquelin , "dev@dpdk.org" , "david.marchand@redhat.com" , "mkp@redhat.com" , "fbl@redhat.com" , "jasowang@redhat.com" , "Liang, Cunming" , "Xie, Yongji" , "echaudro@redhat.com" , "eperezma@redhat.com" , "amorenoz@redhat.com" , "lulu@redhat.com" Subject: RE: [PATCH v3 07/28] vhost: change to single IOTLB cache per device Thread-Topic: [PATCH v3 07/28] vhost: change to single IOTLB cache per device Thread-Index: AQHZjyWzgCRY4w86tE+D2FAO8X9mu69w0CHQ Date: Mon, 29 May 2023 06:32:15 +0000 Message-ID: References: <20230525162551.70359-1-maxime.coquelin@redhat.com> <20230525162551.70359-8-maxime.coquelin@redhat.com> In-Reply-To: <20230525162551.70359-8-maxime.coquelin@redhat.com> Accept-Language: en-US, zh-CN Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: SN6PR11MB3504:EE_|SJ0PR11MB4816:EE_ x-ms-office365-filtering-correlation-id: 52fde3f6-337f-4fc2-4c5d-08db600e715d x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: liirlLSJ1oENeEAoDM2Q/B006d1/0sYXqmemlZ9X0mJIz9FK5NlgO/EE03HwS3FrRH9hEITnHT2POhqTuzbNLkYNyk8lgOdRSAlEIYoc24pGBBGPE9SsrcqC0UyAB28kVEmoTSZTp3isgJVJ2wHCUnf3wB/4XvxHUCnG7ThJvxrmThrgCQcdPhEy6/D8WcL6o745mePi2nKrxVocEbeFIJwBDsQk/q2SJwoXwTFBeZoyqswLynYQLgAst5Yw2rOrQbHYX7LGM8igeDrEJhyGNqmfh3Sa/I1MG74ykY7OGSWbEiQ0r4fHZenqtCjkzjKg8VRFy/bYXfCEHQBK89M68UVULgASsT1tA6ffTHc3sD1U2A48anNwSAQ4RaOgcer56BO/qVkQhO5DNJNd0smb6XkACNOBNO8/ZaYKs27AePm1C3yXDJUpZHZWFDcTcAC3kVmVJbrjvZYXOg5gt245QrRP4aRIC5sjXMyA3a26W/XYQ/TKr1pDOrtA64/BBFqi3VobpJuIPfbCLzfjYifom2oD19NmQ5sZGFk8WILhC2dYlCI7mzSu7TLlDKoJQe54ypjLMU7ESR5zyxjUwLNbyxNnZc/FRFmZ1OjG4mT5qDjrE0W4kYlkAp0Kto3UY19D22QArJ+AyhYtxGc9NTsNLQ== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SN6PR11MB3504.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230028)(366004)(396003)(136003)(39860400002)(346002)(376002)(451199021)(26005)(7696005)(53546011)(9686003)(71200400001)(6506007)(2906002)(316002)(33656002)(186003)(55016003)(52536014)(5660300002)(41300700001)(7416002)(8676002)(8936002)(478600001)(921005)(82960400001)(122000001)(38100700002)(86362001)(110136005)(76116006)(66946007)(38070700005)(66476007)(66556008)(83380400001)(64756008)(66446008); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?0Vlzxg2h+p7uRYPuByOYcF6S6I75e5qcU1XoPD2DL47HacMwDd9PwMwSfVuI?= =?us-ascii?Q?FpALiET0tIIGJKTFw+RllRo8mHQIE4ADw/cHdfxzr8hr9LFRwvDGlhVaCf4/?= =?us-ascii?Q?azlTszxYpcsGcYABijmUY4MIYDXEuIuBljgy/MXadZV+T/l7Oiy9H5lsgQoE?= =?us-ascii?Q?P2+Cv+EOgM6uECq1B1/yuhetsWwvrlleD39D1aJfVINd1oaML9ca0kaZqpJU?= =?us-ascii?Q?HW1Gjdo9mxaWgOloTubDsI7roEWGh4UqqZhq6qJc0DumHbiHEeguF8Zj6Gs2?= =?us-ascii?Q?gHS1Q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PdRKuqclmgsXKF2rRyxkyl+?= =?us-ascii?Q?ahvy6tTcJHprQ2POV6ArfypwnLakaZnORcnl9z8s/D0hkB7ZS+v+yd8ss9vL?= =?us-ascii?Q?53wUEcpTmybiU+AOu9K6taV23bBYR15Mji38cc9LKjhj1KNe20G04zLWBSYm?= =?us-ascii?Q?oCE+gMmRgpKlv50hLcmxQ8juvwbtWpaU02Ctn/eRfDBs46SR8PzWRqMzH1Jc?= =?us-ascii?Q?AgPw3q7wulPd71brLYJrLkJTRS7szc+3MiBhytzAFW/yaQ2FqIG9weNSHYsQ?= =?us-ascii?Q?8Nvupziy/Mmz2E2QL6qdGTO0LaiPJo0cVLhyjBgdR47ueRWXU6SqBJHh4gdz?= =?us-ascii?Q?4tTMrqjd7EdFk6GEnFYzEm9NH+x+5VouoPZGVTS71OcXMkuoqs86Kdk6Xcv0?= =?us-ascii?Q?ULl4ZZGJTsdR/M2niY2GmTBKgL14fMYQdtGuzCr4?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SN6PR11MB3504.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 52fde3f6-337f-4fc2-4c5d-08db600e715d X-MS-Exchange-CrossTenant-originalarrivaltime: 29 May 2023 06:32:15.0494 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: neBGYvp04hZ8/btS/anlOwqnUTLzm3wU2BFFkGR0cbDRoLMycNiLAByjCRLYm7+etLH6whjhPm9Cdl7xANzcjA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ0PR11MB4816 X-OriginatorOrg: intel.com X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org > -----Original Message----- > From: Maxime Coquelin > Sent: Friday, May 26, 2023 12:26 AM > To: dev@dpdk.org; Xia, Chenbo ; > david.marchand@redhat.com; mkp@redhat.com; fbl@redhat.com; > jasowang@redhat.com; Liang, Cunming ; Xie, Yongj= i > ; echaudro@redhat.com; eperezma@redhat.com; > amorenoz@redhat.com; lulu@redhat.com > Cc: Maxime Coquelin > Subject: [PATCH v3 07/28] vhost: change to single IOTLB cache per device >=20 > This patch simplifies IOTLB implementation and improves > IOTLB memory consumption by having a single IOTLB cache > per device, instead of having one per queue. >=20 > In order to not impact performance, it keeps an IOTLB lock > per virtqueue, so that there is no contention between > multiple queue trying to acquire it. >=20 > Signed-off-by: Maxime Coquelin > --- > lib/vhost/iotlb.c | 212 +++++++++++++++++++---------------------- > lib/vhost/iotlb.h | 43 ++++++--- > lib/vhost/vhost.c | 18 ++-- > lib/vhost/vhost.h | 16 ++-- > lib/vhost/vhost_user.c | 23 +++-- > 5 files changed, 159 insertions(+), 153 deletions(-) >=20 > -- > 2.40.1 Reviewed-by: Chenbo Xia =20