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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 15B6EECAAA1 for ; Fri, 9 Sep 2022 15:07:11 +0000 (UTC) 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=tBsSbEClpd0JJs6Ti1CYGl1i0Zk6ip87cajAu0A/wvg=; b=xzDmw/z8oLkSra 8zqDX+nS0F33lH+Oe3C2xMEoMG9joGcCAGMRNNnqtUhX1PoUMMmzsv4S03zQkJsDX4FeEzFua4cyL Bn/zKCe17IqaJeg+TRTk/ynCyiaOjDJjnkSwPy9kgXvM8j/DgvDSqgKNB2vGdXd2WJLIjsQJWctJe gM2I8el6vjzM9vLQzpmF3iehMWnfW2otqjWY9bKPsk3lMktuHhmfsZcT3IXAhnGmhzH58QR/l85QK AeueXn8tnYYWvlR27mhOn30Cp3aleZuvjsJtBeIshmRiBZXwBXA2uWrQlbVqb5GOj+hoX1YybEXme +enz7L2mLlO829BRqwSA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oWfa4-00H3xi-1U; Fri, 09 Sep 2022 15:06:08 +0000 Received: from ams.source.kernel.org ([145.40.68.75]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oWfZz-00H3gu-LM for linux-arm-kernel@lists.infradead.org; Fri, 09 Sep 2022 15:06:05 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id B2C1FB82550; Fri, 9 Sep 2022 15:06:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 76679C433D6; Fri, 9 Sep 2022 15:05:57 +0000 (UTC) Date: Fri, 9 Sep 2022 16:05:53 +0100 From: Catalin Marinas To: George Pee Cc: Robin Murphy , Russell King , "Russell King (Oracle)" , "Kirill A. Shutemov" , Austin Kim , Ard Biesheuvel , Mike Rapoport , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] Report support for optional ARMv8.2 half-precision floating point extension Message-ID: References: <20220901141307.2361752-1-georgepee@gmail.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220909_080603_858658_C82E3A56 X-CRM114-Status: GOOD ( 25.72 ) 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 Fri, Sep 09, 2022 at 09:57:39AM -0500, George Pee wrote: > On Fri, Sep 9, 2022 at 9:07 AM Catalin Marinas wrote: > > On Fri, Sep 09, 2022 at 08:34:26AM -0500, George Pee wrote: > > > Adding the hwcap was part of the diagnosis process-- I added it just > > > to make sure that the cpu in question supported the optional > > > extension. > > > It seems like it could be useful to be able to check for support in > > > /proc/cpuinfo. > > > > Ah, I wasn't aware that the feature doesn't work on arm32. I don't think > > it makes sense to expose a hwcap bit to user in this case. > > The details are here. I originally thought it was a compiler bug > because it first showed up after a toolchain update. > > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106763 > > Since FP16 is an optional extension, wouldn't it be beneficial to a > user who compiled some userspace float16 code using gcc > -mcpu=cortex-a55 which ran on a cortex-a55 with FP16 extensions but > SIGILL'd on a cortex-a55 w/o FP16? (please don't top-post) My point is that if the kernel doesn't have full support for FP16, it shouldn't advertise it to user even if the hardware supports it. If you fix the kernel to properly handle FP16 on supporting hardware, then the HWCAP part is fine by me. -- Catalin _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel