unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
* bug#12892: ‘gc-stats’ w/o ‘bytes-malloced’
@ 2012-11-15  8:42 Thien-Thi Nguyen
  2013-03-05 17:52 ` Andy Wingo
  0 siblings, 1 reply; 8+ messages in thread
From: Thien-Thi Nguyen @ 2012-11-15  8:42 UTC (permalink / raw)
  To: 12892


[-- Attachment #1.1: Type: text/plain, Size: 742 bytes --]

In pre-2.x Guile, ‘gc-stats’ returns an alist w/ keys:

 gc-time-taken
 cells-allocated
 total-cells-allocated
 cell-heap-size
 bytes-malloced
 gc-malloc-threshold
 gc-times
 gc-mark-time-taken
 cells-marked
 cells-swept
 malloc-yield
 cell-yield
 protected-objects
 cell-heap-segments

In Guile 2.0.6, the keys are now:

 gc-time-taken
 heap-size
 heap-free-size
 heap-total-allocated
 heap-allocated-since-gc
 protected-objects gc-times

I think the NEWS should mention this change and the documentation should
summarize what the fields mean.  Practically speaking, i am interested
mostly in the 2.x equivalent for pre-2.x ‘bytes-malloced’, as its lack
causes Guile-SDL to fail "make check DEBUG=1":


[-- Attachment #1.2: .ttn.make-check.log.gz --]
[-- Type: application/octet-stream, Size: 5325 bytes --]

[-- Attachment #1.3: Type: text/plain, Size: 649 bytes --]


by tripping up proc:

 (define (malloced)
   ;; prudence or superstition?  you be the judge!
   (gc) (gc)
   (assq-ref (gc-stats) 'bytes-malloced))
 
in test/leak.scm.  A related issue is how the error is reported.  It
seems strange that the file is "unknown".

-- 
Thien-Thi Nguyen ..................................... GPG key: 4C807502
.                  NB: ttn at glug dot org is not me                   .
.                 (and has not been since 2007 or so)                  .
.                        ACCEPT NO SUBSTITUTES                         .
........... please send technical questions to mailing lists ...........

[-- Attachment #2: Type: application/pgp-signature, Size: 197 bytes --]

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

end of thread, other threads:[~2013-03-13 11:09 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-15  8:42 bug#12892: ‘gc-stats’ w/o ‘bytes-malloced’ Thien-Thi Nguyen
2013-03-05 17:52 ` Andy Wingo
     [not found]   ` <87fw09oz2w.fsf@zigzag.favinet>
2013-03-06  7:00     ` Andy Wingo
     [not found]       ` <87boaxotz6.fsf@zigzag.favinet>
2013-03-06 16:03         ` Andy Wingo
     [not found]           ` <87y5e0nxa0.fsf@zigzag.favinet>
2013-03-07  6:53             ` Andy Wingo
     [not found]               ` <87txono0k2.fsf@zigzag.favinet>
2013-03-07 19:21                 ` Andy Wingo
2013-03-07 20:05                   ` Thien-Thi Nguyen
2013-03-13 11:09           ` Andy Wingo

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).