From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ravi D'Elia Newsgroups: gmane.emacs.bugs Subject: bug#72025: SEGFAULT when using corfu and lsp-mode with clangd Date: Tue, 9 Jul 2024 19:20:15 -0400 Message-ID: <4upkl3dutgscohej2smaonb26asvl6cmp24z2jj25myjzhb3qz@vlrqcyiid7cx> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="karrhczy337jpvcr" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="38498"; mail-complaints-to="usenet@ciao.gmane.io" To: 72025@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jul 10 04:20:54 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sRMww-0009jy-CO for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 10 Jul 2024 04:20:54 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sRMw3-0008Q5-WB; Tue, 09 Jul 2024 22:20:00 -0400 Original-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 ) id 1sRMw1-0008P7-Pd for bug-gnu-emacs@gnu.org; Tue, 09 Jul 2024 22:19:57 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sRMw1-0000yB-HL for bug-gnu-emacs@gnu.org; Tue, 09 Jul 2024 22:19:57 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sRMw7-0006HM-9z for bug-gnu-emacs@gnu.org; Tue, 09 Jul 2024 22:20:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ravi D'Elia Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 10 Jul 2024 02:20:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 72025 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.172057795324038 (code B ref -1); Wed, 10 Jul 2024 02:20:03 +0000 Original-Received: (at submit) by debbugs.gnu.org; 10 Jul 2024 02:19:13 +0000 Original-Received: from localhost ([127.0.0.1]:54544 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sRMvH-0006FW-2J for submit@debbugs.gnu.org; Tue, 09 Jul 2024 22:19:13 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:42990) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sRK8N-0001QI-QR for submit@debbugs.gnu.org; Tue, 09 Jul 2024 19:20:32 -0400 Original-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 ) id 1sRK8F-0004JE-W3 for bug-gnu-emacs@gnu.org; Tue, 09 Jul 2024 19:20:25 -0400 Original-Received: from mail-il1-x12a.google.com ([2607:f8b0:4864:20::12a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sRK8D-0004Rr-Ev for bug-gnu-emacs@gnu.org; Tue, 09 Jul 2024 19:20:23 -0400 Original-Received: by mail-il1-x12a.google.com with SMTP id e9e14a558f8ab-389cb8f18f0so8626745ab.1 for ; Tue, 09 Jul 2024 16:20:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1720567217; x=1721172017; darn=gnu.org; h=content-disposition:mime-version:message-id:subject:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=YBOXu+3qgKaEWBx95RPJ7ES8D49x+Fb/R1iubGRdd8A=; b=HxkDaMJdU6WXnm3WSmalMz3El2ZBqVfGToHWVRv9FaVWsikzciEvBdamTwfvkV0aWI JvIzKTI7ZBMKGw2gcOd8OBchl6jDkjqX6jRDqXOT/WIMmcE6qTJratjDjZfX6isvlwjV vLdCBJKHp5hHGZOCVooOd1k6dK9d4YOzn3i90A4SdW7l8PEOhVFNY3jT0EzeT91Dy7mY /0RJxgfyVkglrHP9p22uKMSh4wEUPxERsvN6wyZPzMHy1igGYQhzcY89yuMEnOl892MX DJ/Td6Uo6mSQgR6JwP5CNRnK73dzvxve0T2Ee95QN3ohapozDlddHjYmUUmTd6ImAHvh JQYQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1720567217; x=1721172017; h=content-disposition:mime-version:message-id:subject:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=YBOXu+3qgKaEWBx95RPJ7ES8D49x+Fb/R1iubGRdd8A=; b=E3BtxejJuiJxBgbJ1wNvMB5EHoF392dNTyS4yV8Yh155lYKuy7niFhGkJ6sjzQv5m9 dm9wRXr+XUAlXcwD1kExt0WqKObOIjRtsl24ixtivFiRA/6mA+JGtM6HbTlXunKWTqyI DEFkyE9SMbAIlLR1BDGEqp4dVwSRtVjp9m6/+4KfmOFRn8Gq8ZINpw9EtX/LZojR8Gp2 FoHeBEbjhPsXW0hJOPJb1+Z6weOrIo12kG0EQP/cgOBjeRh2Cu9MQR0UEzoG0JppBTAH HcOSU5Po3eIs1PAJtbyo7UzaYAu6Hl6dR8I4+LFfbCTIVw16BNbFyO+Kt+PsIj/FPJpS CdQQ== X-Gm-Message-State: AOJu0Ywe6e54TRtoy6EpSYRntzH750uyLLbzmceWZW2bkSW9VGs1UtOs AYet1bjCneX7RcvDzu5mncQ6VIpi+TE7Q74ezdY73Tq2W2f+Z+G6Z/jOJg== X-Google-Smtp-Source: AGHT+IG24bjvDT8q+dRhoXJfR1xuD5R69fr40xBy0Lb1O+GJ/wikhFyf5M1cHxBt56/pkWkKB8hdQQ== X-Received: by 2002:a05:6e02:138e:b0:374:9916:92 with SMTP id e9e14a558f8ab-38a5a0798e5mr48267805ab.22.1720567217239; Tue, 09 Jul 2024 16:20:17 -0700 (PDT) Original-Received: from localhost ([68.235.43.165]) by smtp.gmail.com with ESMTPSA id e9e14a558f8ab-38a49461194sm6409205ab.20.2024.07.09.16.20.16 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Jul 2024 16:20:16 -0700 (PDT) Content-Disposition: inline Received-SPF: pass client-ip=2607:f8b0:4864:20::12a; envelope-from=ravijdelia@gmail.com; helo=mail-il1-x12a.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Tue, 09 Jul 2024 22:19:06 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:288660 Archived-At: --karrhczy337jpvcr Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline At unpredictable times while editing c++ files, emacs will segfault. I haven't been able to reproduce without lsp-mode, but with how unpredictable this is I don't think that necessarily means much. The problem exists with and without native compilation- this report assumes without. STEPS TO REPRODUCE: - Let '~/minimal' contain the attached init file - Start emacs with 'emacs --init-directory ~/minimal' - Open a c++ file - Edit it, taking care to type quickly and go back to edit within words. I can usually get a crash within 10 minutes, but I haven't been able to iterate enough to figure out exactly what is happening. It's always while typing though, I think in response to a keydown. Attached is the init file I used to reproduce this, and the backtrace. I had issues with the .gdbinit, which I will hopefully address when I get back from vacation. Below is the information from report-emacs-bug: In GNU Emacs 29.4 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.42, cairo version 1.18.0) Windowing system distributor 'The X.Org Foundation', version 11.0.12101013 System Description: Arch Linux Configured using: 'configure --sysconfdir=/etc --prefix=/usr --libexecdir=/usr/lib --with-tree-sitter --localstatedir=/var --with-cairo --disable-build-details --with-harfbuzz --with-libsystemd --with-modules --with-x-toolkit=gtk3 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=3 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -g -ffile-prefix-map=/build/emacs/src=/usr/src/debug/emacs -flto=auto' 'LDFLAGS=-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,-z,pack-relative-relocs -flto=auto'' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG JSON LCMS2 LIBOTF LIBSYSTEMD LIBXML2 M17N_FLT MODULES NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XDBE XIM XINPUT2 XPM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix Major mode: Fundamental Minor modes in effect: corfu-echo-mode: t global-corfu-mode: t override-global-mode: t tooltip-mode: t global-eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t blink-cursor-mode: t buffer-read-only: t line-number-mode: t indent-tabs-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: /usr/share/emacs/site-lisp/xscheme hides /usr/share/emacs/29.4/lisp/progmodes/xscheme Features: (shadow sort mail-extr emacsbug message yank-media dired dired-loaddefs rfc822 mml mml-sec epa derived gnus-util mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils flymake-cc time-date flymake-proc flymake warnings lsp-diagnostics lsp-headerline lsp-icons lsp-modeline lsp-lens view lsp-zig lsp-yang lsp-yaml lsp-xml lsp-wgsl lsp-volar lsp-vimscript lsp-vhdl lsp-vetur lsp-html lsp-verilog lsp-vala lsp-v lsp-typeprof lsp-ttcn3 lsp-trunk lsp-toml lsp-tilt lsp-tex lsp-terraform lsp-svelte lsp-steep lsp-sqls lsp-sql lsp-sorbet lsp-solidity lsp-solargraph lsp-semgrep lsp-rust lsp-ruff-lsp lsp-ruby-syntax-tree lsp-ruby-lsp lsp-rubocop lsp-roslyn lsp-rf lsp-remark lsp-racket lsp-r lsp-qml lsp-pylsp lsp-pyls lsp-pwsh lsp-purescript lsp-pls lsp-php lsp-perlnavigator lsp-perl lsp-openscad lsp-ocaml lsp-nushell lsp-nix lsp-nim lsp-nginx lsp-move lsp-mojo lsp-mint lsp-meson lsp-mdx lsp-marksman lsp-markdown lsp-magik lsp-lua lsp-lisp lsp-kotlin lsp-json lsp-jq lsp-javascript lsp-idris lsp-haxe lsp-hack lsp-groovy lsp-graphql lsp-golangci-lint lsp-glsl lsp-gleam lsp-gdscript lsp-fsharp lsp-fortran lsp-eslint lsp-erlang lsp-emmet lsp-elm lsp-elixir lsp-earthly lsp-dockerfile lsp-dhall lsp-d lsp-cypher lsp-cucumber lsp-css lsp-csharp gnutls lsp-crystal lsp-credo lsp-cobol lsp-cmake lsp-clojure lsp-clangd dom lsp-bufls lsp-go lsp-completion lsp-beancount lsp-bash lsp-awk lsp-autotools lsp-astro lsp-asm lsp-ansible lsp-angular lsp-ada lsp-semantic-tokens lsp-actionscript lsp-mode lsp-protocol xref project tree-widget wid-edit spinner pcase network-stream puny nsm markdown-mode rx color thingatpt noutline outline icons lv inline imenu ht filenotify f s ewoc epg rfc6068 epg-config dash compile text-property-search comint ansi-osc ansi-color ring cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs corfu-echo corfu compat compat-30 cl-extra help-mode use-package use-package-ensure use-package-delight use-package-diminish use-package-bind-key bind-key easy-mmode use-package-core corfu-autoloads compat-autoloads lsp-mode-autoloads ht-autoloads f-autoloads info dash-autoloads lv-autoloads markdown-mode-autoloads s-autoloads spinner-autoloads package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify lcms2 dynamic-setting system-font-setting font-render-setting cairo move-toolbar gtk x-toolkit xinput2 x multi-tty make-network-process emacs) Memory information: ((conses 16 203184 12765) (symbols 48 23270 0) (strings 32 74270 2672) (string-bytes 1 2204500) (vectors 16 48780) (vector-slots 8 757848 20048) (floats 8 190 29) (intervals 56 799 0) (buffers 984 16)) --karrhczy337jpvcr Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="init.el" (setq user-emacs-directory "~/minimal/") (add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/")) (require 'use-package) (use-package lsp-mode :ensure t :commands (lsp lsp-deferred) :init (setq lsp-keymap-prefix "C-c l") ;; Or 'C-l', 's-l' :config (setq lsp-completion-provider :none)) (use-package c-mode :ensure nil :hook (((c++-mode c-mode) . lsp-deferred))) (use-package corfu :ensure t :custom (corfu-auto t) (corfu-auto-delay 0.2) (corfu-auto-prefix 1) (corfu-echo-documentation t) (corfu-min-width 20) :config (global-corfu-mode) (corfu-echo-mode)) (custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. '(package-selected-packages '(use-package))) (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. ) --karrhczy337jpvcr Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=bt-full #0 0x000055555577722b in ?? () No symbol table info available. #1 0x00005555556cc5f1 in ?? () No symbol table info available. #2 0x00005555556dc468 in ?? () No symbol table info available. #3 0x00005555556d1e6b in ?? () No symbol table info available. #4 0x0000555555795192 in ?? () No symbol table info available. #5 0x00005555557b35cc in ?? () No symbol table info available. #6 0x000055555576c41d in ?? () No symbol table info available. #7 0x0000555555705a72 in ?? () No symbol table info available. #8 0x00005555557b35cc in ?? () No symbol table info available. #9 0x000055555576c41d in ?? () No symbol table info available. #10 0x000055555576ccf0 in ?? () No symbol table info available. #11 0x00005555557b35cc in ?? () No symbol table info available. #12 0x000055555576c41d in ?? () No symbol table info available. #13 0x000055555576cfda in ?? () No symbol table info available. #14 0x00005555557b35cc in ?? () No symbol table info available. #15 0x000055555576c41d in ?? () No symbol table info available. #16 0x000055555576cfda in ?? () No symbol table info available. #17 0x00005555557b35cc in ?? () No symbol table info available. #18 0x000055555576c41d in ?? () No symbol table info available. #19 0x000055555576cfda in ?? () No symbol table info available. #20 0x00005555557b35cc in ?? () No symbol table info available. #21 0x000055555576c41d in ?? () No symbol table info available. #22 0x00005555556c9fb5 in ?? () No symbol table info available. #23 0x00005555556ca58d in ?? () No symbol table info available. #24 0x00005555556d5600 in ?? () No symbol table info available. #25 0x00005555557be323 in ?? () No symbol table info available. #26 0x00005555556cebe7 in ?? () No symbol table info available. #27 0x00005555556d0ec6 in ?? () No symbol table info available. #28 0x00005555556dd163 in ?? () No symbol table info available. #29 0x00005555556c656f in ?? () No symbol table info available. #30 0x000055555575afbe in ?? () No symbol table info available. #31 0x00005555556c3bc6 in ?? () No symbol table info available. #32 0x000055555575af18 in ?? () No symbol table info available. #33 0x00005555556c62eb in ?? () No symbol table info available. #34 0x000055555583e6cf in ?? () No symbol table info available. #35 0x00005555556c841d in ?? () No symbol table info available. #36 0x0000555555588d4d in ?? () No symbol table info available. #37 0x00007ffff5acac88 in __libc_start_call_main (main=main@entry=0x5555555868c0, argc=argc@entry=4, argv=argv@entry=0x7fffffffe148) at ../sysdeps/nptl/libc_start_call_main.h:58 self = result = unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140737488347464, 8312541994804177299, 4, 0, 140737354125312, 93824995730904, 8312541994810468755, 8312519293894912403}, mask_was_saved = 0}}, priv = {pad = { 0x0, 0x0, 0x4, 0x7fffffffe140}, data = {prev = 0x0, cleanup = 0x0, canceltype = 4}}} not_first_call = #38 0x00007ffff5acad4c in __libc_start_main_impl (main=0x5555555868c0, argc=4, argv=0x7fffffffe148, init=, fini=, rtld_fini=, stack_end=0x7fffffffe138) at ../csu/libc-start.c:360 No locals. #39 0x000055555558a2a5 in ?? () No symbol table info available. --karrhczy337jpvcr--