←2008-04-02 2008-04-03 2008-04-04→ ↑2008 ↑all
00:02:32 -!- ais523|busy has quit ("(1) DO COME FROM ".2~.2"~#1 WHILE :1 <- "'?.1$.2'~'"':1/.1$.2'~#0"$#65535'"$"'"'&.1$.2'~'#0$#65535'"$#0'~#32767$#1"").
00:39:44 <RodgerTheGreat> PLEASE ABSTAIN FROM INTERCAL SIGS!
00:39:53 <RodgerTheGreat> it burns!
01:27:42 -!- Sgeo has quit (Read error: 104 (Connection reset by peer)).
01:30:05 <pikhq> RodgerTheGreat: No it doesn't.
01:30:25 <pikhq> Well, unless you mean in the sense that sufficient levels of radiation burn.
01:30:46 <RodgerTheGreat> "burn" is used somewhat figuratively
01:31:09 -!- Sgeo has joined.
01:36:38 -!- boily has joined.
01:37:10 -!- boily has quit (Client Quit).
01:49:55 -!- wildhalcyon has joined.
01:53:10 <wildhalcyon> Why is our topic in arabic?
01:57:20 <pikhq> Because someone insisted upon it.
01:57:30 -!- pikhq has set topic: It's all Arabic to me!.
01:58:39 <wildhalcyon> Well, that works
02:05:50 * pikhq is astounded
02:06:11 <pikhq> One of the guys in the Fantasy Rules Comission had a metalogic class. . . Taught by Suber.
02:06:53 -!- ehird_ has quit ("This computer has gone to sleep").
02:06:53 -!- ehird has quit.
02:26:06 -!- Tritonio_ has quit (Remote closed the connection).
02:26:59 -!- Tritonio_ has joined.
03:13:59 -!- wildhalcyon has left (?).
03:16:40 -!- calamari has joined.
03:22:58 <GregorR> I've come to the conclusion that all of the opcodes in JSMIPS are implemented correctly to the best of my ability, and so the problem with malloc() is in another part of the design.
03:24:45 <GregorR> However, I'm still loathe to suspect that the error is in newlib's implementation of malloc. That seems extremely unlikely.
03:34:31 <pikhq> Newlib's malloc, last I checked, was a fairly simple and bog-standard algorithm. . . And a fairly reliable one at that.
03:35:20 <GregorR> I haven't a clue why this doesn't work D-8
03:35:42 <GregorR> I'm in an infinite loop of (basically) while ((a & b) == 0) { a <<= 1; }
03:36:06 <GregorR> Shockingly, that doesn't accomplish much.
03:38:59 <pikhq> I suspect that a is either 0x00 or 0xFF.
03:39:29 <pikhq> Or malloc is *really* fucked up. :p
03:40:00 <GregorR> Both a and b are 0x00
03:40:05 <GregorR> Hence the infinite loop.
03:40:27 * GregorR goes to publish the latest state of things.
03:46:25 -!- CakeProphet has joined.
03:47:38 <pikhq> Ah.
03:50:10 <CakeProphet> :D
03:50:46 <GregorR> http://www.codu.org/jsmips/
03:51:03 <GregorR> I have it switching into debug mode when _malloc_r is called and then dying in 100 ops.
03:51:15 <GregorR> You can see it go into the loop, but everything is right except for the actual functionality.
03:53:58 <GregorR> Uh, test.html is a test program, in case you couldn't guess :P
03:55:15 <CakeProphet> ...what exactly is the output supposed to mean
03:55:34 <GregorR> It's the pre- and post- of every operation after it goes into _malloc_r.
03:56:13 <GregorR> Oh, and the address of every operation :P
03:56:24 <CakeProphet> more importantly... wtf does this program do. I kind of arrived late I suppose.
03:56:42 <RodgerTheGreat> http://www.codu.org/jsmips/test.c
03:56:47 <RodgerTheGreat> ^ that, in theory
03:58:54 <GregorR> Yeah, it's that, compiled.
03:59:11 <GregorR> In fact, if you watch carefully, the first thing it outputs is the result of that syscall - but that's before it goes into debug mode.
03:59:47 <CakeProphet> ...something in assembly?
04:03:39 <GregorR> I made a syscall that just outputs its argument in hex - I was testing strlen, which worked fine.
04:13:38 * pikhq makes a syscall that forks the processor.
04:13:48 <pikhq> I think I'll call that syscall 'infinity'.
04:14:48 -!- CakeProphet has quit ("haaaaaaaaaa").
04:16:02 <GregorR> :P
04:16:13 <GregorR> How 'bout you figure out why malloc doesn't work for me! :P
04:17:25 <GregorR> Oh, I uploaded the binutils/gcc/newlib patches too.
04:38:14 <Sgeo> Bye all
04:39:07 <pikhq> Is there something geeky about going to the prom with an SCA member?
04:39:07 -!- shinkuzin has quit (Read error: 113 (No route to host)).
04:40:11 -!- Sgeo has quit ("Ex-Chat").
05:08:28 -!- sebbu2 has joined.
05:13:03 <RodgerTheGreat> hey everyone, I reorganized my code page! http://rodger.nonlogic.org/code.php
05:13:37 -!- EgoBot has quit (brown.freenode.net irc.freenode.net).
05:14:06 -!- EgoBot has joined.
05:19:31 -!- GreaseMonkey has joined.
05:19:53 -!- EgoBot has quit (brown.freenode.net irc.freenode.net).
05:20:41 -!- EgoBot has joined.
05:25:38 <RodgerTheGreat> there are neat things there, honest!
05:26:29 -!- sebbu has quit (Connection timed out).
05:26:30 -!- sebbu2 has changed nick to sebbu.
05:33:34 * pikhq sees firmware for a fembot.
05:33:37 <pikhq> Liar.
05:33:37 <pikhq> :p
05:33:49 <RodgerTheGreat> :(
05:34:32 <RodgerTheGreat> closest thing I ever did to that was the abandoned "botlogic" project: http://rodger.nonlogic.org/botlogic/
05:35:10 <pikhq> You going to get more people in on The Abyss?
05:35:11 <pikhq> >:D
05:35:24 <RodgerTheGreat> that would be fun, to be certain
05:35:34 * pikhq is still proud of being the first person to finish the last puzzle without a hint
05:35:43 <RodgerTheGreat> as well you should be
05:36:06 <RodgerTheGreat> hell, if there's enough interest I might spend some time putting together another level for the Abyss.
05:36:10 <pikhq> w00ts.
05:55:59 <GregorR> ARGH
05:56:01 * GregorR smashes something.
05:56:14 <GregorR> malloc fails before even getting to sbrk() 8-O
05:56:33 <pikhq> 8-O
05:56:39 <pikhq> Try mmap? :p
05:56:51 <RodgerTheGreat> GregorR: check out the new area on my site! http://rodger.nonlogic.org/code
05:56:56 <pikhq> (yeah, I know, I know: sbrk() is much easier. . .)
05:57:04 <RodgerTheGreat> I mean http://rodger.nonlogic.org/code.php
06:03:31 <RodgerTheGreat> pikhq: did you appreciate the fact that the "screenshot" for Abyss highlights the most devious puzzle in the entire game?
06:10:32 <pikhq> That I did. :)
06:34:27 <GregorR> Grrf
06:34:39 <RodgerTheGreat> GregorR: ?
06:34:44 <GregorR> You people are shockingly useless, do you know that?
06:35:00 <GregorR> "malloc fails in my implementation I'm trying to make work properly." "Use mmap!"
06:35:02 <GregorR> *slap*
06:35:05 <RodgerTheGreat> sorry, I don't think I'd be of much assistance debugging your malloc routine
06:35:15 <GregorR> I was referring to pikhq :P
06:35:38 <pikhq> GregorR: I was *kidding*.
06:35:44 <GregorR> YOUR MOM
06:35:50 <RodgerTheGreat> WAS KIDDING
06:35:57 <GregorR> So anyway, I made malloc "work" by disabling -O2 (:( )
06:36:04 <pikhq> First you start with mmap, then you take the leap into memory space randomization.
06:36:10 <GregorR> But printf still doesn't work (not a clue why)
06:36:20 <pikhq> And soon, you're running OpenBSD.
06:36:29 <GregorR> lol - but in your web browser :P
06:37:01 <pikhq> Touche.
06:38:46 <RodgerTheGreat> well, if we are to believe the "blogosphere", "web 2.0" heralded the evolution of a web-browser from a program to a huge, bloated program referred to as a "platform".
06:39:04 <RodgerTheGreat> it's about damn time it started ACTING like a proper platform and running BSD.
06:40:39 <pikhq> It's about damn time it started *ACTING* like a proper platform and support multitasking.
06:40:46 <pikhq> (tabs and windows don't count.)
06:41:26 <RodgerTheGreat> good night everyone
06:41:29 <GregorR> I WANT VIM IN MY BROWSER DAMN IT
06:41:40 -!- RodgerTheGreat has quit.
06:41:47 <GregorR> (If somebody who isn't me could write a vt100 simulator in JS, that'd rool)
06:41:53 <pikhq> I want more than just that.
06:42:10 <pikhq> I WANT MY BROWSER TO HAVE A SANE LANGUAGE IN IT.
06:42:17 <pikhq> HTML? Not sane.
06:42:29 <pikhq> http://pikhq.nonlogic.org/test.html Does that *look* sane to you?
06:42:47 <pikhq> (view source; most browsers can't handle the features of HTML used there)
06:44:41 <GregorR> JavaScript has a nice design, but a poor design.
06:45:54 <GregorR> OK, SOME instruction is horribly wrong, as fflush is jumping off into the ether >_>
06:53:37 <GregorR> Heh, I love the W3 validator's response for that page.
06:53:51 <GregorR> Basically: "Well, yeah, it's correct, I guess, but you really shouldn't be doing this ..."
06:55:52 <pikhq> Yeah; ain't it wonderful?
06:58:07 <Deewiant> With luck, HTML5 will be a lot cleaner
06:58:15 <pikhq> Deewiant: Funny.
06:58:30 <Deewiant> pikhq: not feeling lucky? :-)
06:58:30 <GregorR> In the same way that Perl6 should be cleaner than Perl5 (haw haw haw)
06:58:42 <pikhq> And the same way that C++ should be cleaner than C.
06:59:03 <pikhq> Deewiant: Here's how to make HTML5 cleaner.
06:59:09 <pikhq> Step 1: NEW SYNTAX.
06:59:16 <pikhq> Break backwards compatibility.
06:59:28 <pikhq> Step 2: Get someone with some sanity on the project.
06:59:37 <Deewiant> already exists, it's called JSON/YAML/sexps/whathaveyou.
06:59:45 <pikhq> sexps would be ideal.
06:59:56 <GregorR> SEXPEES
07:12:55 -!- calamari has quit ("Leaving").
07:26:25 <AnMaster> sexps?
07:26:31 <AnMaster> S-Expressions?
07:26:46 <AnMaster> Deewiant, ^
07:31:34 <olsner> AnMaster: almost certainly
07:31:44 <AnMaster> k
07:59:59 -!- clog has quit (ended).
08:00:00 -!- clog has joined.
08:22:52 -!- Iskr has joined.
08:46:47 -!- ais523 has joined.
08:49:36 -!- olsner has quit ("Leaving").
09:01:16 -!- oklopol has joined.
09:01:36 <oklopol> oh shit
09:02:26 <oklopol> i was just idly coding at the uni... and a religious freak started talking loudly in his cell phone about how merciful god can be
09:02:49 <oklopol> also every 5 seconds mirc tells me i cannot connect
09:02:57 <oklopol> in a pop-up window
09:03:01 <oklopol> life can be so cruel.
09:03:55 <oklopol> "david lived a year in sin before god killed him"
09:04:44 <oklopol> wonder if it would be too impolite if i told this guy he's ruining my day
09:27:16 <AnMaster> Deewiant, FIXP's N is mostly useless isn't it? you could do the same by 0\- I think?
09:34:17 <ais523> AnMaster: well, it manages it in one character
09:34:40 <ais523> many other fingerprints, such as ROMA, are trivial to expand the individual instructions into multi-character code
09:34:42 <AnMaster> ais523, but you got to load the fingerprint first
09:34:56 <ais523> AnMaster: yes, but only once
09:35:02 <ais523> then you can use N as much as you like
09:35:08 <AnMaster> ais523, not if you want to load some other that also define N
09:35:12 <ais523> (unless you load another fingerprint that defines N)
09:35:41 <AnMaster> ais523, or if you unload another fingerprint defining N ;P
09:35:53 <ais523> well, yes...
09:47:49 -!- GreaseMonkey has quit ("/me is creating a telnet version of mafia - stay tuned").
09:55:45 <AnMaster> ais523, well I'm adding FIXP fingerprint
09:55:56 <ais523> which one's that?
09:56:26 <AnMaster> rcfunge one, some fixed point math stuff
09:56:51 * ais523 was using fixed point a while ago in some DSP programming
09:57:02 <ais523> it's the one with the assembly language opcode with about 6 parameters
09:57:18 <AnMaster> ais523, well I looked at how ccbi does it, and it just cast to floating point and then rounds
09:57:20 <ais523> the assembly language also implemented Fortran's DO instruction
09:57:24 <AnMaster> so *shrug* did the same there
09:57:36 <ais523> the one where you specify the line label of the end of the loop
09:57:40 <ais523> it's very COME FROM-like
09:57:56 <AnMaster> I got no clue how do do cos without using the cos from libm
09:58:01 <AnMaster> so I just cast and round
09:58:19 <ais523> AnMaster: I implemented cos in MediaWiki once
09:58:24 <AnMaster> eh?
09:58:30 <AnMaster> what do you mean? in php?
09:58:37 <ais523> no
09:58:40 <ais523> in MediaWiki markup
09:58:44 <AnMaster> um wtf
09:58:46 <ais523> http://en.wikipedia.org/wiki/Special:Search?go=Go&search=User:ais523/Sandbox/cos
09:58:47 <AnMaster> is it turing complete?!
09:58:51 <ais523> AnMaster: no
09:58:56 <ais523> because you can't write an infinite loop
09:59:11 <AnMaster> so what computational class?
09:59:14 <ais523> if you remove the arbitrary anti-loop restriction, or allow loops to be restarted by hand, then it's TC
09:59:33 <ais523> OTOH, you can write a finite loop of almost any size with enough repetition
09:59:59 <AnMaster> ais523, oh you are an admin on wikipedia?
10:00:02 <ais523> AnMaster: yes
10:00:13 <ais523> as for computational class, it's below FSM because it can't infinite-loop
10:00:27 <AnMaster> hrrm
10:00:49 <ais523> (clearly, infinitely looping wikimarkup would be a nightmare for the servers, which is why it isn't allowed)
10:00:56 <AnMaster> ais523, your user page is.... fancy....
10:01:35 <ais523> the clock was one of my first serious markup projects
10:02:02 <ais523> oh, BTW, the cos function is only accurate in about the range -pi to pi, because I used the Taylor series, but you can correct that with mod easily enough
10:02:04 <AnMaster> so mediawiki will let you draw images?
10:02:13 <ais523> AnMaster: that's not an image
10:02:20 <ais523> try dragging your mouse over it
10:02:30 <AnMaster> ais523, does not select anything
10:02:38 <ais523> you're not accurate enough, then
10:02:43 <ais523> the dots are all bullet points
10:02:50 <ais523> positioned using CSS
10:02:53 <AnMaster> ouch
10:03:11 <AnMaster> clearly, mediawiki markup should have an entry on esolang
10:03:12 <AnMaster> :D
10:03:15 <ais523> OK, so I was showing off
10:03:27 <ais523> AnMaster: look at Wiki Cyclic Tag on Esolang
10:03:40 <ais523> that's proof that MediaWiki markup is TC when you allow loop-restarting by hand
10:04:23 <AnMaster> that would allow DoS though
10:05:09 <ais523> AnMaster: a restart-by-hand infinite loop is DOS even without the infinite loop bit
10:05:25 <ais523> because someone's making a huge number of edits (or at least previews)
10:05:26 <AnMaster> well but much more rate limited
10:05:42 <AnMaster> there will be delay due to network
10:06:13 <ais523> oh well, there's always the pre-expand include limit
10:06:27 <AnMaster> mhm?
10:06:30 <ais523> it's an anti-DOS measure that has been known to confuse the hell out of people
10:06:40 <ais523> if you write a page that's too complicated, bits near the end just stop working
10:06:47 <AnMaster> oh?
10:06:49 <ais523> and there's an error message, but it's in HTML comments in the output
10:07:22 <AnMaster> well that is stupid
10:07:27 <ais523> (an overly-complex page has to fail /somehow/, so as not to DOS the servers, but the avoid-error-messages-at-all-costs philosophy strikes me as being slightly counterproductive)
10:07:45 <AnMaster> yeah
10:09:09 <ais523> <AnMaster> Deewiant, oh btw I found some new nifty functions to microoptimize with, mostly to irritate ehird really
10:09:16 -!- oklopol has quit (Read error: 110 (Connection timed out)).
10:09:16 <ais523> sorry, I was logreading and that just jumped out at me
10:09:34 <AnMaster> ais523, :)
10:09:40 <AnMaster> tools/fuzz-test.sh: line 109: 30792 Floating point exception( ./cfunge -S fuzz.tmp )
10:09:41 <AnMaster> hm
10:09:52 <ais523> division by zero, probably
10:10:08 <AnMaster> that produced NaN before when I tried
10:10:09 <AnMaster> iirc
10:10:43 <ais523> wow, posix_fadvice is so obscure Google can't figure out what it does
10:11:02 <ais523> and in my experience division by zero is NaN in floats, but a floating point exception when done with integers. Go figure...
10:11:29 <AnMaster> and the fuzz program got ? in it, can't figure reproduce due to them
10:12:37 <ais523> try running it again maybe 4 times to see if you get the same result
10:13:47 <AnMaster> no I don't because there are quite a few ? in it
10:13:53 <ais523> oh dear
10:14:13 <ais523> you need something like C-INTERCAL's +printflow
10:14:35 <ais523> just print out the coordinates at every step and save to a logfile, so that when it errors you can go back and see what route was taken
10:14:41 <AnMaster> ah at last I got it
10:15:02 <AnMaster> ais523, I got trace yes, but wasn't enabled in fuzz testing because it tends to spam with like 200 threads that fuzz sometimes cause
10:15:27 <ais523> (+printflow is weirder; it does static compile-time analysis to figure out what line is executed after each other line (which is far from perfect), and then after each line is executed prints the line it predicted would be executed next)
10:15:36 <ais523> AnMaster: what was the problem
10:15:53 <AnMaster> ais523, not sure yet, trying to follow program flow
10:16:10 <AnMaster> oh wait
10:16:17 <AnMaster> not div by zero, mod by zero
10:16:20 <AnMaster> StackPush(ip->stack, (FUNGEDATATYPE)random() % StackPop(ip->stack));
10:16:23 <AnMaster> or maybe negative?
10:16:37 <ais523> mod by negative doesn't SIGFPE, I think
10:16:43 <AnMaster> hm
10:16:45 <ais523> but mod by zero probably does
10:18:05 * ais523 goes to get lunch
10:18:09 -!- ais523 has quit ("will be back after lunch").
10:26:32 <AnMaster> Deewiant, ccbi crashes on "PXIF"4( 0D @
10:26:40 <AnMaster> with a "floating point exception
10:57:02 -!- ais523 has joined.
11:02:37 <Deewiant> AnMaster: "mostly useless" is up to you, Befunge-98 is turing complete even without fingerprints so you can do whatever however in any case ;-)
11:03:05 <AnMaster> Deewiant, was just noting that it was unusually useless
11:03:19 <Deewiant> it's one instruction to replace 3
11:03:25 <Deewiant> can be handy if you need it a lot
11:03:37 <AnMaster> true
11:04:33 <AnMaster> Deewiant, fixed the crash in ccbi?
11:04:45 <Deewiant> yeah, div by zero
11:05:14 <AnMaster> fuzz testing is useful for such basic things
11:06:07 <AnMaster> quad tree looks very useful, but there are of course issues with it
11:06:14 <AnMaster> like quite complex to implement
11:06:33 <Deewiant> I think befunge98 used some kind of octree
11:06:43 <AnMaster> !befunge or?
11:06:46 <EgoBot> Huh?
11:06:47 <Deewiant> befunge98
11:06:50 <AnMaster> ah
11:07:03 <Deewiant> but it didn't work
11:07:06 <AnMaster> but octree would be for 3D?
11:07:16 <Deewiant> it crashed loading mycology, so he just made the initial size bigger ;-)
11:07:21 <Deewiant> might have fixed it since
11:07:25 <AnMaster> yeah I can make quadtree work, would just be painful to do it
11:07:35 <AnMaster> and probably have a lot of bugs
11:07:38 <Deewiant> AnMaster: works for 2D fine, too, you can keep the diagonals for each cell as well
11:07:57 <AnMaster> a lot of references to update on changes, say new cell added
11:08:41 <Deewiant> might still be less work than hashing + inserting
11:08:43 <Deewiant> I don't know
11:08:47 <AnMaster> hm
11:08:59 <ais523> oh, and ehird, after all your complaints about Debian's speed:
11:09:00 <ais523> Accepted intercal 28:0.28-1 (source i386)Thu 03/04/2008 04:36
11:09:06 <AnMaster> so split into 128x128? well it would allow some nice things
11:09:10 <ais523> that came in my inbox this morning
11:09:21 <ais523> (ehird: I know you're not in the channel right now but I'm assuming you logread)
11:09:31 <AnMaster> Deewiant, for single ip it would be easy to use it to optimize say strings
11:09:41 <AnMaster> and JIT
11:09:46 <AnMaster> ie store a faster way to do it
11:10:01 <AnMaster> for multiple IPs that would be "bloody hard"
11:12:13 <AnMaster> Deewiant, oh btw the fingerprint testing bit my my fuzz testing script is quite nice, it looks up in the source what instructions are implemented by the fingerprint it is told to test
11:12:28 <AnMaster> to reduce useless bounce on not implemented
11:13:03 <Deewiant> heh
11:13:24 <AnMaster> depends on this format of lines in manager.c:
11:13:25 <AnMaster> { .fprint = 0x544f5953, .loader = &FingerTOYSload, .opcodes = "ABCDEFGHIJKLMNOPQRSTUVXYZ",
11:13:46 <AnMaster> ie, looks for the correct Finger.*load, then finds opcodes on same line
11:13:48 <AnMaster> XD
11:14:01 <AnMaster> actually no, it just find everything between "" on same line
11:14:31 <AnMaster> still, as long as it works
11:15:42 * ais523 imagines TRDS being fuzz-tested
11:16:14 <ais523> oh, and a quadtree would be a pain if you had a flying IP
11:16:15 <AnMaster> ais523, and I won't implement TRDS so...
11:16:23 <AnMaster> ais523, true
11:16:33 <AnMaster> but most time the ip doesn't fly
11:16:39 <ais523> not very efficient if you do a lot of p and g instructions either
11:16:50 <Deewiant> that can be dealt with by space partitioning
11:17:24 <Deewiant> i.e. you can lookup a certain 'area' quickly
11:17:38 <AnMaster> and a hash table for storing references to cells recently accesses
11:17:41 <AnMaster> accessed*
11:17:56 <ais523> what you could do would be to make a quadruply linked list
11:18:15 <ais523> and have a 2D array of pointers pointing to it
11:18:17 <AnMaster> however, there is one issue, linked list would destroy locality of reference
11:18:34 <ais523> that would optimise many common cases
11:18:44 <ais523> and would use up huge amounts of memory, but be speed-efficient
11:18:52 <AnMaster> ais523, yeah, but you forgot negative funge space and so on
11:19:04 <ais523> you could use the 2D array of pointers near the centre, and some sort of tree system outside
11:19:19 <ais523> because most programs are going to have most non-32 values at small positive locations
11:19:28 <AnMaster> and that funge space is two vectors that are signed x-bit integers
11:19:32 <AnMaster> where x is 32 or 64
11:19:36 <AnMaster> hm
11:19:37 <ais523> AnMaster: I know
11:19:55 <ais523> but an array is still fastest in the cases where it works, you just need something to supplement it in the cases where it doesn't
11:20:02 <AnMaster> hm
11:20:05 <AnMaster> sounds complex
11:20:10 <Deewiant> in general, if people use pg, it's probably within everything that can be accessed quickly, i.e. up to (15,15)
11:20:28 <AnMaster> ais523, profiling shows that searching in bucket in hash table is the slowest part
11:20:34 <ais523> Deewiant: apart from that Befunge sieve-of-eratosthenes program
11:20:35 <AnMaster> so I guess I need a better hash function?
11:20:53 <Deewiant> ais523: where's it then
11:20:55 <AnMaster> currently I think some standard crc is used
11:21:02 <ais523> Deewiant: can't remember
11:21:11 <Deewiant> ais523: it probably uses only a few cells which are close by, anyway
11:21:20 <ais523> but it worked by writing 234567890234567890234567890, etc in an commented-part of Funge space
11:21:28 <ais523> and obliterated all the complex numbers in it
11:21:34 <ais523> s/complex/composite/
11:21:41 <Deewiant> ais523: so once you find that pos, which only takes time the first time, you can cache a pointer to it and after that all accesses are quick
11:21:54 <ais523> Deewiant: yes, agreed
11:22:05 <AnMaster> hm
11:22:18 <Deewiant> which is why I think a tree is good, since it optimizes the common case of just an IP moving
11:22:30 <AnMaster> ais523, actually if you know a good hash for two 64-bit integers that generate few collisions
11:22:35 <AnMaster> I think that would help a lot
11:22:46 <Deewiant> and you can use such caching to take care of 90% of pg use
11:22:48 <ais523> AnMaster: mingle from INTERCAL
11:22:52 <ais523> alternate bits in the two integers
11:22:53 <AnMaster> because currently I get a lot of linear search into buckets
11:23:07 <AnMaster> ais523, um?
11:23:08 <AnMaster> typedef struct s_fungeVector {
11:23:08 <AnMaster> FUNGEVECTORTYPE x;
11:23:08 <AnMaster> FUNGEVECTORTYPE y;
11:23:08 <AnMaster> } fungeVector;
11:23:11 <AnMaster> that is what I need to hash
11:23:17 <ais523> although a faster method would be to take the bottom few bits of each of x and y and preserve those literally
11:23:19 <AnMaster> where FUNGEVECTORTYPE is either 32-bit or 64-bit
11:23:41 <ais523> e.g. to hash into 1024 buckets, take ((x & 32) << 5) + (y & 32)
11:23:49 <Deewiant> AnMaster: I use murmurhash, seems decent
11:23:55 <AnMaster> Deewiant, link?
11:23:58 <ais523> totally insecure, but will spread the typical rectangular program out
11:24:01 <Deewiant> google.com
11:24:20 <AnMaster> bah
11:24:24 <ais523> if you want to optimise for Unefungish programs too, you can do that with a small modification
11:24:44 <ais523> (((x + y/32) & 32) << 5) + ((y + x/32) & 32)
11:25:26 <ais523> and you could modify it slightly so that you can sort a Befunge-93 program into 2000 different buckets out of 2048
11:25:30 <ais523> not sure how useful that would be
11:26:37 <AnMaster> Deewiant, where is your implementation of it?
11:26:47 <Deewiant> space.d
11:27:04 <AnMaster> must have an old source code version
11:29:57 <AnMaster> Deewiant, your looks 32-bit specific?
11:30:09 <Deewiant> what do you think the static assert's for
11:30:17 <AnMaster> exactly
11:37:29 <AnMaster> Deewiant, what is hash_t?
11:37:50 <Deewiant> beats me, probably uint
11:38:07 <AnMaster> Deewiant, also do you do one hash for x and then one for y or?
11:38:26 <Deewiant> eh? only one hash is returned
11:38:33 <AnMaster> hm
11:38:46 <AnMaster> 0x_c6a4_a793
11:38:49 <AnMaster> wtf is that number?
11:38:50 <AnMaster> _?
11:38:53 <ais523> if you do one hash for x and one for y, then as long as small integers hash to different things then you're likely to end up with few collisions
11:38:59 <Deewiant> _ is just for readability
11:39:02 <Deewiant> doesn't affect value
11:39:13 <ais523> Perl does that too AFAIR
11:39:59 <AnMaster> gcc didn't like it
11:40:00 <Deewiant> it hashes together the x and y as though they're a block of data
11:40:16 <Deewiant> AnMaster: ?
11:43:36 <AnMaster> no difference for speed really it seems, hrrm
11:44:50 <AnMaster> Deewiant, in fact it is worse than the current crc
11:45:12 <Deewiant> AnMaster: for me it was much faster, shows just how crap the builtin D hashtable is :-)
11:45:12 <AnMaster> for 32-bit values, I have not yet tried for 64-bit
11:45:49 <AnMaster> Deewiant, it is faster than CRC, but generates more collisions here
11:46:03 <Deewiant> I have no way of counting them so I don't know
11:47:14 <AnMaster> well mine is based on a simple trick of making the search_in_bucket call another function for each comparing of item, and prevent gcc from inlineing it
11:47:21 <AnMaster> and then look at result of profiling
11:53:35 <AnMaster> 307859 vs. 201398?
11:53:36 <AnMaster> hn
11:53:37 <AnMaster> hm*
11:53:50 <AnMaster> Deewiant, it seems crc gets more collisons, yet it is faster overall
11:53:52 <AnMaster> weird
11:54:12 <Deewiant> AnMaster: so maybe a binary tree instead of a hash table would be faster :-)
11:54:22 <Deewiant> (assuming the fallback is a bintree)
11:54:32 <AnMaster> hm?
11:54:59 <Deewiant> i.e. maybe whatever the hash table uses to resolve collisions would be faster overall
11:55:20 <ais523> most hash tables I know just use a linear linked list to resolve collisions
11:55:27 <ais523> on the basis that they don't happen very often
11:55:30 <AnMaster> Deewiant, anyway why use a different constant m than the the "upstream" murmur does?
11:55:41 <AnMaster> ais523, true
11:55:50 <Deewiant> AnMaster: I don't think I do, maybe it changed since
11:56:00 <AnMaster> Deewiant, murmur2 or murmur1?
11:56:02 <Deewiant> ais523: the D one uses a binary tree
11:56:03 <Deewiant> AnMaster: 2
11:56:06 <AnMaster> hm
11:56:11 <AnMaster> well this is 2
11:56:22 <AnMaster> const unsigned int m = 0x5bd1e995;
11:56:22 <AnMaster> vs
11:56:24 <AnMaster> const hash_t m = 0x_c6a4_a793;
11:57:00 <AnMaster> Deewiant, oh wait you got fixed seed?
11:57:21 <AnMaster> unsigned int h = seed ^ len;
11:57:23 <AnMaster> vs
11:57:24 <AnMaster> hash_t h = 0x7fd6_52ad ^ (8 * m)
12:10:06 <AnMaster> 130574 vs 109371 for 64-bit hm
12:10:48 <AnMaster> Deewiant, it seems even with IO disabled and fingerprints disabled the main mycology uses something random?
12:10:56 <AnMaster> oh wait, that would probably be time from y?
12:14:42 <AnMaster> 1397330 vs 868481
12:14:46 <AnMaster> Deewiant, that is for the scheme thing
12:14:49 <AnMaster> the latter is crc
12:15:28 <AnMaster> so on mycology murmur is better but on the fib in scheme converted to befunge thing, crc is way better
12:15:29 <AnMaster> hm?
12:17:25 <AnMaster> 4331048 vs. 4330944, almost even, again crc slightly better
12:18:58 <AnMaster> Deewiant, looks 4330944 4364795, it looses for 32-bit too hm
12:19:21 <AnMaster> in fact it is only better for mycology it seems
12:20:08 <AnMaster> ais523, <ais523> wow, posix_fadvice is so obscure Google can't figure out what it does <-- try the man page, it knows
12:20:27 <ais523> $ man posix_fadvice
12:20:27 <ais523> No manual entry for posix_fadvice
12:20:29 <AnMaster> posix_fadvise
12:20:31 <AnMaster> typoed it
12:20:32 <AnMaster> the name
12:20:47 <ais523> ah, that explains why I couldn't find it
12:20:55 <AnMaster> as man posix_fad<tab> would tell you
12:20:55 <AnMaster> ;P
12:21:05 <AnMaster> assuming you got completion of that set up
12:21:52 <AnMaster> ais523, also one hint may have been that google said: "Did you mean: posix_fadvise"
12:21:53 <ais523> yes, it does tab-complete, although man tabcompletion takes sufficiently long that I can sense the hesitation
12:21:56 <AnMaster> right at the top
12:22:08 <ais523> AnMaster: yes, but I assumed that it was just trying to fix typoes in programmer words again...
12:22:29 <ais523> the tabcompletion over here is pretty good; it can tab-complete subversion and make too
12:22:36 <AnMaster> so can mine
12:22:41 <AnMaster> gentoo :)
12:22:53 <ais523> (make is particularly interesting because it has to dive into the makefile to find out what make targets are available)
12:23:07 <AnMaster> indeed
12:23:17 <AnMaster> ais523, fails at included makefiles however
12:23:42 <AnMaster> http://rafb.net/p/MURI6z45.html
12:23:46 <ais523> pity, otherwise it might have been possible to prove tab-completion Turing-complete
12:23:50 <AnMaster> ais523, the ones marked with star are enabled
12:24:03 <AnMaster> very nitfy gentoo tool eselect
12:24:06 <AnMaster> when it works
12:24:19 <AnMaster> ais523, it is turing complete in fact
12:24:26 <AnMaster> it is just a bash function
12:24:34 <AnMaster> that returns a result
12:24:56 <ais523> I mean without writing extensions for it
12:24:56 <AnMaster> so you could make it handle included make files
12:25:03 <ais523> as in, is the 'in the wild' version of tabcompletion TC?
12:25:05 <AnMaster> heh
12:25:19 <AnMaster> ais523, well if you make a patch and send it upstream?
12:25:27 <ais523> that would be cheating
12:25:35 <ais523> you can make any program TC like that
12:25:37 <ais523> even /bin/true
12:25:41 <AnMaster> hah
12:25:42 <ais523> if you can somehow get the patch accepted
12:26:00 <AnMaster> ais523, well no, just "look at included makefiles" patch
12:26:05 <AnMaster> it would be an useful feature
12:35:01 -!- ais523 has quit ("leaving for a while, will be back later").
12:58:39 -!- ais523 has joined.
13:06:02 -!- Tritonio_ has quit (Remote closed the connection).
13:06:58 <AnMaster> ais523, hm is the C-INTERCAL website down?
13:07:34 <AnMaster> Firefox can't establish a connection to the server at intercal.freeshell.org.
13:09:57 -!- Tritonio_ has joined.
13:10:55 -!- ais523_ has joined.
13:11:11 -!- ais523 has quit (Read error: 104 (Connection reset by peer)).
13:11:17 -!- ais523_ has changed nick to ais523.
13:11:34 <ais523> sorry, my wireless dropped for a while
13:11:36 <AnMaster> ais523, <AnMaster> ais523, hm is the C-INTERCAL website down? <AnMaster> Firefox can't establish a connection to the server at intercal.freeshell.org.
13:11:51 <ais523> I think it is, because I can't get a connection either
13:11:58 <ais523> ehird's mirror is up, though
13:12:11 <ais523> (and that's the CLC-INTERCAL website, it just happens to host C-INTERCAL too)
13:13:16 <AnMaster> ais523, wikipedia refers to C-INTERCAL on ESR's website, hm?
13:13:23 <ais523> I think so
13:13:47 <ais523> I mentioned intercal.freeshell.org on the talk page, but nobody answered, and I don't want to add it myself because I have a conflict of interest with respect to ir
13:13:48 <AnMaster> he stopped maintaining it I see, but why not provide info to new source it
13:13:49 <ais523> s/ir/it
13:13:55 <ais523> s/$/\//
13:14:09 <AnMaster> ais523, oh? so ESR still thinks he is maintaining it?
13:14:21 <ais523> AnMaster: not sure
13:14:32 <ais523> but if he reads alt.lang.intercal, then he'd know about the newer versions
13:14:39 <ais523> the catb site hasn't been updated in ages AFAICT
13:15:00 <AnMaster> ais523, does intercal have any PLEASE MAKE THIS WORK?
13:15:10 <ais523> AnMaster: not exactly
13:15:12 <AnMaster> heh
13:15:12 <ais523> what isn't working?
13:15:28 <AnMaster> ais523, anything anyone try to write in intercal ;)
13:15:35 <ais523> AnMaster: not true
13:15:37 <AnMaster> well apart from you
13:15:42 <AnMaster> and a few more
13:15:46 <ais523> hey, lots of people get INTERCAL programs to work!
13:15:54 <ais523> in fact, nowadays I think they work more often than not, on average
13:16:04 <AnMaster> hm
13:16:06 <ais523> mostly because people tend to be conservative and stick to the J-INTERCAL command set
13:16:18 <AnMaster> well I didn't mean compiler bugs
13:16:19 <ais523> (i.e. INTERCAL-72 + COME FROM label)
13:16:24 <ais523> AnMaster: neither did I
13:16:38 <AnMaster> what about LOLINTERCAL?
13:16:42 <AnMaster> lolcode + intercal
13:16:43 <AnMaster> hrrm
13:16:54 <AnMaster> PLEASE -> PLZ
13:16:56 <AnMaster> and so on
13:17:11 <ais523> AnMaster: that's a worrying thought
13:17:13 <ais523> probably not worth it
13:17:17 <AnMaster> haha
13:21:18 -!- Tritonio_ has quit ("Bye...").
13:21:34 <AnMaster> ais523, in fact lolintercal would be much easier than lolC
13:21:41 <ais523> AnMaster: yes
13:21:48 <ais523> because INTERCAL has so many keywords
13:22:02 <ais523> I find DO and V are the hardest to avoid when CREATING new statements, though
13:23:09 <AnMaster> eh
13:23:13 <AnMaster> CREATING new statements?
13:23:20 <ais523> it's new in 0.28
13:23:23 <ais523> there's a CREATE command
13:23:26 <AnMaster> are you saying you can create new keywords?
13:23:31 <ais523> AnMaster: new commands
13:23:32 <AnMaster> sounds like forth
13:23:39 <ais523> which is not exactly the same as creating new keywords
13:23:43 <AnMaster> hm ok
13:23:51 <ais523> it took a while to figure out how to do it in a compiled language, though
13:24:13 <ais523> (CLC-INTERCAL is interpreted, and the INTERCAL code itself is implemented entirely using its own version of CREATE)
13:24:39 <ais523> but C-INTERCAL has to compile invalid commands speculatively in case they gain a meaning later
13:25:38 <AnMaster> ais523, is C-INTERCAL slow or?
13:25:52 <ais523> AnMaster: it's pretty fast for an INTERCAL compiler
13:25:56 <AnMaster> considering it seems to love function pointers
13:26:04 <ais523> in some cases you can convert C to INTERCAL, and get back what's almost the original C
13:26:19 <AnMaster> hm
13:26:28 <ais523> the function pointers are used to implement operand overloading; if you don't specify -a and don't use the / operator, they aren't used
13:26:45 <ais523> likewise, if you don't use -m or -e, it does everything entirely without longjmp
13:27:01 <ais523> the general rule is that things that could slow it down have their own command line option
13:27:20 <ais523> (correction: if you don't use -m, -e, or variants on computed COME FROM, it does everything entirely without longjmp)
13:27:48 <ais523> except that things don't have a command line option if they can easily be autodetected
13:27:56 <AnMaster> hm
13:28:44 <ais523> whoops, sorry, -v also turns on operand overloading, but it's rare to need that switch because it allows you to assign to constants, which tends not to lead to maintainable programs
13:31:13 <AnMaster> hm
13:31:44 <ais523> here's a simple example
13:31:58 <ais523> suppose I compile the following program, with optimisation and debugging enabled:
13:32:04 <ais523> DO .5 <- '?"'&"':2~:5'~'"'?"'?":5~:5"~"#65535$#65535"'~'#65535$#0'"$#32768'~'#0$#65535'"$"'?":5~:5"~"#65535$#65535"'~'#0$#65535'"'"$"':5~:5'~#1"'~#1"$#2'~#3
13:32:10 <AnMaster> um
13:32:13 <AnMaster> what does that do?
13:32:14 <ais523> I can then type e 1 into the debugger
13:32:24 <ais523> and it tells me what the line does (which is what it optimised to):
13:32:31 <ais523> yuk007 e 1
13:32:31 <ais523> C1: Expression is (0x2 - ((:2 > (:5 ^ :2)) & (! (! :5))))
13:32:45 <AnMaster> ok that is nifty, that it can tell that
13:32:51 <AnMaster> still what is that useful for?
13:32:53 <ais523> so it's part of a test for greater-than, which is not at all obvious by looking at the original INTERCAL
13:33:20 <ais523> it was part of the original division routine in the system library
13:33:25 <ais523> (arithmetic generally requires a loop)
13:33:27 <AnMaster> ais523, to me it looks like more than "greater than"?
13:33:58 <ais523> it's a greater-than-and-not-equal-to test, showing that the syslib's designers didn't really understand their own code themselves
13:34:02 <AnMaster> <ais523> it was part of the original division routine in the system library <-- well you could implement divide directly into the compiler, something like gcc's __builtin__
13:34:03 <AnMaster> ?
13:34:07 <ais523> because the and-not-equal-to is redundant
13:34:09 <ais523> AnMaster: I did
13:34:33 <ais523> and INTERCAL used to use 1 and 2 as logic levels because they were easier to do conditional branches with
13:35:11 <ais523> thus the 0x2 - at the start
13:35:33 <AnMaster> ais523, compiled with -Os and then stripped cfunge is 51 kb btw
13:36:02 <ais523> ick is 409 kb with -O2 and not stripped
13:36:04 <AnMaster> the debug binary is around 986K heh
13:36:24 <ais523> but it has lots of libraries that compiled programs link with, which are just as much a part of C-INTERCAL as the compiler is
13:36:27 <AnMaster> ais523, anyway I seen far worse
13:36:33 <AnMaster> do you know of the game supertux?
13:36:49 <AnMaster> compile with plain -g, not even -ggdb3, the binary is over 50 MB!
13:36:59 <ais523> I don't know of supertux
13:37:00 <AnMaster> stripped the same binary is around 3 MB iirc
13:37:18 <AnMaster> ais523, it is a mario like platform jumping 2D game, staring Tux
13:37:30 <ais523> -rw-r--r-- 1 root root 106704 2008-04-03 11:35 /usr/local/lib/libick.a
13:37:30 <ais523> -rw-r--r-- 1 root root 121872 2008-04-03 11:35 /usr/local/lib/libickec.a
13:37:30 <ais523> -rw-r--r-- 1 root root 127390 2008-04-03 11:35 /usr/local/lib/libickmt.a
13:37:36 <ais523> the libraries aren't too bad
13:37:41 <ais523> hmm... what about the debugger?
13:37:52 <ais523> -rw-r--r-- 1 root root 29128 2008-04-03 11:35 /usr/local/lib/libyuk.a
13:37:59 <ais523> wow, it's smaller than yours
13:38:14 <AnMaster> ais523, well that is not a binary
13:38:17 <ais523> (again, you probably don't want to know why the debugger is stored in object code form, although you can probably guess)
13:38:28 <AnMaster> ais523, no I'm happy I can't guess it
13:38:49 <AnMaster> on the other hand, supertux is in C++, so that can explain the huge size of debugging data
13:39:57 <ais523> yes, C++ is hard to debug naively
13:40:14 <ais523> hmm... I wonder how much extra space in the executable C-INTERCAL debugging data takes up?
13:40:28 <AnMaster> ais523, strip will take away symbol table too
13:40:38 <AnMaster> and in C++ again that is rather large
13:40:45 <AnMaster> consider long mangled names
13:41:09 <ais523> when compiling with -y C-INTERCAL stores a line number map, explanations for each expression in the program, and the entire program source code in the executable
13:41:14 <ais523> that has to take up some space
13:41:53 <ais523> (that's how to avoid problems with list commands not finding files, or finding the wrong version; you just store the original source in the executable)
13:41:58 <AnMaster> ais523, btw the 986 KB for cfunge with debug info is for -O0 -ggdb3
13:42:21 <ais523> so it makes a big difference sizewise
13:42:27 <AnMaster> ais523, is there any intercal quine?
13:42:37 <ais523> AnMaster: yes
13:42:42 <AnMaster> amazing
13:42:43 <ais523> there's pit/quine.i in the C-INTERCAL distribution
13:42:57 <ais523> it looks like the standard quinish stuff
13:43:11 <ais523> lots of data in a predictable format that represents the rest of the code, followed by the code itself
13:44:22 <ais523> normally using PLEASE on every fourth line is a copout (varying it is more aesthetic), but in the case of a quine program I can understand it
13:45:38 <AnMaster> ais523, a large risk with the befunge bridge thing would be that all someone wrote in intercal was "invoke befunge" basically
13:45:52 <ais523> AnMaster: I'm happy with that
13:45:56 <AnMaster> because befunge seems way easier to program in ;P
13:46:05 <ais523> AnMaster: they're good for different things
13:46:17 <ais523> just try to write an 8-bit bit-reverse in Befunge, for instance
13:46:18 <AnMaster> <ais523> DO .5 <- '?"'&"':2~:5'~'"'?"'?":5~:5"~"#65535$#65535"'~'#65535$#0'"$#32768'~'#0$#65535'"$"'?":5~:5"~"#65535$#65535"'~'#0$#65535'"'"$"':5~:5'~#1"'~#1"$#2'~#3
13:46:22 <AnMaster> not comparing numbers
13:46:29 <ais523> agreed
13:46:30 <AnMaster> very simple to do that in befunge
13:46:36 <AnMaster> <ais523> just try to write an 8-bit bit-reverse in Befunge, for instance
13:46:36 <ais523> INTERCAL is bad at the ordinary sorts of arithmetic
13:46:37 <AnMaster> hm
13:46:40 <AnMaster> good question
13:46:47 <ais523> it's very good at bitwise stuff, though
13:47:03 <AnMaster> ais523, there are fingerprints for bitwise and/or/xor
13:47:07 <AnMaster> so not that hard
13:47:27 <ais523> yes, but it's just 3 lines of INTERCAL
13:47:30 <ais523> and they're all the same line
13:47:41 <ais523> here's the shortest addition I know of, by the way:
13:47:41 <AnMaster> hm?
13:47:43 <ais523> (1) DO COME FROM ".2~.2"~#1 WHILE :1 <- "'?.1$.2'~'"':1/.1$.2'~#0"$#65535'"$"'"'&.1$.2'~'#0$#65535'"$#0'~#32767$#1
13:47:51 <AnMaster> 22+
13:47:52 <AnMaster> :)
13:48:08 <ais523> that line describes how to do long addition using the old school method
13:48:27 <ais523> add corresponding bits, store the carries separately, left shift the carries and add to the result, repeat until the carry is 0
13:48:39 <AnMaster> ais523, but why does it have a 2 there? I thought it used TWO for 2?
13:48:49 <ais523> AnMaster: that's on input
13:48:53 <AnMaster> ah
13:48:57 <ais523> #2 is the constant 2, unless/until you assign to it
13:49:03 <ais523> .2 is a 16-bit variable
13:49:08 <ais523> which is not the same variable as .1 or .3
13:49:08 <AnMaster> ais523, so you can't read strings from input?
13:49:19 <ais523> AnMaster: yes you can, you just use a different input instruction
13:49:32 <ais523> but you get the differences between consecutive characters
13:49:36 <AnMaster> oh god
13:49:39 <ais523> rather than the characters themselves
13:49:46 <AnMaster> ais523, well the first one...
13:49:49 <ais523> AnMaster: it could be worse, CLC-INTERCAL inputs in Baudot
13:49:56 <AnMaster> what is Baudot?
13:50:07 <ais523> 5-bit communication system with shift codes
13:50:13 <ais523> dates back to the days of teletypewriters
13:50:22 <AnMaster> I see
13:50:42 <AnMaster> <ais523> yes, but it's just 3 lines of INTERCAL
13:50:42 <AnMaster> hm
13:50:46 <AnMaster> for reversing bits?
13:50:48 <ais523> yes
13:51:07 <AnMaster> what data type?
13:51:18 <ais523> 8-bit integer
13:51:21 <AnMaster> ah
13:51:27 <ais523> it's 4 lines for a 16-bit integer, 5 for a 32-bit integer
13:51:32 <AnMaster> simple in C I think
13:51:40 <ais523> I would say 'and so on' but there are no larger integers unless you simulate them yourself
13:51:49 <ais523> AnMaster: C uses a similar looking method that differs in the details
13:52:27 <ais523> in C you swap blocks of 4 bits, then 2 bits, then 1 bit
13:52:47 <AnMaster> something like char in = 2, out = 0; for(i=0; i < 8; i++) { in <<= out < 1 }
13:52:50 <AnMaster> or something like that
13:52:56 <ais523> AnMaster: that's terribly inefficient
13:53:00 <AnMaster> ais523, that is true
13:53:05 <fizzie> Or you just table-lookup.
13:53:17 <AnMaster> fizzie, for 8 bit values certainly that would work
13:53:26 <AnMaster> actually I would need
13:53:30 <AnMaster> { in <<= out > 1 }
13:53:34 <AnMaster> err
13:53:36 <ais523> c = (c & 0x0f) << 4 | (c & 0xf0) >> 4;
13:53:36 <AnMaster> { in <<= out >> 1 }
13:53:36 <ais523> c = (c & 0x33) << 2 | (c & 0xcc) >> 2;
13:53:36 <ais523> c = (c & 0x55) << 1 | (c & 0xaa) >> 1;
13:53:37 <AnMaster> even
13:53:46 <ais523> that's an 8-bit-reverse directly from cesspool.c
13:53:46 <AnMaster> ais523, ok
13:54:00 <AnMaster> ais523, now: what do you use 8-bit-reverse for?
13:54:14 <ais523> well, character output has to be bit-reversed
13:54:17 <AnMaster> err
13:54:18 <AnMaster> ?
13:54:19 <ais523> but its main use is for Fourier transforms
13:54:22 <fizzie> For 16-, 32- and 64-bit values you can use the 256-element table and swap the bytes while looking-up.
13:54:22 <AnMaster> ah
13:54:24 <AnMaster> and why the name "cesspool.c"?
13:54:31 <AnMaster> fizzie, hm true
13:54:36 <ais523> AnMaster: it's the runtime library, the name predates me
13:54:41 <ais523> but most of the source files have names like that
13:54:44 <AnMaster> ais523, I see.......
13:54:49 <ais523> except the ones designed to include in other people's programs
13:54:52 <fizzie> I'm sure this link has been mentioned, but for C bit-twiddling, there's http://graphics.stanford.edu/~seander/bithacks.html
13:54:54 <ais523> like ick_ec.h, which is sensible
13:54:57 <AnMaster> ais523, does ick compile with -Wall -Werror?
13:55:00 <ais523> DO .1 <- !1~#255'$!1~#65280'
13:55:00 <ais523> DO .1 <- !1~#255'$!1~#65280'
13:55:00 <ais523> DO .1 <- !1~#255'$!1~#65280'
13:55:00 <ais523> DO .1 <- !1~#255'$!1~#65280'
13:55:01 <AnMaster> -ansi too btw
13:55:09 <AnMaster> oh and -pedantic
13:55:10 <ais523> AnMaster: I already use -Wall
13:55:19 <AnMaster> ais523, no warnings?
13:55:20 <ais523> there's one warning, which is caused by the output from flex
13:55:26 <fizzie> For example, reversing a single byte with b = (b * 0x0202020202ULL & 0x010884422010ULL) % 1023;
13:55:28 <ais523> -ansi makes it fail because it uses POSIX stuff
13:55:29 <AnMaster> fair enough
13:55:49 <AnMaster> ais523, -std=c99 -pedantic -Wall -Wextra?
13:55:56 <ais523> fizzie: that's slow unless your system has a fast 64-bit multiply
13:55:59 <AnMaster> ais523, or the set of warnings used by cfunge?
13:56:02 <ais523> AnMaster: that still excludes POSIX stuff
13:56:21 <AnMaster> ais523, not from headers no
13:56:24 <ais523> but let me put it this way: I've personally reviewed all 8000 warnings that Splint came up with
13:56:38 <ais523> and there are 2 valid ones left
13:56:43 <AnMaster> ais523, just -D_POSIX_SOURCE or whatever
13:56:49 <AnMaster> I don't want gnu extensions
13:56:57 <AnMaster> <ais523> fizzie: that's slow unless your system has a fast 64-bit multiply <-- well.... mine does I think
13:56:59 <ais523> I don't use them
13:57:27 <fizzie> The few benchmarks I've seen seem to have looked like small table-lookups would be "fast enough", and they have the (dis)advantage of being very readable code.
13:57:31 <AnMaster> ais523, splint is more or less crap due to needing stupid annotation IMO
13:57:36 <ais523> except occasionally ({ ... }) to solve a preprocessing problem, but that was in the bit that needed gcc anyway
13:57:37 <AnMaster> oh and the (void)puts thing
13:57:40 <ais523> AnMaster: I added the annotations
13:58:02 <AnMaster> ais523, I would never to my code, they make the code harder to read and therefore maintain
13:58:04 <ais523> many of them are useful to humans too, because wherever I added a warning-suppress annotation I explained why my code was actually correct
13:58:27 <ais523> and things like /*@null@*/ aren't too hard to read, and document the input taken by a function quite well
13:58:29 <AnMaster> ais523, oh and splint fails on cfunge with parser error
13:58:32 <AnMaster> due to C99 stuff
13:58:48 <ais523> AnMaster: it fails on some of the INTERCAL files like that for no apparent reason
13:58:51 <ais523> so I don't run it on those
13:59:05 <AnMaster> ais523, well virtually all files for cfunge
13:59:12 <AnMaster> as it fails on a global header
13:59:39 <AnMaster> return (fungeVector) { .x = x, .y = y };
13:59:40 <ais523> BTW, the external calls code - which can be made standalone to allow COME FROM, etc., to be used in C programs - is as far as I can tell standard strictly conforming freestanding-legal C89
13:59:43 <AnMaster> fails on that for example
13:59:46 <ais523> apart from a few calls to printf
13:59:50 <AnMaster> ais523, I mailed the author of splint a test case
14:00:06 <ais523> and the use of stdint.h for uint16_t and uint32_t, which are easily typedefed in C89
14:00:10 <AnMaster> ais523, who would want COME FROM in C? :(
14:00:29 <ais523> AnMaster: not sure, but the ability to do computed COME FROMs is an interesting one
14:00:38 <AnMaster> ais523, unreadable code
14:00:43 <AnMaster> for C
14:00:51 <AnMaster> for intercal it is fine
14:00:53 <ais523> in C, though, they clobber your procedure's return address and all your auto variables, so you have no way to escape except by doing still more COME FROMs
14:00:55 <AnMaster> but for normal C...
14:01:23 <AnMaster> ais523, well -fstack-protector would HATE that
14:01:28 <ais523> (you can also use NEXT/RESUME to encapsulate them, which are call/return from function in INTERCAL, with some INTERCAL-like twists as usual)
14:01:36 <AnMaster> it checks that return address wasn't overwritten iirc
14:01:43 <ais523> AnMaster: are you sure? I implemented it in standard strictly-conforming freestanding-legal C89
14:01:48 <ais523> I don't overwrite the return address
14:01:57 <ais523> I longjmp out of the function and recall it from elsewhere
14:01:58 <AnMaster> ais523, well, you said it "clobber your procedure's return address"
14:02:05 <AnMaster> ais523, hm
14:02:06 <ais523> thus the return address ends up wrong
14:02:06 <AnMaster> ok
14:02:23 <ais523> this also explains why the auto variables go missing
14:02:34 <AnMaster> with auto you mean?
14:02:48 <ais523> well, auto's the default
14:03:01 <AnMaster> non-register non-volatile?
14:03:03 <ais523> it's a completely useless keyword, because it's illegal everywhere it isn't the default
14:03:18 <ais523> AnMaster: register variables get lost too, and volatile makes no difference
14:03:27 <ais523> static is fine, as is malloced storage and global storage
14:03:33 <AnMaster> well that is what auto is "compiler selects"
14:04:22 <AnMaster> ais523, just don't do that in cfunge code please
14:04:38 <ais523> nowhere apart from the interface functions, if I can avoid it
14:05:00 <ais523> as in, write my own functions that COME FROM the INTERCAL program and then call cfunge
14:05:11 <AnMaster> ais523, if you make it so you can only return between instructions, and that doesn't include k, that must execute in one go, but as in main loop instruction
14:05:15 <AnMaster> it should probably work fine
14:05:26 <ais523> yes
14:05:39 <ais523> although kNEXT ought to be able to work
14:05:40 <AnMaster> just need to replace main loop code then with something else
14:05:56 <AnMaster> kNEXT? that would iterate over kN only
14:06:31 <ais523> I meant NEXT as in (whatever character represents NEXT)
14:06:45 <ais523> which would be a single character in the fingerprint, presumably
14:06:47 <AnMaster> well, you are on your own there
14:07:02 <ais523> unless... unless you have to spell out COMEFROM in some direction in the Befunge code to do a COME FROM
14:07:02 <AnMaster> making k work over t was a pain
14:07:09 <AnMaster> ais523, ewww
14:07:22 <AnMaster> ais523, that would be against the philosophy of funge
14:07:27 <ais523> yep
14:07:34 <AnMaster> that one char = one instruction
14:07:35 <ais523> but somewhat within the philosophy of INTERCAL
14:07:46 <ais523> the problem is where to draw the boundaries when linking the two languages
14:07:52 <AnMaster> hm true
14:07:56 <ais523> but I think it's best if each language keeps its own philopsophy
14:07:59 <AnMaster> maybe an RPC interface? XD
14:08:09 <ais523> except for INTERCAL flow control to link the two languages, whatever they are
14:08:14 <AnMaster> yeah
14:08:21 <ais523> that way, if you link INTERCAL, C, and Befunge, the Befunge can COME FROM the C, etc
14:08:29 <AnMaster> in either case, doing it as a fingerprint will have problems with unloading, but I guess you can just let ppl load it again
14:08:44 <ais523> yes, that would be the plan
14:09:17 <AnMaster> ais523, also, how would you specify what thread to come from in?
14:09:23 <AnMaster> or would it create a new ip each time?
14:09:39 <ais523> multithreading doesn't mix well with external calls
14:09:39 <AnMaster> new ip can only be created by duplicating an existing ip as it is now
14:09:58 <ais523> INTERCAL multithreading (-m) conflicts with INTERCAL external calls (-e), for instance
14:10:01 <AnMaster> ais523, ah skip -DCONCURRENT_FUNGE then iirc
14:10:02 <ais523> so each program may only use one or the other
14:10:13 <AnMaster> or something like that
14:10:17 <AnMaster> cmake knows better :9
14:10:18 <AnMaster> :)*
14:10:46 <ais523> hmm... an INTERCAL fork bomb works correctly
14:10:56 <ais523> (1) DO COME FROM (1) WHILE COME FROM (1)
14:11:10 <ais523> of course, they don't break your computer because all the threads share one process
14:11:13 <ais523> just like in Befunge
14:11:31 <AnMaster> ais523, oh and patches are welcome as long as they are not intercal interface specific and 1) follow current coding style 2) gives no new valgrind error 3) works fine both with boehm-gc and without
14:11:32 <ais523> (that's the closest I could get to the effect of kt, but it doesn't terminate)
14:11:50 <ais523> AnMaster: I'm a bit busy at the moment, but I'll look into it sometime
14:11:55 <AnMaster> ais523, also how would you handle q in befuge?
14:11:58 <AnMaster> befunge*
14:12:11 <ais523> AnMaster: the same as an exit() command in C
14:12:14 <ais523> all programs exit
14:12:16 <AnMaster> ais523, and with your C bridge, how do you handle _exit()
14:12:22 <ais523> AnMaster: I exit
14:12:24 <AnMaster> that is a "fast down" iirc
14:12:28 <AnMaster> _exit != exit
14:12:30 <AnMaster> in C
14:12:39 <ais523> well, I exit without deallocating memory or closing filehandles, then
14:12:47 <ais523> and the OS has to clean up
14:12:56 <ais523> most OSs should be able to handle it
14:13:06 <ais523> DOS couldn't, but you don't write _exit in DOS unless you know what you're doing
14:13:23 <AnMaster> ais523, you wouldn't use DOS IF you know what you were doing ;P
14:13:39 <ais523> AnMaster: some people like a challenge ;-)
14:14:01 <AnMaster> well yes... but not write a OS from scratch instead
14:14:01 <AnMaster> ?
14:14:26 <ais523> AnMaster: no computers I dare to run it on
14:14:36 <AnMaster> qemu
14:14:43 <ais523> I have one program (the MiniMAX interp) written in machine code, but I've never dared run that either
14:14:53 <AnMaster> ais523, again, qemu
14:15:04 <ais523> sounds like an interesting idea, I may install it
14:15:15 <AnMaster> ais523, or vmware or something similar
14:15:36 <AnMaster> ais523, for decent performance with qemu you want kqemu too iirc
14:15:43 <AnMaster> some kernel module for speeding things up a bit
14:19:34 <AnMaster> ais523, would depending on complex.h be an issue for you?
14:19:43 <AnMaster> considering CPLI fingerprint
14:19:47 <ais523> probably not
14:19:47 -!- Judofyr has joined.
14:19:54 <AnMaster> and I think even in recent versions gcc got issues with it
14:20:12 <AnMaster> as in "not exactly the way C99 says it should be"
14:20:22 <AnMaster> ais523, but well you could take a fingerprint out if you didn't like it
14:20:23 <ais523> the only points of contact between your program and mine when I'm using the external calls system are ick_ec.h and my own linker
14:20:50 <ais523> which basically just looks through the output of cpp and changes special predefined tokens into labels which point to each other in the right way
14:21:07 <AnMaster> ./src/ick_ec.h
14:21:07 <AnMaster> ./include/ick_ec.h
14:21:07 <AnMaster> ??
14:22:09 <AnMaster> ais523, before you include it into cfunge fork thing, please make it stop depending on tab == 8 spaces
14:22:10 <AnMaster> :/
14:22:16 <ais523> AnMaster: it doesn't
14:22:17 <AnMaster> it is unreadable when tabstop is set at 4
14:22:25 <ais523> oh, that
14:22:26 <AnMaster> or two
14:22:31 <ais523> I can M-x untabify if you like
14:22:38 <ais523> but tab=8 is pretty much a standard for new code
14:22:40 <AnMaster> ais523, well astyle is a great tool
14:22:50 <AnMaster> ais523, see my tab standard in cfunge :)
14:22:54 <AnMaster> it is way better IMO
14:22:56 <ais523> tabs vs. spaces vs. tab=8, spaces for 2/4/6 is a matter of personal preference
14:23:05 <AnMaster> and what a lot of modern code does
14:23:11 <AnMaster> tab for each indent level
14:23:22 <ais523> AnMaster: but sometimes I indent more than 8 levels
14:23:24 <AnMaster> space to adjust to line up at parentheses after that
14:23:26 <ais523> s/8/10/
14:23:32 <ais523> so that would be unreadable on an 80-character screen
14:23:58 <AnMaster> ais523, hm? well just change tab stop then?
14:23:58 <AnMaster> in the editor
14:24:10 <ais523> AnMaster: tab set to anything other than 8 is evil
14:24:22 <Deewiant> 3 here \o
14:24:24 <AnMaster> well in cfunge code you will have to live with that
14:24:29 <ais523> because then other people's code will break at your end, and vice versa
14:24:38 <AnMaster> Deewiant, indeed and 4 here, yet your code is perfectly readable
14:24:39 <ais523> it's fine to indent by smaller amounts, and I usually do
14:24:41 <AnMaster> ais523, no it won't
14:24:43 <Deewiant> nothing will break if you use tabs correctly
14:24:53 <AnMaster> tab for each indent level
14:24:54 <Deewiant> as in, "indent by one level" instead of "go to next offset of N spaces"
14:25:05 <AnMaster> then spaces after that to line up at parentheses
14:25:16 <AnMaster> do not use tab after any non-whitespace on a line
14:25:28 <AnMaster> that works perfectly
14:25:31 <ais523> AnMaster: most INTERCAL code is written as a tab followed by a line
14:25:37 <ais523> or a line label, then a tab, then the line
14:25:47 <ais523> so you'll have a hard time reading it if tab != 8
14:25:50 <AnMaster> ais523, we were discussing C here I think?
14:26:05 <ais523> AnMaster: you mean your editor has different tab-stop settings for different types of input?
14:26:15 <AnMaster> sure, very easy in emacs
14:26:18 <ais523> so if you copy/paste a fragment of INTERCAL into a comment in a C file, it'll look different?
14:26:25 <AnMaster> -*- mode: C; coding: utf-8; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*-
14:26:32 <AnMaster> is what I put at the top of every file
14:26:50 <ais523> why does that not allow indent-style too?
14:26:57 <AnMaster> ais523, eh?
14:27:01 <ais523> I have to use eval to set the c-indent-style in the mode line
14:27:09 <ais523> because writing c-indent-style:bsd doesn't work
14:27:12 <AnMaster> ais523, ah well no idea
14:27:21 <AnMaster> ais523, anyway I use my own indent style
14:27:24 <AnMaster> not bsd at all
14:27:40 <ais523> bsd's the best approximation to the one I use in Emacs' menus
14:27:43 <AnMaster> from the kdevelop project file:
14:27:44 <AnMaster> <AStyle IndentPreprocessors="1" FillCount="4" PadParenthesesOut="0" IndentNamespaces="1" IndentLabels="1" Fill="Tabs" MaxStatement="40" Brackets="Linux" MinConditional="1" IndentBrackets="0" PadParenthesesUn="1" BlockBreak="0" KeepStatements="0" KeepBlocks="0" BlockIfElse="0" IndentSwitches="1" PadOperators="1" FStyle="UserDefined" IndentCases="0" FillEmptyLines="0" BracketsCloseHeaders="0" BlockBr
14:27:45 <AnMaster> eakAll="0" PadParenthesesIn="0" IndentClasses="1" IndentBlocks="0" FillForce="0" />
14:27:46 <AnMaster> :)
14:27:51 <ais523> and I generally just let it autoindent like that, fixing it myself if needed
14:28:02 <AnMaster> ais523, see the astyle stuff from kdevelop
14:28:05 <AnMaster> that is how I do it
14:28:16 <ais523> I have indent installed, but it isn't very good
14:28:25 <AnMaster> ais523, astyle is way better than indent
14:28:31 <ais523> I guessed
14:30:38 <AnMaster> bbl food
14:39:51 <AnMaster> back
14:54:19 <AnMaster> ais523, it seems those kdevelop options match astyle --indent-preprocessor --indent-namespaces --indent-labels --indent=tab=4 --max-instatement-indent=40 --brackets=linux --min-conditional-indent=1 --unpad=paren --indent-switches --pad=oper
14:54:23 <AnMaster> not prefectly
14:54:28 <AnMaster> but almost
14:54:36 * AnMaster tries to find what is missing
14:54:38 -!- RedDak has joined.
15:02:34 -!- shinkuzin has joined.
15:07:23 -!- RodgerTheGreat has joined.
15:13:34 <ais523> AnMaster: astyle badly messes up some of the INTERCAL source files
15:14:00 <AnMaster> no idea about that
15:14:20 <AnMaster> it works for cfunge apart from a few cases
15:14:41 <AnMaster> code compiles in both cases
15:14:46 <ais523> see http://filebin.ca/mxyxwt/perpet.c
15:14:55 <ais523> the indentation doesn't even finish at the left margin
15:15:03 <ais523> (that was using your settings, by the way)
15:15:09 <ais523> and all the comments are badly messed up
15:15:17 <ais523> at least, the multi-line ones
15:15:34 <AnMaster> ais523, I'd say that file is pretty messed up before
15:15:40 <ais523> no it wasn't
15:16:03 <AnMaster> if (tp->exechance != 100 && tp->exechance != -100) { /* AIS: The double-oh-seven operator prevents
15:16:04 <AnMaster> coopt working. However, syslib contains a
15:16:04 <AnMaster> well
15:16:15 <AnMaster> having a comment at the end of the line like that is bad style
15:16:19 <AnMaster> since it is multiline
15:16:20 <ais523> see http://elliotthird.org/mirror/c-intercal/ick-0.28/src/perpet.c
15:16:27 <ais523> AnMaster: it wasn't on the end of the line before
15:16:41 <ais523> it was presumably on the same line as a { which was /below/ the IF
15:16:42 <AnMaster> ais523, probably too many #ifdef confused it
15:16:44 <ais523> s/IF/if/
15:16:53 <ais523> AnMaster: it's not the ifdefs that confuse it AFAICT
15:16:58 <ais523> because the indentation is sane near them
15:17:06 <AnMaster> well if you want the style where if and { are on different lines just change the options
15:17:28 <AnMaster> having a comment after a { is pretty bad IMO
15:17:39 <ais523> and why does it put seven spaces before the final }?
15:18:21 <AnMaster> no clue
15:18:31 <ais523> also, things like #ifdef are sometimes indented and sometimes aren't
15:18:33 <AnMaster> ais523, it obviously failed at some construct in that file
15:19:09 <AnMaster> ais523, about ifdef indention, astyle doesn't do that at all
15:19:15 <AnMaster> so look in the original source for that
15:19:17 <ais523> yes it does
15:19:22 <AnMaster> --indent-preprocessor is only for:
15:19:26 <ais523> --min-conditional-indent=1
15:19:29 <AnMaster> #define foo(a,b) \
15:19:32 <AnMaster> blah blah
15:19:39 <AnMaster> ais523, no --min-conditional-indent=1 is for normal if
15:19:40 <AnMaster> like:
15:19:51 <AnMaster> if (very long line blah blah &&
15:19:55 <AnMaster> here goes more
15:20:12 <ais523> well, the bit starting with remspace -= strlen(" -lickec"); is completely screwed up
15:20:22 <ais523> and it looks completely fine to me
15:20:28 <ais523> maybe astyle doesn't like -=?
15:20:44 <AnMaster> ais523, I'm quite sure it didn't cause issues for me
15:20:53 <AnMaster> so probably it got confused somewhere before there
15:25:58 <AnMaster> ais523, does it work on other source files?
15:26:09 <ais523> feh2.c breaks slightly, but isn't too bad
15:26:23 <AnMaster> and most "clean" source files
15:26:25 <ais523> let me try unravel.c; I wrote that one entirely myself so its indentation was consistent beforehand
15:26:55 <AnMaster> ais523, I don't think it got an issue with existing indention really, but it *does* with very very complex #ifdef
15:27:13 <AnMaster> ie, where there is a { inside *one* #ifdef #else #endif
15:27:15 <AnMaster> but not in the other
15:28:09 <ais523> AnMaster: I don't do that normally (although there's one example in ick-wrap.c)
15:28:24 <ais523> although I do it with ( in order to use snprintf if available and sprintf otherwise
15:28:41 <AnMaster> ais523, that is very likely to confuse it
15:28:48 <AnMaster> I'd use a varadic macro instead
15:28:52 <ais523> it seemed to handle that bit fine
15:28:53 <AnMaster> but then you would have C99 anyway
15:28:58 <AnMaster> so wouldn't really help heh
15:29:00 <ais523> but got confused later on
15:29:24 <ais523> wow, it's really hard to read code with { on the same line as the if
15:29:28 <AnMaster> also sometimes when {-nesting is not the same at the start of #ifdef and the end of the block
15:29:34 <AnMaster> ais523, hm, change that
15:29:34 <AnMaster> easy
15:29:40 <AnMaster> just select another style
15:29:43 <ais523> I know
15:29:51 <ais523> but I was seeing how it worked on your style
15:30:02 <AnMaster> --brackets=break maybe
15:30:07 <AnMaster> I prefer --brackets=linux
15:30:27 <AnMaster> ais523, I find it easier to read
15:30:40 <AnMaster> lots of line with a single { on just confuses
15:30:45 <AnMaster> locality of reading ;)
15:30:47 <ais523> yes, when I was experimenting with my own styles I used --brackets=break
15:30:58 <AnMaster> and anyway, astyle got lots of options
15:31:05 <ais523> but it's hard to tell between a multiline if and a single-line if when the { is hidden at the end of the preceding line
15:31:13 <ais523> you have to look down a couple more lines to tell what the scope of the if is
15:31:19 <ais523> and it's worse if there are comments in between
15:31:22 <AnMaster> hm
15:32:15 <AnMaster> ais523, I work at 1400x1050, 20", something like Courier New, font size 10
15:32:34 <ais523> that would explain why you got away with so much indentation
15:32:40 <ais523> I tend to stick to 80-char lines
15:32:40 <AnMaster> slight antialias, with the patent encumbered hinting on
15:32:57 <AnMaster> ais523, well I try to not go above 80 chars in README and such
15:32:58 <ais523> that's full screen in DOS, but one typical-sized Emacs window on Linux
15:33:11 <ais523> (it loads at 80 chars wide unless/until I resize it)
15:33:18 <AnMaster> ais523, you can change default size in .emacs iirc
15:33:26 <ais523> yes, but I like this default
15:33:29 <AnMaster> I think I display around 120 chars wide
15:33:49 <AnMaster> but, in kate I got a think grey vertical line at column 80
15:33:57 <AnMaster> don't know if that is possible in emacs
15:34:06 <ais523> it probably is
15:34:14 <ais523> but I find that sort of setting very hard to find
15:34:22 <ais523> because it doesn't seem to be in Customize for some reason
15:34:24 <AnMaster> yeah and wouldn't work in non-X mode
15:34:45 <AnMaster> I use both text mode and X mode
15:34:47 <AnMaster> quite a lot
15:35:02 <AnMaster> ais523, anyway with tab stop 4 my code doesn't look bad
15:35:20 <AnMaster> for bash I even use tab stop 2
15:35:21 <AnMaster> :)
15:35:25 <ais523> I prefer 2 for C because I'm horizontal-space-challenged
15:35:31 <ais523> I've been known to use 1 for Brainfuck
15:36:37 <AnMaster> hah
15:36:48 <AnMaster> ais523, well then just set tab stop 2
15:36:50 <AnMaster> very easy
15:37:06 <ais523> AnMaster: yes, changing indentation size is rarely a problem
15:38:00 <AnMaster> anyway I checked with tab stop 4 in interpreter.c, of a total of 607 lines, just 13 lines are wider than 80 chars
15:38:05 <AnMaster> and those are mostly long strings
15:38:06 <AnMaster> like
15:38:15 <AnMaster> fprintf(stderr,
15:38:15 <AnMaster> "WARN: Unknown instruction at x=%" FUNGEVECTORPRI " y=%" FUNGEVECTORPRI ": %c (%" FUNGEDATAPRI ")\n",
15:38:15 <AnMaster> ip->position.x, ip->position.y, (char)opcode, opcode);
15:38:32 <AnMaster> hard to break such up, breaking a string up is not something I like
15:39:38 <AnMaster> ais523, I don't know if astyle can do it, but I know indent can: put the return type on a different line from the rest
15:39:39 <AnMaster> like:
15:39:48 <AnMaster> static inline void
15:39:49 <AnMaster> PrintUnknownInstrWarn(FUNGEDATATYPE opcode, instructionPointer * restrict ip)
15:39:51 <AnMaster> {
15:39:51 <AnMaster> code
15:39:52 <AnMaster> }
15:39:55 <AnMaster> ais523, ^
15:40:09 <AnMaster> don't think astyle will change current such line break
15:40:15 <AnMaster> gnu indent can do it
15:40:25 <ais523> astyle doesn't mess with line breaks at all, apart from at { } and ;
15:40:35 <ais523> indent goes further than astyle does in terms of messing around with the code
15:40:46 <AnMaster> ais523, well it can be set to add newlines on stuff like:
15:40:54 <AnMaster> foo(x); bar(y);
15:41:01 <AnMaster> or { blah blah }
15:41:10 <AnMaster> ah yes that's what you said
15:41:17 * AnMaster should read properly first heh
15:41:37 * ais523 is running their Brainfuck reindenter on Lost Kingdoms to see if it works
15:41:50 <ais523> I spotted one bug already: blank lines in the source break it
15:42:00 <AnMaster> ais523, oh? link to that reindenter?
15:42:22 <ais523> I pasted it once, but it'll be easier to paste it again than to find the link
15:42:24 <AnMaster> ais523, well lost kingdoms will be a mess
15:42:31 <ais523> it's a part of my collection of esolang modes for Emacs
15:42:37 <AnMaster> it was auto generated after all
15:42:45 <AnMaster> from basic I think
15:42:53 <ais523> yes, I know
15:43:02 <ais523> but it'll be a good test case, I hope
15:43:11 <AnMaster> mhm
15:43:12 <ais523> torture-test case, if nothing else
15:43:20 <AnMaster> hahah
15:43:23 <ais523> I've had the idea of converting it to Fugue at some point
15:43:34 <ais523> but that would last several years in terms of the generated music
15:43:47 <ais523> and I'll need to come up with a portable way to do it
15:43:47 <AnMaster> well brainfuck already lacks very much context info
15:43:52 <AnMaster> so it would expand even more
15:44:04 <AnMaster> basic to befunge directly would probably work better
15:44:05 <ais523> Prelude is normally shorter than BF because you can optimise constants
15:44:15 <AnMaster> Prelude?
15:44:21 <AnMaster> some IDS isn't it?
15:44:23 <ais523> Prelude converts to Fugue
15:44:31 <ais523> ah, you misread Fugue as Funge
15:44:39 <AnMaster> ais523, ah yes I did
15:44:42 <ais523> it's a music-based programming language
15:44:46 <AnMaster> ah I see
15:44:59 <ais523> I wrote a hello world in it, compiled from BF
15:45:09 <AnMaster> I see
15:45:21 <ais523> I managed to make a compiler system, but it was sufficiently nonportable that I don't think it would run on any computer other than the one it ran on
15:45:31 <AnMaster> I see
15:45:39 <AnMaster> ais523, not posix then?
15:45:54 -!- shinkuzin has quit (Read error: 113 (No route to host)).
15:46:02 <ais523> I generated output in a Fugue precursor output, then used VBA on Word to generate a stream of keystrokes that would type the output into a proprietary MIDI editor that happened to be on that computer
15:46:17 <ais523> and I had to heavily customise its keymappings first to avoid needing to use control or alt
15:46:20 <AnMaster> eww
15:46:33 <ais523> I'll have to find a better way
15:46:39 <AnMaster> ais523, why not just generate midi using some library for it?
15:46:51 <AnMaster> I think there are libraries for midi
15:46:53 <ais523> AnMaster: this was back in my Windows days
15:46:58 <AnMaster> ah
15:47:00 <ais523> the concept of using external libraries was a joke, more or less
15:47:13 <AnMaster> ais523, yeah dll is a joke
15:47:18 <AnMaster> apart from system dlls
15:47:25 <ais523> no, they're jokes too
15:47:30 <AnMaster> ais523, well ppl use them
15:47:41 <ais523> only because they have no choice
15:47:45 <AnMaster> yeah
15:48:15 <AnMaster> ais523, well rosegarden or timidity must have midi parsing code
15:48:28 <AnMaster> one is a editor for midi (rosegarden, KDE based)
15:48:38 <ais523> yes, I have both installed
15:48:40 <AnMaster> and the other is a software midi player
15:48:51 <ais523> anyway, here it is: http://pastebin.ca/969225
15:48:56 <ais523> it's still a little buggy, though
15:49:10 <AnMaster> well timidity is certainly buggy yes
15:49:16 <AnMaster> I use hardware based midi :)
15:49:32 <ais523> it wasn't timidity I was referring to, which I'm pretty fond of
15:49:37 <ais523> but to esolangs.el, which I just pasted
15:49:40 <AnMaster> #
15:49:41 <AnMaster> ("(:\\*)" . font-lock-constant-face)
15:49:41 <AnMaster> #
15:49:41 <AnMaster> ("(::\\*\\*)" . font-lock-constant-face)
15:49:41 <AnMaster> #
15:49:41 <AnMaster> ("(:::\\*\\*\\*)" . font-lock-constant-face)
15:49:43 <AnMaster> #
15:49:45 <AnMaster> ("(::::\\*\\*\\*\\*)" . font-lock-constant-face)
15:49:47 <AnMaster> huh?
15:49:51 <AnMaster> it goes on like that
15:50:50 <ais523> AnMaster: because Emacs regexps aren't very powerful
15:50:56 <ais523> so they can't recognise Underload constants
15:51:02 <AnMaster> ah
15:51:27 <AnMaster> ais523, are you sure there are no pcre bindings or such for emacs?
15:51:40 <AnMaster> I seem to recall that there are python bindings
15:51:44 <AnMaster> pymacs or something
15:51:53 <ais523> probably, but they don't hook into Font Lock AFAIK
15:52:11 <AnMaster> hm ok true
15:52:52 <ais523> how much Emacs-lisp do you know?
15:52:55 <ais523> I'm not very good at it
15:53:33 <ais523> although I have resorted to evil tricks in the past, like doing string processing on numbers because Emacs couldn't handle them as numbers due to it not supporting a full 32-bit range for integers
15:54:51 <AnMaster> <ais523> how much Emacs-lisp do you know?
15:54:53 <AnMaster> not much
15:55:07 <AnMaster> just coded a bit for erc
15:55:13 <AnMaster> so not very much indeed
15:55:21 <ais523> pity, I was hoping someone who knew more than me could go through it and say "you're doing it all wrong! you should be doing it like this!"
15:55:32 <AnMaster> tried #emacs ?
15:55:56 <ais523> it's not really worth bothering them with something as pointless as esolangs.el until the code is a bit more mature
15:56:12 <ais523> (e.g. the BF indenter failing on blank lines problem, but I think I know what's causing that)
15:56:38 <ais523> it doesn't support GNU-style indentation, though, just the equivalents of K&R and BSD, and any mix between them
15:57:08 <ais523> it preserves newlines and doesn't add new ones, at the moment, so they determine what sort of indentation is wanted
15:57:47 <ais523> although I'm planning to add an auto-indenter that sorts out newlines: remove existing newlines, change [ and ] to \n[\n and \n]\n, change \n[\n-\n]\n to [-], and reindent
16:01:08 <ais523> BTW, C-g seems to fail as an interrupt key on GTK Emacs on Ubuntu, which is annoying
16:01:53 <AnMaster> typedef int bigint_t __attribute__ ((__mode__ (__TI__))); <-- seems that give 128 bit integers, a gcc hack of course
16:01:55 <AnMaster> hm...
16:02:56 <AnMaster> ais523, no idea about gtk emacs
16:03:21 <ais523> AnMaster: gcc should support 2^n bit integers for all n >= 3
16:03:26 <ais523> I doubt it does, though
16:03:28 <AnMaster> __int128_t hm __uint128_t
16:03:38 <AnMaster> ais523, "should"?
16:03:44 <AnMaster> and what should the types be called?
16:03:45 <ais523> in my opinion
16:03:51 <ais523> and why not just use int128_t?
16:03:58 <ais523> it's reserved by C99 for that purpose
16:04:04 <AnMaster> no clue
16:04:09 <ais523> an implementation is allowed to define intanything_t
16:04:24 <ais523> for any positive integral value of anything that's a multiple of CHAR_BIT
16:04:29 <AnMaster> int12_and_a_half_t?
16:04:42 <AnMaster> oh wait that sounds like TURKY BOMB
16:04:44 <ais523> the _least and _fast versions can have any positive integral value because padding is allowed
16:04:59 <AnMaster> ais523, I still want an "_most"
16:05:07 <AnMaster> to define not bigger than this
16:05:46 <ais523> int_most16_t would therefore be int on DOS, short on Linux, and not implementable at all on some 32 bit DSPs?
16:05:48 <AnMaster> ais523, anyway I lack any clue about printf modifier for int128_t
16:06:01 <AnMaster> ais523, aye that would be the case
16:06:09 <AnMaster> ais523, it could be char too
16:06:12 <ais523> if they had used int128_t, then they would have put a relevant printf modifier in stdint.h
16:06:14 <AnMaster> as I said at most
16:06:24 <ais523> CHAR_BIT is 32 on some DSps
16:06:30 <AnMaster> ouch
16:06:49 <AnMaster> ais523, so a byte there is 32 bits XD
16:06:52 <ais523> yes
16:07:01 <ais523> they can't sensibly address anything smaller without using bitwise arithmetic
16:07:02 <AnMaster> what is a DSP exactly
16:07:07 <ais523> digital signal processor
16:07:22 <AnMaster> hm
16:07:22 <ais523> a bit of hardware designed to do numerical computations that are useful for processing signals
16:07:34 <ais523> so they're really good at doing Fourier Transforms, for instance
16:07:47 <ais523> generally speaking they have some ridiculously specific asm instructions
16:08:09 <fizzie> And fancy addressing modes, like hardware-based circular buffer access.
16:08:21 <ais523> yes, and I've actually used bit-reversed addressing
16:08:30 <AnMaster> $ grep -R int128 /usr/include/
16:08:30 <AnMaster> /usr/include/valgrind/libvex_ir.h: Ijk_Sys_int128, /* amd64/x86 'int $0x80' */
16:08:31 <AnMaster> that is all
16:08:35 <AnMaster> interesting
16:08:53 <AnMaster> and that one is not even related
16:09:14 -!- jix has joined.
16:09:23 <ais523> AnMaster: I got exactly the same results as you on that grep
16:09:52 <AnMaster> $ grep -R int128 /usr/x86_64-pc-linux-gnu/
16:09:57 <AnMaster> hits some binary matches
16:10:09 <AnMaster> $ strings /usr/x86_64-pc-linux-gnu/bin/strip | grep int128
16:10:10 <AnMaster> unsigned __int128
16:10:11 <AnMaster> nice
16:11:31 <tejeez> dsp can also mean digital signal processing in general, not necessarily hardware
16:11:49 <ais523> heh, when I run strings on ick I get the error message Failed! almost at the end
16:11:55 <AnMaster> <ais523> generally speaking they have some ridiculously specific asm instructions
16:11:56 <AnMaster> like?
16:12:07 <AnMaster> ais523, hahah
16:12:23 <AnMaster> (rnd >= 0) && (rnd <= 3)
16:12:29 <AnMaster> debugging data
16:12:55 <ais523> multiply together two registers and add the result to an accumulator, then load those two registers from memory through two pointers which are then incremented, then optionally store the value of another accumulator into memory
16:13:04 <AnMaster> ais523, nice on a stripped binary I get a list of fingerprints at the end
16:13:05 <AnMaster> but
16:13:07 <AnMaster> they are reversed
16:13:08 <ais523> that's a single asm instruction
16:13:14 <AnMaster> as in SYOT
16:13:15 <AnMaster> for TOYS
16:13:28 <AnMaster> and the source doesn't have reversed fingerprint names anywhere
16:13:50 <AnMaster> ais523, ok that is crazy
16:13:53 <ais523> oh, you can also subtract from the accumulator instead of add, and you can add or subtract 1, 2, or 3 words from the pointers rather than just incrementing
16:13:58 <AnMaster> ais523, what is the use for such an instruction?
16:14:05 <ais523> AnMaster: it actually has lots of uses
16:14:10 <AnMaster> oh?
16:14:15 <ais523> generally speaking you run it in a loop
16:14:22 <AnMaster> I see and?
16:14:24 <ais523> to do things like multiplying matrices
16:14:41 <ais523> and lots of calculations can be written in terms of multiplying matrices
16:14:41 <AnMaster> hm
16:15:02 <ais523> I've also seen it be used to take the squared magnitude of all complex numbers in a vector
16:15:06 <AnMaster> why have you programmed for DSPs?
16:15:13 <ais523> university project
16:15:16 <AnMaster> ah
16:15:31 <ais523> although I did get a stripped-down version of INTERCAL running on PICs
16:15:35 <AnMaster> so can a DSP do normal stuff?
16:15:35 <ais523> which are even less powerful
16:15:40 <ais523> AnMaster: yes, but not very well
16:15:46 <AnMaster> ais523, I know what a PIC is yes,
16:15:47 <ais523> because they tend not to have much memory
16:15:52 <AnMaster> I used one very simple once
16:15:55 <AnMaster> 12Fsomething
16:15:56 <ais523> say a few kilobytes of RAM at once
16:16:01 <AnMaster> 12F6*?
16:16:08 <ais523> AnMaster: I generally use the 16F series
16:16:20 <ais523> 12F would be even more primitive
16:16:21 <AnMaster> anyway I remember the serial port interrupt routine *shudder*
16:16:29 <AnMaster> ais523, it was, 32 instructions I think
16:16:41 <ais523> that sort of thing is enough to make me write the serial port routines in software
16:16:53 <AnMaster> ais523, I did write one, in asm yes
16:17:07 <ais523> the university has a C to PIC compiler
16:17:15 <ais523> but it was buggy and I preferred to write in asm
16:17:16 <AnMaster> ais523, well with 1 kb ram...
16:17:24 <AnMaster> eh
16:17:28 <AnMaster> 1 kb program memory
16:17:31 <AnMaster> even less ram
16:17:33 <ais523> on a PIC, the RAM is measured in tens of bytes, normally
16:17:44 <ais523> I vaguely remember that one version I used had 56 bytes memory
16:17:47 <ais523> but most of them have more
16:17:49 <AnMaster> ais523, yeah, don't remember exactly
16:18:14 <ais523> this explains why in PIC-INTERCAL, the NEXT stack has only 16 entries, and STASHes are limited to one member
16:18:16 <AnMaster> 12F629 it seems
16:18:30 <ais523> and I store abstention statuses in 1-bit integers to save space
16:18:49 <ais523> there is no such thing in C unless you use a bitfield, but some PIC C compilers support them anyway because they're so useful
16:19:06 <AnMaster> hah
16:19:26 <AnMaster> ais523, but you can't adress on bit-basis in pic iirc?
16:19:28 <AnMaster> or can you?
16:19:35 <ais523> you can
16:19:35 <AnMaster> I think it was using bytes of some size
16:19:38 <ais523> using bitwise instructions
16:19:38 <AnMaster> hm
16:19:43 <AnMaster> yeah
16:19:48 <ais523> there's a 'skip if bit n of register r is 0' instruction
16:19:53 <AnMaster> you can on anything with bitwise
16:20:00 <ais523> which is bitwise addressing, but only for literal addresses
16:20:03 <AnMaster> but I mean, you can't take a pointer to a bit
16:20:03 <ais523> you can't have bitwise pointers
16:20:32 <AnMaster> ais523, well I think you could on some historical systems heh
16:20:37 <ais523> but INDF is a bit of a tricky way to emulate pointers anyway, especially if they're nested
16:20:46 <ais523> e.g. a->b->c
16:20:49 <AnMaster> true
16:21:03 <ais523> it's useful for accessing things in the wrong bank, though; that's often faster than bank switching
16:21:04 <AnMaster> ais523, anyway it was years ago I coded for PIC
16:21:14 <AnMaster> don't even remember most of the asm opcodes
16:21:23 <ais523> I can still remember many of them
16:21:37 <ais523> PIC asm is much better than x86 asm
16:21:43 <AnMaster> well yes
16:21:45 <AnMaster> it is RISC
16:21:50 <AnMaster> x86 is CISC
16:21:59 <AnMaster> so so much more to keep track of on x86
16:23:01 <ais523> well, x86 isn't nearly as CISC as DSPs can be
16:23:09 <ais523> it's more a medium instruction set computer
16:23:15 <AnMaster> hm
16:23:33 <AnMaster> ais523, where is the source of PIC-INTERCAL?
16:23:42 <ais523> it's in the C-INTERCAL compiler
16:23:43 <ais523> ick -P
16:23:54 <ais523> but most of the advanced features are disabled if you do that
16:23:56 <AnMaster> hm
16:24:31 <ais523> (INTERCAL parsing is sufficiently bad that other dialects of INTERCAL tend to get bolted onto something that has an INTERCAL parser built-in already)
16:24:47 <AnMaster> hahah
16:25:03 <fizzie> Incidentally, I've done an university project DSP programming thing too, for our "Digital Signal Processors and Audio Signal Processing" course.
16:25:11 <AnMaster> ais523, isn't it just a case of a bison/lex/yacc/whatever file
16:25:17 <AnMaster> I can't remember which does what of them
16:25:22 <ais523> AnMaster: have you /read/ it?
16:25:35 <AnMaster> ais523, nop I haven't looked at ick source
16:25:44 <ais523> the parsing takes place both in the flex file and in the bison file
16:26:07 <AnMaster> ais523, well what exactly is the difference between flex, bison and yacc?
16:26:10 <ais523> and there are interactions both ways for various complicated reasons
16:26:16 <ais523> flex generates lexical analysers
16:26:26 <ais523> so you give it a stream of characters, and it generates tokens
16:26:30 <AnMaster> ah ok
16:26:35 <ais523> bison takes the tokens and gives you a parse tree from them
16:26:46 <ais523> and yacc is the program that bison was based on, and is older
16:26:52 <AnMaster> ah
16:27:18 <AnMaster> ais523, I have seen programs that bison fail at, and only byacc can handle
16:27:35 <ais523> yes, the two languages are slightly different
16:27:46 <ais523> but hopefully parser.y works in both bison and yacc
16:28:18 <AnMaster> ais523, well the file in question didn't work under normal yacc either, it needed byacc
16:28:29 <ais523> it's a bit like writing files that are valid C and also valid C++; you can /almost/ do it just by writing C, but there are pitfalls to watch out for
16:28:51 <ais523> AnMaster: I can sort of imagine how to write a file like that, but it's hard to see how one would go about doing it accidentally
16:29:06 <AnMaster> ais523, no clue, it was from some shell
16:29:21 <AnMaster> netbsd mksh or something unusal like that
16:29:25 <AnMaster> don't remember exactly
16:29:36 -!- oklopol has joined.
16:29:38 <AnMaster> I have a collections of shells with an automated building system for them
16:29:50 <AnMaster> ais523, the build system unpacks and so on, written in bash
16:30:07 <ais523> have you seen dd/sh?
16:30:17 <AnMaster> I do have a few called sh
16:30:23 <AnMaster> $ ls /home/arvid/shells/
16:30:23 <AnMaster> README akanga bash ccsh dash fish ksh93 oksh pdksh psh sash sh shellbuild-lib tcsh
16:30:23 <AnMaster> STATUS ash build compile-tools es ftsh mksh osh posh rc scsh shellbuild shish zsh
16:30:47 <ais523> http://intercal.freeshell.org/ talks about what's effectively an esolang that they call dd/sh, which is basically POSIX sh + its builtins + dd
16:30:57 <AnMaster> ais523, ah it was some ash variant that needed byacc
16:31:08 <ais523> the result is Turing-complete and bf-complete, although they recommend that you also use rm to avoid a tempfile leak
16:31:47 <AnMaster> anyway you can code lots of things with just shell built ins
16:31:56 <AnMaster> at least if you use bash or ksh or some other modern shell
16:32:17 <AnMaster> zsh you can even do a irc *client* in pure zsh
16:32:30 <AnMaster> may be possible in bash but I wouldn't know how
16:32:40 <ais523> bash has no way to select AFAIK
16:32:44 <ais523> zsh was always better at piping
16:32:47 <AnMaster> ais523, yeah
16:32:54 <fizzie> There's at least one IRC client in bash.
16:32:55 <AnMaster> you can do loadables in bash however
16:33:02 <AnMaster> fizzie, pure bash?
16:33:07 <AnMaster> and irc client, not bot
16:33:12 <AnMaster> I wrote an irc bot in bash
16:33:13 <AnMaster> works fine
16:33:18 <ais523> bots are easier
16:33:22 <AnMaster> indeed
16:33:46 <ais523> I got ThutuBot to connect to freenode on several occasions, but I never managed to get it to join a channel
16:34:07 <ais523> I think it was confused by spurious control chars coming out of telnet, but am not sure
16:34:28 <fizzie> I'm quite sure it was pure bash; and a client, yes; I used it because it was the smallest binary to download with a GPRS link. I just can't seem to remember the name.
16:34:47 <ais523> a file written in pure bash isn't exactly a 'binary'
16:35:03 <AnMaster> ais523, you should have used netcat
16:35:13 <ais523> yes, I probably should
16:35:21 <ais523> how do you use netcat to get a two-way link going?
16:35:36 <AnMaster> ais523, see how envbot does it?
16:35:52 <ais523> where's the link to envbot source?
16:36:05 <AnMaster> http://envbot.org/trac/browser/anmaster-trunk/transport
16:36:11 <AnMaster> select the netcat module I guess
16:36:25 <AnMaster> ais523, it does use some named fifos
16:36:28 <AnMaster> don't worry about it
16:36:39 <ais523> no, I was using them too
16:36:50 <ais523> although I did make a named fifo alternative script for a University project
16:37:06 <AnMaster> eh?
16:37:07 <ais523> that was a wrapper around a shell command that opened various pipes and told it the file descriptors of the ends
16:37:35 <AnMaster> as you can see from the comment, I recommend other tools
16:37:55 <fizzie> According to my irclogs I had to port the bash IRC client to use netcat instead of the /dev/tcp/foo pseudo-files because Debian's bash is compiled without those. But I _still_ haven't mentioned the name of the client in that conversation.
16:38:14 <ais523> fizzie: that's pretty impressive
16:38:49 <AnMaster> fizzie, well yes, I know debian is stupid
16:39:00 <AnMaster> there are various rants in envbot source about it
16:39:50 <AnMaster> 42 dev-tcp:
16:39:50 <AnMaster> 43 The bash you use must support the pseudo device /dev/tcp. Debian is known
16:39:50 <AnMaster> 44 to disable this. Most other distros are sane and have it on.
16:39:53 <AnMaster> http://envbot.org/trac/browser/anmaster-trunk/README
16:39:56 <AnMaster> just one example
16:40:20 -!- ais523_ has joined.
16:40:30 <ais523_> OK, this is me online using netcat
16:40:36 <AnMaster> hah
16:40:42 <fizzie> Heh, I've been trying to find the client name earlier, too; my irclogs have something like (translated) "I wonder what was the name of that bash irc client. Can only find discussion about it, not the name of the thing."
16:40:43 <AnMaster> backspace may not work
16:40:46 <ais523_> doesn't strike me as being very different from telnet
16:41:00 <ais523_> let me test: b
16:41:09 <AnMaster> said b yes?
16:41:16 <ais523_> yes, it works, I think it's reading from stdin
16:41:25 <ais523_> I typed a backspace b
16:41:33 <AnMaster> ah
16:41:41 <AnMaster> ais523, of course it reads from stdin
16:41:43 <ais523_> and I'm benefitting from stdin's line-buffering
16:41:46 <AnMaster> where else would it read from?
16:42:09 * AnMaster wonders if you can do ctcp here?
16:42:14 <AnMaster> ais523, ^
16:42:41 * ais523_ gets annoyed at AnMaster for sending them lots of CTCPs
16:42:48 <AnMaster> two=
16:42:51 <AnMaster> that isn't lots
16:42:57 <ais523_> three
16:43:05 <AnMaster> nah the first was a /me
16:43:06 <ais523_> you did an ACTION immediately beforehand
16:43:09 <AnMaster> yes
16:43:19 <AnMaster> ais523, but most real clients doesn't show it as ctcp
16:43:23 <ais523_> and it arrived here, therefore you sent me three CTCPs
16:43:35 <AnMaster> ais523, servers with channel modes that block ctcps, does not block /me
16:44:07 <ais523_> maybe they should if they're sent to an individual user rather than a channel
16:44:24 <AnMaster> nop they don't
16:44:36 <ais523_> but I suppose that blocking messages like <CTCP>VERSION<CTCP> sent to a channel would be even more important than blocking them against individual users
16:44:43 <AnMaster> ais523, yeah
16:45:00 <ais523_> the CTCP spec says that I'm meant to be able to put a CTCP in the middle of a line! Why did nobody respond?
16:45:01 <AnMaster> they do block ctcp (anything but ACTION)
16:45:14 <AnMaster> ais523, because most clients do not understand that
16:45:27 <AnMaster> mine showed a small box with \001 in it
16:45:29 <ais523_> this is as bad as that technically-correct-SGML website that someone, I think maybe pikhq, linked to a while ago
16:45:41 <AnMaster> ais523, oh? link?
16:45:53 <Deewiant> http://pikhq.nonlogic.org/test.html
16:45:53 <ais523_> it validated, but with lots of warnings about most browsers not understanding it
16:46:07 <ais523> http://pikhq.nonlogic.org/test.html
16:46:20 <AnMaster> ais523, as Deewiant just said
16:46:39 <ais523_> yes, messages can cross quite effectively on IRC
16:46:54 <ais523_> especially when I'm not paying attention in an effort to finish typing my message
16:47:05 <ais523_> or in this case copy/pasting
16:47:46 -!- ais523_ has left (?).
16:48:41 <AnMaster> ais523, of the browsers I tried only lynx could show that page
16:49:02 <ais523> AnMaster: that single line deserves to be qdb'd
16:49:04 <AnMaster> I tried: firefox, konqueor, links2, w3m and lynx
16:49:18 <fizzie> I think the client might've been this one, but the code really isn't very impressive. It seems to just sort-of alternate between reading the stdin and the IRC fd. http://www.darkwired.org/~dodo/code/junk/pre/bairc/releases/bairc-1.3.bash
16:49:23 <AnMaster> ais523, haha
16:49:37 <AnMaster> ais523, don't have elinks installed
16:52:04 <fizzie> elinks doesn't seem to like it.
16:52:15 <AnMaster> ok
16:52:18 <AnMaster> lynx is best
16:52:25 <ais523> Firefox just shows a blank page with no title
16:52:38 <AnMaster> ais523, same as all the others did basically
16:52:49 <AnMaster> except lynx
16:52:57 <fizzie> Elinks shows "</>" as the title, a "</>"-labeled link to http://pikhq.nonlogic.org/foo and the text "</> </>".
16:53:32 <AnMaster> the link works in lynx
16:54:05 <ais523> I actually visited that link in fizzie's comment, and started laughing
16:54:31 <fizzie> My version of lynx makes the whole "This stuff doesn't show at all, but only because HTML renderers suck." text the link, and the "Valid link" text isn't shown. Not quite sure how it's supposed to work, though.
16:54:47 <AnMaster> fizzie, ah true
16:54:55 -!- thutubot has joined.
16:54:56 <AnMaster> fizzie, but way better than the others
16:54:59 <ais523> yay!
16:55:11 <ais523> now I just have to remember which commands I programmed into it
16:55:12 <AnMaster> ais523, fizzie someone should file a bug to mozilla about that page breaking ;)
16:55:14 <ais523> \hello
16:55:14 <thutubot> Hello, ais523!
16:55:17 <AnMaster> \helop
16:55:19 <AnMaster> \help
16:55:22 <AnMaster> \hello
16:55:23 <thutubot> Hello, AnMaster!
16:55:28 <ais523> I think it's just got \hello and \quit at the moment
16:55:32 <AnMaster> \quit
16:55:32 -!- thutubot has quit (Client Quit).
16:55:35 <AnMaster> ah yes it does
16:55:36 <fizzie> What, no "!list"?
16:55:38 <AnMaster> (sorry)
16:55:54 <ais523> now I have to come up with something useful to do with the world's first IRC bot written in Thutu
16:56:12 <AnMaster> ais523, is it same as thue?
16:56:14 <AnMaster> or?
16:56:19 <ais523> no, it's my own language
16:56:26 <ais523> think of it as Thue with regular expressions and flow control
16:56:29 <ais523> http://esolangs.org/wiki/Thutu
16:57:53 <AnMaster> ais523, isn't Thue turing complete?
16:58:01 <AnMaster> so you could write a irc bot in thue?
16:58:06 <ais523> it's Turing-complete
16:58:10 <ais523> but I'm not sure about BF-complete
16:58:14 <AnMaster> hm ok
16:58:15 <ais523> because its I/O is somewhat primitive
16:58:28 <ais523> Thutu is nicer to work with, anyway
16:58:41 <AnMaster> btw it would be possible to do a irc bot in befunge without any external tool
16:58:43 <AnMaster> just painful
16:58:58 <AnMaster> there is the SOCK fingerprint
17:07:04 -!- thutubot has joined.
17:07:15 <ais523> \ul (:aSS):aSS
17:07:15 <thutubot> (:aSS):aSS
17:07:26 <ais523> \ul (x):::::*****S
17:07:27 <thutubot> xxxxxx
17:07:43 <ais523> be careful with it, though, it'll go into an infinite loop on most invalid input
17:07:47 <ais523> to \ul, that is
17:08:50 <ais523> actually, I'm not sure, maybe it'll just reply with garbage
17:08:58 <ais523> \ul (((unbalanced
17:09:08 <ais523> \ul (did I break it?)S
17:09:17 <ais523> yes, it goes into an infinite loop
17:09:21 -!- thutubot has quit (Remote closed the connection).
17:09:32 -!- thutubot has joined.
17:10:41 <ais523> !daemon ul bf http://pastebin.ca/raw/367774
17:11:26 <ais523> \ul ((!ul )Sa(\ul )~*aS(:^)S):^
17:11:27 <thutubot> !ul (\ul ((!ul )Sa(\ul )~*aS(:^)S)):^
17:11:41 <ais523> !ul (EgoBot, are you working?)S
17:11:43 <EgoBot> EgoBot, are you working?
17:11:56 <ais523> OK, there must have been a mistake in the input I gave to ThutuBot
17:12:06 <ais523> oh, of course
17:12:45 <ais523> \ul ((!ul )Sa(\ul )~*(:^)*aS(S)S):^
17:12:45 <thutubot> !ul (\ul ((!ul )Sa(\ul )~*(:^)*aS(S)S):^)S
17:12:47 <EgoBot> ul ((!ul )Sa(ul )~*(:^)*aS(S)S):^
17:13:14 <ais523> hmm, Egobot's mishandling backslashes. That could be bad for this...
17:13:29 <Deewiant> escape it?
17:13:44 <ais523> writing a quine that escapes backslashes in itself is harder
17:13:53 <ais523> because all characters are given literally in Underload
17:14:05 <ais523> maybe I should just switch thutubot to a different escape character
17:14:07 <ais523> \quit
17:14:07 -!- thutubot has quit (Client Quit).
17:15:31 -!- thutubot has joined.
17:15:35 <ais523> +hello
17:15:35 <thutubot> Hello, ais523!
17:15:43 <ais523> +ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^
17:15:44 <thutubot> !ul (+ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^)S
17:15:47 <EgoBot> +ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^
17:15:47 <thutubot> !ul (+ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^)S
17:15:49 <EgoBot> +ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^
17:15:49 <thutubot> !ul (+ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^)S
17:15:51 <EgoBot> +ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^
17:15:51 <thutubot> !ul (+ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^)S
17:15:52 <AnMaster> \quit
17:15:53 <AnMaster> spam
17:15:53 <EgoBot> +ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^
17:15:53 <thutubot> !ul (+ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^)S
17:15:55 <EgoBot> +ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^
17:15:55 <thutubot> !ul (+ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^)S
17:15:57 <AnMaster> +quit
17:15:57 -!- thutubot has quit (Client Quit).
17:15:57 <EgoBot> +ul ((!ul )Sa(+ul )~*(:^)*aS(S)S):^
17:15:58 <ais523> +quit
17:16:11 <ais523> well, it works, anyway
17:16:29 -!- thutubot has joined.
17:16:39 <ais523> that's the first time I've done a bot loop in pure Underload, I think
17:17:08 <ais523> and it's meta-esolangy because the thutubot Underload interp's written in Thutu, and the EgoBot Underload interp's written in Brainfuck (by Keymaker)
17:22:59 -!- CakeProphet has joined.
17:23:44 <thutubot> Hello, CakeProphet!
17:23:58 <oklopol> yay, oklotalk has a parse
17:23:59 <oklopol> r
17:24:03 <CakeProphet> :)
17:24:04 <CakeProphet> :D
17:24:06 <CakeProphet> :)
17:24:07 <CakeProphet> :D
17:24:10 <CakeProphet> Hello you bastards.
17:24:20 * ais523 has written an IRC bot in Thutu
17:24:22 <oklopol> even CakeProphet may have heard about oklotalk, it's just taken me that long.
17:24:25 <ais523> which runs Underload programs
17:24:31 <oklopol> ais523: cewl :D
17:24:37 <ais523> oklopol: I'm vaguely aware of it
17:24:43 <ais523> but can't remember much about what it does
17:24:47 <oklopol> oklotalk?
17:24:48 <ais523> +ul (:aSS):aSS
17:24:48 <thutubot> (:aSS):aSS
17:24:53 <ais523> oklopol: yes
17:25:00 <oklopol> well it's a fairly large thing
17:25:15 <oklopol> currently, i just have a prefix-kinda parser for it
17:25:23 <oklopol> because the actual parsing is not that easy
17:25:25 <CakeProphet> ....no. no I have not.
17:25:46 <CakeProphet> does anyone want to start a life insurance company with me? I have a brilliant idea to defeat all competition.
17:25:47 <oklopol> current factorial (= fact {(-> 1 1) (-> n (* n (out (' (- n 1)))))}) (fact 4)
17:26:18 <oklopol> with actual oklotalk parsing it would be,,,
17:26:36 <CakeProphet> looks like demented Lisp.
17:26:44 <oklopol> fact={1->1;N->N*out'(n-1)};fact 4
17:26:57 <oklopol> CakeProphet: it's sexps, so, duh
17:27:15 <CakeProphet> rofl... sexps. What a dirty phrase.
17:27:23 <ais523> I have a massive lang project which is about 2/3 of a spec and a parser at the moment
17:27:29 <CakeProphet> Did you know Christianity has a lot of sects?
17:27:38 <ais523> so probably at the same stage as oklotalk
17:27:40 <oklopol> oklotalk doesn't have much to do with lisps
17:27:54 <oklopol> it's just sexps are trivial to parse
17:28:16 <ais523> yes
17:28:23 <ais523> I suppose that Underload uses sexps in theory
17:28:42 <ais523> but it's really just that balanced parens are the only things in the syntax that don't parse as single characters
17:29:09 <oklopol> well then it has nested structures, that's not really sexps automatically
17:29:22 <ais523> sexps = balanced parens, mostly, in my view
17:29:24 <oklopol> i think sexp implies (verb object object*)
17:29:30 <CakeProphet> so... when I start a life insurance company.
17:29:31 <ais523> although I'm sure that a Lisper would tell me that I was wrong on that
17:29:31 <oklopol> is that so?
17:29:39 <CakeProphet> I am going to hire assassins to murder people who use other company's plans.
17:29:47 <CakeProphet> until the company's go out of business from having to pay out so much
17:29:47 <oklopol> well, then i'd say almost every language uses sexps
17:29:55 <ais523> CakeProphet: as a loss-leader kind of thing?
17:29:56 <oklopol> (oklotalk doesn't, still)
17:30:03 <CakeProphet> ...yes.
17:30:37 -!- RedDak has quit (Read error: 104 (Connection reset by peer)).
17:30:49 <CakeProphet> the same concept could be applied to auto insurance. Simply sabotage people's vehicles in order to cause accidents.
17:31:15 <CakeProphet> ...but not flood insurance. Unless you can bomb some kind of dam or levi.
17:31:28 <ais523> CakeProphet: or control the weather
17:31:34 <CakeProphet> that also
17:31:34 <ais523> but that would affect you too
17:31:42 <ais523> unless you did it in areas far from where your customers were
17:32:51 <CakeProphet> though it would be hard to get away with repeated murder. Perhaps the auto sabotage is more feasible.
17:33:16 <ais523> CakeProphet: doing it one at a time would be too small-scale to make any differences
17:33:39 <ais523> break into a company that makes cars, and alter the firmware so you can cause large-scale accidents remotely
17:33:43 -!- Sgeo[College] has joined.
17:34:08 <ais523> +ul (Hello, Sgeo!)S
17:34:08 <thutubot> Hello, Sgeo!
17:34:22 <CakeProphet> ...haha. We are demented geniuses.
17:34:31 <Sgeo[College]> Hi all
17:34:33 <Sgeo[College]> ais523: hm?
17:34:54 <ais523> thutubot's a Thutu program double-piped to netcat
17:34:58 <ais523> that runs Underload programs
17:35:08 <ais523> it also has a +hello command which was just a test
17:35:09 <ais523> +hello
17:35:09 <thutubot> Hello, ais523!
17:35:22 <CakeProphet> +gtfo
17:35:32 <CakeProphet> IT'S NOT WORKING
17:35:44 <ais523> CakeProphet: I don't know that abbrev, so it's unlikely that my bot will
17:35:50 <Sgeo[College]> Can Underload support PSOX? >.>
17:35:59 <Sgeo[College]> gtfo == get the f*** out
17:36:14 <CakeProphet> ais523, gtfo = "get the fuck off" or "get the fuck out" depending on the context.
17:36:24 <ais523> Sgeo[College]: you'd have to embed literal \0s into strings
17:36:27 <ais523> and most interps couldn't handle that
17:36:30 <CakeProphet> it's a... 4chanism
17:36:34 <Sgeo[College]> oh :(
17:36:55 <ais523> \0 is a very inconvenient character to type
17:37:06 <Sgeo[College]> I guess maybe PSOX should support some way to work with clients that can't just send nulls
17:37:23 <Sgeo[College]> In the magic, I guess
17:37:24 <ais523> besides, Underload doesn't have any input
17:37:38 <ais523> so it's not going to be able to communicate very well with PSOX anyway
17:37:42 <Sgeo[College]> ais523: well,... wait, how can there be a bot with no input?
17:37:46 <Sgeo[College]> Oh, n/m
17:37:48 <ais523> the bot's running on Thutu
17:38:12 <ais523> although I do like the idea of a bot that would send out random messages every now and then
17:38:31 <ais523> it could also send out regular PINGs to Freenode; if you ping a server often enough, it doesn't ping you back
17:38:39 <ais523> that way, it wouldn't need input
17:40:09 <CakeProphet> rofl. nice. It's like how I deal with annoying people.
17:40:18 <CakeProphet> ignore them.
17:40:40 <Sgeo[College]> CakeProphet: wha?
17:40:55 <CakeProphet> it could also send out regular PINGs to Freenode; if you ping a server often enough, it doesn't ping you back
17:41:13 <CakeProphet> client: "ping ping ping ping ping ping ping" server: "stfu I'm ignoring you."
17:41:19 <Sgeo[College]> What ab... oh n/m
17:41:29 <Sgeo[College]> I thought you felt insulted about something someone said
17:41:38 <CakeProphet> ...
17:41:39 <CakeProphet> no?
17:41:42 <ais523> CakeProphet: no, it PONGs you back instead
17:42:22 <CakeProphet> ...........
17:42:29 <CakeProphet> I don't think I have ever
17:42:43 <CakeProphet> willingly talked to a more pedantic crowd than you guys.
17:43:10 <ais523> well, I've been on comp.lang.c, and I think that they're slightly more pedantic than #esoteric, but they're an exception
17:43:19 <ais523> they basically all make their living out of being pedantic
17:43:36 <CakeProphet> ...well yeah. But I don't talk to those people. All complang communication channels are like that.
17:43:37 <Sgeo[College]> Am I pedantic?
17:43:44 <ais523> Sgeo[College]: no, just persistent
17:43:51 <ais523> but I don't mind it all that much
17:43:51 <Sgeo[College]> >.>
17:44:02 <CakeProphet> ...#esoteric is more like... theoretical pedantic.
17:44:20 <ais523> we refuse to be bound by the mundane shackles of common sense and efficiency
17:44:29 <Sgeo[College]> Am I ever persistent about things other than PSOX?
17:44:31 <Sgeo[College]> lol ais523
17:44:48 <ais523> Sgeo[College]: not sure, you're so persistent about PSOX we haven't had the chance to check
17:45:02 <ais523> but of course, that sort of persistence leads to a better program overall
17:45:11 <ais523> I can get in that sort of mood over INTERCAL sometimes
17:45:16 <ais523> and I'm sort of in that mood at the moment
17:46:04 <CakeProphet> I'm pretty non-pedantic. for a programmer. I consider it a good thing.
17:46:43 <ais523> many languages need pedantry to work properly
17:46:52 <ais523> you can't be sloppy with Malbolge, for instance
17:47:01 <CakeProphet> ...yeah. They do. But people don't.
17:47:12 <ais523> yes, I suppose that makes sense
17:47:25 <CakeProphet> thereis a difference in communicating with people and machines.
17:47:42 <ais523> my guess is that people who stay in complang channels are so used to getting into a pedantic frame of mind for talking to computers that it boils over into their interaction with humans
17:47:50 <CakeProphet> ...yeah.
17:48:04 <ais523> OTOH, I'm naturally pedantic anyway, which is maybe why I got into computer programming
17:48:10 <CakeProphet> -shrug- it's not bad. Just slightly annoying.
17:52:38 * oklopol saw no pedantry
17:52:53 <AnMaster> <oklopol> yay, oklotalk has a parse
17:52:54 <AnMaster> where?
17:53:01 <oklopol> on my computer
17:53:09 <oklopol> i will put it on an irc bot once it can do anything
17:53:13 <oklopol> i mean
17:53:17 <oklopol> once there's something it can do.
17:53:31 <oklopol> because the code isn't really meant for reading
17:53:35 <oklopol> that's not my style
17:53:50 <AnMaster> oklopol, can you give an example of a oklotalk program?
17:53:50 <oklopol> i did use multiple files this time, though!
17:53:50 <ais523> oklopol: what do you mean by 'meant for reading'
17:53:59 <oklopol> guess i'm growing up or something
17:54:01 <ais523> do you mean 'nicely commented so that others can follow'
17:54:04 <oklopol> yes
17:54:05 <AnMaster> oklopol, and list some key features of it
17:54:20 <ais523> or 'full of idioms, in-jokes, and other things that make the program harder to read but are a fun challenge'?
17:54:31 <oklopol> AnMaster: well, the fact i use lisp syntax currently kinda ruins explaining it
17:54:35 <oklopol> because the syntax is part of the fun
17:54:47 <AnMaster> oklopol, so have an example or not?
17:54:54 <AnMaster> and key features
17:54:55 <oklopol> i'll make a rational number class once i get a few things working
17:54:59 <ais523> e.g. when I wrote clc-cset.c, which handles CLC-INTERCAL character sets, I filled my C code with Perl idioms, because CLC-INTERCAL is written in Perl
17:55:18 <AnMaster> oklopol, so no example then? sigh
17:55:26 <oklopol> AnMaster: well i can show the factorial...
17:55:31 <AnMaster> oklopol, paste
17:55:38 <oklopol> (= fact {(-> 1 (outn 1)) (-> n (outn (* n (' (- n 1)))))}) (fact 4)
17:55:43 <oklopol> this is a simpel recursive one
17:55:45 <AnMaster> explain?
17:55:47 <oklopol> *simple
17:55:57 <AnMaster> oklopol, explain it
17:55:57 <oklopol> well that's sexps, so (function arg arg arg...)
17:56:03 <AnMaster> = ?
17:56:05 <AnMaster> (=
17:56:06 <AnMaster> ?
17:56:08 <oklopol> list: [elem elem elem ...]
17:56:23 <oklopol> lambda: {expression expression expression ...}
17:56:25 <AnMaster> oklopol, ok, doesn't seem too hard to parse
17:56:36 <oklopol> AnMaster: this is the simple lisp syntax
17:56:44 <oklopol> which has nothing to do with oklotalk's actual syntax
17:56:52 <AnMaster> oklopol, so same with the oklotalk syntax?
17:56:56 <AnMaster> care to show it?
17:57:08 <oklopol> it's just so simple to parse i made a parser for it to be able to code stuff without parsing manually
17:57:10 <oklopol> sure
17:57:17 <oklopol> i can show the factorial again
17:57:19 <oklopol> wait a sex
17:57:31 <AnMaster> um you mean sec
17:57:32 <AnMaster> ...
17:57:45 <oklopol> Fact={1->1;N->N*out'(n-1)};fact 4
17:57:51 <oklopol> i mean sex, but by that i mean sec.
17:58:08 <oklopol> basically, just a simple pattern matching
17:58:16 <ais523> +quit
17:58:16 -!- thutubot has quit ("ThutuBot quitting").
17:58:18 -!- ais523 has quit ("(1) DO COME FROM ".2~.2"~#1 WHILE :1 <- "'?.1$.2'~'"':1/.1$.2'~#0"$#65535'"$"'"'&.1$.2'~'#0$#65535'"$#0'~#32767$#1"").
17:58:22 <oklopol> well the second expression in the lambda may be a bit complicated
17:58:35 <lament> oklopol: look, you made ais523 leave
17:58:38 <lament> GOOD JOB
17:58:49 <oklopol> Fact={1->1;N->N*out'(n-1)};fact 4... N*out'(n-1) means N * (out (' (n - 1)))
17:58:55 <oklopol> where out and ' are unary functions
17:58:55 <AnMaster> yes
17:58:56 <oklopol> :<<
17:59:01 <oklopol> oklotalk was too much for them
17:59:02 <AnMaster> but that syntax doesn't seem too hard?
17:59:14 <oklopol> AnMaster: it is not *that* hard
17:59:25 <oklopol> but it does have quite a few quirks
17:59:31 <AnMaster> like?
17:59:31 <oklopol> for instance, it's 100% robust
17:59:34 <AnMaster> eh
17:59:39 <oklopol> any string is a legal program
17:59:40 <AnMaster> you mean no side effects? sure
17:59:46 <AnMaster> oh
17:59:55 <AnMaster> oklopol, so cat /dev/urandom is?
17:59:58 <AnMaster> even non-ascii chars?
18:00:17 <oklopol> well, in theory, but they will be nops, mostly
18:00:30 <oklopol> because an unknown character means a one-character variable
18:00:35 <AnMaster> #vt"drwolH">:#,_ @
18:00:35 <AnMaster> >"lo le">:#,_a,@
18:00:41 <AnMaster> what would that program do?
18:00:46 <AnMaster> it is befunge
18:00:51 <oklopol> wait a mo
18:00:52 <AnMaster> but what would it to in oklotalk
18:01:03 <CakeProphet> do you know of any programming languages besides Perl that can evaluate undefined variables to null values?
18:01:04 <oklopol> it will take me a minute to parse that
18:01:17 <oklopol> CakeProphet: oklotalk does variable -> atom(its name)
18:01:20 <AnMaster> CakeProphet, hm bash evaluates them to empty strings
18:01:37 <AnMaster> so yes empty or unset
18:01:51 <AnMaster> CakeProphet, string and arrays being the only data types of bash
18:01:52 <CakeProphet> I ask because I am looking for a new language to write poems in. I have been using Python lately... but I might switch to Perl or something else.
18:01:54 <oklopol> this is because 5 + 2 actually sends the message [+ 2] to 5
18:02:21 <AnMaster> CakeProphet, however you need $ at the start of variable names of course
18:02:28 <AnMaster> CakeProphet, also not sure if awk would do it
18:02:35 <CakeProphet> yeah
18:02:53 <oklopol> AnMaster: i'll tackle your program now, wait a mo ->
18:03:05 <AnMaster> <oklopol> this is because 5 + 2 actually sends the message [+ 2] to 5
18:03:06 <AnMaster> hm....
18:03:11 <AnMaster> that sounds like smalltalk?
18:03:23 <oklopol> sure, if "sending a message" sounds like smalltalk
18:03:28 <AnMaster> it does
18:03:31 <AnMaster> to me ;P
18:03:33 <oklopol> sure
18:03:47 <AnMaster> or objc
18:03:53 <oklopol> every OO-based language and functional language is about messages, though
18:03:57 <oklopol> it's justt terminology
18:03:59 <oklopol> *jsut
18:04:01 <oklopol> *just
18:04:28 <lament> most OO-based languages and functional languages don't have messages
18:04:31 <AnMaster> well what does my program do?
18:04:38 <AnMaster> lament, indeed C++ doesn't
18:04:45 <AnMaster> objc and smaltalk does
18:04:48 <AnMaster> smalltalk*
18:04:53 <oklopol> but, indeed, oklotalk and smalltalk have a lot in common, which is quite ironic, because i had no idea what smalltalk was when i came up with the name and the semantics for oklotalk
18:05:18 <oklopol> lament: they pass information around
18:05:37 <AnMaster> oklopol, or want a harder program:
18:05:38 <AnMaster> #vtf2*2+"olleH">:#,_'>11p><a,0q
18:05:38 <AnMaster> ><"dlrow">:#,_'>fb+0p@
18:05:41 <oklopol> any high-level language will be about sending messages, if you want to think that way
18:05:41 <AnMaster> what about that one?
18:05:48 <oklopol> AnMaster: i haven't started yet
18:06:09 <lament> oklopol: "passing information around" is more general than "sending messages"
18:06:25 <oklopol> ...except for the fact smalltalk *did* inspire the *name*
18:06:28 <oklopol> lament: okay
18:06:43 <oklopol> how so?
18:06:55 <oklopol> i don't know any exact definition for message-passing
18:06:55 <CakeProphet> ... -facepalm- I don't like where this is heading.
18:06:56 <lament> because it's up to the object to dispatch on the messages
18:06:57 <AnMaster> oklopol, tell me when you are done, I may be afk
18:07:49 <lament> so the dispatch happens at runtime at the discretion of the object
18:07:57 <lament> late binding
18:08:04 <oklopol> i see
18:08:18 <oklopol> well, all i meant was passing information around
18:08:21 <lament> "I got this message, let's see what i can do with it"
18:08:40 <CakeProphet> hmmm... sounds like lament is talking about the difference between static and dynamic typing.
18:08:49 <oklopol> is he?
18:08:49 <CakeProphet> sort of.
18:09:02 <oklopol> i would say binding
18:09:06 <oklopol> which is a bit different
18:09:23 <CakeProphet> -shrug- whatever. my patience with comp terminology is growing thin.
18:09:27 <oklopol> :)
18:09:28 <CakeProphet> lately.
18:09:55 <oklopol> take it easy, man, you seem goddamn tense.
18:10:20 <AnMaster> oklopol, result?
18:10:27 <lament> CakeProphet: with dynamic typing it is still not clear who performs the dispatch
18:10:50 <lament> CakeProphet: the interpreter could tell the object "hey, you got this message '+', figure out what you can do with it"
18:10:55 <oklopol> AnMaster: haven't started, sorry, people keep talking.
18:11:02 <AnMaster> lament, that sounds like objc
18:11:10 <AnMaster> an object can pass it on to someone else
18:11:21 <lament> CakeProphet: or, it could look at the object and say "hmmm, this object doesn't look like it can add stuff, so i'll just die with an error"
18:11:22 <AnMaster> oklopol, just ignore convos on irc and do it?
18:11:27 <AnMaster> ;P
18:12:20 <oklopol> AnMaster: almost done
18:12:58 -!- Tritonio_ has joined.
18:13:07 * Sgeo[College] does the exercises on the professor's slides and goes back to chat
18:13:11 <oklopol> [(> [#vt "drwolH"] (: #)) (@ _ _)]
18:13:11 <oklopol> [(> (> "lo le") (: #)) _a @]
18:13:20 <oklopol> AnMaster: would become these two lists
18:13:39 <oklopol> also a few evaluations would take place, most of which make not much sense
18:14:05 <AnMaster> eh
18:14:11 <AnMaster> oklopol, but what would it output or whatever?
18:14:19 <oklopol> oh, right
18:14:23 <oklopol> i'll evaluate through
18:14:28 <oklopol> you just asked for the parse tree, iirc
18:14:28 <AnMaster> oklopol, anyway there were two lines to eeach
18:14:30 <AnMaster> each*
18:14:42 <oklopol> this is the... first one i think
18:14:46 <AnMaster> oklopol, ah ok
18:14:47 <AnMaster> right
18:15:19 <oklopol> [(> (> "lo le") (: #)) _a @] ==> [(> #t (: #)) _a @] ==> [#t #_a _@]
18:15:31 <oklopol> so second line would evaluate to #t #_a #@
18:15:37 <oklopol> (not _@)
18:15:41 <oklopol> this is a list of atoms
18:15:55 <oklopol> if the first line has no side-effects, this will be the result as well
18:16:13 <oklopol> and it doesn't, unless you've given new semantics to the operations
18:16:50 <oklopol> umm wait, actually [#t $_a $@]
18:17:18 <oklopol> oklotalk currently has two kinds of atoms, the name atom policy is a bit obscure atm
18:18:01 <oklopol> *-name
18:18:48 <AnMaster> oklopol, I see
18:18:59 <AnMaster> oklopol, and what would the second program evaluate as?
18:19:07 <oklopol> lessee
18:19:39 <AnMaster> oklopol, after what, what about mycology ;)
18:21:27 <oklopol> [#vtf 2] * 2 + "olleH" > (: #), _ ' (> 11) p (> (< a)), 0 q _
18:21:28 <oklopol> (> (< "dlrow")) > (: #), _ ' (> (fb (+ 0))) p (@ _)
18:21:36 <oklopol> AnMaster: just two uninteresting lists again
18:21:39 <oklopol> but i can evaluate...
18:21:44 <oklopol> hmm...
18:21:58 <oklopol> i haven't actually chosen semantics for everything
18:22:05 <AnMaster> I see
18:22:05 <oklopol> unary < for a string
18:22:13 <oklopol> wonder what that would do...
18:22:31 <oklopol> oklotalk generally tries to ensure every application, with primitives, means something
18:22:49 <oklopol> why? oklotalk generally doesn't answer that.
18:22:49 -!- Judofyr has quit (Read error: 104 (Connection reset by peer)).
18:23:02 <Sgeo[College]> Turn the string into anumber, then do < on that number?
18:23:10 <oklopol> what's unary < for a number?
18:23:13 <oklopol> (< 5)
18:23:24 <oklopol> curry "<" with 5 as left parameter?
18:23:26 -!- Judofyr has joined.
18:23:47 <AnMaster> oklopol, so what about a string zzzzzzzzzzzzzzzzzzzzzzzzzz just?
18:23:47 * Sgeo[College] was thinking it meant "subtract one"
18:23:47 <oklopol> that wouldn't be very oklotalky, because currying isn't really supported
18:23:52 <Sgeo[College]> But currying might be better
18:23:52 <Sgeo[College]> Although if nothing comes after it..
18:23:53 <oklopol> AnMaster: a lowercase string is a function application
18:24:20 <oklopol> zzzz... would be parsed as (zzzzz... _), meaning "evaluate function zzzzz... with _ as param"
18:24:25 <Sgeo[College]> < string means subtract one from string
18:24:26 <AnMaster> oklopol, lower case == a-z? what about åäö?
18:24:28 <oklopol> _ is what it is in perl
18:24:29 <oklopol> *perl
18:24:33 <AnMaster> oklopol, and utf8 or not?
18:24:40 <Sgeo[College]> <string becomes strinf (I think)
18:24:41 <oklopol> AnMaster: those would be operator characters
18:24:58 <oklopol> Sgeo[College]: subtract one might work
18:25:11 <oklopol> but (oper string) should generally return a string
18:25:25 <AnMaster> oklopol, how long is a char in oklotalk?
18:25:28 <AnMaster> 8 bits?
18:25:30 <oklopol> string -> number will never happen automarically in oklotalk
18:25:34 <oklopol> *automatically
18:25:39 <AnMaster> if yes, then åäö as I sent them would be several codes
18:25:43 <AnMaster> because they are utf8
18:25:50 <oklopol> AnMaster: char is a number with #chr type-tagged
18:25:53 <oklopol> it's a bignum
18:25:56 <oklopol> :)
18:26:03 <AnMaster> hm
18:26:11 <Sgeo[College]> oklopol, string -> number, subtract one, number ->string
18:26:12 <oklopol> there's just lists, atoms and bignums in oklotalk
18:26:15 <AnMaster> oklopol, what would ascii \1 do?
18:26:17 <AnMaster> or \4?
18:26:22 <oklopol> operator characters
18:26:27 <Sgeo[College]> meaning (< string) would return a string
18:26:29 <oklopol> apply function \1 to param
18:26:29 <AnMaster> oklopol, and they do what?
18:26:40 <oklopol> well they will evaluate to the corresponding atom
18:26:44 <oklopol> $\1
18:26:44 <AnMaster> sigh
18:26:59 <AnMaster> oklopol, so what is a ¤?
18:27:09 <oklopol> Sgeo[College]: strings will never be automatically converted to numbers in that fashion
18:27:17 <AnMaster> oklopol, up for this one?
18:27:18 <oklopol> except perhaps as like base 256
18:27:20 <AnMaster> " raey eht ni nettirw saw elpmaxe sihT" >:#,_ "AMOR"4#@(MM+IIX\-\-+.)a,@
18:27:26 <AnMaster> oklopol, :)
18:27:30 <oklopol> AnMaster: what character is that?
18:27:39 <AnMaster> oklopol, the last one is a string
18:27:46 <oklopol> two characters?
18:27:46 <AnMaster> oklopol, the ¤ was a char
18:28:00 <AnMaster> oklopol, ¤ is one char
18:28:00 <AnMaster> ......
18:28:03 <AnMaster> get utf8
18:28:03 <AnMaster> duh
18:28:06 <oklopol> :)
18:28:09 <oklopol> (mirc)
18:28:25 <AnMaster> oklopol, it is the generic currency symbol
18:28:29 <oklopol> do it again
18:28:33 <oklopol> i may have utf on now
18:28:33 <AnMaster> ¤
18:28:37 <oklopol> darn :P
18:28:48 <oklopol> ¤
18:28:50 <oklopol> oh
18:28:53 <AnMaster> oklopol, an x with a o on, the o is filled so you don't see the x behind
18:29:00 <oklopol> i know what it is
18:29:04 <oklopol> but it won't show
18:29:04 <AnMaster> just the bits sticking out
18:29:16 <AnMaster> oklopol, ok, what does the program: " raey eht ni nettirw saw elpmaxe sihT" >:#,_ "AMOR"4#@(MM+IIX\-\-+.)a,@
18:29:22 <AnMaster> evaluate to in oklotalk
18:29:28 <AnMaster> oklopol, and tried a real OS?
18:29:33 <AnMaster> Linux, or *BSD
18:29:35 <oklopol> i'll parse it...
18:29:39 <oklopol> i've tried em
18:29:45 <AnMaster> oklopol, err wait
18:29:48 <AnMaster> mispaste
18:29:51 <AnMaster> on no
18:29:53 <AnMaster> it was correct
18:30:06 <AnMaster> just line broken by irc client made me confused
18:31:05 <oklopol> " raey eht ni nettirw saw elpmaxe sihT" > (: #), _ "AMOR" 4 #@ (MM + IIX \ _ \ - + . _) a _, @
18:31:10 <oklopol> an uninteresting list
18:31:20 <oklopol> " raey eht ni nettirw saw elpmaxe sihT" > (: #) <<< first element
18:31:22 <oklopol> let's evaluate
18:31:35 <AnMaster> mhm
18:31:42 <oklopol> " raey eht ni nettirw saw elpmaxe sihT" > "" << tailed an atom -> converted to string, tailed string
18:31:47 <Sgeo[College]> "You ask this question after class"
18:31:50 <oklopol> this evaluates to true
18:31:52 <oklopol> or #t
18:31:54 <AnMaster> Sgeo[College], ?
18:32:19 <Sgeo[College]> AnMaster: what my professor just told me after I asked something
18:32:25 <AnMaster> Sgeo[College], what did you ask?
18:32:29 <oklopol> so #t, _ "AMOR" 4 #@ (MM + IIX \ _ \ - + . _) a _, @ _ <<< cannot be evaluated without knowing _
18:32:29 <AnMaster> oklopol, hm interesting
18:32:37 <AnMaster> oklopol, and what does _ do?
18:32:42 <oklopol> it's what it is in perl
18:32:52 <oklopol> which, btw, is another re-invention
18:32:55 <AnMaster> oklopol, I don't know perl
18:32:58 <Sgeo[College]> How does Access define the table on the left and the table on the right, because it's not based on what it looks like in the Query Design view
18:33:00 <AnMaster> tell me what _ does
18:33:02 <oklopol> it's function params
18:33:14 <AnMaster> oklopol, so it will give a syntax error then that program?
18:33:17 <oklopol> F = { _ * 8 }; f 7 ====> 56
18:33:30 <oklopol> AnMaster: syntax errors do not exist
18:33:38 <AnMaster> oklopol, so what will the program do?
18:33:54 <oklopol> you can do errors, with continuations, but they will generally not be automatically created for you if you do something silly
18:34:02 <oklopol> AnMaster: depends on _
18:34:10 <AnMaster> oklopol, a simple one then, a bit of C code: k = p_key->p_key.x; k *= m; k ^= k >> 16; k *= m; h += k; h *= m;
18:34:16 <AnMaster> from a hash function
18:34:17 <oklopol> because you are applying stuff to it that cannot be applied stuff to
18:34:21 <oklopol> so _ will be applied to it
18:34:31 <oklopol> oklotalk has a very weird set of rules for application..
18:34:36 <AnMaster> oklopol, assuming it was the whole program I pasted, what would happen?
18:34:40 <oklopol> haha :D
18:34:45 <oklopol> that might actually do something
18:34:50 <oklopol> wait
18:35:17 <oklopol> hmmm....
18:36:05 <oklopol> wait, i have a girl stuck to me
18:36:10 <oklopol> okay, i'll continue
18:36:13 <AnMaster> eh?
18:36:17 <AnMaster> a child?
18:36:19 <oklopol> nm :D
18:36:24 <oklopol> no more like a woman
18:36:38 <AnMaster> so esolangs are more interesting heh
18:36:49 <oklopol> k = p_key -> p_key; <<< actually i don't recall what i desided to do in this situation
18:37:15 <oklopol> could be (k = p_key) -> p_key, which matches _ into both k and p_key, and returns (p_key _)
18:37:18 <oklopol> asd'fkl
18:37:21 <oklopol> my cell phone...
18:37:22 <oklopol> wait
18:37:25 <AnMaster> oklopol, you want something else? more C code? http://rafb.net/p/DRWbPE18.html would that do anything in oklotalk?
18:37:34 <AnMaster> a simple crc function
18:39:03 <oklopol> okay got rid of that too
18:39:10 <oklopol> the phone call that is
18:39:14 <oklopol> let's think
18:39:21 <oklopol> i mean, that c example with p_key
18:39:31 <AnMaster> well
18:39:33 <AnMaster> sure
18:39:51 <AnMaster> oklopol, want the whole function it came from?
18:40:09 <AnMaster> http://rafb.net/p/DenLGQ36.html
18:40:17 <oklopol> k = (p_key -> p_key); was the other possibility, i'm fairly sure (p_key -> p_key) would be a lambda, because you cannot do -> in a normal expression
18:40:25 <oklopol> or... can you 8D
18:40:31 <oklopol> why not, why not...
18:40:35 <AnMaster> what is ->?
18:40:41 <oklopol> -> pattern matches
18:40:42 <oklopol> on _
18:40:50 <AnMaster> well...
18:41:15 <Sgeo[College]> Bye all
18:41:25 <AnMaster> I start to realize why you haven't coded an interpreter for it yet
18:41:27 <AnMaster> Sgeo[College], cya
18:41:32 <AnMaster> let alone a compiler
18:41:44 <oklopol> {[$Init N] -> Val = N; [$+ N] -> Val <- Val + N;} would be a simple number class with just incrementation implemented
18:41:56 <AnMaster> oklopol, um is that what it does?
18:42:01 <AnMaster> the line I mean
18:42:05 <oklopol> oh no
18:42:09 <oklopol> just en example of ->
18:42:19 <oklopol> an
18:42:20 <AnMaster> ok
18:42:30 <oklopol> [$Init N] matches a list of that form
18:42:34 <oklopol> N can match anything
18:42:46 -!- Sgeo[College] has quit ("http://www.mibbit.com ajax IRC Client").
18:43:02 <oklopol> hmm, perhaps i should try getting that to work
18:43:05 <oklopol> that number
18:43:07 <oklopol> class
18:43:09 <oklopol> "class"
18:43:29 <oklopol> i usually call oklotalk functions "things", they're a bit... weird
18:43:31 <AnMaster> so what IS k = p_key->p_key.x; k *= m; k ^= k >> 16; k *= m; h += k; h *= m;
18:43:38 <oklopol> would be wrong to call them functions or objects of classes
18:43:45 <oklopol> hmm
18:43:58 <oklopol> i'll parse, as i think i've specified it
18:44:10 <AnMaster> good idea
18:44:25 <oklopol> usually you don't do multiple high-level operators without explicit precedencing.
18:44:31 <oklopol> = and -> are high-level ones
18:44:40 <AnMaster> well it is C really heh
18:45:04 <oklopol> yarr, just explaining why i'm not sure how that should be parsed
18:46:02 <AnMaster> oklopol, you need to add a sandbox mode that doesn't allow file IO and such so ppl can test the interpreter on anything just to see what happens
18:46:03 <AnMaster> ;P
18:46:15 <oklopol> :D
18:46:26 <oklopol> well, i don't have the parser yet...
18:46:26 <AnMaster> while (p < p_end)
18:46:26 <AnMaster> crc = (crc << 8) ^ crc32_table[(crc >> 24) ^ *(p++)];
18:46:26 <AnMaster> return ~crc; /* transmit complement, per CRC-32 spec */
18:46:35 <AnMaster> what about that one then?
18:46:45 <oklopol> the problem is, stuff like *= just doesn't mean anything, even though it's valid code
18:46:54 <AnMaster> oklopol, so they are no-ops?
18:47:02 <oklopol> yes, unless you give them a meaning
18:47:10 <AnMaster> the code above?
18:47:11 <oklopol> which can be done at runtime, and usually will be
18:47:14 <AnMaster> it is from another hash
18:48:17 <oklopol> k = {p_key -> p_key . x _};
18:48:19 <oklopol> k * = m _;
18:48:21 <oklopol> k ^ = k > > 16;
18:48:23 <oklopol> k * = m _;
18:48:25 <oklopol> h + = k _;
18:48:27 <oklopol> h * = m _;
18:48:28 <oklopol> this is almost parsed as it is in C
18:48:36 <AnMaster> oklopol, ok
18:48:42 <AnMaster> and what would it output or such?
18:48:45 <oklopol> well... would be, if you had >>, and X=-operators
18:49:06 <oklopol> well
18:49:13 <oklopol> k is set to that weird lambda
18:49:39 <AnMaster> and then?
18:49:51 <oklopol> then, the k and * are set to whatever two things calling m with _ as param evaluates into
18:50:07 <oklopol> if just one thing is returned, the second line is a nop
18:50:10 <AnMaster> oklopol, but if there is nothing called m?
18:50:14 <AnMaster> if it is the whole program
18:51:01 <oklopol> well then it means $m, and calling $m with _ as param means calling _ with [#uo $m], or reversed call to _ with the atom m as param
18:51:06 <oklopol> whatever this does depends on _
18:51:11 <oklopol> the parameter for the program
18:51:57 <oklopol> if _ is something like the empty list, $m is *forced* to evaluate with _ as argument
18:52:04 <AnMaster> hm
18:52:11 <AnMaster> oklopol, oh and then what about this then: size_t len = sizeof(fungeSpaceHashKey); return (fungeSpaceHashKey*)memcpy(newobj, oldobj, len);
18:52:17 <oklopol> an atom, when forced into a function, just returns itself.
18:52:33 <oklopol> in which case the line is a nop
18:52:39 <oklopol> because k * cannot be matched on $m
18:52:44 <AnMaster> of course it makes no sense to use a temp variable in C but just to complicate it
18:53:05 <oklopol> i can parse, but this is the last one :D
18:53:13 <AnMaster> heheh
18:55:20 <oklopol> size_t len = sizeof(fungeSpaceHashKey); return [fungeSpaceHashKey *] memcpy [newobj oldobj len];
18:55:21 <oklopol> slightly more interesting.
18:55:21 <oklopol> wait a mo
18:55:21 <oklopol> i have to think
18:55:22 <AnMaster> eh I said () not []
18:55:22 <AnMaster> but whatever
18:55:22 <oklopol> yes but it's already been paesed a bit
18:55:22 <oklopol> *parsed
18:55:22 <oklopol> they evaluated into lists of functions
18:55:22 <oklopol> because they were expressions containing functions only
18:55:22 <AnMaster> oklopol, then what would actual [] evaluate to? like myarray[3] ?
18:55:25 <oklopol> [] -> []
18:55:27 <oklopol> the empty list
18:55:34 <AnMaster> it got a 3 in it
18:55:42 <AnMaster> so [ ] is list?
18:55:43 <AnMaster> well
18:55:44 <oklopol> myarray [3] means call myarray with [3] as argument
18:55:49 <oklopol> what's myarray, depends on that
18:55:58 <oklopol> [3] is a list with just 3 in i
18:55:59 <oklopol> t
18:56:09 <AnMaster> oklopol, char * myarray; ;P
18:56:10 -!- olsner has joined.
18:56:20 -!- jix has quit (Nick collision from services.).
18:56:30 -!- jix has joined.
18:56:31 <oklopol> char * myarray is just a list of functions
18:56:34 <AnMaster> yeah
18:56:35 <oklopol> it doesn't do anything
18:56:38 <AnMaster> back to <oklopol> size_t len = sizeof(fungeSpaceHashKey); return [fungeSpaceHashKey *] memcpy [newobj oldobj len];
18:56:53 <oklopol> okay
18:57:14 <oklopol> return *may* be what it is in x
18:57:15 <oklopol> C
18:57:23 <AnMaster> x?
18:57:32 <oklopol> i'm just not sure if you can grab the continuation of the upper level like that
18:57:34 <oklopol> x -> C
18:57:34 <AnMaster> there is no x or C in that line
18:57:35 <oklopol> i failed
18:57:48 <AnMaster> there is no C either
18:57:54 <oklopol> C is a language
18:57:57 <oklopol> :)
18:58:20 <oklopol> okay, that line might evaluate to the list [fungeSpaceHashKey *]
18:58:39 <oklopol> but depends on return's capability to use the return continuation of whatever calls it
18:58:39 <AnMaster> ah
18:58:54 <AnMaster> I thought you meant variable C
18:58:57 <AnMaster> or such
18:58:57 <oklopol> i've removed uplevel lambdas from oklotalk to simplify scoping a bit
18:59:01 <oklopol> so....
18:59:09 <oklopol> uplevel, as in thin functions
18:59:15 <oklopol> something like what plof ha
18:59:16 <oklopol> has
18:59:18 <oklopol> or had
18:59:28 <AnMaster> oklopol, so is oklotalk functional, object orientated or what?
18:59:31 <oklopol> not sure what plof3 does
18:59:39 <oklopol> dunno
18:59:40 <AnMaster> wtf is plof?
18:59:47 <oklopol> plof is GregorR's language
18:59:52 <AnMaster> I see
19:00:01 -!- CakeProphet has quit ("haaaaaaaaaa").
19:00:34 <AnMaster> oklopol, you know fuzz testing with random program code will be absolutely hilarious with your language
19:01:00 <AnMaster> I use something like that for befunge
19:01:03 <oklopol> i guess oklotalk is multiparadignm
19:01:10 <oklopol> heh
19:01:15 <AnMaster> cat /dev/urandom | tr -Cd -- '-[:lower:][:digit:]\n\\/ ;",.+*[]{}^<>@`_|?:%$#!'\'"${FPRINTINSTRS}" | tr -d 'mhlior' | head -n 100 >> fuzz.tmp
19:01:20 <oklopol> i think befunge is more interesting for that
19:01:22 <AnMaster> oklopol, useful for crash stuff
19:01:37 <AnMaster> catched a few bugs with it so far
19:01:51 <oklopol> ah, interp should never crash?
19:01:51 <AnMaster> several valgrind errors and some SIGSEGV
19:01:54 <AnMaster> and one SIGFPE
19:02:03 <oklopol> hehe, fun
19:02:21 <AnMaster> oklopol, I aim for it to never crash except on something like perror("aiee! out of memory!"); abort();
19:02:25 <oklopol> i'm not sure what exactly to do for the oklotalk charset, i''m already using a few characters over ascii.
19:02:28 <oklopol> *i'm
19:02:35 <oklopol> which isn't good, because i wasn't intending to
19:02:44 <AnMaster> oklopol, and even with out of memory I do some ulimit testing to make sure it detects it
19:02:51 <oklopol> yeah
19:03:05 <AnMaster> but well, on out of memory there isn't much I can do when stuff fails
19:03:13 <oklopol> ofc
19:03:32 <oklopol> i'll start tackling on the rational number class
19:03:36 <AnMaster> oklopol, also I can't test file IO really with fuzz, I'm too lazy to set up a chroot
19:03:42 <AnMaster> and I don't dare do it elsewhere
19:03:50 <AnMaster> so it runs in sandbox mode
19:04:00 <AnMaster> so even if a p creates a o it will just reflect
19:04:45 <AnMaster> oklopol, of course this doesn't guarantee it is acting sensibly
19:04:49 <AnMaster> or anything like that
19:05:19 <oklopol> indeed, but you can prolly look at it as it goes
19:05:30 <oklopol> i tend to be overcareful when writing test programs
19:05:30 <AnMaster> well I can't parse 100 lines or random chars
19:05:37 <AnMaster> for the fuzz testing
19:05:45 <AnMaster> and yes I have done some unit testing
19:05:54 <AnMaster> but well mycology handles most of the correctness bit
19:06:09 <AnMaster> it does pass mycology
19:06:14 <AnMaster> I make sure it does at each revision
19:06:28 <oklopol> rational ->
19:06:30 <AnMaster> I don't commit if it doesn't pass mycology and valgrind
19:06:47 <AnMaster> oklopol, ?
19:07:25 <AnMaster> oklopol, oh and I gpg sign each revision of course, not that anyone would care
19:07:42 <AnMaster> I use the bzr version control system
19:07:48 <AnMaster> it supports signing revisions
19:08:27 <AnMaster> from within function "MediaWikiBagOStuff::_doquery". MySQL returned error "1030: Got error 127 from storage engine (localhost)".
19:08:29 <AnMaster> gah
19:08:33 <AnMaster> I hate that bug
19:08:47 <AnMaster> on esolang
19:14:54 <oklopol> AnMaster: rational numbers
19:14:59 <oklopol> gotta try making them
19:15:03 <AnMaster> hm?
19:15:09 <AnMaster> oklopol, in oklotalk?
19:15:11 <oklopol> yes
19:15:18 <AnMaster> well you mean like 1/3?
19:15:25 <oklopol> to test its extendability in itself
19:15:29 <AnMaster> or 1/10?
19:15:32 <oklopol> yes
19:15:35 <oklopol> that's a rational number
19:15:39 <AnMaster> true
19:15:49 <AnMaster> a pitty about pi heh
19:16:04 <AnMaster> oklopol, why not do symbolic algebra?
19:16:05 <AnMaster> ;D
19:16:20 <oklopol> well the actual types i was thinking for oklotalk were number and list
19:16:33 <oklopol> number being any number
19:16:41 <AnMaster> oklopol, all you need to do is write a common lisp interpreter in oklotalk, then run maxima under that interpreter
19:16:43 <AnMaster> :)
19:16:48 <oklopol> wuz maxima
19:17:01 <oklopol> oklotalk isn't really an algebra language
19:17:02 -!- Judofyr has quit (Read error: 104 (Connection reset by peer)).
19:17:04 <AnMaster> [I] sci-mathematics/maxima
19:17:05 <AnMaster> Available versions: 5.13.0-r1 ~5.14.0 {X clisp cmucl emacs gcl latex linguas_es linguas_pt linguas_pt_BR nls sbcl tk unicode xemacs}
19:17:05 <AnMaster> Installed versions: 5.13.0-r1(14.00.50 2008-03-27)(clisp emacs latex nls tk unicode -cmucl -gcl -linguas_es -linguas_pt -linguas_pt_BR -sbcl)
19:17:05 <AnMaster> Homepage: http://maxima.sourceforge.net/
19:17:05 <AnMaster> Description: Free computer algebra environment based on Macsyma
19:17:28 <AnMaster> oklopol, very useful thing
19:17:28 <oklopol> i have a lot of ideas for something with algebra
19:17:36 <oklopol> most likelt
19:17:38 -!- Judofyr has joined.
19:17:38 <oklopol> likely
19:17:40 <AnMaster> it is coded in lisp
19:17:56 <AnMaster> oklopol, see first paragraph on http://maxima.sourceforge.net/
19:18:37 <oklopol> sounds like it knows its stuff
19:18:43 <AnMaster> it is good yes
19:18:45 <fizzie> Maxima is to Mathematica what Octave is to Matlab. :p
19:19:00 <AnMaster> fizzie, yeah, "a lot cheaper"
19:19:17 <oklopol> zuffancezdroty is to mathematica what gnazzlewimber is to matlab
19:19:24 <AnMaster> oklopol, eh?
19:19:37 <oklopol> == i don't get the reference
19:19:45 <fizzie> Mathematica's student license isn't bad as far as absolute price is concerned, though. There are the... ethical objections to non-free software.
19:20:14 <fizzie> Well, Octave's a free Matlab "clone". It goes so far as to have a more-or-less-compatible-sometimes-maybe syntax in the programming language.
19:20:22 <oklopol> ah
19:21:16 <oklopol> that always makes me a sad panda
19:21:33 <AnMaster> fizzie, well maxima does what I need
19:21:38 <AnMaster> that is the main point for me
19:21:39 <oklopol> (taking a commercial product and making a free version of it)
19:21:45 <AnMaster> oh and it can generate fortran code
19:22:28 <lament> yay (?)
19:22:48 <fizzie> Fortran has a certain charm.
19:23:47 <AnMaster> lament, quite fast
19:24:38 <AnMaster> "For calculations which use floating point and arrays heavily, Maxima offers the possibility of generating code in other programming languages (notably Fortran) which may execute it more efficiently."
19:24:41 <AnMaster> from wikipedia page
19:28:41 <lament> "Fortran 2003 has extensible types, inheritance, polymorphic variables, and type-bound procedures"
19:28:44 <lament> heh
19:35:05 <fizzie> That sounds somehow wrong.
19:36:23 <fizzie> Have they done away with the line length limits and "these columns are reserved for line numbers" thing and stuff?
19:37:26 <fizzie> It all seems so... so tame. Wikipedia article tells me that in Fortran-90 and newer you can use stuff like <= instead of .LE. and all.
20:00:35 <AnMaster> hahahaha
20:09:54 -!- oerjan has joined.
20:28:59 -!- oerjan has quit ("leaving").
20:30:22 <GregorR> Apparently, if you pass both -O2 and -O0 to (mips) GCC, it produces f***ed-up code :P
20:31:15 <GregorR> I was wondering why it subtracted 8 from sp (the stack pointer) then proceeded to store into 20(sp) X-P
20:32:56 <AnMaster> news news on the unusal html4 page of pikhq
20:33:02 <AnMaster> it seems safari will handle it
20:33:04 <AnMaster> Deewiant, ^
20:33:10 <GregorR> O_O
20:33:15 <AnMaster> I talked to someone who said it worked in safari
20:33:19 * GregorR wonders if Konq4 would.
20:33:34 <AnMaster> GregorR, konq3 doesn't
20:36:40 <GregorR> I'd like to see somebody take the MIPS instruction set and reduce it to a minimal TC set without overloading. (i.e. no subtract-and-branch-if-<condition>)
20:36:52 -!- Tritonio_ has quit (Remote closed the connection).
20:38:41 <fizzie> Can't you just take SUB and, say, BLTZ to get the effect of having subtract-and-branch-if-negative.
20:39:23 <GregorR> SUB would be load, load, subtract, store at best (assuming you can't just treat memory as registers)
20:39:45 <GregorR> SUBLEQ is load, load, subtract, compare, store, branch
20:44:14 <fizzie> Is there a 'compare' mips instruction? I didn't think it had any flags, really.
20:44:47 <GregorR> set-if-<condition> sets one register to 1 if <condition>
20:45:20 <GregorR> But there's also branch-if-less-than, etc :P
20:45:20 <fizzie> Yes, but isn't that pretty useless if you have a branch-if-condition.
20:45:50 <GregorR> GCC uses it in some conditions, just depends on whether you still need that flag I guess *shrugs*
20:46:56 <fizzie> Sure it might be useful, but if you wanted a minimum set of instructions. (Haven't been doing MIPS since that one silly course about it.)
20:50:56 <fizzie> It doesn't look like the PC in MIPS is one of them general-purpose registers. A pity.
20:51:10 <GregorR> Yuh :(
20:56:47 -!- timotiis has joined.
21:14:43 -!- Tritonio_ has joined.
21:22:27 -!- ais523 has joined.
21:22:37 -!- ais523 has changed nick to ais523|busy.
21:23:30 -!- thutubot has joined.
21:27:13 <GregorR> I fixed JSMIPS 8-D
21:27:55 <GregorR> OK, what's my next target past Hello, world?
21:32:34 -!- RedDak has joined.
21:35:47 <GregorR> Hm, how about tackling this next failure :(
21:36:08 <GregorR> printf("Hello, world!\n"); // works
21:36:10 <GregorR> printf("Hello, %d!\n", 3); // does not
21:42:09 <GregorR> printf("Hello, %d!\n", 3); // jumps to address 0 (wtf)
21:49:40 -!- shinkuzin has joined.
21:50:00 <ais523|busy> GregorR: is there anything interesting at address 0?
22:11:51 -!- Iskr has quit ("Leaving").
22:25:15 -!- shinkuzin has quit (Read error: 113 (No route to host)).
23:01:50 -!- RedDak has quit (Remote closed the connection).
23:03:58 <GregorR> ais523|busy: Only a segfault waiting to not be caught :P
23:06:18 -!- Tritonio_ has quit (Remote closed the connection).
23:08:41 <ais523|busy> GregorR: I take it you're just running executables, rather than trying to virtualise an entire OS?
23:21:56 <GregorR> Uh, running executables with no syscall infrastructure is somewhat pointless :P
23:22:13 <GregorR> I do in fact provide a syscall layer, and so an OS in a manner of speaking, but yeah, it's not an OS in the conventional sense.
23:22:58 <ais523|busy> it's a stripped-down OS specifically for the purpose of running single executables
23:23:07 <GregorR> Right :)
23:23:23 * ais523|busy remembers writing a minimal window manager that could only show one window at a time, and even then it had to be fullscreen
23:23:43 <ais523|busy> we didn't need any more than that for the project we were working on
23:24:22 <GregorR> http://www.codu.org/jsmips/ // yay, hello, world!
23:24:23 <ais523|busy> hmm... if you allow fork() and exec() as syscalls, you could almost make that into a real OS by starting with some version of init, and adding a filesystem
23:24:57 <GregorR> The problem is, fork() is extremely difficult, perhaps impossible, because JavaScript has no real support for threads ...
23:25:13 <ais523|busy> not exactly
23:25:31 <GregorR> setTimeout is something, but it never actually runs two things concurrently >_<
23:25:34 <ais523|busy> although I've achieved a similar effect to cooperative multithreading by serialising internal state and using setTimeout instructions
23:25:58 <GregorR> Actually, I'm doing nearly that just to make the MIPS emulator not stall out the browser and get killed.
23:26:05 <GregorR> So maybe I'm more on track than I realize :P
23:26:21 <ais523|busy> I tend to do that in lengthy JS programs just so I can see them run
23:26:39 <ais523|busy> although if it's an AJAX program, waiting for an XHR response serves a similar purpose
23:27:00 <GregorR> I suppose AJAX might be a way to go with the filesystem.
23:27:41 <ais523|busy> mutltithreading is really easy if you use CPS
23:27:55 <ais523|busy> you just alternate around a ring of continuations
23:28:07 <ais523|busy> however, that's not very good for JavaScript emulators of processors
23:28:38 <ais523|busy> (I just realised that the reason why multithreading is so easy to simulate in BackFlip is that the entire language is CPS more or less by definition)
23:28:52 <ais523|busy> (pity that it isn't TC, although there are several suggestions to solve that problem)
23:33:04 <ais523|busy> hmm... the main issue with BackFlip was that flow control constructs were easy, but everything else was either difficult or impossible
23:33:18 <GregorR> Heh, that's weird.
23:33:18 <ais523|busy> that and the FSMness and reversibility, neither of which make it easy to write a program
23:34:22 <ais523|busy> http://esolangs.org/wiki/BackFlip (I've added a typing shortcut for Esolang to my IRC client, and want to show it off)
23:38:46 <ais523|busy> anyway, if multithreading is too hard for you, you could still have an OS, you'd just end up with something like DOS
23:40:54 -!- jix has quit ("CommandQ").
23:47:41 -!- timotiis has quit ("leaving").
23:53:10 -!- Sgeo has joined.
23:55:17 -!- wildhalcyon has joined.
←2008-04-02 2008-04-03 2008-04-04→ ↑2008 ↑all