From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-yw1-x1135.google.com (mail-yw1-x1135.google.com [IPv6:2607:f8b0:4864:20::1135]) by sourceware.org (Postfix) with ESMTPS id 02C443858C36 for ; Thu, 11 Jan 2024 03:28:57 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 02C443858C36 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 02C443858C36 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::1135 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1704943738; cv=none; b=pPwfGTl0fhq/+j6o5j1909MLHB9NVLdJEm26Gi23YqCetzV3MMgkWMPVmJLJYuYu4Fe2gJ+K+b2pPgooybLPUXgTlOA+RB2QIH1EwgUXh/lxZI5+05C1NmownV86G6+xHyu6M1j++G3e1ZsreC6OyGCzojWgzsPTDogV76FKhKY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1704943738; c=relaxed/simple; bh=HM8cofVE0DORX+nro6uayGmSVE2XvRtZfczvVIUudSU=; h=DKIM-Signature:MIME-Version:From:Date:Message-ID:Subject:To; b=pkaSAD+ay+8zm64xKAZ7KMDvlsHx+fDsDRV72Wdz5eiDmkHo52t2jJUKTdMTmxSFm35l7tfH2ilxA/RDXdASGfQKSIjYz5C1AaEObptrJkPO/MMwUsWWzq1aHO6CX9F6ZguSv1LGjLitKEHo+AkjnrbORbY8BQaojkbiOieaBJo= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-yw1-x1135.google.com with SMTP id 00721157ae682-5e54d40cca2so38870247b3.3 for ; Wed, 10 Jan 2024 19:28:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1704943736; x=1705548536; darn=gcc.gnu.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=HM8cofVE0DORX+nro6uayGmSVE2XvRtZfczvVIUudSU=; b=WkK/TEYu2thG7u0j60a3vI5X882DpfbwIUxPwkTciQ1FCbBRMUcpmNhbwe//OL01ba cmdKASoeMvw+seCTJMm5utpfw4RhWwnNwydq5fAbZcbQh+i76/b4pJYBVmR0gmOtRsag IzLhY5mhsInNbrPAMfuOwb2TJORj41wPCcCECjD51HPtHnb2ijSbN9+zpxmOqyQYk0Xg TILpjPH725JgoYQGHnnm2TcPsEMr+F1cR+yP5uHGqwEm2N2Izj3+yKM1IwxrSZUZMWQl HxBxHVNutKYaWYHcjnm8TYnQgQ6Te0CKPlsPDSS0gsnHt6ae5PmblnGLpwJLIZ2bRe6r riMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704943736; x=1705548536; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=HM8cofVE0DORX+nro6uayGmSVE2XvRtZfczvVIUudSU=; b=KDmqAvPco17mbGjfxsByYfwzx4Mq/HzWo/xHbYSNPrtTIoki4TyJhBYoP++5h9tVdn pt7bUpoDqglddEPVoiztucSgxmss24CD+fg8QIWkedNN9jMEDReizOhUbLbG/qJ00lDi qrOFOz+MH4KHHn6B9VqYlvY96tXpu0RGIxhls4PERo5wScktWkPq6qf3tqj87UTW0wfM ID8E/3ld+hE+/vk8hTDqNE7YAk4adHQ0NAVGqhn9DAI8y53H4InFoSgaZLYUWSQNMTC9 Z1Zsde+Wf8Hfgq6Pi4qHNjft1vTcWjHd1LmKfURSyqZlYkM2OIiVnOotucNwsYovLYI0 y0dg== X-Gm-Message-State: AOJu0YxxAGu+rnr8eucbpKzXB2tW+MHogfjzK1vS0Ouz1VpS0x1mBZ9d 57F0T0Qi+12Q++Y3yZ/QSepDa/y2mkinlHms19Y= X-Google-Smtp-Source: AGHT+IEi7PjQTdMmdfMf9lV3hmsglUolgnAhtW7AZsOFzqdbTtLHd+mnhJ3oQh7A79M4+ZDcF5Duyyavg4lkThAe488= X-Received: by 2002:a25:d882:0:b0:dbe:a05a:6c24 with SMTP id p124-20020a25d882000000b00dbea05a6c24mr469543ybg.88.1704943735254; Wed, 10 Jan 2024 19:28:55 -0800 (PST) MIME-Version: 1.0 References: <20240109070702.413866-1-hongyu.wang@intel.com> <87o7dslre6.fsf@linux.intel.com> In-Reply-To: <87o7dslre6.fsf@linux.intel.com> From: Hongtao Liu Date: Thu, 11 Jan 2024 11:28:43 +0800 Message-ID: Subject: Re: [PATCH] i386: [APX] Document inline asm behavior and new switch for APX To: Andi Kleen Cc: Hongyu Wang , gcc-patches@gcc.gnu.org, hongtao.liu@intel.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,KAM_SHORT,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Thu, Jan 11, 2024 at 7:06=E2=80=AFAM Andi Kleen wro= te: > > Hongtao Liu writes: > >> > >> +@opindex mapx-inline-asm-use-gpr32 > >> +@item -mapx-inline-asm-use-gpr32 > >> +When APX_F enabled, EGPR usage was by default disabled to prevent > >> +unexpected EGPR generation in instructions that does not support it. > >> +To invoke EGPR usage in inline asm, use this switch to allow EGPR in > >> +inline asm, while user should ensure the asm actually supports EGPR. > > Please align with > > https://gcc.gnu.org/pipermail/gcc-patches/2024-January/642228.html. > > Ok after changing that. > > BTW I think we would need a way to specify this individually per inline > asm statement too. > > Otherwise a library which wants to use APX inline asm in the header > never can do so until all its users set the option, which will be > awkward to deploy. > > Perhaps it could be a magic clobber string. We do have new constraints string for gpr32 or gpr16 for registers, but not for memory due to restrictiction of GCC RA infrastructure which assumes universal BASE_REG_CLASS/INDEX_REG_CLASS for all inline asm. > > -andi --=20 BR, Hongtao