IRC channel logs

2015-01-18.log

back to list of logs

<mark_weaver>I can confidently say that we'll have reasonably full support for r7rs-small, since the work is almost done on the 'r7rs-wip' branch.
<please_help>by the way, is there a way to see why a docket was rejected for r7rs?
<mark_weaver>as far r7rs-large, I don't know, it depends what it looks like.
<mark_weaver>you could look in the mailing list archives
<ijp>jcowan would pretty much add every conceivable function if he could
<mark_weaver> http://gmane.org/find.php?list=gmane.lisp.scheme.reports
<ijp>(and fwiw I've said as much to him)
<mark_weaver>yeah, I've not be impressed with the r7rs-large effort so far.
<mark_weaver>not been*
<davexunit>seems like all the scheme standards are a total mess.
<ijp>ya
<mark_weaver>I agree with what wingo wrote in http://article.gmane.org/gmane.lisp.scheme.reports/4005 and http://article.gmane.org/gmane.lisp.scheme.reports/4019
<mark_weaver>I think we should build on R6RS and SRFIs.
<please_help>Are most people rather happy with the rnrs process? Has no-one considered organizing a separate scheme standard and accompanying committee?
<ijp>that did happen, with the usual results
<ijp>I think larceny is the only implementation that advertises ERR5RS support
<ijp>please_help: the problem isn't the lack of people who will write standards, but people who will write *to* standards
<mark_weaver>well said
<zacts>hum..
<ijp>looks like pfds adds up to just over 5000 lines of portable scheme these days
<zacts>can guile be compiled down to machine code?
<zacts>or should I use another scheme implementation for that?
***DeeEff_ is now known as DeeEff
<DeeEff>zacts: AFAIK guile doesn't compile to machine code explicitly, given that Guile itself is a VM.
<zacts>ah ok
<DeeEff>In fact, there are few scheme implementations that do compile to machine code
<DeeEff>the closest I know of is CHICKEN scheme, which compiles to C first and then to machine code
<zacts>ah ok
<zacts>what is stalin?
<zacts>does it compile to machine code?
<DeeEff>stalin does, but it doesn't fully support R5RS scheme IIRC
<DeeEff>it's a minimal subset of scheme, and has an aggressive optimizer when compiling
<DeeEff>Is stalin still in active development though?
<DeeEff>IIRC there were forks made of it because it hasn't seen any progress after R5RS
<DeeEff>(I could be wrong, for what it's worth I'm just going off memory)
<zacts>huh
<zacts>well, cool
<zacts>perhaps I could improve something like stalin one day
<zacts>or guile
<zacts>I'm interested in both interpreters and compilers
***_zxq9_ is now known as zettoekusukyuuna
***zettoekusukyuuna is now known as _zxq9_
***_zxq9_ is now known as zxq9
<civodul>Hello Guilers!
<artyom-poptsov>Hi civodul
<please_help>Is there an unwind-protect equivalent for guile?
<civodul>please_help: yes, 'dynamic-wind'
<civodul>it's from R5RS
<please_help>right, thanks
<please_help>For some reason, I have a C function that works in guile without segfaulting if and only if I add a printf statement before returning.
<please_help>the function is meant to close a file and doesn't return anything
<please_help>any idea why?
<wingo>please_help: pastebin?
<mark_weaver>if it's a C function that's meant to called from Scheme directly, then it needs to return some SCM value. use SCM_UNSPECIFIED if nothing else is appropriate. if you didn't return anything, maybe Guile is seeing a garbage SCM value being returned, which could cause a crash.
<mark_weaver>(and that kind of thing could be affected by what you do before returning)
<mark_weaver>*meant to be
*mark_weaver goes afk
<please_help>wingo http://pastebin.com/xKMMJV0h
<please_help>mark_weaver, ok I'll give it a try; didn't know it was mandatory to retunr something.
<wingo>what mark_weaver said
<please_help>that did it
<please_help>thanks
<wingo>tx mark :)
<mark_weaver>np!
<davexunit>is it possible to attach documentation to any scheme object, or is it just for procedures?
<ijp>in theory, any object
<ijp>object-documentation from ice-9 documentation is just an object-property, but that's slightly different from what we do for procedures
<ijp>the latter have special support in tree-il
*wingo added slot definition objects to goops
<wingo>hum, slot-ref still 2.5x slower in scheme (golfed down from 10x slower)
<wingo>more inlining needed
<Rashack>wingo: i asked about ZeroMQ (as "kjell") a couple of days ago
<Rashack>and saw later that you started talking about ownership/maintenance
<Rashack>i'm not sure i'm the right person for that, even though there are interesting aspects to it
<Rashack>anyway, I got it to compile and working with version 3.2
<Rashack>wingo: not seeing you here for a while, i decided to make the code available
<Rashack>wingo: https://github.com/rashack/guile-zeromq-3
<Rashack>let me know if you want me to take it down or...
<wingo>Rashack: dunno, i have no intention of using whatever zeromq wrapper i had
<wingo>better to wrap the newest version, git has the old versions
<wingo>lmk your gitorious user id and you can be admin on that project
<wingo>if only to put in a notice redirecting users to your github
<wingo>but feel free to have the project name, etc
<Rashack>wingo: i have no gitorious account, is that the official guile repo site?
<wingo>that's the repo for my guile zeromq thing
<wingo>s/my/the old/
<Rashack>ok
<Rashack>oh, while you're here
<Rashack>there is a file missing (?): autogen-support.sh
<wingo>hmm
<Rashack>that's referenced from autogen.sh
<Rashack>i found it in one of your other repos (if i recall correctly)
<wingo>yeah i used to use that, then i switched to just use autoreconf -vif
<Rashack>but i'm not sure if it's the "right" one
<wingo>so i guess autogen.sh should just call "autoreconf -vif"
<wingo>instead of whatever it's doing now
<Rashack>ok, i have little experience with autoconf
<wingo>lemme push that just to clear that up...
<Rashack>sweet
<Rashack>there is also a reference to guile-cairo, i'm guressing you "borrowed heavily" from there? ;)
<wingo>probably :)
<wingo>pushed that autogen fix
<wingo>but lmk your gitorious id once you get that set up and i'll add you on the project so you can take over, even if just to link to github :)
<Rashack>another thing, the html manual on gitourios seems to have a somewhat broken formatting
<Rashack>ok, i'll do that
<Rashack>wingo: created an account, same login as my nick
<wingo>Rashack: can you admin https://gitorious.org/guile-zmq now?
<wingo>you should be able to edit anything i think
<wingo>you can transfer the project to you from the "guile-hackers" group if you need to, otherwise it could be fine to leave it like it is, dunno
<Rashack>looks like I can administrate it
<Rashack>wingo: i'm thinking i might clean up "as little as possible", and link to a version 3.2/4... on github perhaps
<Rashack>what do you think about that?
<wingo>fine by me, you're the boss :)
<Rashack>and touch as little as possible, for people that might be using you version (however unlikely)
<Rashack>hehe, ok
<Rashack>thanks!
<wingo>thank you! happy hacking :)
<please_help>I have some trouble with bytevectors
<please_help> http://pastebin.com/eZygMmbv
<please_help>I should get 784 but I get a very large number instead (index 0 works as expected)
<DeeEff>Hey guys, I have a quick question regarding par-map vs n-par-map. Specifically, what does par-map do differently and why is it often slower?
<Rashack>please_help: (bytevector-u64-ref bv 8 (endianness little))
<DeeEff>as an e.g.: (par-map (lambda (x) (sleep 3) (* x x)) (iota 10)) vs (n-par-map 8 (lambda (x) (sleep 3) (* x x)) (iota 10))
<DeeEff>moreover, as an extreme case, it appears that n-par-map doesn't even perform the full "sleep" function if you set the number of threads to something unreasonable, like 400
<ijp>please_help: as Rashack points out, the index is not scaled to the size of the bytevector
<DeeEff>Just for reference of some things I tried: http://paste.lisp.org/display/145270
<please_help>thanks ijp, rashack
<Rashack>DeeEff: i think par-map restricts the number of parallell threads based on current-processor-count
<Rashack>DeeEff: and your call to n-par-map tells it to use 8
<Rashack>moreover, (current-processor-count) returns 4 on my machine, which is probably fully capable of running 8 threads
<Rashack>DeeEff: when you do (n-par-map 100 (lambda (x) (sleep 3) (* x x)) (iota 100)) 100 threads are started, and all of them sleep and thus yield the processing power to other threads, starting 100 threads is fast, all of them sleep for a short while
<Rashack>DeeEff: https://www.gnu.org/software/guile/manual/html_node/Parallel-Forms.html has it all
<Rashack>DeeEff: try (sleep 1) and experiment with (iota x) and let x vary around multiples of (current-processor-count). It'll be quite obvious from the running time how many threads are running in parallel for par-map (fixed thread pool as opposed to dynamic thread pool for n-par-map)
<DeeEff>Rashack: thanks for the thorough explanation
<DeeEff>(sorry for idling)
<DeeEff>in any case, how come using 400 threads with n-par-map forces it to occassionally run in < 3 seconds? wouldn't at the very least, the operation have to take 3 seconds if I specify sleep 3? Even if they were perfectly parallel, the 3 second overhead should still be visible.