From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Andrea Corallo via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#46256: [feature/native-comp] AOT eln files ignored if run from build tree Date: Thu, 04 Mar 2021 14:49:47 +0000 Message-ID: References: <86blch14qt.fsf@gmail.com> <83h7m84h9g.fsf@gnu.org> <86v9ao5czu.fsf@gmail.com> <86wnutogrh.fsf@gmail.com> <86wnut8fb9.fsf@gmail.com> <861rd1tbpa.fsf@gmail.com> <83pn0km6y3.fsf@gnu.org> <86ft1f8ara.fsf@gmail.com> <83sg5cjdn8.fsf@gnu.org> <83r1kwjcy2.fsf@gnu.org> <83k0qoj9zv.fsf@gnu.org> <83im68j963.fsf@gnu.org> <83tuprhur0.fsf@gnu.org> Reply-To: Andrea Corallo Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36889"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: eliz@gnu.org, andrewjmoreton@gmail.com To: 46256@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Mar 04 16:08:21 2021 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 1lHpaP-0009TH-6W for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 04 Mar 2021 16:08:21 +0100 Original-Received: from localhost ([::1]:48396 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lHpaO-0004x6-4e for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 04 Mar 2021 10:08:20 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:60776) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lHpIi-0003mb-LF for bug-gnu-emacs@gnu.org; Thu, 04 Mar 2021 09:50:04 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:46725) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lHpIg-0000Ak-4C for bug-gnu-emacs@gnu.org; Thu, 04 Mar 2021 09:50:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lHpIg-0006eb-1V for bug-gnu-emacs@gnu.org; Thu, 04 Mar 2021 09:50:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Andrea Corallo Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 04 Mar 2021 14:50:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 46256 X-GNU-PR-Package: emacs X-Debbugs-Original-To: Andrea Corallo via "Bug reports for GNU Emacs, the Swiss army knife of text editors" X-Debbugs-Original-Cc: Eli Zaretskii , andrewjmoreton@gmail.com, 46256@debbugs.gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.161486939825564 (code B ref -1); Thu, 04 Mar 2021 14:50:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 4 Mar 2021 14:49:58 +0000 Original-Received: from localhost ([127.0.0.1]:58271 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lHpIc-0006eG-7b for submit@debbugs.gnu.org; Thu, 04 Mar 2021 09:49:58 -0500 Original-Received: from lists.gnu.org ([209.51.188.17]:37560) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lHpIb-0006e8-9e for submit@debbugs.gnu.org; Thu, 04 Mar 2021 09:49:57 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:60764) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lHpIa-0003ko-7T for bug-gnu-emacs@gnu.org; Thu, 04 Mar 2021 09:49:57 -0500 Original-Received: from mx.sdf.org ([205.166.94.24]:61288) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lHpIW-000063-2o; Thu, 04 Mar 2021 09:49:56 -0500 Original-Received: from mab (ma.sdf.org [205.166.94.33]) by mx.sdf.org (8.15.2/8.14.5) with ESMTPS id 124EnlGN000968 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits) verified NO); Thu, 4 Mar 2021 14:49:47 GMT In-Reply-To: (Andrea Corallo via's message of "Thu, 04 Mar 2021 14:24:47 +0000") Received-SPF: pass client-ip=205.166.94.24; envelope-from=akrl@sdf.org; helo=mx.sdf.org X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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" Xref: news.gmane.io gmane.emacs.bugs:201401 Archived-At: Andrea Corallo via "Bug reports for GNU Emacs, the Swiss army knife of text editors" writes: > I'll keep on using it for what I can and see if something pops-up, > that's still possible. Exactly... I've a reproducer that is most luckily due to the same issue you are observing: emacs -batch -l comp -f batch-native-compile .../emacs/lisp/progmodes/cc-engine.el GC kicks-in and we end-up marking #, we try then to mark its compilation unit but we segfault (backtrace below). Will look more into this as soon as I can. Andrea (gdb) bt #0 0x081ccce3 in symbol_marked_p (s=0x110a02e0) at alloc.c:3982 #1 0x081d1053 in mark_object (arg=XIL(0x8a15f3008a6e8c0)) at alloc.c:6775 #2 0x081d0fe3 in mark_object (arg=XIL(0xa000000008986f10)) at alloc.c:6754 #3 0x081d107f in mark_object (arg=XIL(0xc000000008a78510)) at alloc.c:6781 #4 0x081d1095 in mark_object (arg=XIL(0x351b38)) at alloc.c:6782 #5 0x081d122c in mark_object (arg=XIL(0xc00000000899b4a0)) at alloc.c:6828 #6 0x081d122c in mark_object (arg=XIL(0xc00000000899b470)) at alloc.c:6828 #7 0x081d122c in mark_object (arg=XIL(0xc00000000899b160)) at alloc.c:6828 #8 0x081d10d9 in mark_object (arg=XIL(0x304c78)) at alloc.c:6785 #9 0x081d122c in mark_object (arg=XIL(0xc000000008935960)) at alloc.c:6828 #10 0x081d122c in mark_object (arg=XIL(0xc000000008935420)) at alloc.c:6828 #11 0x081d10d9 in mark_object (arg=XIL(0x273fa0)) at alloc.c:6785 #12 0x081d0d97 in mark_objects (obj=0x89366f8, n=333) at alloc.c:6575 [...] #979 0x081d1024 in mark_object (arg=XIL(0xa0000000086cc2c0)) at alloc.c:6766 #980 0x081d0fe3 in mark_object (arg=XIL(0xa00000000884a410)) at alloc.c:6754 #981 0x081d107f in mark_object (arg=XIL(0xacd34d78)) at alloc.c:6781 #982 0x081d122c in mark_object (arg=XIL(0xc0000000086d6260)) at alloc.c:6828 #983 0x081d1095 in mark_object (arg=XIL(0x5f78)) at alloc.c:6782 #984 0x081d122c in mark_object (arg=XIL(0xc0000000b5918910)) at alloc.c:6828 #985 0x081d0fcd in mark_object (arg=XIL(0xa0000000b59188d4)) at alloc.c:6753 #986 0x081d107f in mark_object (arg=XIL(0x51b8)) at alloc.c:6781 #987 0x081cf4cf in mark_object_root_visitor ( root_ptr=0x8629f6c , type=GC_ROOT_BUFFER_LOCAL_DEFAULT, data=0x0) at alloc.c:5907 #988 0x081cf3dd in visit_vectorlike_root (visitor=..., ptr=0x8629f20 , type=GC_ROOT_BUFFER_LOCAL_DEFAULT) at alloc.c:5858 #989 0x081cf40a in visit_buffer_root (visitor=..., buffer=0x8629f20 , type=GC_ROOT_BUFFER_LOCAL_DEFAULT) at alloc.c:5873 #990 0x081cf428 in visit_static_gc_roots (visitor=...) at alloc.c:5885 #991 0x081cfb2d in garbage_collect () at alloc.c:6105 #992 0x081cf8c0 in maybe_garbage_collect () at alloc.c:6018 #993 0x08200031 in maybe_gc () at lisp.h:5124 #994 0x0820825d in Ffuncall (nargs=2, args=0xbfffbfe0) at eval.c:2993 #995 0x082077b7 in call1 (fn=XIL(0xa000000008a11d18), arg1=XIL(0xc000000008b076f0)) at eval.c:2869 #996 0x08218858 in mapcar1 (leni=352, vals=0xbfffc0d0, fn=XIL(0xa000000008a11d18), seq=XIL(0xc000000008b07cf0)) at fns.c:2742 #997 0x08218e34 in Fmapcar (function=XIL(0xa000000008a11d18), sequence=XIL(0xc000000008b07cf0)) at fns.c:2798 #998 0xb425f1c5 in F627974652d636f6d70696c652d726563757273652d746f706c6576656c_byte_compile_recurse_toplevel_0 () from /home/andcor03/emacs2/native-lisp/28.0.50-92e930fb/bytecomp-12882072-bfe84587.eln #999 0x082087c6 in funcall_subr (subr=0x87ee840, numargs=2, args=0xbfffce40) at eval.c:3086 #1000 0x08208375 in Ffuncall (nargs=3, args=0xbfffce38) at eval.c:3009 #1001 0xb4270738 in F627974652d636f6d70696c652d746f706c6576656c2d66696c652d666f726d_byte_compile_toplevel_file_form_0 () from /home/andcor03/emacs2/native-lisp/28.0.50-92e930fb/bytecomp-12882072-bfe84587.eln #1002 0x0820879f in funcall_subr (subr=0x884a010, numargs=1, args=0xbfffd008) at eval.c:3084 #1003 0x08208375 in Ffuncall (nargs=2, args=0xbfffd000) at eval.c:3009 #1004 0xb426dfc8 in F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_43 () from /home/andcor03/emacs2/native-lisp/28.0.50-92e930fb/bytecomp-12882072-bfe84587.eln #1005 0x0820879f in funcall_subr (subr=0x86c8840, numargs=1, args=0xbfffd1e8) at eval.c:3084 #1006 0x08208375 in Ffuncall (nargs=2, args=0xbfffd1e0) at eval.c:3009 #1007 0xb426eddc in F627974652d636f6d70696c652d66726f6d2d627566666572_byte_compile_from_buffer_0 () from /home/andcor03/emacs2/native-lisp/28.0.50-92e930fb/bytecomp-12882072-bfe84587.eln #1008 0x0820879f in funcall_subr (subr=0x8849e50, numargs=1, args=0xbfffd438) at eval.c:3084 #1009 0x08208375 in Ffuncall (nargs=2, args=0xbfffd430) at eval.c:3009 #1010 0xb426b91a in F627974652d636f6d70696c652d66696c65_byte_compile_file_0 () from /home/andcor03/emacs2/native-lisp/28.0.50-92e930fb/bytecomp-12882072-bfe84587.eln #1011 0x082087c6 in funcall_subr (subr=0x8849dd0, numargs=1, args=0xbfffd608) at eval.c:3086 #1012 0x08208375 in Ffuncall (nargs=2, args=0xbfffd600) at eval.c:3009 #1013 0x0825e5b4 in exec_byte_code (bytestr=XIL(0x8000000008815760), vector=XIL(0xa0000000086b1828), maxdepth=make_fixnum(16), args_template=make_fixnum(257), nargs=1, args=0xbfffded0) at bytecode.c:632 #1014 0x08208c03 in fetch_and_exec_byte_code (fun=XIL(0xa0000000086b1968), syms_left=make_fixnum(257), nargs=1, args=0xbfffdec8) at eval.c:3133 #1015 0x08208fe9 in funcall_lambda (fun=XIL(0xa0000000086b1968), nargs=1, arg_vector=0xbfffdec8) at eval.c:3214 #1016 0x082083d7 in Ffuncall (nargs=2, args=0xbfffdec0) at eval.c:3013 #1017 0x08206ca2 in Fapply (nargs=3, args=0xbfffdec0) at eval.c:2592 #1018 0x082086fa in funcall_subr (subr=0x85db400 , numargs=3, args=0xbfffdec0) at eval.c:3064 #1019 0x08208375 in Ffuncall (nargs=4, args=0xbfffdeb8) at eval.c:3009 #1020 0x0825e5b4 in exec_byte_code (bytestr=XIL(0x80000000b55aa5f8), vector=XIL(0xa0000000089994a0), maxdepth=make_fixnum(14), args_template=make_fixnum(385), nargs=1, args=0xbfffe4e0) at bytecode.c:632 #1021 0x08208c03 in fetch_and_exec_byte_code (fun=XIL(0xa0000000089984c8), syms_left=make_fixnum(385), nargs=1, args=0xbfffe4d8) at eval.c:3133 #1022 0x08208fe9 in funcall_lambda (fun=XIL(0xa0000000089984c8), nargs=1, arg_vector=0xbfffe4d8) at eval.c:3214 #1023 0x082083d7 in Ffuncall (nargs=2, args=0xbfffe4d0) at eval.c:3013 #1024 0xb43033fd in F636f6d702d7370696c6c2d6c6170_comp_spill_lap_0 () from /home/andcor03/emacs2/native-lisp/28.0.50-92e930fb/comp-7672a6ed-2df580e9.eln #1025 0x0820879f in funcall_subr (subr=0x89984f8, numargs=1, args=0xbfffe6c8) at eval.c:3084 #1026 0x08208375 in Ffuncall (nargs=2, args=0xbfffe6c0) at eval.c:3009 #1027 0xb434f53d in F636f6d702d2d6e61746976652d636f6d70696c65_comp__native_compile_0 () from /home/andcor03/emacs2/native-lisp/28.0.50-92e930fb/comp-7672a6ed-2df580e9.eln #1028 0x08208803 in funcall_subr (subr=0x89a70a8, numargs=1, args=0xbfffe8b0) at eval.c:3089 #1029 0x08208375 in Ffuncall (nargs=2, args=0xbfffe8a8) at eval.c:3009 #1030 0xb4350921 in F62617463682d6e61746976652d636f6d70696c65_batch_native_compile_0 () from /home/andcor03/emacs2/native-lisp/28.0.50-92e930fb/comp-7672a6ed-2df580e9.eln #1031 0x08208785 in funcall_subr (subr=0x89a71a8, numargs=0, args=0xbfffeb18) at eval.c:3082 #1032 0x08208375 in Ffuncall (nargs=1, args=0xbfffeb10) at eval.c:3009 #1033 0xb4a2b841 in F636f6d6d616e642d6c696e652d31_command_line_1_0 () from /home/andcor03/emacs2/src/../native-lisp/28.0.50-92e930fb/startup-bbc6ea72-9be7c541.eln #1034 0x0820879f in funcall_subr (subr=0xb55deb90, numargs=1, args=0xbfffeec8) at eval.c:3084 #1035 0x08208375 in Ffuncall (nargs=2, args=0xbfffeec0) at eval.c:3009 #1036 0xb4a2168d in F636f6d6d616e642d6c696e65_command_line_0 () from /home/andcor03/emacs2/src/../native-lisp/28.0.50-92e930fb/startup-bbc6ea72-9be7c541.eln #1037 0x08208785 in funcall_subr (subr=0xb54eccb0, numargs=0, args=0xbffff0b8) at eval.c:3082 #1038 0x08208375 in Ffuncall (nargs=1, args=0xbffff0b0) at eval.c:3009 #1039 0xb4a1c8ce in F6e6f726d616c2d746f702d6c6576656c_normal_top_level_0 () from /home/andcor03/emacs2/src/../native-lisp/28.0.50-92e930fb/startup-bbc6ea72-9be7c541.eln #1040 0x08206353 in eval_sub (form=XIL(0xc0000000b565b170)) at eval.c:2481 #1041 0x082059ee in Feval (form=XIL(0xc0000000b565b170), lexical=XIL(0)) at eval.c:2313 #1042 0x081391f5 in top_level_2 () at keyboard.c:1103 #1043 0x08203347 in internal_condition_case (bfun=0x81391cc , handlers=XIL(0x78), hfun=0x8138ab4 ) at eval.c:1448 #1044 0x08139268 in top_level_1 (ignore=XIL(0)) at keyboard.c:1111 #1045 0x082029e7 in internal_catch (tag=XIL(0xa410), func=0x81391fd , arg=XIL(0)) at eval.c:1198 #1046 0x081390d6 in command_loop () at keyboard.c:1072 #1047 0x08138666 in recursive_edit_1 () at keyboard.c:720 #1048 0x08138841 in Frecursive_edit () at keyboard.c:789 #1049 0x08134e4a in main (argc=7, argv=0xbffff5f4) at emacs.c:2095 Lisp Backtrace: "Automatic GC" (0x0) 0x8a11d18 PVEC_COMPILED "byte-compile-recurse-toplevel" (0xbfffce40) "byte-compile-toplevel-file-form" (0xbfffd008) 0x86c8840 PVEC_SUBR "byte-compile-from-buffer" (0xbfffd438) "byte-compile-file" (0xbfffd608) 0x86b1968 PVEC_COMPILED "apply" (0xbfffdec0) "comp-spill-lap-function" (0xbfffe4d8) "comp-spill-lap" (0xbfffe6c8) "comp--native-compile" (0xbfffe8b0) "batch-native-compile" (0xbfffeb18) "command-line-1" (0xbfffeec8) "command-line" (0xbffff0b8) "normal-top-level" (0xbffff168) (gdb)