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
orivej has quit [Ping timeout: 256 seconds]
orivej_ has joined #picolisp
orivej has joined #picolisp
orivej_ has quit [Ping timeout: 264 seconds]
aw- has quit [Quit: Leaving.]
orivej has quit [Ping timeout: 258 seconds]
karswell has joined #picolisp
aw- has joined #picolisp
_whitelogger has joined #picolisp
<Regenaxer> Cool, thanks!
orivej has joined #picolisp
orivej has quit [Ping timeout: 256 seconds]
orivej has joined #picolisp
razzy has joined #picolisp
orivej has quit [Ping timeout: 264 seconds]
orivej has joined #picolisp
orivej has quit [Ping timeout: 260 seconds]
orivej has joined #picolisp
orivej has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
orivej has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
orivej_ has joined #picolisp
orivej has quit [Ping timeout: 246 seconds]
orivej_ has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
orivej has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
<Regenaxer> orivej: It would be nice if you either join or not join ;)
<Regenaxer> It clobbers my screen if you join and leave all day long
<aw-> gaga teag u noticed that too
orivej has quit [Quit: No Ping reply in 180 seconds.]
<aw-> oops*
<aw-> well yeah
<aw-> orivej needs to fix the chat client
orivej has joined #picolisp
<Regenaxer> yeah
orivej has quit [Ping timeout: 256 seconds]
orivej has joined #picolisp
orivej_ has joined #picolisp
orivej has quit [Ping timeout: 264 seconds]
razzy has quit [Quit: Connection closed]
orivej_ has quit [Ping timeout: 256 seconds]
orivej has joined #picolisp
<tankf33der> Regenaxer: struct function finished? i am back to showip code
<Regenaxer> Yes, struct was simple
<Regenaxer> just reuses part of the native machinery
<tankf33der> then back to this example
<tankf33der> http://ix.io/2rLI
<tankf33der> pil64 ok
<tankf33der> pil21 fails.
<Regenaxer> -1 is a float with scale zero?
<Regenaxer> ah, no
orivej has quit [Quit: No Ping reply in 180 seconds.]
<Regenaxer> it is the third arg
orivej has joined #picolisp
<Regenaxer> So it is 3 integers
<Regenaxer> 1, 0, 1
<tankf33der> yeap
orivej has quit [Ping timeout: 246 seconds]
orivej has joined #picolisp
<Regenaxer> doesn't work here, neither pil64 nor pil21
<Regenaxer> returns 9
<Regenaxer> and R = 0
<Regenaxer> 9 must be one of the return values
<Regenaxer> EAI_SERVICE perhaps
orivej has quit [Ping timeout: 240 seconds]
orivej has joined #picolisp
orivej_ has joined #picolisp
orivej has quit [Ping timeout: 240 seconds]
orivej_ has quit [Ping timeout: 272 seconds]
orivej has joined #picolisp
<Regenaxer> Good thing
<tankf33der> Regenaxer: so this is not pil21 issue, right?
<Regenaxer> Most probably
<tankf33der> then i will create tests for combinations
<tankf33der> lets see.
<Regenaxer> ok :)
orivej has quit [Ping timeout: 246 seconds]
orivej has joined #picolisp
orivej has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
karswell has quit [Ping timeout: 258 seconds]
orivej has quit [Ping timeout: 256 seconds]
orivej has joined #picolisp
<tankf33der> Regenaxer: already asked monthes ago and forget again:
<tankf33der> got N from native and should make it unsigned 64 bits, how to do it?
<Regenaxer> 'abs'?
orivej has quit [Ping timeout: 240 seconds]
orivej has joined #picolisp
<Regenaxer> no, you want the highest bit
<tankf33der> yea
<tankf33der> i got 8242820295824506896
<Regenaxer> xor with (hex "8000000000000000") then subtract it
<Regenaxer> hmm, but this is on machine level ;)
<Regenaxer> ie 2s complement
<Regenaxer> So better add the number, then mask with FF...FF
<Regenaxer> or check if lt0 and add 2**64
<Regenaxer> this is more efficient
<Regenaxer> as positive numbers are not changed
orivej has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
<Regenaxer> Hmm, perhaps we should introduce one additional return type?
<Regenaxer> 'P'
<Regenaxer> like 'N', but means "positive" or "pointer"?
<Regenaxer> bbl
<beneroth> U for unsigned integer?
<beneroth> well unisgned long
<tankf33der> http://ix.io/2rME
<tankf33der> question: if i have such a struct how correctly get byte into R ?
<tankf33der> strange 4 and 8 are show there is no paddings.
orivej_ has joined #picolisp
orivej has quit [Ping timeout: 272 seconds]
orivej_ has quit [Ping timeout: 240 seconds]
orivej has joined #picolisp
Blukunfando has joined #picolisp
<Regenaxer> ret
<Regenaxer> beneroth, I think more typically it is a pointer
<Regenaxer> and unsigned are other integers too
Blukunfando has quit [*.net *.split]
root____ has quit [*.net *.split]
<Regenaxer> tankf33der, such structs depend highly on the compiler configuration
orivej has quit [Ping timeout: 256 seconds]
<Regenaxer> even on command line arguments
<Regenaxer> ei. how int's are aligned (padded to 64 bits?)
orivej has joined #picolisp
Blukunfando has joined #picolisp
root____ has joined #picolisp
<tankf33der> Regenaxer: i tried in c
<tankf33der> map is those 4s and 8s
<Regenaxer> ok
<tankf33der> 4 4 4 4 8 8 8 8
<Regenaxer> yes
<tankf33der> without pads
<Regenaxer> 4 ints
<tankf33der> so first 8 is corrupting :)
<tankf33der> should be 16 but i getting huge number
<tankf33der> 8242820295824506896
<Regenaxer> too big for a size ;)
<tankf33der> on pil21 everything is corrupted
<tankf33der> everything is worse
<tankf33der> 63bit
<tankf33der> its N
<tankf33der> but should be size_t
<Regenaxer> size_t is 64 bits usually
<beneroth> when will the 128bit CPU's come??
<beneroth> then we get bigger small numbers :D
orivej has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
<tankf33der> i dont understand how to make this trivial code work
<Regenaxer> OK, I check the man page
<Regenaxer> What to pass as 'node'?
<Regenaxer> NIL gives an empty string
<Regenaxer> is that good?
<Regenaxer> Or better pass a null pointer
<Regenaxer> ie 0
<Regenaxer> And Hints? Sorry, I don't have your code frem this morning any more
<Regenaxer> can you paste again?
<Regenaxer> And, does it work in pil64? I think both should behave the same, just that pil21 does a little more init checks
<tankf33der> afk.
orivej has quit [Ping timeout: 240 seconds]
orivej has joined #picolisp
<tankf33der> this is my main code for the issue
<tankf33der> http://ix.io/2rMY
<tankf33der> this output on any x64 linux
<Regenaxer> I added 'P'
<Regenaxer> (hope it works ;)
<Regenaxer> Not really tested
<tankf33der> the main problem i cant make it work in pil64
<Regenaxer> hehe
<Regenaxer> I will check a little late
<Regenaxer> hurry atm
orivej_ has joined #picolisp
orivej has quit [Ping timeout: 272 seconds]
<tankf33der> [mpech@lambda ~]$ pil t1.l
<tankf33der> R 20902192
<tankf33der> ((0 2 1 6) (16 20902240 0 20904016))
<tankf33der> ok
<tankf33der> (0 0 1 0 0)
<tankf33der> [mpech@lambda ~]$ pil t1.l +
<tankf33der> (0 0 1 0 0)
<tankf33der> R 7828432
<tankf33der> ((0 2 1 6) (8242820295824506896 7828480 0 7847648))
<tankf33der> ok
<tankf33der> now it correct
<tankf33der> i spent all day and + is solver.
<tankf33der> OMG
<tankf33der> afk.
orivej_ has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
orivej has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
alexshendi has joined #picolisp
orivej has quit [Ping timeout: 256 seconds]
orivej has joined #picolisp
<alexshendi> Good evening
orivej has quit [Quit: No Ping reply in 180 seconds.]
orivej has joined #picolisp
orivej has quit [Ping timeout: 256 seconds]
orivej_ has joined #picolisp
<Regenaxer> ret
<Regenaxer> Hi alexshendi :)
<Regenaxer> tankf33der, sorry, was busy
<Regenaxer> What was the problem?
<tankf33der> run pil with and without +
<Regenaxer> This changes 'native' behavior?
<tankf33der> yeap
<tankf33der> see above
<Regenaxer> I did not understand
orivej_ has quit [Ping timeout: 256 seconds]
orivej has joined #picolisp
f8l has quit [Ping timeout: 240 seconds]
<tankf33der> why?
<tankf33der> pil64 running the same file with and without + prints different digits
<Regenaxer> Strange
<Regenaxer> I get exactly the same with and without debug mode
<Regenaxer> pil21
<Regenaxer> and pil64 too
<tankf33der> [mpech@lambda ~]$ pil t1.l
<tankf33der> ok
<tankf33der> (0 0 1 0 0)
<tankf33der> ((0 2 1 6) (16 33128800 0 33130576))
<tankf33der> R 33128752
<tankf33der> [mpech@lambda ~]$ pil21 t1.l
<tankf33der> (0 0 1 0 0)
<tankf33der> R 139940568306848
<tankf33der> ((1041597160 21973 -1388986768 32766) (94374357994648 139940568306896 94374357992328 139940568159976))
<tankf33der> ok
<tankf33der> pil64 and pil21 are different
<Regenaxer> Seems I don't have t1.l
<Regenaxer> I've lost track ;)
<tankf33der> http://ix.io/2rNo
<tankf33der> try on x64 too
<Regenaxer> ok
<Regenaxer> I get the same in all three
<Regenaxer> (0 0 1 0 0)
<Regenaxer> R 0
<Regenaxer> NIL
<Regenaxer> ok
<tankf33der> i gave up.
<Regenaxer> You still call with NIL
<Regenaxer> I asked above
<Regenaxer> NIL is the same as ""
<Regenaxer> thus a pointer to a NULL byte
<Regenaxer> is that correct?
<Regenaxer> Why not 0 (NULL pointer)?
<tankf33der> not 0 is my bad.
<tankf33der> now pil21 works.
<tankf33der> but pil64 with and without + prints different numbers.
<Regenaxer> With 0 I get:
<Regenaxer> (0 0 1 0 0)
<Regenaxer> R 524619214848
<Regenaxer> ((0 10 1 6) (28 0 524619214896 524619215040))
<Regenaxer> ok
<tankf33der> with same without +
<Regenaxer> Something must be garbage
<Regenaxer> + or not + should not matter
<Regenaxer> just different memory layout
<Regenaxer> So something is not initialized
<Regenaxer> Results are random
<Regenaxer> I don't understand getaddrinfo
orivej has quit [Ping timeout: 264 seconds]
orivej_ has joined #picolisp
<tankf33der> so, udp client-server works too on pil21.
<tankf33der> enough for today.
<tankf33der> cu.
<Regenaxer> ok, thx! :)
orivej_ has quit [Ping timeout: 256 seconds]
orivej has joined #picolisp
orivej_ has joined #picolisp
orivej has quit [Ping timeout: 272 seconds]
<alexshendi> Regenaxer: I have a problem with pil21 under NetBSD 9/aarch64. Files dec.l, flow
<Regenaxer> what happens?
<tankf33der> alexshendi: you should run my test suite on netbsd on pil21.
<alexshendi> Regenaxer: I have a problem with pil21 under NetBSD 9/aarch64. Files dec.l, flow.l and main.l reference setjmp/longjmp directly. Under NetBSD 9 these libc routines, but are called __setjmp14/__longjmp14. /usr/include/setjmp.h rectifies this by use of preprocessor magick. I just used sed to rename all instances of setjmp/longjmp, but this doesn't seem quit right to me. Should I dispatch on *Os?
<alexshendi> Regenaxer: I get a linker error setjmp /longjmp not defined.
<alexshendi> In previous versions of pil21, only lib.c used setjmp/longjmp so cpp magick worked.
<Regenaxer> I see
<Regenaxer> So these functions must be moved to src/lib.c it seems
<alexshendi> This should be easy to fix, but I'm looking for a good solution :)
<Regenaxer> thats what I mean
<Regenaxer> all system stuff is in lib.c
<Regenaxer> C macros etc
<Regenaxer> hmm, no
<Regenaxer> difficult
<alexshendi> You could also check for *Os in the *.l files.
<Regenaxer> these two functions are special
<Regenaxer> No, I want to keep the .l files generic
<Regenaxer> Big problem
<Regenaxer> you cannot jump from a called function
<alexshendi> Building from the supplied *.bc files also never worked for that reason on netbsd 9.
<Regenaxer> hmm
<Regenaxer> only setjmp/longjmp or also other things?
<alexshendi> Only these two. On OpenBSD I haven't encountered such problems, but have only tested on amd64.
<Regenaxer> The CPU does not matter I think
<Regenaxer> it is the compiler
<alexshendi> I think it's really netbsd's fault, because these functions are kind of special...
<Regenaxer> Too bad, it really blows up my concept
<Regenaxer> ie isolate the "few" system dependent things into lib.c
<alexshendi> It's not the compilers fault, but libc's I think.
<Regenaxer> but setjmp/longjmp can't be done that way
<Regenaxer> yes, includes + libs
<Regenaxer> ie setjmp/longjmp being macros
<alexshendi> The solutions are all a bit hacky....
orivej_ has quit [Ping timeout: 260 seconds]
orivej has joined #picolisp
<alexshendi> Regenaxer: How long does misc/bigtest take to run?
<Regenaxer> It depends a lot on the hardware
<Regenaxer> less than an hour
<Regenaxer> you see the dots, 100 in total
<alexshendi> Hmm about 15 dots so far...
<Regenaxer> ok
<alexshendi> The machine is a bit slow though
<Regenaxer> How many cores?
<Regenaxer> bigtest uses 3
<Regenaxer> well, 3 processes to be correct
<alexshendi> Quadcore Cortex-A53, but only at 1.1 Ghz.
<Regenaxer> ok
Blukunfando has quit [*.net *.split]
root____ has quit [*.net *.split]
Blukunfando has joined #picolisp
root____ has joined #picolisp