unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
From: Artyom Bologov <mail@aartaka.me>
To: Skyler Ferris <skyvine@protonmail.com>
Cc: Artyom Bologov <mail@aartaka.me>, guile-user@gnu.org
Subject: Re: Writing on Guile optimization: what are anon #x... functions?
Date: Mon, 08 Apr 2024 02:26:27 +0400	[thread overview]
Message-ID: <87il0skds3.fsf@aartaka.me> (raw)
In-Reply-To: <712fb121-ed4f-4cbc-adf3-1a0248c2be78@protonmail.com>

Hi Skyler,

> "Previously statprof would show strings like "anon #x1234" for primitives
> written in C."

This made me grep through Guile sources. I found this function:

(define (addr->printable addr pdi)
  (or (and=> (and=> pdi program-debug-info-name) symbol->string)
      (and=> (primitive-code-name addr) symbol->string)
      (string-append "anon #x" (number->string addr 16))))

Seems like any function that's neither named in debug info nor a
built-in one is assigned the anon label. So these might be C functions
indeed.

> It's in the section for changes new to 3.0.3 so if you're on 3.0.2 or 
> below then upgrading might help you get more useful analysis. If you're 
> already on/past 3.0.3 then I'm confused.

I'm on Guile 3.0.9, so now I'm confused too!

Thanks,
--
Artyom.



      reply	other threads:[~2024-04-07 22:26 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-05 20:17 Writing on Guile optimization: what are anon #x... functions? Artyom Bologov
2024-04-05 23:04 ` Olivier Dion
2024-04-06  0:25   ` Artyom Bologov
2024-04-07 20:59 ` Skyler Ferris
2024-04-07 22:26   ` Artyom Bologov [this message]

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

  List information: https://www.gnu.org/software/guile/

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

  git send-email \
    --in-reply-to=87il0skds3.fsf@aartaka.me \
    --to=mail@aartaka.me \
    --cc=guile-user@gnu.org \
    --cc=skyvine@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.
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).