From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?Q?Gerd_M=C3=B6llmann?= Newsgroups: gmane.emacs.devel Subject: Re: Some experience with the igc branch Date: Thu, 26 Dec 2024 06:27:36 +0100 Message-ID: References: <87o713wwsi.fsf@telefonica.net> <86o7112rnq.fsf@gnu.org> <867c7p2nz4.fsf@gnu.org> <861pxx2lh7.fsf@gnu.org> <86ldw40xbo.fsf@gnu.org> <87cyhf8xw5.fsf@protonmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12419"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Eli Zaretskii , ofv@wanadoo.es, emacs-devel@gnu.org, eller.helmut@gmail.com, acorallo@gnu.org To: Pip Cet Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Dec 26 06:28:00 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1tQgPg-00031U-2i for ged-emacs-devel@m.gmane-mx.org; Thu, 26 Dec 2024 06:28:00 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tQgPQ-0000yM-5S; Thu, 26 Dec 2024 00:27:44 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tQgPP-0000yD-1B for emacs-devel@gnu.org; Thu, 26 Dec 2024 00:27:43 -0500 Original-Received: from mail-ed1-x52a.google.com ([2a00:1450:4864:20::52a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tQgPN-00081C-GL; Thu, 26 Dec 2024 00:27:42 -0500 Original-Received: by mail-ed1-x52a.google.com with SMTP id 4fb4d7f45d1cf-5d34030ebb2so4071282a12.1; Wed, 25 Dec 2024 21:27:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1735190859; x=1735795659; darn=gnu.org; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=vhJsI+oXiu+EqLM25U0wmZrl8bvD6tBR9pSnd5Agnac=; b=DX+gdbl3AnMY/TwjgCJS8WfC3v3mFWyt+Oble44MeiSx2Gry5Dg6p30MgObW9BnlNd eLK7DgLR9C9UD9/2wrFvZbw3bgxYw19TqqGRKhmeo5KkFrL0RYAIC8nUVpQmA2YOdBNX VaMZJaEY99TtGJZPE1fF+2CPlpnVSFt0lALBlghzrh94bglR8rLQnfltp3qqz/ae1Dj9 AOWcoltxP+RVOqPm3AdDKxaH9iXuJbUelkhKqlPF9Bpfur7ZmNo7T863J71k8pm7is6m f+mv/vqvFvP84b6EvcF+gBBnlwkpEkMkmfEankqxY9GD9d+Tn2pnErfde2C5iiFMUVCW mmdA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1735190859; x=1735795659; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=vhJsI+oXiu+EqLM25U0wmZrl8bvD6tBR9pSnd5Agnac=; b=wsO7G7jbLnb4JFTVQbh7ZM0ij6cernsC40eT2mBwnn09fef6DNQFits8lmFb+8G+0q 7TV/OsBG3CM3gxIA3qCp6k0+GS47tfTFoPGsgrL+8/br7OCEU5NMZ5BKHAVPkg8a9IK/ OfotqBvtUAGV5W1f04XujOifY+sLJEY1S8WTitswLwEdcUyfmoJh4ADLBB+fKFSDneua y8xZCxOi0FOdk5BYOrgkw8zc2vMkNoFvNRpdGVOc0mhOocJ0ZxLgjV/QBf2G5HFLfvmh YoMAazjhC6TaguCxD44351BLGPskT34iWlV5MLcnKbTd1Auc4TvOS0e1XZPZI3DQgYWu AO0g== X-Forwarded-Encrypted: i=1; AJvYcCX7d79KaOgV8DqkGMZm8H1D5t+DDl2d/heIwrA2tsG2YXYGXceCv4r2v95/OfL+4ebNb7jAL1XyhLHJ3Qo=@gnu.org, AJvYcCXs3G14M7Ze/9hnndMaH2h8wqoq8bnKpm2B0bQxItGtW11q6ZPKQ+r20Y076LLfEgfRbnwtSY61fw==@gnu.org X-Gm-Message-State: AOJu0Ywm+juCRGlAbXbatAkg9hYM0nPRfz55ZE8kNe8U33psHi13Ra1J 5FueF6lSWML5ll8QHElVKR6AiAfxnVT0grFxDvqUOSYnQvfdAIf+lju1GQ== X-Gm-Gg: ASbGncuOANBOwKZhZNgyLQfcpKdMR30UYrV56uv3IZJYL8iUp4/TruUZSO7wQupF9A0 m3PZAOQeKfR4UMuh5cwlcKoL1UR/CoRsTBzKd+SaJ8Lj3g+cNgIGp1L68SnaM7YQ6zWc1xtK3r0 3JUGbXxsdkEytTa+8OA6vdQ3SucE2tTKbxtUr5wG7W+OdM4tILp79e2oq0kuUtCFrCVlPsehRhB 6sbpemb9BYMnZK4YNeFvVUew1nFZuyCLUPGSKXZG42YxgT4SCHlsZSNP7TKhnfNo6R2P8dej5Qx sGW661Lk0N1hbFWFwzVzz9S1zP3lN7PWfYMZeGLTFbc24+iFDZcZoecxOEPciBD/gw== X-Google-Smtp-Source: AGHT+IGznphdvut4cD9v0hxSPa6U774rbwdOAbi4QV9hyF6clg0+mxAJWWREWyUBR9qwOBfcVbVF0A== X-Received: by 2002:a05:6402:13c8:b0:5d4:3761:d184 with SMTP id 4fb4d7f45d1cf-5d81dd7f3b0mr20864089a12.10.1735190858825; Wed, 25 Dec 2024 21:27:38 -0800 (PST) Original-Received: from pro2 (p200300e0b747910049c6927f9e8bb023.dip0.t-ipconnect.de. [2003:e0:b747:9100:49c6:927f:9e8b:b023]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5d80676f26dsm8888347a12.20.2024.12.25.21.27.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Dec 2024 21:27:37 -0800 (PST) In-Reply-To: <87cyhf8xw5.fsf@protonmail.com> (Pip Cet's message of "Wed, 25 Dec 2024 17:40:42 +0000") Received-SPF: pass client-ip=2a00:1450:4864:20::52a; envelope-from=gerd.moellmann@gmail.com; helo=mail-ed1-x52a.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:327132 Archived-At: Pip Cet writes: > Gerd M=C3=B6llmann writes: >> DEFUN ("function-equal", Ffunction_equal, Sfunction_equal, 2, 2, 0, >> doc: /* Return non-nil if F1 and F2 come from the same source. >> Used to determine if different closures are just different instances of >> the same lambda expression, or are really unrelated function. */) >> (Lisp_Object f1, Lisp_Object f2) >> { >> bool res; >> if (EQ (f1, f2)) > > This EQ can also trip. Sorry to insist on that, but I think it's an > important point: if we change Lisp internals (such as the slow EQ > thing), the "we're not dereferencing it, just looking at the bit > representation of the pointer" approach will fail again, in unexpected > places. > > I haven't seen a technical argument against using separate stacks for > MPS and signals (I don't consider "it's a change and we'd need to test > it" to be any more true for this change than for any other proposed > change, or for what's in scratch/igc now). It would get us on par with > master. (Both versions need to add the best memory barrier we have to > the specpdl_ptr++ code) > > (I don't think MPS works on multi-threaded systems if word stores aren't > atomic. If thread A is in the middle of updating an mps_word > referencing another object, and thread B triggers a GC, thread A is > stopped and thread B might scan the segment in the inconsistent state.) > > Miraculously, everything can be made to work out in the WIDE_EMACS_INT > case, even though 64-bit words are stored in two insns: we only look at > the LSB 32-bit word when fixing (because we USE_LSB_TAG), so that'll > just work. Late exthdr creation needed to be changed a little, and now > assumes changing a 64-bit value to another 64-bit value which differs > only in one 32-bit half is atomic. > > Here's a snapshot of the current code. It still assumes strong memory > ordering between threads because I'm pretty sure MPS needs that, too, so > it's just asm volatile ("" ::: "memory") for now. Thanks.=20