Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1366428pxj; Fri, 21 May 2021 12:23:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy5S1NTxt7qneQKUWYfnxu/Mzko1LIPc5irugO+ndQr4sI5zndQokjn9tttxGmv1gS36WO2 X-Received: by 2002:a05:6402:1a:: with SMTP id d26mr12860196edu.99.1621624988099; Fri, 21 May 2021 12:23:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621624988; cv=none; d=google.com; s=arc-20160816; b=aaHj4vfsWfgGA2Xp4fC8lGmUAo8I4JuV1z+xH4UCvStibzxL8o0vEvkazw+UWssq3Z rWRc7hMU/TyUuFWRulN3n7AO9Z7PgudHVUyJOojOA27+mx9DtyXAjLoGbxYWkVDirbZx jotnyquuUUnvPay7bXlCosKtNzli4ML5pVTPxl6ysShEScU0ARtAy6ALYlYTlp75a+b5 FpMq7nN+WuvhrZOkDl61P88w369ZBJ1K6VRJuuOiFoxrHZXGmxjs87Uw+FIHCPI0XkTS fcRjt3j0NJPo+g6k7KdZIIgCcmR23jOZcG09YgYIn2+GLcJtfqJxC/sksDNnCax9/hSv 69nQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version; bh=HqMs01SwhIzac61wHIqbpImRVDJ7bAhjZqygW+SGW5k=; b=qq1k8OUw6k5Q/0vhv6YeS3ODZkD2i+/kx8OhW2sLpzfpOXSWg/EzxhaahukV50klcG mgIUOLzgM6zjeeMXaOxl9sLTIxt46Bd8ZLsJUEXxngZ51gek3D4fJCe1WcxCG9lUUA7h jo/UqByJ4i5hpjoR9MdvkI5wGLsqkJ2i4rOHj8WXunh1GHy3xNh7m8bfTzqzUXfcvlK5 Qn/8M1JS0L3tcVxHb3Ygh1KOEpUkLQ1v4Yoma4IoY1mW0IpzhyZSzr6SHkcpWYNhu4Ay 7GklKwpe52VFU19tuvoMl1cR5ZgVlOLH9mqo1M8ku+iV1PL6KJgd1gIdSce5Vh5Q+nCR rBoQ== ARC-Authentication-Results: i=1; mx.google.com; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id hh4si6125721ejb.79.2021.05.21.12.22.44; Fri, 21 May 2021 12:23:08 -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; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235758AbhETTRz (ORCPT + 99 others); Thu, 20 May 2021 15:17:55 -0400 Received: from mail-ed1-f45.google.com ([209.85.208.45]:46886 "EHLO mail-ed1-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237612AbhETTRv (ORCPT ); Thu, 20 May 2021 15:17:51 -0400 Received: by mail-ed1-f45.google.com with SMTP id r11so20619335edt.13; Thu, 20 May 2021 12:16:29 -0700 (PDT) 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=HqMs01SwhIzac61wHIqbpImRVDJ7bAhjZqygW+SGW5k=; b=lhRSKBUssk+/Zt+EfKfXtRgVQPw6l6JekPVo6nFAKKxaykCQJpEtRsevixmB0D9390 Ev2sW6y7l00FEA3pgo25ycb3IkvrRgQZT4btpu2ZjqywRZmGlpInW2Hj4tRGky0j91mr sG/5kwa4RZc6oHOI/376xxs7IzCBiZL53uZD/C6owP0dzDVXNh+HVgJF6Q4FZL1es014 cTy34J4aMd2yrnezlpD/cgJSNY2pr91UaQLEUI0LvFjLCUAFkJoBmIWeO24FTTBHwqLT TTGFo4P8G6QwLRlIzx2xjmhss/IrhpldyBVwP7EoyKWwRK/3XCPm28PCZ2+uGvqKorAp 2X2g== X-Gm-Message-State: AOAM532gaUH8jze/uhkrVyCrZm3CsjrdLYcsjlPXaAeqw67BE5gHXoXI hhY23r6WfWxdhSPdIRTYRmCC26U6tcLOOSo0pYU= X-Received: by 2002:a05:6402:2789:: with SMTP id b9mr6665889ede.122.1621538188915; Thu, 20 May 2021 12:16:28 -0700 (PDT) MIME-Version: 1.0 References: <20210415044258.GA6318@zn.tnic> <20210415052938.GA2325@1wt.eu> <20210415054713.GB6318@zn.tnic> <20210419141454.GE9093@zn.tnic> <20210419191539.GH9093@zn.tnic> <20210419215809.GJ9093@zn.tnic> <8735uxmucw.ffs@nanos.tec.linutronix.de> In-Reply-To: From: Len Brown Date: Thu, 20 May 2021 15:16:17 -0400 Message-ID: Subject: Re: Candidate Linux ABI for Intel AMX and hypothetical new related features To: Andy Lutomirski Cc: Thomas Gleixner , Borislav Petkov , Willy Tarreau , Florian Weimer , "Bae, Chang Seok" , Dave Hansen , X86 ML , LKML , linux-abi@vger.kernel.org, "libc-alpha@sourceware.org" , Rich Felker , Kyle Huey , Keno Fischer Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 19, 2021 at 7:29 PM Andy Lutomirski wrote: > > It is established that there exists application code that counts on > > this opaque state being complete so that it can do a user-space > > XRESTORE instead of a sigreturn(2). > > Is this established? > > Note that the specific case of a user program doing XRSTOR will work > just fine if we omit the allocation of non-in-use states from the > buffer, at least by my reading of the pseudocode. Yes, your understanding is correct -- XRESTOR works as one would expect. > The case that would > break is if user code then assumes that it can XSAVE back to the same > buffer. The other case that would break is if the concept of what features were supported (eg. XCR0) changed between when the context was saved and when it was subsequently restored. Yes, if a feature appeared, you'd get INIT; but if a feature went away, you would fault. I've been told that user-space software exists that does this. If I can find specific examples, I'll share that. thanks, Len Brown, Intel Open Source Technology Center