unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#46797: mac_font_shape EXC_BAD_ACCESS
@ 2021-02-26 16:30 Jimmy Yuen Ho Wong
  2021-02-26 19:03 ` Alan Third
  0 siblings, 1 reply; 4+ messages in thread
From: Jimmy Yuen Ho Wong @ 2021-02-26 16:30 UTC (permalink / raw)
  To: 46797

Emacs crash on the NSPort of emacs27 HEAD, here's the LLDB info:

Process 94921 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason =
EXC_BAD_ACCESS (code=1, address=0x7ffeefc00000)
    frame #0: 0x00000001003abd3a
Emacs`mac_font_shape(font=0x000000011fb480c0, string=@"𝆺𝅥𝅯𝉂\0\0\0\0",
glyph_layouts=0x00007ffeefbe9a50, glyph_len=8, dir=DIR_UNKNOWN) at
macfont.m:3754:34
   3751               struct mac_glyph_layout *gl =
   3752                 glbuf + range.location + range.length;
   3753
-> 3754               if (gl->comp_range.length
   3755                   > comp_range.location + comp_range.length)
   3756                 comp_range.length = gl->comp_range.length -
comp_range.location;
   3757               min_location = gl->comp_range.location;
Target 0: (Emacs) stopped.
(lldb) bt --all
error: bt [<digit> | all]
(lldb) bt all
* thread #1, queue = 'com.apple.main-thread', stop reason =
EXC_BAD_ACCESS (code=1, address=0x7ffeefc00000)
  * frame #0: 0x00000001003abd3a
Emacs`mac_font_shape(font=0x000000011fb480c0, string=@"𝆺𝅥𝅯𝉂\0\0\0\0",
glyph_layouts=0x00007ffeefbe9a50, glyph_len=8, dir=DIR_UNKNOWN) at
macfont.m:3754:34
    frame #1: 0x00000001003a529e
Emacs`macfont_shape(lgstring=0x0000000106e2f005,
direction=0x0000000000000000) at macfont.m:3000:16
  thread #4, name = 'gmain'
    frame #0: 0x00007fff203211fe libsystem_kernel.dylib`__select + 10
    frame #1: 0x0000000101f4cbef libglib-2.0.0.dylib`g_poll + 505
    frame #2: 0x0000000101f40a3e
libglib-2.0.0.dylib`g_main_context_iterate + 340
    frame #3: 0x0000000101f40aec
libglib-2.0.0.dylib`g_main_context_iteration + 55
    frame #4: 0x0000000101f41b99 libglib-2.0.0.dylib`glib_worker_main + 30
    frame #5: 0x0000000101f620bd libglib-2.0.0.dylib`g_thread_proxy + 90
    frame #6: 0x00007fff2034d950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2034947b libsystem_pthread.dylib`thread_start + 15
  thread #7
    frame #0: 0x00007fff203211fe libsystem_kernel.dylib`__select + 10
    frame #1: 0x000000010036dd4d Emacs`-[EmacsApp
fd_handler:](self=0x000000010532b7f0, _cmd="fd_handler:",
unused=0x0000000000000000) at nsterm.m:6066:20
    frame #2: 0x00007fff211c9e1d Foundation`__NSThread__start__ + 1042
    frame #3: 0x00007fff2034d950 libsystem_pthread.dylib`_pthread_start + 224
    frame #4: 0x00007fff2034947b libsystem_pthread.dylib`thread_start + 15
  thread #9, name = 'com.apple.NSEventThread'
    frame #0: 0x00007fff20318e7e libsystem_kernel.dylib`mach_msg_trap + 10
    frame #1: 0x00007fff203191f0 libsystem_kernel.dylib`mach_msg + 60
    frame #2: 0x00007fff20445bf7 CoreFoundation`__CFRunLoopServiceMachPort + 316
    frame #3: 0x00007fff204442ca CoreFoundation`__CFRunLoopRun + 1315
    frame #4: 0x00007fff204436ce CoreFoundation`CFRunLoopRunSpecific + 563
    frame #5: 0x00007fff22de97c6 AppKit`_NSEventThread + 124
    frame #6: 0x00007fff2034d950 libsystem_pthread.dylib`_pthread_start + 224
    frame #7: 0x00007fff2034947b libsystem_pthread.dylib`thread_start + 15
  thread #293
    frame #0: 0x00007fff2031a53e libsystem_kernel.dylib`__workq_kernreturn + 10
    frame #1: 0x0019a19a00004000
    frame #2: 0x00007fff20349467 libsystem_pthread.dylib`start_wqthread + 15
(lldb) vars
error: 'vars' is not a valid command.
(lldb) var
(CTFontRef) font = 0x000000011fb480c0
(CFStringRef) string = 0x0000000110d6b1c0 @"𝆺𝅥𝅯𝉂\0\0\0\0"
(mac_glyph_layout *) glyph_layouts = 0x00007ffeefbe9a50
(CFIndex) glyph_len = 8
(lgstring_direction) dir = DIR_UNKNOWN
(CFIndex) used = 4
(CFIndex) result = 0
(CTLineRef) ctline = 0x00000001242fa0a0
(CFArrayRef) ctruns = 0x0000000110da2e10 @"2 elements"
(CFIndex) k = 0
(CFIndex) ctrun_count = 2
(CGFloat) total_advance = 0
(CFIndex) total_glyph_count = 0
(CTRunRef) ctrun = 0x00000001242f9d00
(CFIndex) i = 14
(CFIndex) min_location = 8458716092896928869
(CFIndex) glyph_count = 1
(mac_glyph_layout *) glbuf = 0x00007ffeefbe9a50
(CFRange) string_range = location=0 length=2
(CFRange) comp_range = location=9223372036854775807 length=0
(CFRange) range = location=1142 length=493
(CFIndex *) permutation = 0x0000000000000000
(mac_glyph_layout *) gl = 0x00007ffeefbffff8


Jimmy Yuen Ho Wong





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#46797: mac_font_shape EXC_BAD_ACCESS
  2021-02-26 16:30 bug#46797: mac_font_shape EXC_BAD_ACCESS Jimmy Yuen Ho Wong
@ 2021-02-26 19:03 ` Alan Third
  2021-02-27  5:07   ` Jimmy Yuen Ho Wong
  0 siblings, 1 reply; 4+ messages in thread
From: Alan Third @ 2021-02-26 19:03 UTC (permalink / raw)
  To: Jimmy Yuen Ho Wong; +Cc: 46797

On Fri, Feb 26, 2021 at 04:30:13PM +0000, Jimmy Yuen Ho Wong wrote:
> Emacs crash on the NSPort of emacs27 HEAD, here's the LLDB info:
> 
> Process 94921 stopped
> * thread #1, queue = 'com.apple.main-thread', stop reason =
> EXC_BAD_ACCESS (code=1, address=0x7ffeefc00000)
>     frame #0: 0x00000001003abd3a
> Emacs`mac_font_shape(font=0x000000011fb480c0, string=@"𝆺𝅥𝅯𝉂\0\0\0\0",
> glyph_layouts=0x00007ffeefbe9a50, glyph_len=8, dir=DIR_UNKNOWN) at
> macfont.m:3754:34
>    3751               struct mac_glyph_layout *gl =
>    3752                 glbuf + range.location + range.length;
>    3753
> -> 3754               if (gl->comp_range.length
>    3755                   > comp_range.location + comp_range.length)
>    3756                 comp_range.length = gl->comp_range.length -
> comp_range.location;
>    3757               min_location = gl->comp_range.location;
> Target 0: (Emacs) stopped.
> (lldb) bt --all
> error: bt [<digit> | all]
> (lldb) bt all
> * thread #1, queue = 'com.apple.main-thread', stop reason =
> EXC_BAD_ACCESS (code=1, address=0x7ffeefc00000)
>   * frame #0: 0x00000001003abd3a
> Emacs`mac_font_shape(font=0x000000011fb480c0, string=@"𝆺𝅥𝅯𝉂\0\0\0\0",
> glyph_layouts=0x00007ffeefbe9a50, glyph_len=8, dir=DIR_UNKNOWN) at
> macfont.m:3754:34
>     frame #1: 0x00000001003a529e
> Emacs`macfont_shape(lgstring=0x0000000106e2f005,
> direction=0x0000000000000000) at macfont.m:3000:16

The interesting bit here is missing.

Can you repeat the crash and give us a recipe?
-- 
Alan Third





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#46797: mac_font_shape EXC_BAD_ACCESS
  2021-02-26 19:03 ` Alan Third
@ 2021-02-27  5:07   ` Jimmy Yuen Ho Wong
  2021-05-13 11:53     ` Lars Ingebrigtsen
  0 siblings, 1 reply; 4+ messages in thread
From: Jimmy Yuen Ho Wong @ 2021-02-27  5:07 UTC (permalink / raw)
  To: Alan Third, Jimmy Yuen Ho Wong, 46797

All I did was type really fast under emacs-lisp-mode that has company
and company-box setup, I just typed faster than company was able to
show me a completion menu.

Like many emacs crashes and hangs, I have no way of reproducing them
consistently. Given there's not even an lldbinit written, I can't even
debug it effectively. All I can do is run emacs compiled with
debugging information under lldb.

Jimmy

On Fri, Feb 26, 2021 at 7:03 PM Alan Third <alan@idiocy.org> wrote:
>
> On Fri, Feb 26, 2021 at 04:30:13PM +0000, Jimmy Yuen Ho Wong wrote:
> > Emacs crash on the NSPort of emacs27 HEAD, here's the LLDB info:
> >
> > Process 94921 stopped
> > * thread #1, queue = 'com.apple.main-thread', stop reason =
> > EXC_BAD_ACCESS (code=1, address=0x7ffeefc00000)
> >     frame #0: 0x00000001003abd3a
> > Emacs`mac_font_shape(font=0x000000011fb480c0, string=@"𝆺𝅥𝅯𝉂\0\0\0\0",
> > glyph_layouts=0x00007ffeefbe9a50, glyph_len=8, dir=DIR_UNKNOWN) at
> > macfont.m:3754:34
> >    3751               struct mac_glyph_layout *gl =
> >    3752                 glbuf + range.location + range.length;
> >    3753
> > -> 3754               if (gl->comp_range.length
> >    3755                   > comp_range.location + comp_range.length)
> >    3756                 comp_range.length = gl->comp_range.length -
> > comp_range.location;
> >    3757               min_location = gl->comp_range.location;
> > Target 0: (Emacs) stopped.
> > (lldb) bt --all
> > error: bt [<digit> | all]
> > (lldb) bt all
> > * thread #1, queue = 'com.apple.main-thread', stop reason =
> > EXC_BAD_ACCESS (code=1, address=0x7ffeefc00000)
> >   * frame #0: 0x00000001003abd3a
> > Emacs`mac_font_shape(font=0x000000011fb480c0, string=@"𝆺𝅥𝅯𝉂\0\0\0\0",
> > glyph_layouts=0x00007ffeefbe9a50, glyph_len=8, dir=DIR_UNKNOWN) at
> > macfont.m:3754:34
> >     frame #1: 0x00000001003a529e
> > Emacs`macfont_shape(lgstring=0x0000000106e2f005,
> > direction=0x0000000000000000) at macfont.m:3000:16
>
> The interesting bit here is missing.
>
> Can you repeat the crash and give us a recipe?
> --
> Alan Third





^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#46797: mac_font_shape EXC_BAD_ACCESS
  2021-02-27  5:07   ` Jimmy Yuen Ho Wong
@ 2021-05-13 11:53     ` Lars Ingebrigtsen
  0 siblings, 0 replies; 4+ messages in thread
From: Lars Ingebrigtsen @ 2021-05-13 11:53 UTC (permalink / raw)
  To: Jimmy Yuen Ho Wong; +Cc: Alan Third, 46797

Jimmy Yuen Ho Wong <wyuenho@gmail.com> writes:

> All I did was type really fast under emacs-lisp-mode that has company
> and company-box setup, I just typed faster than company was able to
> show me a completion menu.
>
> Like many emacs crashes and hangs, I have no way of reproducing them
> consistently. Given there's not even an lldbinit written, I can't even
> debug it effectively. All I can do is run emacs compiled with
> debugging information under lldb.

This was ten weeks ago, so I guess it's unlikely that there'll be
further progress on this bug report, and I'm closing it.  If further
progress can be made, please respond to the debbugs address and we'll
reopen.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-05-13 11:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-26 16:30 bug#46797: mac_font_shape EXC_BAD_ACCESS Jimmy Yuen Ho Wong
2021-02-26 19:03 ` Alan Third
2021-02-27  5:07   ` Jimmy Yuen Ho Wong
2021-05-13 11:53     ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).