From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andy Wingo Subject: bug#27476: libguile/memoize.c is not thread safe, so syntax parameter expansion is not thread-safe Date: Wed, 09 May 2018 12:18:01 +0200 Message-ID: <87lgct5e06.fsf@igalia.com> References: <87h8vvp1q7.fsf@elephly.net> <87377esu1a.fsf@gnu.org> <87k20nz18u.fsf@igalia.com> <87a81jj5gg.fsf@gnu.org> <87bmlyzxj7.fsf@elephly.net> <87shf44ny0.fsf@elephly.net> <878tfi9x15.fsf@gnu.org> <87h8nstms1.fsf@gnu.org> <874ljstlvq.fsf_-_@gnu.org> <87603x6x1f.fsf@igalia.com> <878t8tyyfk.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44805) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fGMBg-0000Iu-6T for bug-guix@gnu.org; Wed, 09 May 2018 06:19:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fGMBb-0007Tj-6K for bug-guix@gnu.org; Wed, 09 May 2018 06:19:08 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:46935) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fGMBb-0007Tf-2Z for bug-guix@gnu.org; Wed, 09 May 2018 06:19:03 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <878t8tyyfk.fsf@gnu.org> ("Ludovic =?UTF-8?Q?Court=C3=A8s?="'s message of "Wed, 09 May 2018 11:23:59 +0200") List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 27476@debbugs.gnu.org On Wed 09 May 2018 11:23, ludo@gnu.org (Ludovic Court=C3=A8s) writes: >> Is the memoization you are referring to the "set!" in the "lazy" form in >> ice-9/eval.scm ? Or something else? FWIW I would not think the "set!" >> could be the issue, at least on x86, but who knows. > > Actually I=E2=80=99m not sure exactly. =E2=80=98memoize-expression=E2=80= =99 itself is > side-effect-free, right? As far as I know (and I had a look this morning), yes. It takes a Tree-IL input and returns a memoized output. The internal mutation that exists in the evaluator is just the lazy "compilation" (see the invocations of the "lazy" form). Of course the function being evaluated could mutate shared state as well! Andy