all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Pip Cet <pipcet@protonmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: scratch/igc 90e80a9a53e 6/6: Adjust igc.c code to header changes
Date: Sun, 21 Jul 2024 15:07:24 +0300	[thread overview]
Message-ID: <861q3nc5j7.fsf@gnu.org> (raw)
In-Reply-To: <ZdmR7RrpFQxzSjf9NMjF-67V-7E-2Ttn-efKnk8GBtORJ8Ugq_M85VqBhT6Ffk7AuXpb7YQRzfbnH0AO6HMrqlodaPrd1GpMyEGTLQ7uOsc=@protonmail.com> (message from Pip Cet on Sun, 21 Jul 2024 11:42:41 +0000)

> Date: Sun, 21 Jul 2024 11:42:41 +0000
> From: Pip Cet <pipcet@protonmail.com>
> Cc: emacs-devel@gnu.org
> 
> > Error: error ("Memory exhausted--use M-x save-some-buffers then exit and restart Emacs")
> > dump-emacs-portable("d:/gnu/git/emacs/feature/src/bootstrap-emacs.pdmp")
> > 
> > The last commit that did build was 55670e0.
> 
> Thanks for letting me know! It builds here on 32-bit and 64-bit GNU/Linux systems, so it's possible this is a Windows issue...

Maybe, maybe not.  I see nothing specific to Windows yet.

> > The backtrace from the call to memory_full is below. The reason seems
> > to be the recent changes in igc_dump_finish_obj: the result is that
> > dump_igc_finish_obj wants to write a preposterously large amount of
> > zeros into the dump: 744MB in the backtrace below, but I've seen much
> > larger numbers there, like 1.2GB(!). This causes dump_grow_buffer
> > requests 2GB from the OS, which rightfully fails.
> 
> That all points to an object with a broken MPS header (or none). The question is what kind of object.
> 
> > #8 dump_float (lfloat=<optimized out>, ctx=<optimized out>) at pdumper.c:2381
> > 
> > #9 dump_object (ctx=0x724eb38, ctx@entry=0x724eb3c, object=XIL(0xcbf005))
> > at pdumper.c:3306
> 
> This section puzzles me. If object is a vectorlike (the type bits of 0xcbf005 are 5, so it should be), it should be dumped as a vectorlike, not a float.

Does the below help?

  #4  dump_write (ctx=0x71ceb38, buf=0x71ce848, nbyte=8) at pdumper.c:792
  792     dump_write (struct dump_context *ctx, const void *buf, dump_off nbyte)
  (gdb) p ctx->igc_obj_dumped
  $1 = (void *) 0xc3f000 <Sinternal_show_cursor_p>

> (Also, ctx@entry shouldn't be different from ctx, should it?)

I think this is just GDB trying (and failing) to understand the
complexity of GCC's allocation of the place to hold the value:

  (gdb) fr 9
  #9  dump_object (ctx=0x71ceb38, ctx@entry=0x71ceb3c,
      object=0xc3f005 <Sinternal_show_cursor_p+5>) at pdumper.c:3306
  3306          offset = dump_float (ctx, XFLOAT (object));
  (gdb) info address ctx
  Symbol "ctx" is multi-location:
    Range 0x6d2df0-0x6d2e14: a variable in $eax
    Range 0x6d2e14-0x6d2f84: a variable in $ebx
    Range 0x6d2f84-0x6d2f88: a complex DWARF expression:
       0: DW_OP_GNU_entry_value
	 2: DW_OP_reg0 [$eax]
       3: DW_OP_stack_value

    Range 0x6d2f88-0x6d2f8b: a variable in $eax
    Range 0x6d2f8b-0x6d300a: a variable in $ebx
    Range 0x6d300a-0x6d300e: a complex DWARF expression:
       0: DW_OP_GNU_entry_value
	 2: DW_OP_reg0 [$eax]
       3: DW_OP_stack_value

    Range 0x6d300e-0x6d3bb5: a variable in $ebx
    Range 0x8a1c70-0x8a1c75: a variable in $ebx

From poking inside igc_dump_finish_obj, the value returned by obj_size
here:

	return base + obj_size (h);

is preposterously large.



  reply	other threads:[~2024-07-21 12:07 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-21 10:47 scratch/igc 90e80a9a53e 6/6: Adjust igc.c code to header changes Eli Zaretskii
2024-07-21 11:42 ` Pip Cet
2024-07-21 12:07   ` Eli Zaretskii [this message]
2024-07-21 14:11     ` Pip Cet
2024-07-21 14:25       ` Eli Zaretskii
2024-07-21 16:20         ` Pip Cet
2024-07-21 16:27           ` Eli Zaretskii
2024-07-22 14:35             ` Pip Cet

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=861q3nc5j7.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=pipcet@protonmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.