From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C4FA2C12002 for ; Wed, 21 Jul 2021 10:01:54 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9472F61019 for ; Wed, 21 Jul 2021 10:01:54 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9472F61019 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=TKvSYPDacXqkuYGnPA7RObP1L2JKx6+gcDucVtISs0g=; b=4nTMXVvZO6Jg5N WiA6L5WQUyANMcZB3WO8Xip1XmWNcpt9Lc+4FKWk7BLswR0GOpJIHe+n5ZncBm5CekEN5MGtGliV1 ENLeQ1Zn8ogQDv6ZtFHR4z+721lLhrFHuE43VcPQZzGermnjdJXo+ATPdeSlsOvUItCT/w0EVz0q9 UOnV6rs7QAfxOY8axKHVuaLBSCAcLylEPx0DK1rV5aayr1EOLtZL+LAoDBdo1hFKYaFqj1MSh6BFm GiYHClZ4c48AGbAyduMwZjSfDsaCXHcFgpW7CkPtfBpV4i9fufEgJQQR/hVvm+5U5PCxkOmVr63gB do1c3B+Yz3p8rf8VeqWw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1m691G-00F9dq-9p; Wed, 21 Jul 2021 10:00:02 +0000 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1m6911-00F9bB-Jy for linux-arm-kernel@lists.infradead.org; Wed, 21 Jul 2021 09:59:49 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1626861586; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=3NEHt8cctnmAx7xk3wK9xWSkrUlp4CC4dKGzkyQQ8Yw=; b=QgYmcPTZKNExy+oIS1UDKOdqjusHJ5sS0dHFKAtEsDSL9pTMhfUmgHeX5Bh/y/zhgCQPpQ g37Lwu/ZeZJ9mUHeJHLh+GRN5q0+uUociaIZKqG0spqtAh1TLPRS5XdCGVFNQHphQbU0MX h6WMGQbTssqucBk1OrBbSs2mB+Rjido= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-484-SJTRjZVnNn6qQpwZLzi5uw-1; Wed, 21 Jul 2021 05:59:42 -0400 X-MC-Unique: SJTRjZVnNn6qQpwZLzi5uw-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 97276423C7; Wed, 21 Jul 2021 09:59:41 +0000 (UTC) Received: from T590 (ovpn-13-178.pek2.redhat.com [10.72.13.178]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 2AB3319D7C; Wed, 21 Jul 2021 09:59:32 +0000 (UTC) Date: Wed, 21 Jul 2021 17:59:28 +0800 From: Ming Lei To: John Garry Cc: Robin Murphy , iommu@lists.linux-foundation.org, Will Deacon , linux-arm-kernel@lists.infradead.org, linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [bug report] iommu_dma_unmap_sg() is very slow then running IO from remote numa node Message-ID: References: <23e7956b-f3b5-b585-3c18-724165994051@arm.com> <74537f9c-af5f-cd84-60ab-49ca6220310e@huawei.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <74537f9c-af5f-cd84-60ab-49ca6220310e@huawei.com> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210721_025947_797494_D41574FC X-CRM114-Status: GOOD ( 17.97 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, Jul 21, 2021 at 10:23:38AM +0100, John Garry wrote: > On 21/07/2021 02:40, Ming Lei wrote: > > > I think that you should see a significant performance boost. > > There is build issue, please check your tree: > > > > MODPOST vmlinux.symvers > > MODINFO modules.builtin.modinfo > > GEN modules.builtin > > LD .tmp_vmlinux.btf > > ld: Unexpected GOT/PLT entries detected! > > ld: Unexpected run-time procedure linkages detected! > > ld: drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.o: in function `smmu_test_store': > > /root/git/linux/drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c:3892: undefined reference to `smmu_test_core' > > BTF .btf.vmlinux.bin.o > > pahole: .tmp_vmlinux.btf: No such file or directory > > LD .tmp_vmlinux.kallsyms1 > > .btf.vmlinux.bin.o: file not recognized: file format not recognized > > make: *** [Makefile:1177: vmlinux] Error 1 > > Ah, sorry. I had some test code which was not properly guarded with > necessary build switches. > > I have now removed that from the tree, so please re-pull. Now the kernel can be built successfully, but not see obvious improvement on the reported issue: [root@ampere-mtjade-04 ~]# uname -a Linux ampere-mtjade-04.khw4.lab.eng.bos.redhat.com 5.14.0-rc2_smmu_fix+ #2 SMP Wed Jul 21 05:49:03 EDT 2021 aarch64 aarch64 aarch64 GNU/Linux [root@ampere-mtjade-04 ~]# taskset -c 0 ~/git/tools/test/nvme/io_uring 10 1 /dev/nvme1n1 4k + fio --bs=4k --ioengine=io_uring --fixedbufs --registerfiles --hipri --iodepth=64 --iodepth_batch_submit=16 --iodepth_batch_complete_min=16 --filename=/dev/nvme1n1 --direct=1 --runtime=10 --numjobs=1 --rw=randread --name=test --group_reporting test: (g=0): rw=randread, bs=(R) 4096B-4096B, (W) 4096B-4096B, (T) 4096B-4096B, ioengine=io_uring, iodepth=64 fio-3.27 Starting 1 process Jobs: 1 (f=1): [r(1)][100.0%][r=1503MiB/s][r=385k IOPS][eta 00m:00s] test: (groupid=0, jobs=1): err= 0: pid=3143: Wed Jul 21 05:58:14 2021 read: IOPS=384k, BW=1501MiB/s (1573MB/s)(14.7GiB/10001msec) [root@ampere-mtjade-04 ~]# taskset -c 80 ~/git/tools/test/nvme/io_uring 10 1 /dev/nvme1n1 4k + fio --bs=4k --ioengine=io_uring --fixedbufs --registerfiles --hipri --iodepth=64 --iodepth_batch_submit=16 --iodepth_batch_complete_min=16 --filename=/dev/nvme1n1 --direct=1 --runtime=10 --numjobs=1 --rw=randread --name=test --group_reporting test: (g=0): rw=randread, bs=(R) 4096B-4096B, (W) 4096B-4096B, (T) 4096B-4096B, ioengine=io_uring, iodepth=64 fio-3.27 Starting 1 process Jobs: 1 (f=1): [r(1)][100.0%][r=138MiB/s][r=35.4k IOPS][eta 00m:00s] test: (groupid=0, jobs=1): err= 0: pid=3063: Wed Jul 21 05:55:31 2021 read: IOPS=35.4k, BW=138MiB/s (145MB/s)(1383MiB/10001msec) Thanks, Ming _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel