GNU bug report logs - #75135
30.0.93; Infinite loop in comp--native-compile

Previous Next

Package: emacs;

Reported by: Hugh Daschbach <hdasch <at> ccss.com>

Date: Fri, 27 Dec 2024 06:13:03 UTC

Severity: normal

Tags: patch

Found in version 30.0.93

Full log


Message #22 received at 75135 <at> debbugs.gnu.org (full text, mbox):

From: hugh <at> ccss.com
To: Stefan Kangas <stefankangas <at> gmail.com>
Cc: 75135 <at> debbugs.gnu.org, Andrea Corallo <acorallo <at> gnu.org>,
 Eli Zaretskii <eliz <at> gnu.org>, Hugh Daschbach <hdasch <at> ccss.com>
Subject: Re: bug#75135: 30.0.93; Infinite loop in comp--native-compile
Date: Sat, 01 Mar 2025 21:52:51 -0800
Stefan Kangas <stefankangas <at> gmail.com> writes:

> Andrea Corallo <acorallo <at> gnu.org> writes:
>
>> The attached should be fixing it, could you give it a try?
>
> Ping, Hugh, any chance you could try the below patch?  Thanks.

Currently running 30.1 (git commit 92e96a11752) I confirm that the
infinite loop still exists without the patch.

The problem is resolved with the patch.

Thanks for the fix.

Hugh

>> Circular objects are rare in code and we lived with this for a long
>> time, I'd suggest to install this only on master not to touch the
>> release branch.  Eli WDYT?
>>
>> Thanks
>>
>>   Andrea
>>
>> diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el
>> index 2966ed255ac..f3b6b8fd606 100644
>> --- a/lisp/emacs-lisp/comp.el
>> +++ b/lisp/emacs-lisp/comp.el
>> @@ -2481,8 +2481,9 @@ comp--ssa-rename-insn
>>                   (setf (comp-vec-aref frame slot-n) mvar
>>                         (cadr insn) mvar))))
>>       (pcase insn
>> -       (`(setimm ,(pred targetp) ,_imm)
>> -        (new-lvalue))
>> +       (`(setimm ,lval ,_imm)
>> +        (when (targetp lval)
>> +          (new-lvalue)))
>>         (`(,(pred comp--assign-op-p) ,(pred targetp) . ,_)
>>          (let ((mvar (comp-vec-aref frame slot-n)))
>>            (setf (cddr insn) (cl-nsubst-if mvar #'targetp (cddr insn))))




This bug report was last modified 160 days ago.

Previous Next


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