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.9 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 F2697C54FC9 for ; Tue, 21 Apr 2020 18:34:27 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D76E02068F for ; Tue, 21 Apr 2020 18:34:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1587494067; bh=P4ncD5bZbHABRs0QYU1Pe/eIgzdYrE9K7q1Hk9tSOzQ=; h=References:In-Reply-To:From:Date:Subject:To:Cc:List-ID:From; b=RdpxLnTAelW7zu9Lc/GZKWew3V5B8sG8agRFO+F3VcqZDojuvQK/l5gSx3Qe2okgl c92ciuQ7fmXLQqnZj3VA02uHDPZl6Krx8QqWHyeblgjgcQD46tCWwgb4m6KWDsvqWW ABLrCAQfFh0sgu1txFlf8qm5KezDuIFH1k4nbBMY= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729355AbgDUSe1 (ORCPT ); Tue, 21 Apr 2020 14:34:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58340 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725870AbgDUSe0 (ORCPT ); Tue, 21 Apr 2020 14:34:26 -0400 Received: from mail-lj1-x242.google.com (mail-lj1-x242.google.com [IPv6:2a00:1450:4864:20::242]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E0E5EC0610D5 for ; Tue, 21 Apr 2020 11:34:24 -0700 (PDT) Received: by mail-lj1-x242.google.com with SMTP id j3so15018099ljg.8 for ; Tue, 21 Apr 2020 11:34:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=h2Sxsn5oS4nqpkBX5BqB24mfzH+Rga+VCB+qgnhYUWk=; b=EN4eMrfRCQ2BTajrHemVrZRGdfNv+VjF0Hxxcl6iPzUIc4bkpVZwbpHp6Y8qjqbOly NQiQcxT3IZhkG8k/a9SX63SzMRhr6smIcOvnSUCBWIYLh5jNRcmyHxwhZdGgJqJWyNtZ yrajiBGrLqcdHIip5S59MA6DWpMQ2o4gnwtCo= 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=h2Sxsn5oS4nqpkBX5BqB24mfzH+Rga+VCB+qgnhYUWk=; b=aVaAMnPmAbrf039D+AS3TUBEccbmp3tdMso3/rcEBR8TD6WsiZMSH7OTOu5F2JyiO5 OHxyY48R0M4Tt3Ko7iAroNxcbdTQ3N7FQgY2mVZmiJtpC6zkmBqBYsnLZLMFhdVsZJyH 3Zn/YesR5/3SdEJzLOQxKv45agUHc6XN6H/+Xgyu0PaZsJcGiwhEfiWwYn4+7DYJZNSK tTYIpQul/WjMy0XdaZLPCNuGY9aSjoeKqKKj3zAuRTljammSciTbPcLI+Z4ft+W8Kq3q 155/7bWEpiLTxYSGVVT0LEqcJ4RpyA8JTnVAWnSMshoacwUO7/lc22Fo/ZIf4SiEHDFV Jw4A== X-Gm-Message-State: AGi0PuaB2JUVhnozMGnEDfRk/2dnyaNBKZDPM6Cl/E239QHHAhqTH++H B6lvgVCi4zXqg/yhfDdEV1G8GolEEQQ= X-Google-Smtp-Source: APiQypK8rwKR7A9IFjYksSY50BHy07Vl0RUfB7/+HSuKaCH1T8e9Ia3ySgYz6heS/b84ErmQoepROw== X-Received: by 2002:a2e:878a:: with SMTP id n10mr13828584lji.130.1587494063012; Tue, 21 Apr 2020 11:34:23 -0700 (PDT) Received: from mail-lj1-f171.google.com (mail-lj1-f171.google.com. [209.85.208.171]) by smtp.gmail.com with ESMTPSA id d24sm2770272lfi.21.2020.04.21.11.34.21 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 21 Apr 2020 11:34:21 -0700 (PDT) Received: by mail-lj1-f171.google.com with SMTP id g4so6942462ljl.2 for ; Tue, 21 Apr 2020 11:34:21 -0700 (PDT) X-Received: by 2002:a2e:8512:: with SMTP id j18mr9624239lji.201.1587494060836; Tue, 21 Apr 2020 11:34:20 -0700 (PDT) MIME-Version: 1.0 References: <36e43241c7f043a24b5069e78c6a7edd11043be5.1585898438.git.christophe.leroy@c-s.fr> <42da416106d5c1cf92bda1e058434fe240b35f44.1585898438.git.christophe.leroy@c-s.fr> <20200403205205.GK23230@ZenIV.linux.org.uk> <20200421024919.GA23230@ZenIV.linux.org.uk> In-Reply-To: <20200421024919.GA23230@ZenIV.linux.org.uk> From: Linus Torvalds Date: Tue, 21 Apr 2020 11:34:04 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 5/5] uaccess: Rename user_access_begin/end() to user_full_access_begin/end() To: Al Viro Cc: Christophe Leroy , Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman , Dave Airlie , Daniel Vetter , Andrew Morton , Kees Cook , Peter Anvin , Linux Kernel Mailing List , linuxppc-dev , Linux-MM , linux-arch , intel-gfx@lists.freedesktop.org, Russell King Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Apr 20, 2020 at 7:49 PM Al Viro wrote: > > The only source I'd been able to find speaks of >= 60 cycles > (and possibly much more) for non-pipelined coprocessor instructions; > the list of such does contain loads and stores to a bunch of registers. > However, the register in question (p15/c3) has only store mentioned there, > so loads might be cheap; no obvious reasons for those to be slow. > That's a question to arm folks, I'm afraid... rmk? _If_ it turns out to be expensive, is there any reason we couldn't just cache the value in general? That's what x86 tends to do with expensive system registers. One example would be "msr_misc_features_shadow". But maybe that's something to worry about when/if it turns out to actually be a problem? Linus 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.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED 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 15845C54FCC for ; Tue, 21 Apr 2020 18:34:29 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id ABE122068F for ; Tue, 21 Apr 2020 18:34:28 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="EN4eMrfR" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org ABE122068F Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 097038E0005; Tue, 21 Apr 2020 14:34:28 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 04E8F8E0003; Tue, 21 Apr 2020 14:34:28 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EA02A8E0005; Tue, 21 Apr 2020 14:34:27 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0005.hostedemail.com [216.40.44.5]) by kanga.kvack.org (Postfix) with ESMTP id D13488E0003 for ; Tue, 21 Apr 2020 14:34:27 -0400 (EDT) Received: from smtpin08.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 8C81F1EF3 for ; Tue, 21 Apr 2020 18:34:27 +0000 (UTC) X-FDA: 76732712574.08.wave27_9c33f5429263 X-HE-Tag: wave27_9c33f5429263 X-Filterd-Recvd-Size: 4777 Received: from mail-lf1-f66.google.com (mail-lf1-f66.google.com [209.85.167.66]) by imf30.hostedemail.com (Postfix) with ESMTP for ; Tue, 21 Apr 2020 18:34:26 +0000 (UTC) Received: by mail-lf1-f66.google.com with SMTP id 131so11903446lfh.11 for ; Tue, 21 Apr 2020 11:34:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=h2Sxsn5oS4nqpkBX5BqB24mfzH+Rga+VCB+qgnhYUWk=; b=EN4eMrfRCQ2BTajrHemVrZRGdfNv+VjF0Hxxcl6iPzUIc4bkpVZwbpHp6Y8qjqbOly NQiQcxT3IZhkG8k/a9SX63SzMRhr6smIcOvnSUCBWIYLh5jNRcmyHxwhZdGgJqJWyNtZ yrajiBGrLqcdHIip5S59MA6DWpMQ2o4gnwtCo= 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=h2Sxsn5oS4nqpkBX5BqB24mfzH+Rga+VCB+qgnhYUWk=; b=sirGzRlaNYFkPjoLqXt5gmYSu727DIRUzcwr2CXt78WYssFZYDZgwzIUCLPs9YMAql tvXIeSXM1SsxdwFIejmcnCLUFICGZgWbETYAWMV+iCqv1SWSRMRa4aClWHy0gJqsayRT 5lQ2448E+yM9Mz8aTOUOwUB1UZvCtAAG24cvdMYciIM3+N8qNebYTisaiDIv9bZdwIWr 2vZizzNWLHhAks8/MYI5hoyHYbMkgdHPoPAVpZBcSaYqtvBWoDIbYBfeGKkuhFVUA01u ci84JH7eTempNxlXC4P1DjSqqDMW/VRId/qU73hfYfmCgfmJEgj9KeId4sRM3wH6Ns0D +hHQ== X-Gm-Message-State: AGi0PuYPBEPx/qLv0mqHDxTgwPQfwjR6AWZuzmkqR23a1z0a1qBKVMfR xjUKFT1YoWQPomm77TEecwL9BH7C+4c= X-Google-Smtp-Source: APiQypLH8oWwE5C/6dh/k43vMFrVSAYY0IId9z+Mrrt/WPUeClA8iEnNo6Lpu5Fy8c6G0Gtr3AAyjw== X-Received: by 2002:a05:6512:10c9:: with SMTP id k9mr14584973lfg.183.1587494064116; Tue, 21 Apr 2020 11:34:24 -0700 (PDT) Received: from mail-lj1-f176.google.com (mail-lj1-f176.google.com. [209.85.208.176]) by smtp.gmail.com with ESMTPSA id i3sm2484957ljg.82.2020.04.21.11.34.21 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 21 Apr 2020 11:34:22 -0700 (PDT) Received: by mail-lj1-f176.google.com with SMTP id z26so15039382ljz.11 for ; Tue, 21 Apr 2020 11:34:21 -0700 (PDT) X-Received: by 2002:a2e:8512:: with SMTP id j18mr9624239lji.201.1587494060836; Tue, 21 Apr 2020 11:34:20 -0700 (PDT) MIME-Version: 1.0 References: <36e43241c7f043a24b5069e78c6a7edd11043be5.1585898438.git.christophe.leroy@c-s.fr> <42da416106d5c1cf92bda1e058434fe240b35f44.1585898438.git.christophe.leroy@c-s.fr> <20200403205205.GK23230@ZenIV.linux.org.uk> <20200421024919.GA23230@ZenIV.linux.org.uk> In-Reply-To: <20200421024919.GA23230@ZenIV.linux.org.uk> From: Linus Torvalds Date: Tue, 21 Apr 2020 11:34:04 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 5/5] uaccess: Rename user_access_begin/end() to user_full_access_begin/end() To: Al Viro Cc: Christophe Leroy , Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman , Dave Airlie , Daniel Vetter , Andrew Morton , Kees Cook , Peter Anvin , Linux Kernel Mailing List , linuxppc-dev , Linux-MM , linux-arch , intel-gfx@lists.freedesktop.org, Russell King Content-Type: text/plain; charset="UTF-8" X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Mon, Apr 20, 2020 at 7:49 PM Al Viro wrote: > > The only source I'd been able to find speaks of >= 60 cycles > (and possibly much more) for non-pipelined coprocessor instructions; > the list of such does contain loads and stores to a bunch of registers. > However, the register in question (p15/c3) has only store mentioned there, > so loads might be cheap; no obvious reasons for those to be slow. > That's a question to arm folks, I'm afraid... rmk? _If_ it turns out to be expensive, is there any reason we couldn't just cache the value in general? That's what x86 tends to do with expensive system registers. One example would be "msr_misc_features_shadow". But maybe that's something to worry about when/if it turns out to actually be a problem? Linus 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.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED 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 67F6FC54FC9 for ; Tue, 21 Apr 2020 18:44:58 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (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 D97F82068F for ; Tue, 21 Apr 2020 18:44:57 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="EN4eMrfR" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D97F82068F Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from lists.ozlabs.org (unknown [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 496CD71HshzDqQd for ; Wed, 22 Apr 2020 04:44:55 +1000 (AEST) Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=linuxfoundation.org (client-ip=2a00:1450:4864:20::644; helo=mail-ej1-x644.google.com; envelope-from=torvalds@linuxfoundation.org; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: lists.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=linux-foundation.org header.i=@linux-foundation.org header.a=rsa-sha256 header.s=google header.b=EN4eMrfR; dkim-atps=neutral Received: from mail-ej1-x644.google.com (mail-ej1-x644.google.com [IPv6:2a00:1450:4864:20::644]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 496C8M6GWxzDql6 for ; Wed, 22 Apr 2020 04:41:39 +1000 (AEST) Received: by mail-ej1-x644.google.com with SMTP id x1so11784083ejd.8 for ; Tue, 21 Apr 2020 11:41:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=h2Sxsn5oS4nqpkBX5BqB24mfzH+Rga+VCB+qgnhYUWk=; b=EN4eMrfRCQ2BTajrHemVrZRGdfNv+VjF0Hxxcl6iPzUIc4bkpVZwbpHp6Y8qjqbOly NQiQcxT3IZhkG8k/a9SX63SzMRhr6smIcOvnSUCBWIYLh5jNRcmyHxwhZdGgJqJWyNtZ yrajiBGrLqcdHIip5S59MA6DWpMQ2o4gnwtCo= 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=h2Sxsn5oS4nqpkBX5BqB24mfzH+Rga+VCB+qgnhYUWk=; b=ioJ18r3eAd9XJR4eS6e/+5CpNbGJRsA3XoIqJrVZZgsSRAaETMnhhCTUYzVNOkh0mY a2zebyqhP+TmHmnhZnmGpMk+xL2uD+I669TZN7mZ5V+30lXP9MYmQBqJZcKhFTD3Rubn hh4LP5EEO/ZzUql5+MtzfXHsYTOW/vBwZ7/UURR6K/GrY/8ghRTseivHrQQOyAMKre13 p5dFygx1CcpUZbgavcW35s8ET20SYkAV9hvth89MBfb/laxOH91SVbrWikUHPzsDsuSj k87m7/M3yNTgXqTk+xHPeNC9LKBQFSeljSiHvR9I3t79wwJ2r0X17V2wyJ/tz7EMGoNB ErFg== X-Gm-Message-State: AGi0PubXtqAi3Y/kZN1k6chEgn4AolGDROwu6O82r69bijn7GmQr9LhZ 7Lr1jk/7kMMstt2wPuzMm0KcB9iApuI= X-Google-Smtp-Source: APiQypKGi9ceWlZ+060R3v8wbWntZ5zjWtCW2Jo9HP8MmsC+JYsKAPyLNd7CZw+16hWWBmg4h697Ag== X-Received: by 2002:a17:906:c44b:: with SMTP id ck11mr22891953ejb.110.1587494494559; Tue, 21 Apr 2020 11:41:34 -0700 (PDT) Received: from mail-ed1-f42.google.com (mail-ed1-f42.google.com. [209.85.208.42]) by smtp.gmail.com with ESMTPSA id s7sm117070edg.73.2020.04.21.11.41.34 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 21 Apr 2020 11:41:34 -0700 (PDT) Received: by mail-ed1-f42.google.com with SMTP id a8so5999731edv.2 for ; Tue, 21 Apr 2020 11:41:34 -0700 (PDT) X-Received: by 2002:a2e:8512:: with SMTP id j18mr9624239lji.201.1587494060836; Tue, 21 Apr 2020 11:34:20 -0700 (PDT) MIME-Version: 1.0 References: <36e43241c7f043a24b5069e78c6a7edd11043be5.1585898438.git.christophe.leroy@c-s.fr> <42da416106d5c1cf92bda1e058434fe240b35f44.1585898438.git.christophe.leroy@c-s.fr> <20200403205205.GK23230@ZenIV.linux.org.uk> <20200421024919.GA23230@ZenIV.linux.org.uk> In-Reply-To: <20200421024919.GA23230@ZenIV.linux.org.uk> From: Linus Torvalds Date: Tue, 21 Apr 2020 11:34:04 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 5/5] uaccess: Rename user_access_begin/end() to user_full_access_begin/end() To: Al Viro Content-Type: text/plain; charset="UTF-8" X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arch , Kees Cook , Dave Airlie , intel-gfx@lists.freedesktop.org, Peter Anvin , Linux Kernel Mailing List , Russell King , Linux-MM , Paul Mackerras , Daniel Vetter , Andrew Morton , linuxppc-dev Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" On Mon, Apr 20, 2020 at 7:49 PM Al Viro wrote: > > The only source I'd been able to find speaks of >= 60 cycles > (and possibly much more) for non-pipelined coprocessor instructions; > the list of such does contain loads and stores to a bunch of registers. > However, the register in question (p15/c3) has only store mentioned there, > so loads might be cheap; no obvious reasons for those to be slow. > That's a question to arm folks, I'm afraid... rmk? _If_ it turns out to be expensive, is there any reason we couldn't just cache the value in general? That's what x86 tends to do with expensive system registers. One example would be "msr_misc_features_shadow". But maybe that's something to worry about when/if it turns out to actually be a problem? Linus 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.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED 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 4579CC54FC9 for ; Tue, 21 Apr 2020 18:42:28 +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 1E7A92072D for ; Tue, 21 Apr 2020 18:42:28 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="EN4eMrfR" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1E7A92072D Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=intel-gfx-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id AF7FB6E2DE; Tue, 21 Apr 2020 18:42:27 +0000 (UTC) Received: from mail-ed1-x542.google.com (mail-ed1-x542.google.com [IPv6:2a00:1450:4864:20::542]) by gabe.freedesktop.org (Postfix) with ESMTPS id 182276E31E for ; Tue, 21 Apr 2020 18:42:26 +0000 (UTC) Received: by mail-ed1-x542.google.com with SMTP id r16so4335032edw.5 for ; Tue, 21 Apr 2020 11:42:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=h2Sxsn5oS4nqpkBX5BqB24mfzH+Rga+VCB+qgnhYUWk=; b=EN4eMrfRCQ2BTajrHemVrZRGdfNv+VjF0Hxxcl6iPzUIc4bkpVZwbpHp6Y8qjqbOly NQiQcxT3IZhkG8k/a9SX63SzMRhr6smIcOvnSUCBWIYLh5jNRcmyHxwhZdGgJqJWyNtZ yrajiBGrLqcdHIip5S59MA6DWpMQ2o4gnwtCo= 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=h2Sxsn5oS4nqpkBX5BqB24mfzH+Rga+VCB+qgnhYUWk=; b=BevKwUg9+32Ya6pUfw+figfq7Cgt5LVBFhbwIOve8DNyXfNiXU4NokZzdOEGH7u5gP pjG07AkJfg3hAVvG8T08oBrt6oijHe/vh0mJQSO4sLdXx+NDcz20Jh4Ehy767SQpND/L +LTDfAAK/Kx+1HG2VLSgoeT0bjSeOfOPBddUdTBlDXrRzFQtJrvhuzWKEH6Z6S6HDFXW dVfgwEdhpWW2KyMroKS45yXBp2QxaVuUnwnzvvqa3ZBAVIDaLGMQQhw96q3mA15MP7/A dXftA/9yWJqCg8iwkHDt30gIc+qEShdfXTCPqrizmP9HXfgpjH+spS87sp96OY7L+WM4 MmYg== X-Gm-Message-State: AGi0PuagPJz9UQwNbB8tVOrKWrN29pxuFpQHzUJYoghn9zU5KYYLhKqR ogPHS11x/uGopFBBXGBOH/0PLJv5PFs= X-Google-Smtp-Source: APiQypIMEoFYWWPVTADgmVp6sf5Yn4DpQTzynM0bMCTKs7DsGk8Qo+VoF+OTeeT5SRG69bUdw0NHXw== X-Received: by 2002:aa7:c453:: with SMTP id n19mr20048365edr.218.1587494544268; Tue, 21 Apr 2020 11:42:24 -0700 (PDT) Received: from mail-wr1-f52.google.com (mail-wr1-f52.google.com. [209.85.221.52]) by smtp.gmail.com with ESMTPSA id f21sm549328ejw.55.2020.04.21.11.42.23 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 21 Apr 2020 11:42:24 -0700 (PDT) Received: by mail-wr1-f52.google.com with SMTP id d17so17707719wrg.11 for ; Tue, 21 Apr 2020 11:42:23 -0700 (PDT) X-Received: by 2002:a2e:8512:: with SMTP id j18mr9624239lji.201.1587494060836; Tue, 21 Apr 2020 11:34:20 -0700 (PDT) MIME-Version: 1.0 References: <36e43241c7f043a24b5069e78c6a7edd11043be5.1585898438.git.christophe.leroy@c-s.fr> <42da416106d5c1cf92bda1e058434fe240b35f44.1585898438.git.christophe.leroy@c-s.fr> <20200403205205.GK23230@ZenIV.linux.org.uk> <20200421024919.GA23230@ZenIV.linux.org.uk> In-Reply-To: <20200421024919.GA23230@ZenIV.linux.org.uk> From: Linus Torvalds Date: Tue, 21 Apr 2020 11:34:04 -0700 X-Gmail-Original-Message-ID: Message-ID: To: Al Viro Subject: Re: [Intel-gfx] [PATCH v2 5/5] uaccess: Rename user_access_begin/end() to user_full_access_begin/end() X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Christophe Leroy , linux-arch , Kees Cook , Dave Airlie , Benjamin Herrenschmidt , intel-gfx@lists.freedesktop.org, Peter Anvin , Linux Kernel Mailing List , Russell King , Linux-MM , Paul Mackerras , Michael Ellerman , Andrew Morton , linuxppc-dev Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" On Mon, Apr 20, 2020 at 7:49 PM Al Viro wrote: > > The only source I'd been able to find speaks of >= 60 cycles > (and possibly much more) for non-pipelined coprocessor instructions; > the list of such does contain loads and stores to a bunch of registers. > However, the register in question (p15/c3) has only store mentioned there, > so loads might be cheap; no obvious reasons for those to be slow. > That's a question to arm folks, I'm afraid... rmk? _If_ it turns out to be expensive, is there any reason we couldn't just cache the value in general? That's what x86 tends to do with expensive system registers. One example would be "msr_misc_features_shadow". But maybe that's something to worry about when/if it turns out to actually be a problem? Linus _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx