From patchwork Thu Aug 9 20:26:42 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Omar Sandoval X-Patchwork-Id: 10561897 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id E414714E2 for ; Thu, 9 Aug 2018 20:26:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C5D262B9EE for ; Thu, 9 Aug 2018 20:26:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B805D2B9F7; Thu, 9 Aug 2018 20:26:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5BA362B9EE for ; Thu, 9 Aug 2018 20:26:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726953AbeHIWxY (ORCPT ); Thu, 9 Aug 2018 18:53:24 -0400 Received: from mail-pf1-f193.google.com ([209.85.210.193]:33295 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726890AbeHIWxY (ORCPT ); Thu, 9 Aug 2018 18:53:24 -0400 Received: by mail-pf1-f193.google.com with SMTP id d4-v6so3390234pfn.0 for ; Thu, 09 Aug 2018 13:26:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=osandov-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=8HapiRAuOOENX6vake9bCkcDFgMaPg9vINyq61Quz30=; b=ktT7SQ66GLBnPvDy3c4uvVgF0CNjFuJaNDulvS7muvs+Pz6//jr66eniLmDOZ0IN6N ZMMF4+rxmzkluWKBSywC1+th9Xpw3r+04eTQLTp143NHuOvC0v2yZSUn4jEqpsx2wATp zt+qlcVFvFfCemdqTy6Wx3I04tEL68ZcSdECC1VRMOXT8KQlcUzOvjg9Qkp6oGf5v66+ OeHlW8TD5W9dpEChRT6ez32aiXb5CcgzHp+EtwCdvzPBD97vYzU6qWqWy/Eu7wKez/m+ NqTrtudb3ehWklVcdFQSVxUkV4WYevb3k+qXfkNMK1KM5SB6iD4hsODznzdZvJ7tecUr cdSg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=8HapiRAuOOENX6vake9bCkcDFgMaPg9vINyq61Quz30=; b=Aa0xdCcDQHmQtf3f9GJN+8t+RBEuY7kgEuhmLd/UGvth3x/26nz7H7mqAJhhPCxLHb Um7as7MSyakcNZDGfsEsjsv32OuC0R25xG7imi3SL5i4wDV9eyMQk1Fccdr4epz9oqFQ Gbul5cD64XBxR5JmwP8oPFQ0Fzu6pQGNwnM+slEcFqBXV5LMrxMgMryGhL3Obrq4x6jC lvKYck3fEO1UrJTSaQJQXntU3YjZ6ebOEmSuVmnLRpupZveFumrwyzI+iQXx5n9c8pww oGqyNg+JiI8hkCVVmnLGPUlba0atuwwypCFa9P7Fq+JLqtmnyfw3HhRiiLAWM0DMvID5 SRlQ== X-Gm-Message-State: AOUpUlFBJ6fhmDrm6doyyZSuOi0sZdZHQAiMz0JdeRiRNWCxEMzcD8cO P8EHzwiUzTeTgqmLoQ6rlovAac252BY= X-Google-Smtp-Source: AA+uWPxgU4N5rGLZUfwPzA86PGRu8MWwU4IUA3iBqmNC5JIjYWYd4i2x9XuujnIR2sJ3LOLk3gBMwA== X-Received: by 2002:a62:f909:: with SMTP id o9-v6mr3883720pfh.141.1533846415146; Thu, 09 Aug 2018 13:26:55 -0700 (PDT) Received: from vader.thefacebook.com ([2620:10d:c090:200::4:dd24]) by smtp.gmail.com with ESMTPSA id u2-v6sm9841709pfn.59.2018.08.09.13.26.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 09 Aug 2018 13:26:54 -0700 (PDT) From: Omar Sandoval To: linux-block@vger.kernel.org Cc: Jens Axboe , kernel-team@fb.com Subject: [RFC PATCH 0/5] kyber: better heuristics Date: Thu, 9 Aug 2018 13:26:42 -0700 Message-Id: X-Mailer: git-send-email 2.18.0 Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Omar Sandoval Hello, I've spent the past few weeks experimenting with different heuristics for Kyber in order to deal with some edge cases we've hit here. This series is my progress so far, implementing less handwavy heuristics while keeping the same basic mechanisms. Patches 1 and 2 are preparation. Patch 3 is a minor optimization. Patch 4 is the main change, and includes a detailed description of the new heuristics. Patch 5 adds tracepoints for debugging. Please, take a look and try it out. Thanks! Omar Sandoval (5): block: move call of scheduler's ->completed_request() hook block: export blk_stat_enable_accounting() kyber: don't make domain token sbitmap larger than necessary kyber: implement improved heuristics kyber: add tracepoints block/blk-mq-sched.h | 4 +- block/blk-mq.c | 5 +- block/blk-stat.c | 1 + block/kyber-iosched.c | 541 +++++++++++++++++++---------------- include/linux/elevator.h | 2 +- include/trace/events/kyber.h | 76 +++++ 6 files changed, 383 insertions(+), 246 deletions(-) create mode 100644 include/trace/events/kyber.h