GNU bug report logs - #78394
31.0.50; Questions about native-comp-speed and type decl

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: "Yue Yi" <include_yy@HIDDEN>; dated Mon, 12 May 2025 15:56:01 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 78394 <at> debbugs.gnu.org:


Received: (at 78394) by debbugs.gnu.org; 1 Jul 2025 11:18:42 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jul 01 07:18:42 2025
Received: from localhost ([127.0.0.1]:55324 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uWZ0b-0001I5-Dr
	for submit <at> debbugs.gnu.org; Tue, 01 Jul 2025 07:18:42 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:60326)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1uWZ0X-0001Gu-O3
 for 78394 <at> debbugs.gnu.org; Tue, 01 Jul 2025 07:18:38 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1uWZ0R-0003DL-V2; Tue, 01 Jul 2025 07:18:31 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=jnhBjo0FIdQkaDYGlRCTS9v+zGGv38Aq/Y+nvlb9kxk=; b=ORDQzYFZZ+Um+zwrd7uV
 SjxfQBoU52MGVFayFb82fuszaoSMVCAVMhwcSnRrxCu9y4jrGiS/zkQt8JfUEDJD8d+9q0T/KqoEa
 N9OhYzEtxQtny2Swuf08bwHOTgLcooVvk2bEUUi1eNgRoOfuY59NzS+IzYoWinqJOZf+y4UWoTqc5
 w4h0ej5zUIDVKIDfVDeRkDhVLTyVkSGj3M/DYFWe8IwnktSpynxMIpN4DmMFa8Do6ikiLPvgcP9Oi
 EmnZCs+mJpHAXoInyhZhgCqldbXjU29deOAO6mTQ4taNpS+/Pq0ADPBxNLuynAPc+oSR4H5Hf6Tra
 1hEsaSNSTaLFLQ==;
Date: Tue, 01 Jul 2025 14:18:28 +0300
Message-Id: <86ms9o2m7v.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: "Yue Yi" <include_yy@HIDDEN>
In-Reply-To: <tencent_10379C22DF0FE0208EAB5620952DD0CC9D09@HIDDEN>
 (include_yy@HIDDEN)
Subject: Re: bug#78394: 31.0.50;
 Questions about native-comp-speed and type decl
References: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
 <yp1tt3x4rdi.fsf@HIDDEN>
 <tencent_10379C22DF0FE0208EAB5620952DD0CC9D09@HIDDEN>
MIME-version: 1.0
Content-type: text/plain; charset=gb18030
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 78394
Cc: acorallo@HIDDEN, 78394 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: "Yue Yi" <include_yy@HIDDEN>
> Cc: "78394" <78394 <at> debbugs.gnu.org>, "Eli&nbsp;Zaretskii" <eliz@HIDDEN>
> Date: Mon, 30 Jun 2025 19:34:02 +0800
> 
> > "Possible values are:
> >   0 - emitted code can misbehave, even crash Emacs, if declarations of
> >       functions do not correctly describe their actual behavior;
> >   1 - emitted code is to be generated in a safe manner, even if functions
> >       are mis-declared."
> > 
> > The situation for 'compilation-safety' with the current code in case of
> > incorrect declarations is:
> > 
> > 0 we perform optimizations, code can even crash.
> > 1 it cannot crash but still we can perform some otimizations (which can
> >   produce unexpected results at execution time).
> 
> Thank you for the explanation -- I now understand that when
> `compilation-safety' is set to 1 (the default), it generates code in a
> safer manner that avoids crashes, even if function declarations are
> incorrect. However, it does *not* guarantee the correctness of the
> generated code in such cases.
> 
> > If we are unsatisfied with this granularity we could introduce a new value:
> > 
> > 2 no optimizations are performed based on function type declarations.
> > 
> > Mmmh maybe is not a bad idea.
> 
> Mmm, I somewhat agree with this idea. I actually discovered the
> consequences of incorrect type declarations while running code under ERT
> tests, but it’s a kind of issue that's not immediately obvious as being
> caused by a misdeclared type. If adding this option wouldn’t be too
> much trouble, please consider implementing it. TIA!

Patches to implement it are welcome, but I tend to think this
enhancement is not very important.  After all, producing incorrect
code when the programmer provides wrong information is not unexpected,
and the fix is easy.

> Another possible improvement might be to clarify the docstring for
> compilation-safety. I mean, making it more explicitly state that it
> ensures *safety*, but does not guarantee *correctness*.

"Safe" indeed doesn't mean "correct", but I added that nit to the doc
string.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#78394; Package emacs. Full text available.

Message received at 78394 <at> debbugs.gnu.org:


Received: (at 78394) by debbugs.gnu.org; 30 Jun 2025 11:34:25 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jun 30 07:34:25 2025
Received: from localhost ([127.0.0.1]:41445 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uWCmG-0008TB-Fp
	for submit <at> debbugs.gnu.org; Mon, 30 Jun 2025 07:34:25 -0400
Received: from xmbghk7.mail.qq.com ([43.163.128.53]:47471)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <include_yy@HIDDEN>) id 1uWCmA-0008RZ-6h
 for 78394 <at> debbugs.gnu.org; Mon, 30 Jun 2025 07:34:22 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qq.com; s=s201512;
 t=1751283243; bh=WWz3tL5XgWsiuhaXSeOy8wPH71F4iJYP/nRh1otWnpY=;
 h=In-Reply-To:References:From:To:Cc:Subject:Date;
 b=SoxwYvHYI2Pa1AeKo8FbMasH2xRyX38TPPA/Bf49zmcKT2X2Mn9TAq3Gi0o4tuw34
 c21zhfIMH482gGHeWKmt5z6FL+ke7JLNPwStBSBnMidIMtLjrLdQPDblh6NDlcRnDX
 TZEgj2MleypExG1IQNxUH+6S3IkQEeV3RZ9tRZ9Q=
X-QQ-FEAT: oHWrrGTW1dCi2Uhv/TjzETR5+gOBkNuu
X-QQ-SSF: 00000000000000F0000000000000
X-QQ-XMRINFO: MSVp+SPm3vtS1Vd6Y4Mggwc=
X-QQ-XMAILINFO: ODP7Xsg997RQ/FCu0YYlTUJUmpUL3v9oQjUBSrlAngVhC1y01SDRaQ3q4G5Vyb
 m5iQTV/75aGU4T3rc/QaFtd8KtehW+TmSri4k3rWopmBjs0l5IBJAPDaNsFBmX8ijMwVBksd3pnhi
 XsvdJ+0YBHn/oeRm1katKlOVJKQ+JVSk/v23la+iWlz3xsMDhbjfl/NbReY6QqnakBjs0CmuerJlE
 Tre7FFEtLnDajFVMd1p3OvsTaiUT60ikQz55lseB0Ryj6BJakNML5JxKRWQYRENSwacf7Id87KyoE
 VqKQ/Tuk9CXDHT3HAZyqPJzeu5chaOLBavquoQzDVa6JflePgcM0c9liwPIH/rKBKKv80o7TuFM5o
 YqBPuqUVpwjSSk4nrzpjsZolIGJDxm+HEgjlnYgEReY6W/YmWEF5YxKMEc3PFL+e0QHna8ADWQmvv
 SICvQe6ixekZuuhGy4UYf+VL6+YGrmXO8vu52r3kUYh3cEXBwlUBNJyNfUxOnf0K6zrUrxrEz+yTp
 WhAvNI9d4UOxhINxVZKF7zYUlxp/YAPYH4Tzn1f++YUIQk6C7N84FItVBF3cLH0cKd45d+tvn6Sem
 HRo0R7wrAXcSB2PBnfMH4xigOynO515zaHmNwYrtJmPfjjP0A56az+Vg6YEIL77qUWSCJIIYMKOc4
 ueHWgZ/+3AjNvIXJqQmXrAzfJVifsiRQQFnCb60mXxO13c0KpO2D8gxnyO7MrVHBVtffQTHTpZDpG
 0lxCodvGmgoJsWNLaXuwjq6fwjTL8OX8MfrREL9lvjjYhW3EsEIYINAWs/pqWLtPv9yqhORb34xJx
 DFJh/h6Ii4yw9DlzJjQA7RFcEo4W/9mu3kguIliA+B5M7VJ30VjIeb8ReVqSMoYYrQjtQvpRGLqcp
 gWrXcBSh+15T0gjdb95PcKu/dM/lYQp8nKNORXsHsbCXdZ6GpLUmIjRbV5X/zVtdq61o/vfK5vYX6
 0+Zz5H6zIrLX6QYA1du0fSIAnQ8n1r17lU9dtwxX3vzIidCXp+ssiY3WTUhnbvBpvuAGkVHKtyH9N
 x5vM7vXUWoIJoNkhOHpJ3nw7Q5/XsoNlmJ1W5
X-HAS-ATTACH: no
X-QQ-BUSINESS-ORIGIN: 2
X-Originating-IP: 183.7.218.64
In-Reply-To: <yp1tt3x4rdi.fsf@HIDDEN>
References: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
 <yp1tt3x4rdi.fsf@HIDDEN>
X-QQ-STYLE: 
X-QQ-mid: webmail739t1751283242t5296205
From: "=?gb18030?B?WXVlIFlp?=" <include_yy@HIDDEN>
To: "=?gb18030?B?QW5kcmVhIENvcmFsbG8=?=" <acorallo@HIDDEN>
Subject: Re: bug#78394: 31.0.50;
 Questions about native-comp-speed and type decl
Mime-Version: 1.0
Content-Type: multipart/alternative;
 boundary="----=_NextPart_6862762A_11089F78_6419F45F"
Content-Transfer-Encoding: 8Bit
Date: Mon, 30 Jun 2025 19:34:02 +0800
X-Priority: 3
Message-ID: <tencent_10379C22DF0FE0208EAB5620952DD0CC9D09@HIDDEN>
X-QQ-MIME: TCMime 1.0 by Tencent
X-Mailer: QQMail 2.x
X-QQ-Mailer: QQMail 2.x
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 78394
Cc: =?gb18030?B?RWxpJm5ic3A7WmFyZXRza2lp?= <eliz@HIDDEN>,
 =?gb18030?B?NzgzOTQ=?= <78394 <at> debbugs.gnu.org>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

This is a multi-part message in MIME format.

------=_NextPart_6862762A_11089F78_6419F45F
Content-Type: text/plain;
	charset="gb18030"
Content-Transfer-Encoding: base64

VGhhbmtzLCBFbGkgYW5kIEFu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acs@HIDDEN:
bug#78394; Package emacs. Full text available.

Message received at 78394 <at> debbugs.gnu.org:


Received: (at 78394) by debbugs.gnu.org; 30 Jun 2025 07:32:15 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jun 30 03:32:15 2025
Received: from localhost ([127.0.0.1]:38291 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uW8zu-0007qs-Pi
	for submit <at> debbugs.gnu.org; Mon, 30 Jun 2025 03:32:15 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:33502)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <acorallo@HIDDEN>) id 1uW8zj-0007ob-3E
 for 78394 <at> debbugs.gnu.org; Mon, 30 Jun 2025 03:32:07 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <acorallo@HIDDEN>)
 id 1uW8zZ-0000Di-KF; Mon, 30 Jun 2025 03:31:53 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To:
 From; bh=9hSAkdoWHPXgEHixBd8wyq7OTQW2RpyzZTR8d0wCEbo=; b=mDwECRYPoWnXkuGSfjNz
 /rgt1JyXbleRRoSOBEW/ES9YHZ+dJAg6tU7Ztyb+wAhpB0wQAhPeOOXr7W0uT8jtiznOruc1qrhg4
 inpIDqsxLJkmKDbc+wfQ+FPwoKY9FZTusSGlkPpFseWEdx1ABOcya/HeJr5iEjZK2qdITk5Jvnmhf
 Bpj0uGC8wmOOSO4SkUKFqOyssROPoTWZD0MF7oyqOj3eLhyMxi+YJsMC8kifWBr0BD6yzZEwviFz+
 bDXH//GDZaXNOO7EbhZnmaWFCd+r0itqMVbZCcI9rJgv3NDGYXz1AfEHwy1plXOChRExrIEO7rUxb
 JR5MSYnfugnI4g==;
Received: from acorallo by fencepost.gnu.org with local (Exim 4.90_1)
 (envelope-from <acorallo@HIDDEN>)
 id 1uW8zZ-0007TC-BC; Mon, 30 Jun 2025 03:31:53 -0400
From: Andrea Corallo <acorallo@HIDDEN>
To: "Yue Yi" via "Bug reports for GNU Emacs, the Swiss army knife of text
 editors" <bug-gnu-emacs@HIDDEN>
Subject: Re: bug#78394: 31.0.50; Questions about native-comp-speed and type
 decl
In-Reply-To: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN> (Yue Yi's
 message of "Mon, 12 May 2025 23:55:01 +0800")
References: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
Date: Mon, 30 Jun 2025 03:31:53 -0400
Message-ID: <yp1tt3x4rdi.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 78394
Cc: 78394 <at> debbugs.gnu.org, Yue Yi <include_yy@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

"Yue Yi" via "Bug reports for GNU Emacs, the Swiss army knife of text
editors" <bug-gnu-emacs@HIDDEN> writes:

> Hello Emacs maintainers,
>
> When modifying an org HTML export backend, I tentatively added type
> annotations to a function to make the code run faster. However, during
> unit testing, byte compilation produced correct results, while native
> compilation did not. Specifically, the following cleaned-up code
> illustrates the issue:
>
> --------------------------->8<-----------------------------
> (defconst my/plist '(:html-checkbox-type unicode))
> (defconst t-checkbox-types
>   '(( unicode .
>       ((on . "=E2=98=92") (off . "=E2=98=91")
>        (trans . "=E2=98=93")))))
>
> (let ((native-comp-speed 2))
>   (defun t--checkbox (checkbox info)
>     "Format CHECKBOX into HTML."
>     (declare (ftype (function (t plist) string))
>     (side-effect-free t) (important-return-value t))
>     (cdr (assq checkbox
>                (cdr (assq (plist-get info :html-checkbox-type)
>                           t-checkbox-types)))))
>
>   (defun t--format-checkbox (checkbox info)
>     "Format a CHECKBOX option to string.
>
> CHECKBOX can be `on', `off', `trans', or anything else.
> Returns an empty string if CHECKBOX is not one of the these three."
>     (declare (ftype (function (t plist) string))
>     (side-effect-free t) (important-return-value t))
>     (let ((a (t--checkbox checkbox info)))
>       (concat a (and a " "))))
>   ;; native comp
>   (native-compile 't--checkbox)
>   (native-compile 't--format-checkbox))
> --------------------------->8<-----------------------------
>
> AFACK, the default value of `native-comp-speed' is 2. In this case, the
> behavior of the following code is inconsistent with that of the
> byte-compiled or non-compiled code:
>
> --------------------------->8<-----------------------------
> ;; normal
> (t--format-checkbox nil my/plist) ;;=3D> ""
> ;; byte-code
> (t--format-checkbox nil my/plist) ;;=3D> ""
> ;; speed 1
> (t--format-checkbox nil my/plist) ;;=3D> ""
> ;; speed 2
> (t--format-checkbox nil my/plist) ;;=3D> " "
> --------------------------->8<-----------------------------
>
> Of course, we can notice that the type declaration for `t--checkbox' is
> problematic --- its return type should be (or null string) instead of
> string. After correcting this mistake, the function works properly under
> speed=3D2.

Hi Yue,

yep that's correct with (declare (ftype (function (t plist) (or string
null)))) it works as expected.

> In C, we generally avoid aggressive optimizations because they can lead
> to unpredictable behavior. What I=E2=80=99d like to ask is whether similar
> situations can occur in Emacs Lisp=E2=80=99s native compilation as well -=
-- like
> the issue I encountered here?

Yep the manual says 'Incorrect type declarations may cause crashes in
natively compiled code'.

> Another question is about `compilation-safety'. As I understand it, when
> set to 1, it prevents Emacs from crashing due to faulty
> optimizations. Does this mean the variable only guards against the most
> severe cases, rather than ensuring the correctness of optimizations in
> general?

The doc for compilation-safety says:

"Possible values are:
  0 - emitted code can misbehave, even crash Emacs, if declarations of
      functions do not correctly describe their actual behavior;
  1 - emitted code is to be generated in a safe manner, even if functions
      are mis-declared."

The situation for 'compilation-safety' with the current code in case of
incorrect declarations is:

0 we perform optimizations, code can even crash.
1 it cannot crash but still we can perform some otimizations (which can
  produce unexpected results at execution time).

If we are unsatisfied with this granularity we could introduce a new value:

2 no optimizations are performed based on function type declarations.

Mmmh maybe is not a bad idea.

  Andrea




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#78394; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 30 Jun 2025 07:32:07 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jun 30 03:32:07 2025
Received: from localhost ([127.0.0.1]:38289 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uW8zn-0007pn-46
	for submit <at> debbugs.gnu.org; Mon, 30 Jun 2025 03:32:07 -0400
Received: from lists.gnu.org ([2001:470:142::17]:40448)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <acorallo@HIDDEN>) id 1uW8zj-0007oe-C7
 for submit <at> debbugs.gnu.org; Mon, 30 Jun 2025 03:32:04 -0400
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 <acorallo@HIDDEN>) id 1uW8zd-0002zM-SN
 for bug-gnu-emacs@HIDDEN; Mon, 30 Jun 2025 03:31:57 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <acorallo@HIDDEN>)
 id 1uW8zZ-0000Di-KF; Mon, 30 Jun 2025 03:31:53 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To:
 From; bh=9hSAkdoWHPXgEHixBd8wyq7OTQW2RpyzZTR8d0wCEbo=; b=mDwECRYPoWnXkuGSfjNz
 /rgt1JyXbleRRoSOBEW/ES9YHZ+dJAg6tU7Ztyb+wAhpB0wQAhPeOOXr7W0uT8jtiznOruc1qrhg4
 inpIDqsxLJkmKDbc+wfQ+FPwoKY9FZTusSGlkPpFseWEdx1ABOcya/HeJr5iEjZK2qdITk5Jvnmhf
 Bpj0uGC8wmOOSO4SkUKFqOyssROPoTWZD0MF7oyqOj3eLhyMxi+YJsMC8kifWBr0BD6yzZEwviFz+
 bDXH//GDZaXNOO7EbhZnmaWFCd+r0itqMVbZCcI9rJgv3NDGYXz1AfEHwy1plXOChRExrIEO7rUxb
 JR5MSYnfugnI4g==;
Received: from acorallo by fencepost.gnu.org with local (Exim 4.90_1)
 (envelope-from <acorallo@HIDDEN>)
 id 1uW8zZ-0007TC-BC; Mon, 30 Jun 2025 03:31:53 -0400
From: Andrea Corallo <acorallo@HIDDEN>
To: "Yue Yi" via "Bug reports for GNU Emacs, the Swiss army knife of text
 editors" <bug-gnu-emacs@HIDDEN>
Subject: Re: bug#78394: 31.0.50; Questions about native-comp-speed and type
 decl
In-Reply-To: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN> (Yue Yi's
 message of "Mon, 12 May 2025 23:55:01 +0800")
References: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
Date: Mon, 30 Jun 2025 03:31:53 -0400
Message-ID: <yp1tt3x4rdi.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: submit
Cc: 78394 <at> debbugs.gnu.org, Yue Yi <include_yy@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

"Yue Yi" via "Bug reports for GNU Emacs, the Swiss army knife of text
editors" <bug-gnu-emacs@HIDDEN> writes:

> Hello Emacs maintainers,
>
> When modifying an org HTML export backend, I tentatively added type
> annotations to a function to make the code run faster. However, during
> unit testing, byte compilation produced correct results, while native
> compilation did not. Specifically, the following cleaned-up code
> illustrates the issue:
>
> --------------------------->8<-----------------------------
> (defconst my/plist '(:html-checkbox-type unicode))
> (defconst t-checkbox-types
>   '(( unicode .
>       ((on . "=E2=98=92") (off . "=E2=98=91")
>        (trans . "=E2=98=93")))))
>
> (let ((native-comp-speed 2))
>   (defun t--checkbox (checkbox info)
>     "Format CHECKBOX into HTML."
>     (declare (ftype (function (t plist) string))
>     (side-effect-free t) (important-return-value t))
>     (cdr (assq checkbox
>                (cdr (assq (plist-get info :html-checkbox-type)
>                           t-checkbox-types)))))
>
>   (defun t--format-checkbox (checkbox info)
>     "Format a CHECKBOX option to string.
>
> CHECKBOX can be `on', `off', `trans', or anything else.
> Returns an empty string if CHECKBOX is not one of the these three."
>     (declare (ftype (function (t plist) string))
>     (side-effect-free t) (important-return-value t))
>     (let ((a (t--checkbox checkbox info)))
>       (concat a (and a " "))))
>   ;; native comp
>   (native-compile 't--checkbox)
>   (native-compile 't--format-checkbox))
> --------------------------->8<-----------------------------
>
> AFACK, the default value of `native-comp-speed' is 2. In this case, the
> behavior of the following code is inconsistent with that of the
> byte-compiled or non-compiled code:
>
> --------------------------->8<-----------------------------
> ;; normal
> (t--format-checkbox nil my/plist) ;;=3D> ""
> ;; byte-code
> (t--format-checkbox nil my/plist) ;;=3D> ""
> ;; speed 1
> (t--format-checkbox nil my/plist) ;;=3D> ""
> ;; speed 2
> (t--format-checkbox nil my/plist) ;;=3D> " "
> --------------------------->8<-----------------------------
>
> Of course, we can notice that the type declaration for `t--checkbox' is
> problematic --- its return type should be (or null string) instead of
> string. After correcting this mistake, the function works properly under
> speed=3D2.

Hi Yue,

yep that's correct with (declare (ftype (function (t plist) (or string
null)))) it works as expected.

> In C, we generally avoid aggressive optimizations because they can lead
> to unpredictable behavior. What I=E2=80=99d like to ask is whether similar
> situations can occur in Emacs Lisp=E2=80=99s native compilation as well -=
-- like
> the issue I encountered here?

Yep the manual says 'Incorrect type declarations may cause crashes in
natively compiled code'.

> Another question is about `compilation-safety'. As I understand it, when
> set to 1, it prevents Emacs from crashing due to faulty
> optimizations. Does this mean the variable only guards against the most
> severe cases, rather than ensuring the correctness of optimizations in
> general?

The doc for compilation-safety says:

"Possible values are:
  0 - emitted code can misbehave, even crash Emacs, if declarations of
      functions do not correctly describe their actual behavior;
  1 - emitted code is to be generated in a safe manner, even if functions
      are mis-declared."

The situation for 'compilation-safety' with the current code in case of
incorrect declarations is:

0 we perform optimizations, code can even crash.
1 it cannot crash but still we can perform some otimizations (which can
  produce unexpected results at execution time).

If we are unsatisfied with this granularity we could introduce a new value:

2 no optimizations are performed based on function type declarations.

Mmmh maybe is not a bad idea.

  Andrea




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#78394; Package emacs. Full text available.

Message received at 78394 <at> debbugs.gnu.org:


Received: (at 78394) by debbugs.gnu.org; 30 Jun 2025 06:16:19 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jun 30 02:16:19 2025
Received: from localhost ([127.0.0.1]:37202 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uW7oQ-0006Et-6C
	for submit <at> debbugs.gnu.org; Mon, 30 Jun 2025 02:16:18 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:36538)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <acorallo@HIDDEN>) id 1uW7oO-0006Dy-44
 for 78394 <at> debbugs.gnu.org; Mon, 30 Jun 2025 02:16:16 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <acorallo@HIDDEN>)
 id 1uW7oI-0003bM-MJ; Mon, 30 Jun 2025 02:16:10 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To:
 From; bh=EQg8fC395tq6AuvXBzApWfNf+P6A8Y9vsqoC7AiFW0g=; b=CmkvUtk3qO9nYydW+wPY
 C8fyc537PPfk5mBLkjxRfMbB2kfG/9lkM2LB+ukIZzCr/PgNJx8KB5iL3ktfsVzRCPOcmdNf+l7QO
 z0pwJb+CtVm2NPAcbpjCfOLwVVf6MD7P7cfg5ubBJ5cPvVuoPmC4PLBb65BtJhNJJ1lBE29gsleAi
 mfq9uzMs6fbQHQpMO7igeiDeDYXfA8PVozD22Vrk0qjmg/M43AEnDKi6/GFVbEzFrEgzU6BLhvkAn
 w7MsVFq/+QPqpuNVTmIX4sHp4lMg1E4PWPUSX/ZQS9/ai7lLCyIqsir6XfutQ0xjcpODv3HWAWZaG
 FIjjkYQReS/NDg==;
Received: from acorallo by fencepost.gnu.org with local (Exim 4.90_1)
 (envelope-from <acorallo@HIDDEN>)
 id 1uW7oH-0001ej-SC; Mon, 30 Jun 2025 02:16:10 -0400
From: Andrea Corallo <acorallo@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#78394: 31.0.50; Questions about native-comp-speed and type
 decl
In-Reply-To: <86h6008d6c.fsf@HIDDEN> (Eli Zaretskii's message of "Sat, 28 Jun
 2025 11:48:11 +0300")
References: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
 <867c2l7qk8.fsf@HIDDEN> <86o6v9rvh4.fsf@HIDDEN>
 <86h6008d6c.fsf@HIDDEN>
Date: Mon, 30 Jun 2025 02:16:09 -0400
Message-ID: <yp1y0t94uvq.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 78394
Cc: 78394 <at> debbugs.gnu.org, include_yy@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Eli Zaretskii <eliz@HIDDEN> writes:

> Ping! Ping!  Andrea, could you please respond?

Sorry I completely missed this bug.  Looking at it.

  Andrea




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#78394; Package emacs. Full text available.

Message received at 78394 <at> debbugs.gnu.org:


Received: (at 78394) by debbugs.gnu.org; 28 Jun 2025 08:48:23 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Jun 28 04:48:23 2025
Received: from localhost ([127.0.0.1]:47717 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uVRET-0001H7-Tf
	for submit <at> debbugs.gnu.org; Sat, 28 Jun 2025 04:48:23 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:50678)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1uVRER-0001Fs-Cl
 for 78394 <at> debbugs.gnu.org; Sat, 28 Jun 2025 04:48:20 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1uVREM-0000gb-2y; Sat, 28 Jun 2025 04:48:14 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=4mFfH8eJuFDWDajpBhwJxqzfgZo42luqGzl7fHRoheE=; b=BTbkOxSgxg/uF0wVhhDq
 y+4+fPkEieZOpWpAvr00oBzVvogqLV4aW9d+tyjNdUNyrOcRh2uQ9XzIpKBYG3KMb4wTpWLPxpCfN
 nI4vrB9r1TWzUS0yuvswHgnVPOq/YwYyZIJqyvVzZhzKWMKmMk4FaDJAFod/14s+W8Fl7ZJQgSNGj
 9FSL809lHXjV8Sko/i0h+wMUd09YaKaTr/vFBMDXamTbAXnvB2UNsjPwxB3qWO03FUl8pCLfWuQvW
 kgCtBRvOde7q/R1ik+kS3p+KmyUfnSZP85b6baQA+WKP3dtWdAAxQysi++DIATK313Pky/zrRnN+u
 WEEJewb1sXSZ3Q==;
Date: Sat, 28 Jun 2025 11:48:11 +0300
Message-Id: <86h6008d6c.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: acorallo@HIDDEN
In-Reply-To: <86o6v9rvh4.fsf@HIDDEN> (message from Eli Zaretskii on Sat, 31
 May 2025 12:16:23 +0300)
Subject: Re: bug#78394: 31.0.50;
 Questions about native-comp-speed and type decl
References: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
 <867c2l7qk8.fsf@HIDDEN> <86o6v9rvh4.fsf@HIDDEN>
MIME-version: 1.0
Content-type: text/plain; charset=gb18030
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 78394
Cc: 78394 <at> debbugs.gnu.org, include_yy@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Ping! Ping!  Andrea, could you please respond?

> Cc: 78394 <at> debbugs.gnu.org, include_yy@HIDDEN
> Date: Sat, 31 May 2025 12:16:23 +0300
> From: Eli Zaretskii <eliz@HIDDEN>
> 
> Ping!  Andrea, could you please answer these questions?
> 
> > Cc: 78394 <at> debbugs.gnu.org
> > Date: Mon, 12 May 2025 19:16:07 +0300
> > From: Eli Zaretskii <eliz@HIDDEN>
> > 
> > > Date: Mon, 12 May 2025 23:55:01 +0800
> > > From:  "Yue Yi" via "Bug reports for GNU Emacs,
> > >  the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN>
> > > 
> > > When modifying an org HTML export backend, I tentatively added type
> > > annotations to a function to make the code run faster. However, during
> > > unit testing, byte compilation produced correct results, while native
> > > compilation did not. Specifically, the following cleaned-up code
> > > illustrates the issue:
> > > 
> > > --------------------------->8<-----------------------------
> > > (defconst my/plist '(:html-checkbox-type unicode))
> > > (defconst t-checkbox-types
> > >   '(( unicode .
> > >       ((on . "☑") (off . "☐")
> > >        (trans . "☒")))))
> > > 
> > > (let ((native-comp-speed 2))
> > >   (defun t--checkbox (checkbox info)
> > >     "Format CHECKBOX into HTML."
> > >     (declare (ftype (function (t plist) string))
> > >     (side-effect-free t) (important-return-value t))
> > >     (cdr (assq checkbox
> > >                (cdr (assq (plist-get info :html-checkbox-type)
> > >                           t-checkbox-types)))))
> > > 
> > >   (defun t--format-checkbox (checkbox info)
> > >     "Format a CHECKBOX option to string.
> > > 
> > > CHECKBOX can be `on', `off', `trans', or anything else.
> > > Returns an empty string if CHECKBOX is not one of the these three."
> > >     (declare (ftype (function (t plist) string))
> > >     (side-effect-free t) (important-return-value t))
> > >     (let ((a (t--checkbox checkbox info)))
> > >       (concat a (and a " "))))
> > >   ;; native comp
> > >   (native-compile 't--checkbox)
> > >   (native-compile 't--format-checkbox))
> > > --------------------------->8<-----------------------------
> > > 
> > > AFACK, the default value of `native-comp-speed' is 2. In this case, the
> > > behavior of the following code is inconsistent with that of the
> > > byte-compiled or non-compiled code:
> > > 
> > > --------------------------->8<-----------------------------
> > > ;; normal
> > > (t--format-checkbox nil my/plist) ;;=> ""
> > > ;; byte-code
> > > (t--format-checkbox nil my/plist) ;;=> ""
> > > ;; speed 1
> > > (t--format-checkbox nil my/plist) ;;=> ""
> > > ;; speed 2
> > > (t--format-checkbox nil my/plist) ;;=> " "
> > > --------------------------->8<-----------------------------
> > > 
> > > Of course, we can notice that the type declaration for `t--checkbox' is
> > > problematic --- its return type should be (or null string) instead of
> > > string. After correcting this mistake, the function works properly under
> > > speed=2.
> > > 
> > > In C, we generally avoid aggressive optimizations because they can lead
> > > to unpredictable behavior. What I’d like to ask is whether similar
> > > situations can occur in Emacs Lisp’s native compilation as well --- like
> > > the issue I encountered here?
> > > 
> > > Another question is about `compilation-safety'. As I understand it, when
> > > set to 1, it prevents Emacs from crashing due to faulty
> > > optimizations. Does this mean the variable only guards against the most
> > > severe cases, rather than ensuring the correctness of optimizations in
> > > general?
> > 
> > I hope Andrea (CC'ed) will be able to answer your questions.
> > 
> > 
> > 
> > 
> 
> 
> 
> 




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#78394; Package emacs. Full text available.

Message received at 78394 <at> debbugs.gnu.org:


Received: (at 78394) by debbugs.gnu.org; 31 May 2025 09:17:25 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat May 31 05:17:24 2025
Received: from localhost ([127.0.0.1]:55537 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uLIL9-0003Tu-RN
	for submit <at> debbugs.gnu.org; Sat, 31 May 2025 05:17:24 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:58244)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1uLIKO-0003NL-LD
 for 78394 <at> debbugs.gnu.org; Sat, 31 May 2025 05:16:36 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1uLIKI-0001ES-Pk; Sat, 31 May 2025 05:16:26 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=UqhPU4KWyF4EXYWd6CNfQnoGdui6NRGd2vmZ9TgpK5I=; b=VvCc/CgAn3dNwtrTFHTv
 OymgwgLkNOUf88GDSpeWy0oeJLC5ire7cNFVuQsjN5na/jPnuIqzNImg7uxU5RI9RNWYLH95BuRvL
 bzOKV1wgotwgmSMj95zzqp63fZt09cUj2+T0hsJIEkAlfwTREEJUXdKW1zu5fAyuEtbuwdGcP3lHN
 7pPsGt+x5wX6I85tFtHcPMMwMxFEXeHdFfE303ZShHWJVzP4BNdb/SOJD4F57zbavOGfJ5R7uG0iB
 buDoFslKp/96vHy11jnf1+dDwvc2+Ucqw/KFzfsMRRMtZX6lHv0A1hrVUNsjjVqV0n2jOnmJFufFw
 buVdf23yrdJDog==;
Date: Sat, 31 May 2025 12:16:23 +0300
Message-Id: <86o6v9rvh4.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: acorallo@HIDDEN
In-Reply-To: <867c2l7qk8.fsf@HIDDEN> (message from Eli Zaretskii on Mon, 12
 May 2025 19:16:07 +0300)
Subject: Re: bug#78394: 31.0.50;
 Questions about native-comp-speed and type decl
References: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
 <867c2l7qk8.fsf@HIDDEN>
MIME-version: 1.0
Content-type: text/plain; charset=gb18030
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 78394
Cc: 78394 <at> debbugs.gnu.org, include_yy@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Ping!  Andrea, could you please answer these questions?

> Cc: 78394 <at> debbugs.gnu.org
> Date: Mon, 12 May 2025 19:16:07 +0300
> From: Eli Zaretskii <eliz@HIDDEN>
> 
> > Date: Mon, 12 May 2025 23:55:01 +0800
> > From:  "Yue Yi" via "Bug reports for GNU Emacs,
> >  the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN>
> > 
> > When modifying an org HTML export backend, I tentatively added type
> > annotations to a function to make the code run faster. However, during
> > unit testing, byte compilation produced correct results, while native
> > compilation did not. Specifically, the following cleaned-up code
> > illustrates the issue:
> > 
> > --------------------------->8<-----------------------------
> > (defconst my/plist '(:html-checkbox-type unicode))
> > (defconst t-checkbox-types
> >   '(( unicode .
> >       ((on . "☑") (off . "☐")
> >        (trans . "☒")))))
> > 
> > (let ((native-comp-speed 2))
> >   (defun t--checkbox (checkbox info)
> >     "Format CHECKBOX into HTML."
> >     (declare (ftype (function (t plist) string))
> >     (side-effect-free t) (important-return-value t))
> >     (cdr (assq checkbox
> >                (cdr (assq (plist-get info :html-checkbox-type)
> >                           t-checkbox-types)))))
> > 
> >   (defun t--format-checkbox (checkbox info)
> >     "Format a CHECKBOX option to string.
> > 
> > CHECKBOX can be `on', `off', `trans', or anything else.
> > Returns an empty string if CHECKBOX is not one of the these three."
> >     (declare (ftype (function (t plist) string))
> >     (side-effect-free t) (important-return-value t))
> >     (let ((a (t--checkbox checkbox info)))
> >       (concat a (and a " "))))
> >   ;; native comp
> >   (native-compile 't--checkbox)
> >   (native-compile 't--format-checkbox))
> > --------------------------->8<-----------------------------
> > 
> > AFACK, the default value of `native-comp-speed' is 2. In this case, the
> > behavior of the following code is inconsistent with that of the
> > byte-compiled or non-compiled code:
> > 
> > --------------------------->8<-----------------------------
> > ;; normal
> > (t--format-checkbox nil my/plist) ;;=> ""
> > ;; byte-code
> > (t--format-checkbox nil my/plist) ;;=> ""
> > ;; speed 1
> > (t--format-checkbox nil my/plist) ;;=> ""
> > ;; speed 2
> > (t--format-checkbox nil my/plist) ;;=> " "
> > --------------------------->8<-----------------------------
> > 
> > Of course, we can notice that the type declaration for `t--checkbox' is
> > problematic --- its return type should be (or null string) instead of
> > string. After correcting this mistake, the function works properly under
> > speed=2.
> > 
> > In C, we generally avoid aggressive optimizations because they can lead
> > to unpredictable behavior. What I’d like to ask is whether similar
> > situations can occur in Emacs Lisp’s native compilation as well --- like
> > the issue I encountered here?
> > 
> > Another question is about `compilation-safety'. As I understand it, when
> > set to 1, it prevents Emacs from crashing due to faulty
> > optimizations. Does this mean the variable only guards against the most
> > severe cases, rather than ensuring the correctness of optimizations in
> > general?
> 
> I hope Andrea (CC'ed) will be able to answer your questions.
> 
> 
> 
> 




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#78394; Package emacs. Full text available.

Message received at 78394 <at> debbugs.gnu.org:


Received: (at 78394) by debbugs.gnu.org; 12 May 2025 16:16:55 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon May 12 12:16:55 2025
Received: from localhost ([127.0.0.1]:54284 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uEVpn-0003yb-1o
	for submit <at> debbugs.gnu.org; Mon, 12 May 2025 12:16:55 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:34420)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <eliz@HIDDEN>) id 1uEVpj-0003yJ-Ph
 for 78394 <at> debbugs.gnu.org; Mon, 12 May 2025 12:16:52 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1uEVpc-0003m7-67; Mon, 12 May 2025 12:16:44 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=5EI2CIFcC9W3Vw7P+/IWnG3X7z4vo6AOZLoStcWV/oo=; b=H3Gwuj+E+weGrfOEljPk
 N15u+sr4lQDUdz4/YaDxIz/vj+AhfgvVhzJPSpRR7TvFNSZmr/w8egc2B8jS5bc2pjER9LLt1v0tW
 9aNhF4tOWSraaKt4d0dMITbrwg4e2h3Ey7xyRJZRatOYNGBvjImxHg5obKEKFdRIDyrCdRRHx1KOl
 FgXM0zDkgtppDNdAr451GrBF+3EizjQgl/51A5T+MQrnVomEwGAC+v4jKPp54vq9gTiSXzm0KEEmK
 ZatilsdsvmzRwUHJx0v8YBHQIXzKVH4vSJ6xPUxxvBvMPeOoaCS77Jmw0cdMa/HxogtKPNgKIIYtM
 OTmgorf6I5BTZQ==;
Date: Mon, 12 May 2025 19:16:07 +0300
Message-Id: <867c2l7qk8.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: "Yue Yi" <include_yy@HIDDEN>, Andrea Corallo <acorallo@HIDDEN>
In-Reply-To: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
 (bug-gnu-emacs@HIDDEN)
Subject: Re: bug#78394: 31.0.50;
 Questions about native-comp-speed and type decl
References: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
MIME-version: 1.0
Content-type: text/plain; charset=gb18030
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 78394
Cc: 78394 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> Date: Mon, 12 May 2025 23:55:01 +0800
> From:  "Yue Yi" via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs@HIDDEN>
> 
> When modifying an org HTML export backend, I tentatively added type
> annotations to a function to make the code run faster. However, during
> unit testing, byte compilation produced correct results, while native
> compilation did not. Specifically, the following cleaned-up code
> illustrates the issue:
> 
> --------------------------->8<-----------------------------
> (defconst my/plist '(:html-checkbox-type unicode))
> (defconst t-checkbox-types
>   '(( unicode .
>       ((on . "☑") (off . "☐")
>        (trans . "☒")))))
> 
> (let ((native-comp-speed 2))
>   (defun t--checkbox (checkbox info)
>     "Format CHECKBOX into HTML."
>     (declare (ftype (function (t plist) string))
>     (side-effect-free t) (important-return-value t))
>     (cdr (assq checkbox
>                (cdr (assq (plist-get info :html-checkbox-type)
>                           t-checkbox-types)))))
> 
>   (defun t--format-checkbox (checkbox info)
>     "Format a CHECKBOX option to string.
> 
> CHECKBOX can be `on', `off', `trans', or anything else.
> Returns an empty string if CHECKBOX is not one of the these three."
>     (declare (ftype (function (t plist) string))
>     (side-effect-free t) (important-return-value t))
>     (let ((a (t--checkbox checkbox info)))
>       (concat a (and a " "))))
>   ;; native comp
>   (native-compile 't--checkbox)
>   (native-compile 't--format-checkbox))
> --------------------------->8<-----------------------------
> 
> AFACK, the default value of `native-comp-speed' is 2. In this case, the
> behavior of the following code is inconsistent with that of the
> byte-compiled or non-compiled code:
> 
> --------------------------->8<-----------------------------
> ;; normal
> (t--format-checkbox nil my/plist) ;;=> ""
> ;; byte-code
> (t--format-checkbox nil my/plist) ;;=> ""
> ;; speed 1
> (t--format-checkbox nil my/plist) ;;=> ""
> ;; speed 2
> (t--format-checkbox nil my/plist) ;;=> " "
> --------------------------->8<-----------------------------
> 
> Of course, we can notice that the type declaration for `t--checkbox' is
> problematic --- its return type should be (or null string) instead of
> string. After correcting this mistake, the function works properly under
> speed=2.
> 
> In C, we generally avoid aggressive optimizations because they can lead
> to unpredictable behavior. What I’d like to ask is whether similar
> situations can occur in Emacs Lisp’s native compilation as well --- like
> the issue I encountered here?
> 
> Another question is about `compilation-safety'. As I understand it, when
> set to 1, it prevents Emacs from crashing due to faulty
> optimizations. Does this mean the variable only guards against the most
> severe cases, rather than ensuring the correctness of optimizations in
> general?

I hope Andrea (CC'ed) will be able to answer your questions.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#78394; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 12 May 2025 15:55:33 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon May 12 11:55:33 2025
Received: from localhost ([127.0.0.1]:54205 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1uEVV6-0002uR-Rq
	for submit <at> debbugs.gnu.org; Mon, 12 May 2025 11:55:33 -0400
Received: from lists.gnu.org ([2001:470:142::17]:42400)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <include_yy@HIDDEN>) id 1uEVV2-0002u2-Ac
 for submit <at> debbugs.gnu.org; Mon, 12 May 2025 11:55:31 -0400
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 <include_yy@HIDDEN>) id 1uEVUu-0003sx-Hm
 for bug-gnu-emacs@HIDDEN; Mon, 12 May 2025 11:55:21 -0400
Received: from out203-205-221-242.mail.qq.com ([203.205.221.242])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <include_yy@HIDDEN>) id 1uEVUp-0000qZ-Ra
 for bug-gnu-emacs@HIDDEN; Mon, 12 May 2025 11:55:20 -0400
DKIM-Signature: v=1; a=rsa-sha256; c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MfHdQJDEdSEiBLFH
 QIlf7NLC0xq1mWsYc68y5U8Mo29Ucqqiqt9jYoy8JkLYMOlGHpt5vIsDTr0xtc5Lnh7ISqfFBCLhU
 aPdf4qfiIGJykO06dQgUtVyAEV7iJjZokuLlfEiQXz6+RZ9qbVwFCDCuvO7FLofMsZuImnW7FtFxp
 9kYOazqSzBHW+ZChRqgH44gAee6LfDyNdlRVtcTz8Bko29AJ0dv4uY50DKCcOEkihlhN18DKVDCyF
 CzDgoFmTKHeWPq/aExzBNUNSo1+mQ5WRWeAM6LG/8iY/S82Mx3R3kMTQ3DQ96Qe0fD0krjWbWKFs9
 xh2uM/5zjsDVOE65bO5Z9/gal2r4O3GQdPXvXn3xp8E+wSUAvRsRHNkqQK4o9XGG83XKH1p9mvMB1
 wllfU
X-HAS-ATTACH: no
X-QQ-BUSINESS-ORIGIN: 2
X-Originating-IP: 112.94.111.207
X-QQ-STYLE: 
X-QQ-mid: webmail739t1747065302t3561523
From: "=?gb18030?B?WXVlIFlp?=" <include_yy@HIDDEN>
To: "=?gb18030?B?YnVnLWdudS1lbWFjcw==?=" <bug-gnu-emacs@HIDDEN>
Subject: 31.0.50; Questions about native-comp-speed and type decl
Mime-Version: 1.0
Content-Type: multipart/alternative;
 boundary="----=_NextPart_682219D5_13C997E8_0D93638F"
Content-Transfer-Encoding: 8Bit
Date: Mon, 12 May 2025 23:55:01 +0800
X-Priority: 3
Message-ID: <tencent_F01FA7D8F74C389263C89576653B3438E707@HIDDEN>
X-QQ-MIME: TCMime 1.0 by Tencent
X-Mailer: QQMail 2.x
X-QQ-Mailer: QQMail 2.x
Received-SPF: pass client-ip=203.205.221.242; envelope-from=include_yy@HIDDEN;
 helo=out203-205-221-242.mail.qq.com
X-Spam_score_int: 65
X-Spam_score: 6.5
X-Spam_bar: ++++++
X-Spam_report: (6.5 / 5.0 requ) BAYES_00=-1.9, CHARSET_FARAWAY_HEADER=3.2,
 DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 FREEMAIL_FROM=0.001, FROM_EXCESS_BASE64=0.001, HELO_DYNAMIC_IPADDR=1.951,
 HTML_MESSAGE=0.001, MIME_CHARSET_FARAWAY=2.45, RCVD_IN_DNSWL_NONE=-0.0001,
 RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001,
 RDNS_DYNAMIC=0.982, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=no autolearn_force=no
X-Spam_action: reject
X-Spam-Score: 0.9 (/)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.1 (/)

This is a multi-part message in MIME format.

------=_NextPart_682219D5_13C997E8_0D93638F
Content-Type: text/plain;
	charset="gb18030"
Content-Transfer-Encoding: base64

SGVsbG8gRW1hY3MgbWFpbnRhaW5lcnMsIFdoZW4gbW9kaWZ5aW5nIGFuIG9yZyBIVE1MIGV4
cG9ydCBiYWNrZW5kLCBJIHRlbnRhdGl2ZWx5IGFkZGVkIHR5cGUgYW5ub3RhdGlvbnMgdG8g
YSBmdW5jdGlv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s@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#78394; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Tue, 1 Jul 2025 11:30:04 UTC

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