GNU bug report logs - #75322
SAFE_ALLOCA assumed to root Lisp_Objects/SSDATA(string)

Previous Next

Package: emacs;

Reported by: Pip Cet <pipcet <at> protonmail.com>

Date: Fri, 3 Jan 2025 17:21:02 UTC

Severity: normal

Full log


View this message in rfc822 format

From: Gerd Möllmann <gerd.moellmann <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: pipcet <at> protonmail.com, 75322 <at> debbugs.gnu.org
Subject: bug#75322: SAFE_ALLOCA assumed to root Lisp_Objects/SSDATA(string)
Date: Mon, 06 Jan 2025 04:57:37 +0100
Eli Zaretskii <eliz <at> gnu.org> writes:

>> From: Gerd Möllmann <gerd.moellmann <at> gmail.com>
>> Cc: pipcet <at> protonmail.com,  75322 <at> debbugs.gnu.org
>> Date: Sun, 05 Jan 2025 21:04:56 +0100
>> 
>> Eli Zaretskii <eliz <at> gnu.org> writes:
>> 
>> > How can we possibly make sure this works reliably and safely??  For
>> > each variable we have in every function, we will need to analyze
>> > whether the variable is
>> >
>> >   . an automatic variable
>> >   . a static variable that is protected by someone
>> >   . a global variable that is protected by someone
>> >   . a result of dereferencing a pointer that is somehow protected
>> >
>> > etc. etc., where "protected by someone" means that it is a descendant
>> > of some staticpro, or of some root, or...
>> >
>> > And if we cannot prove to ourselves that one of the above happens,
>> > then we'd need to force a copy of the variable to be on the stack?
>> >
>> > Does this sound practical?
>> >
>> > If this is the price of using MPS, and I'm not missing something
>> > obvious, then it sounds like we should run away from MPS, fast.
>> > Because we will sooner or later have to rewrite every single line of
>> > code we ever wrote.
>> 
>> I'm bowing out again. It's not worth it.
>
> I don't understand why?  I need to understand the implications to be
> able to make decisions, which are part of my job.  So I ask questions,
> and I'm grateful for your answers, which clarify the issues for me.
> That I sometimes sound overwhelmed by the implications shouldn't be
> held against me, it's just a normal human reaction, nothing more.

I don't hold that against you, that's why I'm trying to answer
questions, write stuff up, and so on, but for me your reply before this
one was a leaf node in the thread.

From my POV: So we're talking about things, you want to make it
concrete, we land in call_process, I explain why SAFE_NALLOCA is unsafe
when used with references even with the old GC, you think references are
on the stack because the parameter args is on stack, and I say no.

Next thing I get is a rant. You don't even say "you're right" or "you're
wrong", so I don't know for sure if you accept my argumentation or not.
Instead, you write something that came across here as "unreasonable,
can't be true, we have to change every line of code, let's run from
MPS".

What should I reply to that? Nothing of course.

> If I somehow sound impolite, I apologize.

No worries about politeness. It wasn't impolite, and I'm not very
sensible anyway.





This bug report was last modified 147 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.