Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp4198125pxu; Mon, 12 Oct 2020 12:01:32 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz3EpBr1IC4JEbjydWH3Ye/MVMCltFNTirvMiAN4h1bqk2JcwwZTM2jrOd9WkRxsTYvM5VB X-Received: by 2002:a17:906:a0cb:: with SMTP id bh11mr30549084ejb.314.1602529292767; Mon, 12 Oct 2020 12:01:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602529292; cv=none; d=google.com; s=arc-20160816; b=ZHtYt+JIx1YqhNsHnzGk42xRV0Ede5AVDGOcxZsVjhuSuX/9X19AdzWGGnz7zwbwiW U/aON4ujXEkNVPqU3vy4AGCGWWSj2bh3bzX6V55ZS99Y4Rh1y86wXJylmHDjXxSPtaKA egyYLDNbj0NG6G+q7HNCF7q1kgqUg6ldmNs43lbgqZJAfCbsEQekxch4FXgUlY209ln3 sVh0MvWF/WYB5df9MiEcRJKdysbKYRhlc97dM/tw5Kd7zmAa+CyUWpvWt+zmcl0VFUdw G0DI7IbAUs5pGy9Rr+Wl4b4TLJ6y8+AyG3F+JbALm9efrC8jaHMyWJHXxOI+e/aTkYEi 7R9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=z38xt7QuaaNmuknyixMSJVUbIhDopUruZ+mwFLEsK5Y=; b=VJR1WgAZZ8nsUCey75jjGRHgLEwxKFTF47Jq4HVb7ta6PtJsjWDMhGe/GLOO6lPLaO ypeqjQc8As73Vv0mq4wx9nIkWz4mtSLfbG6dbHva+4mKmA/h9a+6NTi+qlrxI0h4NKPa ZGpx7sK0UfKjJFblVA+w2UHr+YpfxGqHACzDWDazRLmjuM+ADgzMMrnsUboCiooefjv5 HiqKoyM2/bAcIK+X5+giCxJRpXYWcWA8BGxGLNnjipW6DHHkcTDdg7mhLEOmcOS8t1ZX O6GKbTJUl1rQNbhI6RLyfhqvB+s7ymHfF3JNBKASGq7BWcY1FmXdTwot53jceobs/Me2 Jn7g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=RPfXh09o; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 89si3690253edy.301.2020.10.12.12.01.06; Mon, 12 Oct 2020 12:01:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=RPfXh09o; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730706AbgJLS7T (ORCPT + 99 others); Mon, 12 Oct 2020 14:59:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52306 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727115AbgJLS7T (ORCPT ); Mon, 12 Oct 2020 14:59:19 -0400 Received: from mail.skyhub.de (mail.skyhub.de [IPv6:2a01:4f8:190:11c2::b:1457]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0ECD4C0613D0; Mon, 12 Oct 2020 11:59:19 -0700 (PDT) Received: from zn.tnic (p200300ec2f06920038fd325cadbd10b1.dip0.t-ipconnect.de [IPv6:2003:ec:2f06:9200:38fd:325c:adbd:10b1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id AAE691EC0315; Mon, 12 Oct 2020 20:59:16 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1602529156; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=z38xt7QuaaNmuknyixMSJVUbIhDopUruZ+mwFLEsK5Y=; b=RPfXh09oY+Jl5wqACEKFIeADB51jj53jw5Ohrmoc2Xa/L8ykDb4tR4wmyXyV5dRbXxJE9C iWpN8OBmfzcSrueHd64TjwqbkCCY7X+8ogVxv6LvrDnz0doVAJZ5CbPwATpeGGTcz9y/1i QgmKgjN1DQY+Mp1askLWjw01TjC9LQE= Date: Mon, 12 Oct 2020 20:59:13 +0200 From: Borislav Petkov To: Linus Torvalds Cc: Uros Bizjak , x86-ml , lkml , linux-toolchains@vger.kernel.org Subject: Re: [GIT PULL] x86/asm updates for v5.10 Message-ID: <20201012185913.GL22829@zn.tnic> References: <20201012110557.GK25311@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org + linux-toolchains@vger.kernel.org for clang folks... On Mon, Oct 12, 2020 at 11:56:45AM -0700, Linus Torvalds wrote: > On Mon, Oct 12, 2020 at 11:41 AM Uros Bizjak wrote: > > > > GCC does not distinguish between %ah and %al and it is not possible to pass "%ah" to the assembly. To access the high part of the %ax register, %h modifier has to be used in the assembly template. > > Do you know whether that's true for clang too, for example? > > Also note that even if the _asm_ might get "%al", maybe the compiler > decided to use "%ah" for something else? > > I have memories of gcc using the high registers at some point, but it > might have been some special case code - and it might also be very > historical. > > [ Goes off and checks ] > > In fact, I can still find gcc generating high register code, although > it's quite possible that yes, it's only peephole bit extract > instruction kind of use.. > > I also find that clang generates code that uses the high byte > registers, although again, that's not from any knowledge of clang > internals, and just by looking at my kernel image disassembly. > > So yes, it _may_ all be just peepholes, but it's not obvious that this > is all safe. > > Linus -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette