From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pj1-x1034.google.com (mail-pj1-x1034.google.com [IPv6:2607:f8b0:4864:20::1034]) by sourceware.org (Postfix) with ESMTPS id 5756B3858D1E for ; Wed, 15 Feb 2023 06:42:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 5756B3858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pj1-x1034.google.com with SMTP id gd1so6526597pjb.1 for ; Tue, 14 Feb 2023 22:42:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=2INQdQ2JmmlmqDMzzp3Z3aUre967wOa3+hcw74t7alU=; b=EZZcMxJm/yZgXb49fv2IQJwIUX5d8kiVZaT5QBsk3f/PXQZ0+u8lOITM3KA3KMuZqy J01N0Ua1r7uui0pmYSWwcoHHrJ0l+LR6i3GkxNFZmJ5YoBhKYjgDyGD8u9kqOvertENB OK2VIpSEmbXm9zZ+jY5setLBGSC7+CDE1EiY9ttL9UPd0vqMEaFWrxTnlx9gA/m3C8q7 +d026MkGjHCMfwKByJDaGmQ7lIfntwl3bW7vr+dupXUj2eacJhsoQSWIM+3YY3KMlrnI d9pnt4DOB/bPaRNTQUXzrC7aKFiEPCpfE3MXMPJJztwv7I+GPht1vAdtgv+6o3D7ac5+ 4WIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=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=2INQdQ2JmmlmqDMzzp3Z3aUre967wOa3+hcw74t7alU=; b=yM7Pn6pVyxGEPIzKUgl80D2vPA7tS/NvDz1ZcoREzqfDcXkJOL1sYhZHNrWCeNuKb7 qdtkr/JO5WZIZ7RTwv3KA8bynx4Tlf2NQ2YDJU+9LneN4EXxq+9KNlwF3kqCQZ+LGnKq osWo9y73dYTZMB5nfZ+fDnQpLODuqwjYe5PaTtcUekyzF5pAmAr5w+MS4h9p7Aar4PLL rR4IZgAeWtkplsBbyxRxePpVfjc+ahpXgnqHZiX2+dIvdaV8l/OE1V+ywrKwG+uWIiTX nWcuh6H5IMOI+lYPmvnDd2M4cMZ84jRl2tQGC2/yiJoKBOPekO7wC4s8Dkzfrdu/x7z9 YsuQ== X-Gm-Message-State: AO0yUKWcipZr2AOuNEBKkNTXUlcXQwfgMb6bFSz+/G0XQRYRqjtLopcr aN6C6qC158vXSsfE8cZ096c26Cou8NXHCw3O+5E= X-Google-Smtp-Source: AK7set9w2V0JIh7xa8iS796Nbyo0gvu+JDJE/T8hsOeQVP6XqGk6D0uywJ6osbmG/05y0ycnJg68I1pvkgEeC6m5G4Q= X-Received: by 2002:a17:90a:6841:b0:233:d42f:a464 with SMTP id e1-20020a17090a684100b00233d42fa464mr286709pjm.137.1676443366235; Tue, 14 Feb 2023 22:42:46 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Sergey Bugaev Date: Wed, 15 Feb 2023 09:42:36 +0300 Message-ID: Subject: Re: [PATCH glibc] Define PC, SP and SYSRETURN for hurd x86_64 To: Flavio Cruz Cc: bug-hurd@gnu.org, libc-alpha@sourceware.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,KAM_NUMSUBJECT,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=no 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 Wed, Feb 15, 2023 at 9:17 AM Flavio Cruz wrote: > > Moved thread_state.h to x86 directory since we only need to customize > those 3 definitions. No, that won't be enough. We also need to customize those MACHINE_THREAD_STATE_FLAVOR definitions to include the potential new i386_FSGS_BASE_STATE that we were discussing recently [0]. [0] https://sourceware.org/pipermail/libc-alpha/2023-February/145528.html I was just looking at this file yesterday and concluded the MACHINE_THREAD_STATE_FLAVOR / MACHINE_NEW_THREAD_STATE_FLAVOR abstraction cannot work as is for x86_64, because half of the time it's used for indeed accessing registers like SP and PC, and other times it's used to access TLS/TCB. So this needs to be two distinct definitions, and all the users inside glibc have to be reworked. So let's please not rush with moving this to x86/ Sergey