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=-0.5 required=3.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, 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 707A2C43462 for ; Fri, 7 May 2021 19:55:54 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (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 32E6B6142D for ; Fri, 7 May 2021 19:55:54 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 32E6B6142D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id D0FB86E175; Fri, 7 May 2021 19:55:51 +0000 (UTC) Received: from mail-ot1-x32d.google.com (mail-ot1-x32d.google.com [IPv6:2607:f8b0:4864:20::32d]) by gabe.freedesktop.org (Postfix) with ESMTPS id AF5586E175; Fri, 7 May 2021 19:55:50 +0000 (UTC) Received: by mail-ot1-x32d.google.com with SMTP id c8-20020a9d78480000b0290289e9d1b7bcso8909954otm.4; Fri, 07 May 2021 12:55:50 -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; bh=mQnyWX8UpAFeWLBPcl0wEiusAg79AJ6iCjS7XN+qQUM=; b=O5HPILdivS0YKoqsFW5OAMccSfukgoFEyl8T8sxZ8qj4bfkEpHHl5xDocVhjtlKa/h KsmUB1DuEpCrO/tSrnyXV/6Dglcw9GYIoKGsbHmB1BVHAE7+08kotid/6awVvg2KMcLP OgJN3XzHyoWPbAGypOHIurPHF9JhVWJaE05OCMq28h2SBibVWcUrJTrDOVjDoN2ktJqH hrHWUvUXr4Zl90u3mOepyMvg6WFXF1FhjSSMN/UWyXUzr3YKNx29U1CUHg3p5WnQcjge WbRs0n0b6ywU9WJy4EGJsdc12xiRjZJondmU2lAWvgX717bAFdUw9cm8E2c4kelZO79s ASxg== 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=mQnyWX8UpAFeWLBPcl0wEiusAg79AJ6iCjS7XN+qQUM=; b=NvN76UY+rm4a8Cqq7dJua2BEbLDciFZNTfNnRcJpE1uHBZwi8B5mwT1/MwQjjWl7Y1 ySsFa5kPHvk6RtMmr1kA23AQvKpltfuTBF+szCVEq9WUSCx1P06qdIoXOLNirZssaxXn D4tNRNodwui7Mj+R7itkFsEKnTi4+QEKS+5k80Y+gpHp/hSFATGBRHJqBeL+NoNFBnBZ 3Uuys4AAIQ7dUrVR6B1glIznlwkGm9JFnkEOPIX6X8gHhEAdztAT8VkTXPAsNVLOcir9 P0Z0BLlewxxjw5k4OPA3tUzYOsDyR/utyhpUe+9MaYzQqZOPKQAAyeADYXYCRsGRqcjf RAqQ== X-Gm-Message-State: AOAM532akWGUhCpnGwDzl9Bwgy+UPeoAjYvitBJr22pVLSZZwVsZqsFq PHsQI8BnMtCxOhNEqbXNfGg0eNT1QTOoFknkZMo= X-Google-Smtp-Source: ABdhPJxSN3/17xHdFjhSCghcx/8s/LWHl/NuI+//RSo2pAWsPuDQlJpfn0/5Rjl3B/LGJlLffIe5AbmBEavYIDEc+bk= X-Received: by 2002:a9d:51c6:: with SMTP id d6mr3297673oth.311.1620417349972; Fri, 07 May 2021 12:55:49 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Alex Deucher Date: Fri, 7 May 2021 15:55:39 -0400 Message-ID: Subject: Re: [RFC] Add BPF_PROG_TYPE_CGROUP_IOCTL To: Tejun Heo Content-Type: text/plain; charset="UTF-8" X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Song Liu , Alexei Starovoitov , DRI Development , Alexei Starovoitov , Daniel Borkmann , Brian Welty , John Fastabend , amd-gfx list , Yonghong Song , Andrii Nakryiko , Linux-Fsdevel , Kenny Ho , Alexander Viro , KP Singh , "open list:CONTROL GROUP \(CGROUP\)" , Kenny Ho , Network Development , Alex Deucher , bpf , Martin KaFai Lau Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" On Fri, May 7, 2021 at 3:33 PM Tejun Heo wrote: > > Hello, > > On Fri, May 07, 2021 at 06:54:13PM +0200, Daniel Vetter wrote: > > All I meant is that for the container/cgroups world starting out with > > time-sharing feels like the best fit, least because your SRIOV designers > > also seem to think that's the best first cut for cloud-y computing. > > Whether it's virtualized or containerized is a distinction that's getting > > ever more blurry, with virtualization become a lot more dynamic and > > container runtimes als possibly using hw virtualization underneath. > > FWIW, I'm completely on the same boat. There are two fundamental issues with > hardware-mask based control - control granularity and work conservation. > Combined, they make it a significantly more difficult interface to use which > requires hardware-specific tuning rather than simply being able to say "I > wanna prioritize this job twice over that one". > > My knoweldge of gpus is really limited but my understanding is also that the > gpu cores and threads aren't as homogeneous as the CPU counterparts across > the vendors, product generations and possibly even within a single chip, > which makes the problem even worse. > > Given that GPUs are time-shareable to begin with, the most universal > solution seems pretty clear. The problem is temporal partitioning on GPUs is much harder to enforce unless you have a special case like SR-IOV. Spatial partitioning, on AMD GPUs at least, is widely available and easily enforced. What is the point of implementing temporal style cgroups if no one can enforce it effectively? Alex > > Thanks. > > -- > tejun