freenode/#sbcl - IRC Chatlog
Search
14:18:39
borodust
if my lisp image conses too many SAPs (by looking at #'room), what for I should look first? Too much FFI?
14:30:29
scymtym
is the problem the memory lost to SAPs that are retained although they should be garbage or is the problem the CPU time for allocating and collecting the SAPs
15:58:36
borodust
scymtym: it's not the problem per se, cuz they are properly deallocated during garbage collection
16:02:28
scymtym
borodust: i see. i have no good advice then. maybe compile with SPEED 3 and look for SAP boxing notes (I think they say "doing SAP to pointer conversion")
17:18:12
mrcode_
is there a way to make an array of uint8 with sbcl and get an address of an underlying storage or is this something best done with aliens ?
18:17:15
saturn2
mrcode_: i believe you can use sb-sys:vector-sap to get a pointer to the underlying storage
18:34:36
mrcode_
saturn2: cool. thx a lot ! i'm exploring the feasibility of avoiding conversions from aliens to vectors given that they mostly feel like no-ops despite of doing work
19:44:33
|3b|
depends on context, pin + vector-sap might be better for optimizing cases where you don't create the vectors
19:46:20
|3b|
or if you don't care about portability and have long-lived vectors. static-vectors has some annoying limitations due to portability, so you need to explicitly free them but can't distinguish them from normal vectors that don't need freed
20:57:27
scymtym
dougk_: i believe binding the gensym counter to 1 in SB-XC:GET-SETF-EXPANSION breaks SHIFT: (shiftf a b c) macroexpands to (LET* ((#:OUT665 A) (#:NEW1 B) (#:NEW1 C)) (SETQ A #:NEW1) (SETQ B #:NEW1) (VALUES #:OUT665)). do you remember what the justification was?
21:39:48
scymtym
pkhuong: it is not. *print-circle* would have made me realize my mistake. thanks for the hint
21:55:11
fitzsim
I haven't got output from having enabled :sb-show yet; I'm trying to see why the invocation just after "//doing warm init - compilation phase" is segfaulting right away
21:57:30
fitzsim
it seems like sbcl is calling into Lisp, possibly even successfully, and then Lisp very quickly calls back into C
21:58:19
fitzsim
then the mfctr 11 in ppc64-assem.S loads a value into r12 that doesn't make sense and subsequently gets used resulting in a segfault
22:01:14
fitzsim
I haven't been able to figure out what C function it's trying to call yet (hence enabling :sb-show)