ChanServ changed the topic of #picolisp to: PicoLisp language | Channel Log: https://irclog.whitequark.org/picolisp/ | Check also http://www.picolisp.com for more information
shpx has joined #picolisp
ubLIX has quit [Quit: ubLIX]
shpx has quit [Quit: Textual IRC Client: www.textualapp.com]
_whitelogger has joined #picolisp
orivej has quit [Ping timeout: 240 seconds]
_whitelogger has joined #picolisp
_whitelogger has joined #picolisp
shpx has joined #picolisp
shpx has quit [Ping timeout: 240 seconds]
_whitelogger has joined #picolisp
xkapastel has quit [Quit: Connection closed for inactivity]
_whitelogger has joined #picolisp
razzy has quit [Ping timeout: 246 seconds]
razzy has joined #picolisp
orivej has joined #picolisp
razzy has quit [Ping timeout: 252 seconds]
ubLIX has joined #picolisp
razzy has joined #picolisp
_whitelogger has joined #picolisp
razzy has quit [Ping timeout: 268 seconds]
razzy has joined #picolisp
<razzy> hi, my guess picolisp does not have something like profiler.
<Regenaxer> @lib/prof.l
<razzy> hmm, cool!. does it have ussage?
<razzy> i would expect bench everywhere
<razzy> and listing percentage of time spend in sub-expression
<Regenaxer> The syntax of 'prof' is like that of 'trace' and 'debug'
<Regenaxer> and 'unprof' like 'untrace' and 'unbug' :)
<Regenaxer> Then run your program, and then (profile)
<Regenaxer> Seems like it is not documented :(
<Regenaxer> But see (doc 'tick)
<razzy> thx
razzy has quit [Ping timeout: 252 seconds]
ubLIX has joined #picolisp
alexshendi has joined #picolisp
xkapastel has quit [Quit: Connection closed for inactivity]
alexshendi has quit [Ping timeout: 268 seconds]
xkapastel has joined #picolisp
razzy has joined #picolisp
<razzy> it is a mystery to read picolisp code. to the last moment it seem like code is impossible to work. and than it just
<razzy> work. pure artform
<beneroth> keep reading code. the mystery will vanish. the beauty will stay.
<razzy> ah, it is soo painfull
<beneroth> so is hiking, swimming, weight lifting, speaking a foreign language - everything when done without training.
<beneroth> no pain no gain.
<razzy> how fine measurement is tick?
<beneroth> tick is a time measurement unit in computers. One computer instruction cycle.
<beneroth> so the length depends on the hardware/OS.
<razzy> also sucessfull prof returns NIL : (prof 'sgame) -> NIL which is imho not intended
<beneroth> but profiling is usually done in ticks, as you usually compare multiple runs on the same hardware, and you are interested in relative differences, not absolute values.
<beneroth> why not?
<beneroth> all unix tools return 0 on success.
<razzy> eh?
<razzy> (debug 'cost) return T when sucessfull
<razzy> i am ok with tick measurements
<razzy> just got lots of zeros... so no much info there
<beneroth> well do you know what you are looking for?
<razzy> picolisp consistently returning T when sucess
<razzy> imho
<beneroth> well then make your own version of prof.l
<beneroth> just replace the unless with an if ... T
<beneroth> but nobody cares beside you, and nobody cares if you like it or not.
<razzy> sure i do. when time allows. i just think community should know
<beneroth> the community is not interested.
<razzy> and i read somewhere, "even small things make difference" :-)
<razzy> no offence
<beneroth> it's mental masturbation without practical value. when looking at prof.l, its easy to see that it is successful when it does not print an error message.
razzy has quit [Ping timeout: 268 seconds]
razzy has joined #picolisp
<razzy> hm, tick seem to wide interval for my purposes. also nested ticks does not seem to work
<razzy> btw, i consider printing "nothing" very bad sucess message. i think linux send "0" which is not "NIL" no offence
<razzy> bench offer finer resolution than tick by a factor of 10,... hm
<razzy> ok, factor of 5, which still surprise me
<Regenaxer> ret
<Regenaxer> The return value of 'prof' is not interesting
<Regenaxer> it is for the side effect
<Regenaxer> You need to let the program run for a while to see a meaningful profile
<razzy> am i right that tick have problems nesting?
<Regenaxer> nope
<razzy> ok problem on my side
<razzy> it seem like upward tick does not count inside ticks
<razzy> is it intended behaviour?
<Regenaxer> right
<Regenaxer> It measures the time in *that* function, accumulated
<Regenaxer> : (mapc prof '(game move moves cost))
<Regenaxer> -> NIL
<Regenaxer> ...
<Regenaxer> : (go)
<Regenaxer> : (profile)
<Regenaxer> (11495 460 move)
<Regenaxer> (1693 95 cost)
<Regenaxer> (684 31 moves)
<Regenaxer> (128 8 game)
<razzy> ouside tick have 0.0 inner tick have 3300 .2 and 4500 .3
<Regenaxer> So you see most time is spent inside 'move'
<Regenaxer> If you prof functions called *in* move, these functions show up
<Regenaxer> and 'move' uses less time
<razzy> but game should have been more than cost right? because game call cost
<razzy> so it substracting inner ticks
<Regenaxer> right, and move and moves too
<Regenaxer> So the *rest* is shown
<Regenaxer> Experiment with it
<razzy> hmm hmm i see.
<razzy> thx afk
<Regenaxer> me too :)
razzy has quit [Ping timeout: 240 seconds]
razzy has joined #picolisp
alexshendi has joined #picolisp
ubLIX has quit [Quit: ubLIX]
alexshendi has quit [Ping timeout: 240 seconds]
ubLIX has joined #picolisp