GNU bug report logs - #72863
30.0.50; tree-sitter elixir-ts-mode hangs and memory leak on some elixir and heex code

Previous Next

Package: emacs;

Reported by: mail <at> ssbb.me

Date: Thu, 29 Aug 2024 03:30:02 UTC

Severity: normal

Found in version 30.0.50

Full log


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

From: mail <at> ssbb.me
To: bug-gnu-emacs <at> gnu.org
Subject: 30.0.50; tree-sitter elixir-ts-mode hangs and memory leak on some
 elixir and heex code
Date: Thu, 29 Aug 2024 06:57:38 +0400
[Message part 1 (text/plain, inline)]
Code in attached file cause Emacs to hang and memory leak infinitely
while editing. Try to open this code in elixir-ts-mode and move cursor
on line 6 (between <:loading>  </:loading>) and type char by char:

<.some_component a={

(for some reason it does not happen with electric-pair-mode when {}
inserted automatically).

I am able to reproduce this with -Q on few different machines (Linux and
MacOS) and Emacs 29, 30.0.5 and current HEAD.

C-g does nothing (including with debug-on-quit and sending SIGUSR2)

At the same time I can't reproduce this in other tree-sitter based editors.

I got this sample code sample from elixir-ts-mode repo but now it's moved
to the Emacs core so seems to be out of scope of Github repo issues.

Attaching samle code and LLDB backtrace. 
Also attaching report from built-in MacOS crash reporting tool just in case.

[code.ex (application/octet-stream, attachment)]
[backtrace (application/octet-stream, attachment)]
[report (application/octet-stream, attachment)]
[Message part 5 (text/plain, inline)]

In GNU Emacs 30.0.50 (build 1, aarch64-apple-darwin23.2.0, NS
 appkit-2487.30 Version 14.2.1 (Build 23C71)) of 2024-06-23 built on
 Sviatoslavs-MacBook-Pro.local
Windowing system distributor 'Apple', version 10.3.2487
System Description:  macOS 14.2.1

Configured using:
 'configure --disable-dependency-tracking --disable-silent-rules
 --enable-locallisppath=/opt/homebrew/share/emacs/site-lisp
 --infodir=/opt/homebrew/Cellar/emacs-plus <at> 30/30.0.50/share/info/emacs
 --prefix=/opt/homebrew/Cellar/emacs-plus <at> 30/30.0.50 --with-xml2
 --with-gnutls --with-native-compilation --without-compress-install
 --without-dbus --without-imagemagick --with-modules --with-rsvg
 --with-webp --with-ns --disable-ns-self-contained 'CFLAGS=-Os -w -pipe
 -mmacosx-version-min=14
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk
 -DFD_SETSIZE=10000 -DDARWIN_UNLIMITED_SELECT
 -I/opt/homebrew/opt/gcc/include -I/opt/homebrew/opt/libgccjit/include'
 'CPPFLAGS=-I/opt/homebrew/opt/zlib/include
 -I/opt/homebrew/opt/jpeg/include -I/opt/homebrew/opt/icu4c/include
 -I/opt/homebrew/opt/sqlite/include -I/opt/homebrew/opt/readline/include
 -isystem/opt/homebrew/include -F/opt/homebrew/Frameworks
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk'
 'LDFLAGS=-L/opt/homebrew/opt/zlib/lib -L/opt/homebrew/opt/jpeg/lib
 -L/opt/homebrew/opt/icu4c/lib -L/opt/homebrew/opt/sqlite/lib
 -L/opt/homebrew/opt/readline/lib -L/opt/homebrew/lib
 -F/opt/homebrew/Frameworks -Wl,-headerpad_max_install_names
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk
 -L/opt/homebrew/lib/gcc/14 -I/opt/homebrew/opt/gcc/include
 -I/opt/homebrew/opt/libgccjit/include''




This bug report was last modified 281 days ago.

Previous Next


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