From: Daniel Colascione <dancol@dancol.org>
To: Paul Eggert <eggert@cs.ucla.edu>
Cc: Stefan Monnier <monnier@IRO.UMontreal.CA>, emacs-devel@gnu.org
Subject: Re: inlinable functions instead of macros
Date: Sat, 18 Aug 2012 15:15:12 -0700 [thread overview]
Message-ID: <503013F0.1020300@dancol.org> (raw)
In-Reply-To: <502EDAF3.6030005@cs.ucla.edu>
[-- Attachment #1: Type: text/plain, Size: 1465 bytes --]
On 8/17/12 4:59 PM, Paul Eggert wrote:
> On 08/17/2012 04:48 PM, Stefan Monnier wrote:
>> While inlinable functions are much cleaner than macros, they have
>> a very serious downside: you just end up with
>>
>> lisp.h:2416: Emacs fatal error: assertion failed: found == !EQ (blv->defcell, blv->valcell)
>>
>> I.e. the file&line info is always the same rather than giving the
>> file&line where the inlinable function was called.
>
> On systems that use glibc we could adjust eassert so that it
> also prints a backtrace, using glibc's 'backtrace' function. See
> <http://www.gnu.org/software/libc/manual/html_node/Backtraces.html>.
> This would not be quite the same thing, as it would print function
> names, insn offsets, and return addresses; but it would recapture
> some of the ground lost here, and the backtrace info would in some
> cases be more useful than what we have now.
On Windows, we solved this problem a long time ago by teaching the
operating system itself how to walk stack frames. When a program
crashes, the OS captures a minidump containing the faulting stack,
instruction pointer, register contents, and (optionally) things like
data segments. If you have one of these minidumps, you don't need
particularly good assertion-failure output: you have everything you
need in the minidump, which you can load into the debugger and examine.
I hear Google's breakpad provides similar facilities for other systems.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 235 bytes --]
next prev parent reply other threads:[~2012-08-18 22:15 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-17 23:48 inlinable functions instead of macros Stefan Monnier
2012-08-17 23:59 ` Paul Eggert
2012-08-18 22:15 ` Daniel Colascione [this message]
2012-08-18 22:55 ` John Yates
2012-08-19 4:22 ` Richard Stallman
2012-08-21 17:50 ` Stefan Monnier
2012-08-22 9:24 ` C backtraces for Emacs Paul Eggert
2012-08-22 16:01 ` Eli Zaretskii
2012-08-22 16:39 ` Paul Eggert
2012-08-23 0:40 ` Daniel Colascione
2012-08-23 16:55 ` Eli Zaretskii
2012-08-24 10:48 ` Paul Eggert
2012-08-25 4:41 ` Paul Eggert
2012-08-25 5:57 ` Eli Zaretskii
2012-08-22 9:28 ` inlinable functions instead of macros Paul Eggert
2012-08-22 9:48 ` Andreas Schwab
2012-08-22 14:31 ` Stefan Monnier
2012-08-24 21:37 ` Paul Eggert
2012-08-25 1:38 ` Tom Tromey
2012-08-25 2:58 ` Paul Eggert
2012-08-25 5:35 ` Eli Zaretskii
2012-08-25 20:13 ` Tom Tromey
2012-08-26 4:42 ` Paul Eggert
2012-08-25 2:05 ` Stefan Monnier
2012-08-26 5:31 ` Paul Eggert
2012-08-22 16:03 ` Eli Zaretskii
2012-08-18 19:08 ` Richard Stallman
2012-08-18 20:57 ` Paul Eggert
2012-08-18 21:03 ` Eli Zaretskii
2012-08-18 21:31 ` Paul Eggert
2012-08-19 2:45 ` Eli Zaretskii
2012-08-18 21:14 ` Óscar Fuentes
2012-08-19 17:28 ` Florian Weimer
2012-08-20 20:38 ` Sam Steingold
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=503013F0.1020300@dancol.org \
--to=dancol@dancol.org \
--cc=eggert@cs.ucla.edu \
--cc=emacs-devel@gnu.org \
--cc=monnier@IRO.UMontreal.CA \
/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.