| delorie.com/archives/browse.cgi | search |
| X-Recipient: | archive-cygwin AT delorie DOT com |
| X-Original-To: | cygwin AT cygwin DOT com |
| Delivered-To: | cygwin AT cygwin DOT com |
| DMARC-Filter: | OpenDMARC Filter v1.4.1 sourceware.org E5490396E471 |
| Authentication-Results: | sourceware.org; |
| dmarc=none (p=none dis=none) header.from=maxrnd.com | |
| Authentication-Results: | sourceware.org; spf=none smtp.mailfrom=maxrnd.com |
| Subject: | Re: many cygwin shells/tools (tcsh, fish, bash, and zsh) crashing |
| STATUS_ACCESS_VIOLATION | |
| From: | Mark Geisert <mark AT maxrnd DOT com> |
| To: | cygwin AT cygwin DOT com |
| References: | <CAJtSMguEyZ=cyVrfigEnBVM1JdRG04sk4A=nxh6+W6w_ZvbuQw AT mail DOT gmail DOT com> |
| <0a68361c-0bca-c2d0-e122-ede519e03e01 AT SystematicSw DOT ab DOT ca> | |
| <CAJtSMguC=gPdA=EUj0Gf=in6GA52EY6M9R4_F7=fARR9Mb6LAw AT mail DOT gmail DOT com> | |
| <c4b69d0f-89c9-c9b6-097a-9ad91a449e25 AT SystematicSw DOT ab DOT ca> | |
| <CAJtSMgvHBPUxZ_WZ+_QTABj06XsOxdexrKEkhV7kRZ+-zB7u+w AT mail DOT gmail DOT com> | |
| <6cfbde9b-16ff-5de0-a040-8dcfb5d54bc3 AT SystematicSw DOT ab DOT ca> | |
| <CAJtSMgukBj0uwB3fY9+JzshQLJmgbOv1NiishNC8BuPwYW4S3Q AT mail DOT gmail DOT com> | |
| <3b947ca2-d86d-90f7-1270-2796e55bbbd6 AT maxrnd DOT com> | |
| Message-ID: | <08cdda56-2994-ae30-d508-9491ad24422f@maxrnd.com> |
| Date: | Tue, 10 Aug 2021 22:27:08 -0700 |
| User-Agent: | Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 |
| Firefox/52.0 SeaMonkey/2.49.4 | |
| MIME-Version: | 1.0 |
| In-Reply-To: | <3b947ca2-d86d-90f7-1270-2796e55bbbd6@maxrnd.com> |
| X-Spam-Status: | No, score=-3.9 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, |
| KAM_LAZY_DOMAIN_SECURITY, NICE_REPLY_A, SPF_HELO_NONE, SPF_NONE, TXREP, | |
| WEIRD_PORT autolearn=no autolearn_force=no version=3.4.4 | |
| X-Spam-Checker-Version: | SpamAssassin 3.4.4 (2020-01-24) on |
| server2.sourceware.org | |
| X-BeenThere: | cygwin AT cygwin DOT com |
| X-Mailman-Version: | 2.1.29 |
| List-Id: | General Cygwin discussions and problem reports <cygwin.cygwin.com> |
| List-Unsubscribe: | <https://cygwin.com/mailman/options/cygwin>, |
| <mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe> | |
| List-Archive: | <https://cygwin.com/pipermail/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-request AT cygwin DOT com?subject=help> |
| List-Subscribe: | <https://cygwin.com/mailman/listinfo/cygwin>, |
| <mailto:cygwin-request AT cygwin DOT com?subject=subscribe> | |
| Errors-To: | cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com |
| Sender: | "Cygwin" <cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com> |
| X-MIME-Autoconverted: | from base64 to 8bit by delorie.com id 17B5SWFR003148 |
Replying to myself, ahem...
Mark Geisert wrote:
> Hi David,
>
> David Dyck via Cygwin wrote:
>> On Tue, Aug 10, 2021 at 10:56 AM Brian Inglis wrote:
>>> Apparently that Windows Version is for the Windows 11 Preview.
>>> That appears to be an alpha quality product, from bug fix announcements.
>>> I didn't find anything much useful from MS or articles only features.
>>> You might want to reach out for help via the Windows Feedback Hub,
>>> and/or MS App Assure re compatibility if your org has 150+ licenses.
>>
>> I'm interested in what could be going wrong that would cause only some
>> cygwin programs to fail.
>>
>> I'd be happy to report the issue via Windows Feedback if I could point
>> to something specific.
[...]
> You could try downgrading ncurses via Cygwin setup. Best case: things work. Worst
> case: things break but at a different address within the DLL.
On another branch of this thread David reported that downgrading worked. We still
don't know what the issue with current ncurses is, so I did try the following:
> Another tack could be for somebody *on a working system* install the debuginfo for
> ncurses, figure out the exception's address *in the ncurses installed locally*,
> run 'more' under gdb after setting a breakpoint at that address. Poke around to
> see what ncurses is doing in that area. Maybe it's acting on a Windows result
> that's busted on the Windows preview. Or something else. Good luck with this
> route :-/.
Here's the gdb session from my own Windows 10 machine...
/usr/lib/debug/usr/bin gdb -q more.exe
Reading symbols from more.exe...
(No debugging symbols found in more.exe)
(gdb) b main
No symbol table is loaded. Use the "file" command.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 1 (main) pending.
(gdb) b ncwrap_cur_term <-- I deduced the faulting func using exception address
No symbol table is loaded. Use the "file" command.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 2 (ncwrap_cur_term) pending.
(gdb) r
Starting program: /usr/bin/more.exe
[New Thread 12052.0x388]
[New Thread 12052.0x2750]
[New Thread 12052.0x2d08]
[New Thread 12052.0x275c]
Thread 1 "more" hit Breakpoint 2, ncwrap_cur_term ()
at /usr/src/debug/ncurses-6.1-1.20190727/ncurses/tinfo/lib_cur_term.c:68
68 return NCURSES_SP_NAME(_nc_get_cur_term) (CURRENT_SCREEN);
(gdb) disassem ncwrap_cur_term
Dump of assembler code for function ncwrap_cur_term:
=> 0x00000003cc658a30 <+0>: mov 0x18a39(%rip),%rax # 0x3cc671470
<.refptr.SP>
0x00000003cc658a37 <+7>: mov (%rax),%rcx
0x00000003cc658a3a <+10>: jmp 0x3cc658a10 <_nc_get_cur_term_sp>
End of assembler dump.
(gdb) list
63
64 NCURSES_EXPORT(TERMINAL *)
65 NCURSES_PUBLIC_VAR(cur_term) (void)
66 {
67 #if NCURSES_SP_FUNCS
68 return NCURSES_SP_NAME(_nc_get_cur_term) (CURRENT_SCREEN);
69 #else
70 return NCURSES_SP_NAME(_nc_get_cur_term) (NCURSES_SP_ARG);
71 #endif
72 }
(gdb) bt
#0 ncwrap_cur_term ()
at /usr/src/debug/ncurses-6.1-1.20190727/ncurses/tinfo/lib_cur_term.c:68
#1 0x00000003cc65ac7c in _nc_setupterm (tname=0x80003a055 "xterm", Filedes=1,
errret=0xffffc4e4, reuse=0)
at /usr/src/debug/ncurses-6.1-1.20190727/ncurses/tinfo/lib_setup.c:646
#2 0x00000001004057fd in ?? ()
#3 0x0000000180049cbb in dll_crt0_1 () at /oss/src/winsup/cygwin/dcrt0.cc:1037
#4 0x0000000180047736 in _cygtls::call2 (this=0xffffce00,
func=0x180048c40 <dll_crt0_1(void*)>, arg=0x0, buf=buf AT entry=0xffffcdf0)
at /oss/src/winsup/cygwin/cygtls.cc:40
#5 0x00000001800477e4 in _cygtls::call (func=<optimized out>,
arg=<optimized out>) at /usr/include/w32api/psdk_inc/intrin-impl.h:838
#6 0x0000000000000000 in ?? ()
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
(gdb)
So the fault happens during ncurses initialization. As to why this happens on a
Win 11 Preview and evidently not on Win 10, I have no idea. The code is trying to
get the current value of 'cur_term', but that's not a local variable and I don't
grok what the machine instructions are doing. The fault address is the 2nd mov,
so I believe the fault occurred during the 1st mov.
That is all the help/damage I can do at this point.
Cheers,
..mark
--
Problem reports: https://cygwin.com/problems.html
FAQ: https://cygwin.com/faq/
Documentation: https://cygwin.com/docs.html
Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |