From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Aaron Jensen Newsgroups: gmane.emacs.bugs Subject: bug#60220: 29.0.60; macOS 13.1 crash shortly after starting Emacs Date: Thu, 29 Dec 2022 22:54:50 -0500 Message-ID: References: <24A595DF-81D8-47E7-90BC-FCDDB27315E8@gmail.com> <83ilhz2r14.fsf@gnu.org> <83r0wl0z6g.fsf@gnu.org> <204d542c-73e6-243a-f2d5-36b92cfa25ee@cs.ucla.edu> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11010"; mail-complaints-to="usenet@ciao.gmane.io" Cc: gerd.moellmann@gmail.com, Eli Zaretskii , 60220@debbugs.gnu.org To: Paul Eggert Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Dec 30 04:56:16 2022 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 1pB6VE-0002ee-Ck for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 30 Dec 2022 04:56:16 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pB6V2-0000mm-HM; Thu, 29 Dec 2022 22:56:04 -0500 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 1pB6V0-0000mN-UI for bug-gnu-emacs@gnu.org; Thu, 29 Dec 2022 22:56:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pB6V0-0006l2-Mf for bug-gnu-emacs@gnu.org; Thu, 29 Dec 2022 22:56:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pB6V0-0001Fa-AP for bug-gnu-emacs@gnu.org; Thu, 29 Dec 2022 22:56:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Aaron Jensen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 30 Dec 2022 03:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 60220 X-GNU-PR-Package: emacs Original-Received: via spool by 60220-submit@debbugs.gnu.org id=B60220.16723725114743 (code B ref 60220); Fri, 30 Dec 2022 03:56:02 +0000 Original-Received: (at 60220) by debbugs.gnu.org; 30 Dec 2022 03:55:11 +0000 Original-Received: from localhost ([127.0.0.1]:33286 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pB6UA-0001EQ-Lf for submit@debbugs.gnu.org; Thu, 29 Dec 2022 22:55:11 -0500 Original-Received: from mail-pj1-f46.google.com ([209.85.216.46]:33408) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pB6U8-0001EA-IK for 60220@debbugs.gnu.org; Thu, 29 Dec 2022 22:55:09 -0500 Original-Received: by mail-pj1-f46.google.com with SMTP id gv5-20020a17090b11c500b00223f01c73c3so19660509pjb.0 for <60220@debbugs.gnu.org>; Thu, 29 Dec 2022 19:55:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=Tmydkn/0Rttb0VKBu5ojo/FFLeXiAs7uI98onrqoTd8=; b=HZf9uTbMvzJWncYw4veIvt7quWjLHg4rn2/TLSKTlrHSioZL+OL9VuUQ9IJaFTq4rh iPCKBkQuhdJtatZrByiG12yztTHdf1BeEElw3Ii0bDHql3l/DB6fBBHStyLtQ5sGk7dP BIrc3pIe9OcJKDVx23VIMJ6G2jOKvzMhJdo7r+Q0D6tyGl0paVE+LEQDQDLFO4j2XDP6 o0riPtIsag76lci4iHTNVDykUeAF9RVEVoD+9Spmy0+Ww7HvsVVj4zPcUyVnpS40P9xE 7pBCuW0WnUcdU9tzrXYnpnzcBOXR7NIgsErsi8Ikx0uxLNo8yCBw6oibS5EOYyaApOOw 3Yog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Tmydkn/0Rttb0VKBu5ojo/FFLeXiAs7uI98onrqoTd8=; b=dlxJ/OH3TIl87w4xaiHA0Yh9Wakz7ViPt1b4lOEHd3je7JqJvsSEqhZQl/wZR4VSPK 5sx4RzaS7wPs8KuAqiSVbMK6syMO0VB0DBLnyVgfIIfcgW4oykphmi+zsQJvDVyWq87e iBqbJI3Hj5iSqSSd0Oqoa8TyJFCvXyonw+KuXSpB2PnikOyNXfcMPlqjIRlA+14ewn6+ abEoD8K98DNQKHoonENh1yPnT23OwPJtQ3cKkEWXmAmaAEWY/h/EobaQVzMfMvf1myEd YYEI3HsgnoheKnBnhWJ8y2q8GkTJmpKy7rT8ZQTbxYSaC/lezesYDniRM5+10CV/QDDJ 5LsA== X-Gm-Message-State: AFqh2kr+qw1HXTC93BBOK35u4XYYe6RsC4u7AoyW8CLDGYL8xbfziMtr Owo4jRtJSSuDCDmZTsp2AWqvbVZusLBv7WYPtjw= X-Google-Smtp-Source: AMrXdXvdak47VNEHpRKe9dOunTaxhcPn11M5TO1txvQNjam/xEuO1iNAkJQGWl9tdTSDQmBoKrsmMxsrA+68dMUwPJQ= X-Received: by 2002:a17:90b:3a8c:b0:226:1537:5638 with SMTP id om12-20020a17090b3a8c00b0022615375638mr656972pjb.198.1672372502366; Thu, 29 Dec 2022 19:55:02 -0800 (PST) In-Reply-To: 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:252079 Archived-At: On Thu, Dec 29, 2022 at 9:11 PM Aaron Jensen wrote: > > On Thu, Dec 29, 2022 at 8:16 PM Paul Eggert wrote: > > > > On 12/29/22 16:03, Aaron Jensen wrote: > > > Would it make sense to use block_atimers while loading native lisp? If > > > > Might, but it might make more sense not to be dynamically loading code > > during an idle timer. Surely this could cause problems even in > > non-native lisp. Anyway, I suggest consulting a macOS expert before > > doing much experimenting; there's not enough evidence now for me to give > > advice. > > > I reported a bug and opened a discussion on the developer forum. We > will see where that goes. > > I also added printfs on either side of native-elisp-load. When I got a > crash, it was in a magit eln again and from what I can tell, every > "start loading" had a matching "loaded" logged. I don't know that that > definitely rules out the load interrupted theory or not. > > Furthermore, I've been able to crash it in a debugger. I don't know > what to do there though, so I'm not sure how useful that is at this > point. > > Aaron I was able to reproduce it in an after-init hook (so no timers involved) ------------------------------------- Translated Report (Full Report Below) ------------------------------------- Process: Emacs [33253] Path: /opt/homebrew/*/Emacs.app/Contents/MacOS/Emacs Identifier: org.gnu.Emacs Version: Version 29.0.60 (9.0) Code Type: ARM-64 (Native) Parent Process: zsh [69115] Responsible: iTerm2 [64164] User ID: 501 Date/Time: 2022-12-29 22:51:06.9736 -0500 OS Version: macOS 13.1 (22C65) Report Version: 12 Anonymous UUID: CD1F31D7-5E61-2935-643D-55F58CD29C12 Sleep/Wake UUID: F85FABBE-D01F-449A-BF1E-0176C31B6028 Time Awake Since Boot: 210000 seconds Time Since Wake: 128 seconds System Integrity Protection: enabled Crashed Thread: 0 Dispatch queue: com.apple.main-thread Exception Type: EXC_BAD_ACCESS (SIGABRT) Exception Codes: KERN_INVALID_ADDRESS at 0x00000000000000f9 Exception Codes: 0x0000000000000001, 0x00000000000000f9 VM Region Info: 0xf9 is not in any region. Bytes before following region: 105553518919431 REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL UNUSED SPACE AT START ---> MALLOC_NANO (reserved) 600018000000-600020000000 [128.0M] rw-/rwx SM=NUL ...(unallocated) Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 libsystem_kernel.dylib 0x1a6d621b0 __pthread_kill + 8 1 libsystem_pthread.dylib 0x1a6d98cec pthread_kill + 288 2 libsystem_c.dylib 0x1a6c9aa50 raise + 32 3 Emacs 0x100a31aec terminate_due_to_signal + 204 4 Emacs 0x100a322f0 emacs_abort + 20 5 Emacs 0x100a00db0 ns_term_shutdown + 132 6 Emacs 0x1008ecb94 shut_down_emacs + 332 7 Emacs 0x100a31ab4 terminate_due_to_signal + 148 8 Emacs 0x10090f084 handle_fatal_signal + 16 9 Emacs 0x10090f100 deliver_thread_signal + 124 10 Emacs 0x10090d700 deliver_fatal_thread_signal + 12 11 Emacs 0x10090f160 handle_sigsegv + 96 12 libsystem_platform.dylib 0x1a6dc72a4 _sigtramp + 56 13 dyld 0x1a6a99380 lsl::BTree, false>::const_iterator::operator++() + 60 14 dyld 0x1a6a99d54 lsl::BTree, false>::erase(lsl::BTree, false>::const_iterator) + 76 15 dyld 0x1a6a999fc lsl::PersistentAllocator::reserveRange(lsl::BTree::const_iterator&, lsl::Allocator::Buffer) + 264 16 dyld 0x1a6a9a0b0 lsl::PersistentAllocator::allocate_buffer(unsigned long, unsigned long, unsigned long, lsl::Allocator**) + 624 17 dyld 0x1a6a991e0 lsl::Allocator::aligned_alloc(unsigned long, unsigned long) + 180 18 dyld 0x1a6a99230 lsl::Allocator::strdup(char const*) + 48 19 dyld 0x1a6a968b8 dyld4::FileManager::fileRecordForPath(char const*) + 40 20 dyld 0x1a6ab4624 dyld4::Atlas::ProcessSnapshot::Serializer::readMappedFileInfo(std::__1::span&, unsigned long long&, lsl::UUID&, dyld4::FileRecord&) + 132 21 dyld 0x1a6ab3170 dyld4::Atlas::ProcessSnapshot::Serializer::deserialize(std::__1::span) + 928 22 dyld 0x1a6ab2cec dyld4::Atlas::ProcessSnapshot::ProcessSnapshot(lsl::Allocator&, dyld4::FileManager&, bool, std::__1::span) + 304 23 dyld 0x1a6a7ef64 lsl::UniquePtr lsl::Allocator::makeUnique const&>(lsl::EphemeralAllocator&, dyld4::FileManager&, bool&&, std::__1::span const&) + 80 24 dyld 0x1a6a7bafc dyld4::RuntimeState::getCurrentProcessSnapshot() + 96 25 dyld 0x1a6a7b8cc dyld4::RuntimeState::notifyDebuggerLoad(std::__1::span const&) + 72 26 dyld 0x1a6aaaf3c dyld4::APIs::dlopen_from(char const*, int, void*)::$_0::operator()() const + 748 27 dyld 0x1a6aa4968 dyld4::APIs::dlopen_from(char const*, int, void*) + 892 28 Emacs 0x1009b4db0 Fnative_elisp_load + 356 29 Emacs 0x10099088c Fload + 2104 30 Emacs 0x1009925f0 save_match_data_load + 92 31 Emacs 0x10096c928 load_with_autoload_queue + 120 32 Emacs 0x100978d84 Frequire + 560 33 Emacs 0x100968a30 eval_sub + 2236 34 Emacs 0x10096b158 internal_lisp_condition_case + 884 35 Emacs 0x10096889c eval_sub + 1832 36 Emacs 0x100968bac Fprogn + 48 37 Emacs 0x10096a3a8 Fwhile + 80 38 Emacs 0x10096889c eval_sub + 1832 39 Emacs 0x100968bac Fprogn + 48 40 Emacs 0x10096889c eval_sub + 1832 41 Emacs 0x10096889c eval_sub + 1832 42 Emacs 0x100968bac Fprogn + 48 43 Emacs 0x10096e10c funcall_lambda + 1316 44 Emacs 0x10096a724 Ffuncall + 316 45 Emacs 0x100968998 eval_sub + 2084 46 Emacs 0x100968bac Fprogn + 48 47 Emacs 0x10096a2b4 Flet + 840 48 Emacs 0x10096889c eval_sub + 1832 49 Emacs 0x100968bac Fprogn + 48 50 Emacs 0x10096e10c funcall_lambda + 1316 51 Emacs 0x10096a724 Ffuncall + 316 52 Emacs 0x100968998 eval_sub + 2084 53 Emacs 0x100968bac Fprogn + 48 54 Emacs 0x10096889c eval_sub + 1832 55 Emacs 0x10096b158 internal_lisp_condition_case + 884 56 Emacs 0x10096889c eval_sub + 1832 57 Emacs 0x100968bac Fprogn + 48 58 Emacs 0x10096e10c funcall_lambda + 1316 59 Emacs 0x10096a724 Ffuncall + 316 60 Emacs 0x10096d35c run_hook_wrapped_funcall + 28 61 Emacs 0x10096d1f0 run_hook_with_args + 320 62 Emacs 0x100968998 eval_sub + 2084 63 Emacs 0x10096b158 internal_lisp_condition_case + 884 64 Emacs 0x10096889c eval_sub + 1832 65 Emacs 0x100968bac Fprogn + 48 66 Emacs 0x10096a2b4 Flet + 840 67 Emacs 0x10096889c eval_sub + 1832 68 Emacs 0x100968bac Fprogn + 48 69 Emacs 0x10096a3a8 Fwhile + 80 70 Emacs 0x10096889c eval_sub + 1832 71 Emacs 0x100968bac Fprogn + 48 72 Emacs 0x10096a2b4 Flet + 840 73 Emacs 0x10096889c eval_sub + 1832 74 Emacs 0x100968bac Fprogn + 48 75 Emacs 0x10096e10c funcall_lambda + 1316 76 Emacs 0x10096a724 Ffuncall + 316 77 Emacs 0x10096cf28 Fapply + 612 78 Emacs 0x1009ab940 exec_byte_code + 2988 79 Emacs 0x10096a724 Ffuncall + 316 80 startup-bbc6ea72-452f9f58.eln 0x104f8431c F636f6d6d616e642d6c696e65_command_line_0 + 5452 81 Emacs 0x10096a724 Ffuncall + 316 82 startup-bbc6ea72-452f9f58.eln 0x104f80bb8 F6e6f726d616c2d746f702d6c6576656c_normal_top_level_0 + 3156 83 Emacs 0x100968918 eval_sub + 1956 84 Emacs 0x10096ca4c Feval + 88 85 Emacs 0x10096b32c internal_condition_case + 96 86 Emacs 0x1009011c8 top_level_1 + 48 87 Emacs 0x10096ad50 internal_catch + 88 88 Emacs 0x100a31f08 command_loop.cold.1 + 64 89 Emacs 0x1008ef488 command_loop + 152 90 Emacs 0x1008ef344 recursive_edit_1 + 148 91 Emacs 0x1008ef5a8 Frecursive_edit + 264 92 Emacs 0x1008ee924 main + 7484 93 dyld 0x1a6a6fe50 start + 2544 Thread 1: 0 libsystem_pthread.dylib 0x1a6d93e18 start_wqthread + 0 Thread 2: 0 libsystem_pthread.dylib 0x1a6d93e18 start_wqthread + 0 Thread 3:: gmain 0 libsystem_kernel.dylib 0x1a6d64a00 __select + 8 1 libglib-2.0.0.dylib 0x10189b090 g_poll + 424 2 libglib-2.0.0.dylib 0x10188e234 g_main_context_iterate + 340 3 libglib-2.0.0.dylib 0x10188e2fc g_main_context_iteration + 60 4 libglib-2.0.0.dylib 0x10188f694 glib_worker_main + 48 5 libglib-2.0.0.dylib 0x1018b2918 g_thread_proxy + 68 6 libsystem_pthread.dylib 0x1a6d9906c _pthread_start + 148 7 libsystem_pthread.dylib 0x1a6d93e2c thread_start + 8 Thread 4: 0 libsystem_pthread.dylib 0x1a6d93e18 start_wqthread + 0 Thread 5: 0 libsystem_pthread.dylib 0x1a6d93e18 start_wqthread + 0 Thread 6: 0 libsystem_kernel.dylib 0x1a6d5ffa4 __pselect + 8 1 libsystem_kernel.dylib 0x1a6d5fe7c pselect$DARWIN_EXTSN + 64 2 Emacs 0x100a01e90 -[EmacsApp fd_handler:] + 184 3 Foundation 0x1a7d79470 __NSThread__start__ + 716 4 libsystem_pthread.dylib 0x1a6d9906c _pthread_start + 148 5 libsystem_pthread.dylib 0x1a6d93e2c thread_start + 8 Thread 7:: com.apple.NSEventThread 0 libsystem_kernel.dylib 0x1a6d59d70 mach_msg2_trap + 8 1 libsystem_kernel.dylib 0x1a6d6b8a4 mach_msg2_internal + 80 2 libsystem_kernel.dylib 0x1a6d625c4 mach_msg_overwrite + 540 3 libsystem_kernel.dylib 0x1a6d5a0ec mach_msg + 24 4 CoreFoundation 0x1a6e78bc0 __CFRunLoopServiceMachPort + 160 5 CoreFoundation 0x1a6e774ac __CFRunLoopRun + 1232 6 CoreFoundation 0x1a6e76888 CFRunLoopRunSpecific + 612 7 AppKit 0x1aa222410 _NSEventThread + 172 8 libsystem_pthread.dylib 0x1a6d9906c _pthread_start + 148 9 libsystem_pthread.dylib 0x1a6d93e2c thread_start + 8