From owner-dev-commits-src-main@freebsd.org Fri Feb 19 03:38:04 2021 Return-Path: Delivered-To: dev-commits-src-main@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id CD05053A32C; Fri, 19 Feb 2021 03:38:04 +0000 (UTC) (envelope-from asomers@gmail.com) Received: from mail-ot1-f53.google.com (mail-ot1-f53.google.com [209.85.210.53]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4DhcjS47SQz4p5M; Fri, 19 Feb 2021 03:38:04 +0000 (UTC) (envelope-from asomers@gmail.com) Received: by mail-ot1-f53.google.com with SMTP id s107so3945097otb.8; Thu, 18 Feb 2021 19:38:04 -0800 (PST) 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; bh=191z9Cc+7QNPXruC9nYKiOctTgTxqPgO/reL6DRJzdY=; b=Rmvk/C8DScUfkpy165u/enRzFRtyZ1KECDoM9hOzMa5D2/oltgM+Uc3rGPO5B4RsP8 nGSyQ3WJOxMvCK7+2mm8uechC3rR5TSUfiyH4XrAJplAXBp0swsWufR/K7sFTvARcB69 KLswu4tNEepsV1Y3/fHv/WVbiXMw+4F0YfA8WPP5GrLsx57vOLni1NZx4dSpPQ8Llbwj 4oWIHcRRlbht1tTh4MHmm8JAbF3KOBl96Hx0ToyQSHW0mvk/8+WLvxc7Lm8D04uQnAGQ c3pniUOF3elDMVxwki+6uCZRKOd5MFYtnQXPCXN//vqiJpvx1CAXGFK0IzTAv17b5lAx Lhrw== X-Gm-Message-State: AOAM531c5zm3VTn72V7e5cIKuPgd9Lz2KqIfUPrhnGwfJShxNqiqgXdr TbPAk32l2ZMYaFRzZrtmtWir28aXU6LEpHcJg05pY/rRnwc= X-Google-Smtp-Source: ABdhPJx+hGXpLdTEo7hBc8pqTx89eyNVrV3a9kmcZOyNvTns5OJkWq6Pw3zJXkXh4/qMLAKFElUM555kdL8c9aEHNM4= X-Received: by 2002:a05:6830:18e6:: with SMTP id d6mr5547310otf.251.1613705882950; Thu, 18 Feb 2021 19:38:02 -0800 (PST) MIME-Version: 1.0 References: <202102190329.11J3TgmF088194@gitrepo.freebsd.org> In-Reply-To: <202102190329.11J3TgmF088194@gitrepo.freebsd.org> From: Alan Somers Date: Thu, 18 Feb 2021 20:37:51 -0700 Message-ID: Subject: Re: git: 812c9f48a2b7 - main - Save context switch per I/O for iSCSI and IOCTL frontends. To: Alexander Motin Cc: src-committers , dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org X-Rspamd-Queue-Id: 4DhcjS47SQz4p5M X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.34 X-BeenThere: dev-commits-src-main@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for the main branch of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Feb 2021 03:38:04 -0000 On Thu, Feb 18, 2021 at 8:29 PM Alexander Motin wrote: > The branch main has been updated by mav: > > URL: > https://cgit.FreeBSD.org/src/commit/?id=812c9f48a2b7bccc31b2a6077b299822357832e4 > > commit 812c9f48a2b7bccc31b2a6077b299822357832e4 > Author: Alexander Motin > AuthorDate: 2021-02-19 03:07:32 +0000 > Commit: Alexander Motin > CommitDate: 2021-02-19 03:29:38 +0000 > > Save context switch per I/O for iSCSI and IOCTL frontends. > > Introduce new CTL core KPI ctl_run(), preprocessing I/Os in the caller > context instead of scheduling another thread just for that. This call > may sleep, that is not acceptable for some frontends like the original > CAM/FC one, but iSCSI already has separate sleepable per-connection RX > threads, and another thread scheduling is mostly just a waste of time. > IOCTL frontend actually waits for the I/O completion in the caller > thread, so the use of another thread for this has even less sense. > > With this change I can measure ~5% IOPS improvement on 4KB iSCSI I/Os > to ZFS. > Cool! That sounds very useful.