00:01:00 oh 00:01:14 you can? 00:01:15 wow 00:01:20 that's like crazy 00:01:24 your own functions! 00:01:39 lol you can't write functions in python 00:01:41 w00t a c00l l4ngu4ge 00:02:02 ehird, and yes I saw it was python and tried it in python 00:02:04 duh 00:02:21 a: [T](T)T 00:02:23 ↑ A real type. 00:02:34 ehird, language? 00:02:38 Scala. 00:02:45 Meaning: Taking type parameter T, a function taking T and returning T. 00:02:57 To clarify, (Int, Int)String would be "Takes two ints and returns a string." 00:03:12 And [T](T, Int)Int would be "taking a type parameter T, takes a T and an Int and returns an Int." 00:03:20 Of course, you don't need to specify [T] as it's inferred from the argument. 00:03:31 It is like Haskell's "forall a." 00:03:36 haskell in disguise? 00:03:40 this scala I mean 00:03:43 Scala is similar to Haskell. 00:03:50 It runs on the JVM and has many OOP features. 00:03:56 And also a lot of Haskell-esque things. 00:04:01 And a lot of Ruby-esque things. 00:04:36 didn't scala do some publicity stunt with a suicide recently 00:04:46 :-) 00:05:03 .. 00:05:07 Tony Morris is back to being annoying on reddit. 00:05:13 who 00:05:19 The guy who was going to off himself. 00:05:25 didn't he do it 00:05:25 iirc 00:05:28 No. 00:05:28 did he ever post an apology? 00:05:30 what 00:05:39 ehird, what was it about then 00:05:41 AnMaster_ipv6: The post saying he shot himself was a troll. 00:05:49 oh 00:06:10 ehird, so the police managed to find him in advance of that or 00:06:12 And the whole thing was that he'd said he'd going to on IRC (and email simultaneously: it was automated), had already taken his motorbike and couldn't be found. 00:06:18 AnMaster_ipv6: Yes. The police found him. 00:06:23 mhm 00:06:36 ehird: do you know what happened since? Did he post anything? 00:06:42 apart from reddit trolls 00:06:56 ehird, a cron job would have made sense though for it 00:07:02 lament: He replied to the message saying he'd been found saying he's doing much better now and then returned to insulting christians on reddit 00:07:03 he's in #Scala so i assume he apologized somehow 00:07:25 lament: An apology was never expected afaik,. 00:07:39 --> 00:07:40 they were talking about ostracizing him 00:07:46 Er, since when? 00:07:46 for being a douche 00:07:55 -!- FireFly has quit ("Later"). 00:07:55 Right, it's lament's-troll-reality. 00:07:55 when they were searching for him 00:08:03 eh, check the logs if you want 00:08:11 They never said anything of the sort, and I was there for it. 00:08:21 what a silly address: "Faculty street 1" 00:08:24 guess what that is 00:09:07 ehird: they did. 00:09:10 so, basically, if he later really commits suicide, no one will care? 00:09:23 oerjan, now that is an evil thought 00:09:34 lament: The most I heard was one of the people who regularly talked to him saying they were going to shout at him for saying he'd do it. 00:09:51 Based on your less-than-immaculate reputation for, uh, truth, I'm inclined to believe my, more probable, version. 00:09:52 oerjan, hah at iwc btw 00:10:17 oerjan, though darth&droids was funnier 00:10:22 * oerjan needs to recall what it was about 00:10:35 oerjan, iwc: martians 00:10:36 eh, i could check the logs for the exact quote, but it's easier to just ban you 00:10:41 ah yes 00:10:46 Feel free to do either. 00:11:00 oerjan, D&D: 3 pages background on shape shifter 00:11:03 :D 00:11:40 ah yes 00:12:04 you would think the GM had learned by now ;) 00:12:14 lament: I'm waiting! 00:12:27 oerjan, so you would 00:13:18 lament: Oi. 00:14:26 night 00:14:28 really 00:14:50 AnMaster_ipv6: also, my evil thought is known as the story of "The boy who cried wolf" 00:15:26 wow that's ancient 00:20:56 * Sgeo wants to play Paranoia again at some point 00:22:14 "If Google would have actually put a fraction of the effort that they put into dreaming up the April's Fools joke into actually *doing* something about AGI , we'd be there by now." 00:22:17 * ehird rolleye 00:22:17 s 00:23:31 A fraction of a fraction of the effort they normally do? 00:24:03 well, i'm sure their server clusters would be useful for it 00:28:50 "First of all," Akon said. "First of all. Does anyone have any plausible hypothesis, any reasonable interpretation of what we know, under which the aliens do *not* eat their own children?" 00:28:51 — Eliezer Yudkowsky, Three Worlds Collide, "The Baby-Eating Aliens" 00:31:35 hm the title sounds like one of my theories for why aliens don't show up in public 00:32:13 (basically, we are so prejudiced that we would hate them if we knew their culture) 00:32:43 heh 00:32:53 (to be clear, for much less than eating babies) 00:33:25 ehird: link? 00:33:38 http://www.overcomingbias.com/2009/01/the-babyeating-aliens.html first part of http://www.overcomingbias.com/2009/01/three-worlds-collide.html 00:33:46 which is, in typical yudkowsky fashion, about rationality. 00:36:19 -!- psygnisfive has quit (Read error: 104 (Connection reset by peer)). 00:36:38 -!- psygnisfive has joined. 00:41:31 -!- M0ny has quit ("PEW PEW"). 00:44:04 "And ancient environmentalist arguments about population control, plus... oh, dear. I don't think they've realized that Adolf Hitler is a bad guy." 00:44:11 (from the second part) 00:51:40 [[Akon flipped a hand. "I don't think we'll run short of volunteers to watch disgusting alien pornography. Just post it to the ship's 4chan, and check after a few hours to see if anything was modded up to +5 Insightful." ]] 01:20:52 oerjan: i like it, maybe you can put that in your comic 01:21:17 "i read adolf hitler is a dead guy" and i was like wut 01:21:25 but then i realized my silly mistake. 01:21:52 huh? 01:22:07 was that to ehird? 01:22:11 *i read " 01:22:19 oerjan: comic for you, rest for no one 01:22:24 * oerjan has no comic 01:22:37 well "silly" was for ehird, and also "then" 01:23:41 * oerjan refrains from believing anything oklopol_ just said 01:23:56 well umm err 01:24:05 about the comic 01:24:15 haven't i told you like a million times i want you to make a comic 01:24:23 no 01:24:28 because if you made one, it would awesome (as a verb) 01:24:34 yes i have 01:24:36 ... 01:24:49 no 01:25:02 well i'm telling now anyhow. 01:25:11 although if you reduce that million a bit, i'm not entirely sure 01:25:17 and that comic thing was a reference to this 01:25:24 well maybe like 5. 01:25:57 actually i think it was my catch phrase at some point, so probably more. 01:26:12 anyway sleep time, you get working on your mathketeers 01:26:14 -> 01:26:29 get working? 01:26:32 well anyway -> 01:26:40 oh those 01:44:10 very much sleep-time indeed, 3 am dammit 01:44:29 and here I'm supposed to get up to work later this morning 01:45:37 very cool novella about the aliens btw 02:01:42 I think I just thought of what it might be a metaphor for, but I might be completely misunderstanding 02:25:01 -!- Gracenotes_ has joined. 02:47:19 -!- Gracenotes has quit (Connection timed out). 02:53:48 -!- rodgort has quit (Client Quit). 02:57:01 -!- rodgort has joined. 02:58:14 -!- Gracenotes_ has quit (Connection timed out). 03:35:29 -!- Asztal_ has quit (Read error: 110 (Connection timed out)). 03:51:11 -!- Gracenotes has joined. 04:01:05 oklopol_: do you have a real name? 05:04:08 -!- mtve has quit (Read error: 110 (Connection timed out)). 05:26:51 -!- GreaseMonkey has joined. 05:48:10 he does! 05:48:31 that's just a rumor! 05:48:44 his name is oklopol 05:48:46 or oklofok 05:48:48 or ... 06:21:18 -!- jix has quit (Read error: 60 (Operation timed out)). 06:21:35 -!- jix has joined. 06:28:55 -!- neldoreth has quit (Read error: 113 (No route to host)). 07:24:25 -!- neldoreth has joined. 07:31:49 -!- mtve has joined. 07:59:59 -!- clog has quit (ended). 08:00:00 -!- clog has joined. 08:08:05 http://qntm.org/?leak <== ALL Fine Structure fans, READ 08:15:03 -!- Sgeo has quit ("Leaving"). 08:28:03 -!- Mony has joined. 08:28:31 -!- Mony has changed nick to Guest43671. 08:29:06 -!- Guest43671 has changed nick to M0ny. 08:29:16 yop 09:03:16 -!- FireFly has joined. 09:22:54 -!- BeholdMyGlory has joined. 09:51:48 -!- Judofyr has joined. 09:54:51 -!- FireFly has quit (Read error: 110 (Connection timed out)). 09:57:07 -!- FireFly has joined. 10:03:32 -!- Judofyr has quit (Read error: 60 (Operation timed out)). 10:04:41 -!- Judofyr has joined. 10:08:24 -!- olsner has quit ("Leaving"). 10:26:50 -!- Gracenotes has quit ("Leaving"). 10:27:35 -!- Gracenotes has joined. 10:35:46 -!- Asztal_ has joined. 10:38:59 -!- tombom has joined. 10:47:41 -!- FireFly has quit ("Later"). 11:08:40 -!- FireFly has joined. 11:16:00 -!- FireyFly has joined. 11:17:07 -!- FireFly has quit (Nick collision from services.). 11:17:11 -!- FireyFly has changed nick to FireFly. 11:17:45 -!- AnMaster_ipv6 has changed nick to AnMaster. 11:38:40 -!- GreaseMonkey has quit ("X-Chat -> http://xchat.org <- At least when I quit I don't look like a lamer"). 12:04:24 -!- Judofyr has quit (Read error: 110 (Connection timed out)). 12:06:04 -!- Judofyr has joined. 12:55:05 -!- M0ny has quit (Read error: 104 (Connection reset by peer)). 12:55:24 -!- Mony has joined. 12:55:51 -!- Mony has changed nick to Guest87749. 12:58:27 -!- Guest87749 has changed nick to M0ny. 13:25:28 -!- FireFly has changed nick to FireMipo. 13:27:27 -!- Judofyr has quit ("raise Hand, 'wave'"). 14:00:17 -!- oerjan has quit ("leaving"). 14:12:51 -!- victor______ has joined. 14:21:49 hello! i just wrote cli bf debugger. does anybody know what to do with it ? :) 15:07:40 nobody knows.. 15:08:33 -!- victor______ has left (?). 15:10:08 -!- fungot has quit (Read error: 145 (Connection timed out)). 15:10:27 -!- und3f has joined. 15:11:47 -!- fizzie has quit (Read error: 145 (Connection timed out)). 15:13:42 -!- victor______ has joined. 15:14:24 hello! i just wrote cli bf debugger. does anybody know what to do with it ? :) < try eating it 15:15:52 -!- fizzie has joined. 15:17:20 thanx i try maybe. i mean i can put it somewhere if anybody need 15:18:04 Well, you can link it on the wiki 15:39:58 -!- KingOfKarlsruhe has joined. 15:58:20 -!- FireMipo has changed nick to FireFly. 16:15:42 victor______, hm... 16:15:49 bf debugger? 16:15:54 how would it work 16:16:46 i just didn't found one for command line. mm. 'next instruction', 'set breakpoint' etc 16:17:49 well right 16:17:51 hm 16:18:05 watch point in memory? 16:18:18 as in break when a specific cell is written/read 16:18:45 yes, for example 16:19:26 so what lang did you write the debugger in? 16:19:35 bf? :D 16:19:42 no :) 16:19:44 perl 16:20:12 mhm 16:20:34 new here or just long time idler? 16:20:44 first time 16:20:51 (A nick like that I think I would remember) 16:21:18 so, have you made this debugger public? It sounds interesting. 16:21:44 though I don't know much perl. 16:22:30 yes, but i'm looking for free ftp to put it. it terrible, all services needs javascript enabled 16:22:42 hm 16:22:50 a few minutes and it will be public :) 16:23:00 if it is a single perl file, why not use a pastebin 16:23:24 http://dpaste.com/25639/ 16:23:25 :) 16:23:51 ./bfg-0.2 -p prog.b 16:23:53 * AnMaster notice a lack of use strict 16:24:21 no criticism, I don't know enough perl be sure if that is a good or bad thing. 16:24:43 i think it won't copile with strict :) 16:25:14 "real programmers who use fortran for strings" don't need strict 16:25:44 but larry says that its bad 16:25:47 fortran for strings? I'm afraid I don't get that part of the reference 16:26:33 (C, Scheme, Erlang, Bash I know well, Befunge98 too, haskell I want to learn as soon as I have some free time for that) 16:26:54 (oh and I can read python and a few other langs too) 16:26:58 ive found howto about real programmers in isolnag today :) 16:27:27 haskell is my dream too 16:27:28 victor______, hm "print "[1B\r" . (' ' x 50);" looks odd 16:27:33 what encoding are you using 16:27:59 it looks like an embedded "char missing" here 16:28:02 ah, yes, it requires ansi sequences 16:28:09 what os do you use ? 16:28:14 Linux atm 16:28:21 ok 16:28:27 its just for colors 16:28:33 etc 16:28:35 well it should work, but not in firefox :P 16:28:41 (where I was viewing the paste) 16:29:01 i hope dpaste didn't eat them 16:29:25 its possible to rewrite it using ANSI::color module 16:29:56 that would mean I would have to deal with cpan :( 16:30:30 ah no, this distro does have a perl-core/Term-ANSIColor package 16:30:57 i mean _i can rewrite if necessary :) 16:31:28 no need. I'm not heavily into bf anyway, there are others here (seem to be idling atm though) who may be more interested 16:31:41 ^bf +++++[->+++++[->+++++<]<]>>----[->+>+<<]>-----------------.---.>. 16:31:45 meh 16:31:48 where is that bot 16:31:51 fizzie, where is fungot? 16:33:50 victor______, but the debugger looks nice, haven't tried it, since 1) I don't know perl well enough 2) I am paranoid 3) no offence meant. 16:34:44 ok, '2)' is enough 16:34:50 well I'll just create another user I guess. 16:35:17 you can run it in sandbox for example 16:36:01 and, if you were looking at the sources i already know your root pass :) 16:36:02 hm 16:36:14 http://dpaste.com/25639/plain/ is mangled it seems 16:36:29 wait no 16:36:44 my mistake 16:38:28 hm 16:38:51 interesting 16:39:04 victor______, when run in interpreter mode do you optimise the program btw? 16:39:11 no 16:39:16 ah 16:39:18 its quite slow 16:39:41 except sum simple things like caching ']' and '[' 16:39:48 //some 16:40:11 hm tried the lost kingdom program in it? (a text adventure in bf, file is around 1.7 MB or something iirc) 16:40:28 trie TakeOverTheWorld 16:40:28 http://jonripley.com/i-fiction/games/LostKingdomBF.html 16:40:39 haven't heard of that one 16:42:34 AnMaster: but that is compiled from BFBASIC... :p 16:42:43 lifthrasiir, that is true 16:42:52 but it is a good way to test bf interpreters 16:42:57 agreed. 16:43:10 I mean, somewhat like a acid test for bf interpreters 16:43:16 an* 16:43:25 i'd like to see bigger brainfuck program, so it can be used as milestone for optimization. 16:43:47 (as like mycology suite have been informally used for funge-98 performance test) 16:44:30 lifthrasiir, well, lostking.b can be optimised optimised even on a bf level iirc 16:44:35 some useless [-] and such 16:44:40 when cell is known to be zero 16:44:56 i also tested awib, but its not too big 16:44:58 lifthrasiir, also I prefer to compile bf really 16:46:22 * AnMaster waits for perl -i bfg.pl LostKingdomBF/LostKng.b 16:46:26 2.1 MB file even 16:47:20 aha, i'm waiting too 16:47:30 well 16:47:34 but it's just debugger 16:47:37 true 16:47:53 and .. bfg -p -i 16:48:13 bfint LostKng.b 16:48:14 Error: Program is too large, maximum is 65535 operations. 16:48:44 err what does -p do? 16:49:11 $ perl bfg.pl -p -i LostKingdomBF/LostKng.b 16:49:15 that just quits directly 16:49:24 and yes I put the -i in the wrong place indeed 16:49:42 preprocess. it is necessary because it includes '!' and it is end of code like in dbfi 16:49:55 but with '-p' it skip comments, insert includes, etc 16:50:12 hm 16:50:26 ah 16:50:38 well you should skip every unknown char in bf 16:50:43 btw how do you handle EOF 16:51:00 what value does that push to the program 16:51:11 zero :) 16:51:21 mhm 16:51:23 i skip any chars except '!' 16:51:31 I see 16:51:38 what do you think about befunge btw? 16:52:22 i didn't know or use it 16:52:44 ok. A self modifying two dimensional language. 16:52:57 http://esolangs.org/wiki/Befunge 16:53:19 yes, i know what is it, but don't know it 16:53:23 ah 16:53:57 fizzie, there? 16:54:27 awib segfaults when tried to compile lostkindom 16:54:41 heh 16:56:03 victor______, I wrote a "bf-to-C" compiler once, it worked and so on and optimised code somewhat, it compiled everything into one function though, when compiling the resulting C file for lostkingdom, GCC ran out of memory 16:56:29 hh 16:56:42 what do we want from basic ? 16:56:51 huh? 16:57:02 anwyay... maybe I should try again now that GCC 4.3 is stable on gentoo... 16:57:38 is let gcc to segfault only once using -fast-math and -whole-program 16:58:18 I'm sorry, but I didn't understand that.. 16:58:22 4.3.3 is in testing branch on gentoo 16:58:43 well true. 4.3.2 is stable here on Gentoo x86_64 (which I run) at least 16:58:58 my english is too bad? i learned it only from perl 16:59:07 it's ok. 16:59:13 (I'm not a native speaker either anyway) 16:59:17 hh 17:00:21 you learned english from perl? :D 17:00:24 also why would I want to use -fwhole-program, most of the time it doesn't help very much, and it requires a special build system. 17:01:42 i tried to use it once, it was c++ programm with a lot of templates so main.cpp includes almost everything 17:01:58 but gcc failed to compile it 17:02:04 with -whole 17:07:50 mhm 17:08:17 as for -ffast-math, unless you know exactly how the program works and how it will be affected it would be a bad idea 17:09:22 i knew. it was a boring math program partly written in assembler which had only two target users 17:09:38 and fast-math increased perfomance twice 17:10:06 mhm 17:10:47 but in most cases fat-math breaks all :) 17:10:53 //fast 17:13:51 Deewiant, I'm going to merge the exact bounds stuff back into cfunge trunk, so that other branch will soon be deprecated. 17:14:26 Alright 17:14:44 merged and pushed 17:16:24 next item: error handling cleanup 17:16:37 less random fputs and abort, and some central system 17:17:26 15:24 victor______: i think it won't copile with strict :) 17:17:28 fail 17:17:48 ehird, it's rather eso isn't it? 17:18:04 -!- ais523 has joined. 17:18:10 hi ais523 17:18:21 AnMaster: that was fast, and hi 17:18:28 mhm 17:21:43 ais523, since you know gcc so well, any idea why -fgcse-sm and -fgcse-las are not enabled at any -O level by default? 17:21:48 they don't seem to break anything 17:22:14 and for cfunge they offer a measurable speed-up on certain processors (such as one of mine) 17:22:15 common subexpression elimination can make programs slower 17:22:35 ais523, certain types of gcse is enabled by -O and higher though 17:22:38 yes 17:22:45 presumably those are the ones more likely to help 17:22:50 -fgcse-lm 17:22:50 When -fgcse-lm is enabled, global common subexpression elimination will attempt to move loads which are only killed by stores into themselves. This allows a loop 17:22:50 containing a load/store sequence to be changed to a load outside the loop, and a copy/store within the loop. 17:22:55 hm 17:22:59 wait 17:23:01 wrong one 17:23:09 (copy-fail) 17:23:14 -fgcse-sm 17:23:15 When -fgcse-sm is enabled, a store motion pass is run after global common subexpression elimination. This pass will attempt to move stores out of loops. When used 17:23:15 in conjunction with -fgcse-lm, loops containing a load/store sequence can be changed to a load before the loop and a store after the loop. 17:23:17 and 17:23:19 -fgcse-las 17:23:19 When -fgcse-las is enabled, the global common subexpression elimination pass eliminates redundant loads that come after stores to the same memory location (both 17:23:20 partial and full redundancies). 17:23:23 are the ones I mean 17:23:44 ais523, at least the latter I can't see how it would slow down things 17:24:54 -!- fizzie has quit (Remote closed the connection). 17:25:25 ais523, also we had someone new here today, who wrote a brainfuck debugger in perl heh 17:25:33 http://dpaste.com/25639/ 17:25:34 ah, interesting 17:29:16 -!- Judofyr has joined. 17:30:17 hm 17:30:40 ais523, what would you call a error/warning/notice handling code file. errors.c seems wrong... 17:30:52 and it isn't a full "logging framework" or such 17:31:01 diagnostic.c 17:31:07 ah good idea 17:31:14 * ais523 steals naming ideas from the C standard 17:31:38 they used it? 17:32:18 yes, for that purpose 17:33:28 in some example you mean? 17:33:41 no, it's a term defined by the standard 17:33:45 that's used to represent errors and warnings 17:33:55 lots of things require a diagnostic, according to the standard 17:34:02 ah right 17:34:04 which means that a compiler must give an error or warning if you try them 17:34:10 that's what -pedantic does 17:34:14 it adds all the required warnings to the code 17:34:21 in the form of "warning: ANSI C requires..." 17:34:33 the gcc people think they're silly warnings because it's obvious what you meant 17:34:44 but technically complying with the standard is always a good idea IMO 17:34:51 at least, if it's a sensible standard 17:35:42 hm 17:36:08 btw why is it: fputs(string, file); but fprintf(file, string, ...) 17:36:14 I mean, why not always put file first 17:36:25 file always goes last 17:36:28 I see why putting it last in fprintf would be an issue yes 17:36:31 except in fprintf, where that would be an issue 17:36:45 what is the reason for putting it last? 17:37:09 fseek takes it first 17:37:24 well, all the file I/O puts it last 17:37:33 and why 17:37:34 presumably it's so you can just put a ,file at the end of the command and an f at the start 17:37:44 and C89 wasn't designed to be consistent, but to model common practice 17:37:57 so presumably that weird practice sprung up before it was standardised 17:37:57 ais523, that would be as easy as f at the start and file, just after ( 17:38:03 well, yes 17:38:12 don't ask me to justify C to you, though, I didn't invent it 17:38:17 true 17:42:57 ais523, what is a safe way to print "out of memory" and exit. 17:43:14 I mean, I need to pre-allocate in some way I guess 17:43:21 if you use write to print a constant string, it should be safe 17:43:32 using write means that you don't have trouble with stdio buffering 17:43:49 and constant string means it's loaded into memory already, so you don't have to allocate the string you're printing 17:44:05 ais523, well what about: 17:44:09 void diag_oom(void) { 17:44:09 fputs("FATAL: Out of memory!\n", stderr); 17:44:09 abort(); 17:44:09 } 17:44:18 hm write ok 17:44:22 right 17:44:34 probably the stdio buffers won't be extended anyway 17:44:38 ais523, any reason to not use fputs()? 17:44:41 but in theory, I think an interp's allowed to allocate them lazily 17:44:56 it's a very unlikely problem to come up in practice, though 17:45:12 (if you're really insane, you could statically allocate the stdio buffer for stderr yourself, to avoid the implementation coming up with one0 17:45:14 *) 17:45:52 ais523, no, and I do that for stdout already in cfunge if -b is passed 17:46:00 you would say -b is insane I bet... 17:46:28 -b = you allocate your own stdio buffers yourself, rather than relying on the defaults? 17:46:30 why? 17:46:37 ais523, -b = fully buffered output 17:46:42 and larger buffer 17:46:49 ah, aha 17:46:58 and only affects stdout 17:47:12 -!- KingOfKarlsruhe has quit (Remote closed the connection). 17:47:23 make a large difference in mycology when not redirecting stdout to /dev/null 17:47:50 ais523, meh, stderr is fd 2 right? 17:47:53 yes 17:51:34 * AnMaster tries to remember how to use vfprintf 17:52:24 personally I very seldom write code using variable argument count to functions 17:53:36 -!- und3f has left (?). 17:55:55 AnMaster: run va_start, pass the result to vfprintf, run va_end 17:56:09 va_end is a no-op on more or less all architectures, but the ones that need it need it badly 17:56:21 What needs it? 17:56:51 I don't know, offhand 17:56:56 I'm just repeating the standard c.l.c answer 17:57:10 :-) 17:57:23 presumably it would be useful on an architecture with strange calling conventions 17:58:11 "va_end must also be called from within the body of the function having the variable argument list. In many implementations, this is a do-nothing operation; but those implementations that need it probably need it badly." 17:58:23 "Probably" 17:58:30 Sounds like they don't know either :-P 18:10:29 ais523, right 18:10:36 and I found it 18:10:47 I was just complaining about having to loop it up.. 18:11:37 * AnMaster wonders if there is no better way than: 18:11:38 void diag_error_format(const char* format, ...) 18:11:38 { 18:11:38 va_list ap; 18:11:38 fputs("FATAL: ", stderr); 18:11:38 va_start(ap, format); 18:11:39 vfprintf(stderr, format, ap); 18:11:41 va_end(ap); 18:11:45 putc('\n', stderr;) 18:11:47 } 18:11:49 err 18:11:51 typo there 18:11:53 about the ; 18:12:00 And it should be fputc, not putc 18:12:11 Deewiant, why? 18:12:28 Oh right, putc is that stupid thing which is the same as fputc 18:12:51 ais523, hm 18:12:52 BUGS 18:12:53 It is not advisable to mix calls to output functions from the stdio library with low-level calls to write(2) for the file descriptor associated with the same output 18:12:53 stream; the results will be undefined and very probably not what you want. 18:12:59 AnMaster: Of course? 18:12:59 from man 3 puts 18:13:05 Is that somehow unexpected 18:13:06 AnMaster: yes, undesirable to mix 18:13:12 are you stdio-writing to stderr? 18:13:18 ais523, so why did you suggest write() for fatal 18:13:22 -!- Judofyr has left (?). 18:13:24 ais523, normally I am yes 18:13:27 oh 18:13:34 you can mix safely if you do fflush(stderr) in between 18:13:37 ais523, doing fprintf and such to stderr 18:13:41 ah, ok 18:13:50 in that case, it's probably safest to just fputs the string 18:14:21 but isn't stderr unbuffered anyway? 18:14:45 I can't remember if it's unbuffered or line-buffered by default 18:14:53 and I can't remember if the default's the same on all systems, either 18:17:12 why does gcc hate returning results from GCC docs, and prefer to return irrelevant ones from mailing list.. meh 18:17:14 brb 18:18:16 -!- kar8nga has joined. 18:23:17 -!- olsner has joined. 18:35:29 -!- neldoreth has quit ("Lost terminal"). 18:36:34 -!- fizzie has joined. 18:38:13 I seriously should not have hyped that ISP of mine, they went and broke the interwebs today. (First time in the 8 months I've been a customer, so it's not exactly *frequent*, but still.) 18:44:36 fizzie, where is fungot 18:45:20 another question, any way to set ulimits for a process you debug under gdb 18:45:24 I want to debug OOM handling 18:50:05 Er, what I just said about broken interwebs is directly related to fungot's non-appearance. It @s at a socket read error, and is not in a crontab or anything. 18:50:07 AnMaster: you could use the ulimit syscall inside the process 18:52:10 ais523, setrlimit iirc? 18:52:24 Don't know about gdb + ulimit. If you don't mind changing the program being debugged, adding a suitable strlimit call at start of main should be enough, though. 18:52:29 AnMaster: I think so 18:52:38 s/str/setr/ 18:52:39 ulimit's the old interface to the same syscall 18:53:27 The AI tournament I've been incessantly bothering you about uses a JNI-callable blob which uses setrlimit to implement the "each player has one hour of thinking-time per game" feature. 18:54:07 could you add your own JNI-callable blob to cancel the limit? 18:54:10 or are they using hard limit? 18:54:37 ais523: Assuming unbroken Java sandbox implementation, no, since they run under a securitymanager with no privileges. 18:54:44 ah 18:54:53 And it is also the hard limit, I think, so it can't be raised again. 18:55:38 Anyway, I could've of course done the ulimit before starting the Java VM, but I also need to call getrusage to report to the programs how much thinking time they have left. 18:56:05 hm 18:56:07 rlimit.rlim_cur = (rlimit.rlim_cur > 25000) ? 25000 : rlimit.rlim_cur; 18:56:12 undefined or not? 18:56:30 yes I know it is a silly way to write it 18:56:59 also it should be tmp_rlimit 18:57:02 but anyway 18:58:06 There's the sequence point inherent in ?:, but I let ais523 to decide. 18:58:22 AnMaster: defined 18:58:25 k 18:58:35 you're using the value twice to the right of the =, those are both reads so legal 18:58:44 and for the write, the value written depends on the value read 18:58:46 so legal 18:59:40 hum 18:59:48 ais523: How about "foo = (++foo > 42) ? 6667 : foo;"? There's a sequence point between the evaluation of ?:'s conditional and the selected operand, after all. 19:00:30 fizzie: that's legal I think, foo = foo is legal, ++foo ? anything : anything is legal if the anythings are legal 19:00:57 Right. 19:01:20 (In the sense of "okay, good to know", not in the sense of "yes, you got it right".) 19:03:54 gdb is failing step when there is an inline asm statement in the way it seems 19:04:43 yes, longjmp confuses it too 19:04:52 if you put a breakpoint on the other side and continue instead, though, it's fine 19:05:38 ais523, it fails because there is a label inside the asm block 19:05:43 but I need that since it contains a loop 19:05:50 but it seems to think it is a new function 19:06:54 ais523, this was funny: can i expect a slowdown of only 1000x ? 19:07:09 haha 19:07:14 ais523, someone finding out his platform lacked hardware watch point support in gdb 19:07:25 -!- tombom has quit ("Peace and Protection 4.22.2"). 19:23:50 -!- ehird has left (?). 19:24:17 -!- ehird has joined. 19:26:38 17:38 fizzie: I seriously should not have hyped that ISP of mine, they went and broke the interwebs today. (First time in the 8 months I've been a customer, so it's not exactly *frequent*, but still.) 19:26:45 mine does that daily 19:26:49 * ehird is gonna buy wrt router todays 19:26:56 16:44 AnMaster: void diag_oom(void) { 19:26:56 16:44 AnMaster: fputs("FATAL: Out of memory!\n", stderr); 19:26:57 16:44 AnMaster: abort(); 19:26:59 16:44 AnMaster: } 19:27:09 AnMaster: if you're oom, chances are you don't get to print 19:27:28 ehird, see other related discussion... 19:27:30 malloc actually returning NULL is vanishingly rare and you'll have bigger problems than cfunge 19:27:38 fizzie: they got word you'd hyped them and wanted to discredit you 19:27:45 AnMaster: also, you can save a branch each allocation by not checking malloc 19:27:48 ehird: the trick is to try to survive on a null malloc 19:27:48 which should save a lot 19:27:53 so IMO i'd remove the check 19:27:55 ais523: yes, but this is for cfunge 19:28:05 ais523: null mallocs happen basically never 19:28:13 and when you do, you have problems bigger than cfunge exiting gracefully 19:28:24 and you get a speedup by not checking 19:28:27 I rest my case 19:28:42 the trick to survive may be to free some memory I guess. Since you are about to exit anyway just free some huge memory pool 19:28:55 Nobody ever listens... 19:29:22 guys have i mentioned scala is great? 19:29:59 AnMaster: the trick is not to call anything that might malloc 19:31:01 ais523, hm I guess free() might call malloc 19:31:05 ... 19:31:10 i think that's very unlikely. 19:31:22 ehird, well not guaranteed afaik 19:31:22 I'd punch anyone who made a malloc impl that requires free to allocate 19:39:36 anyway if you malloc() a large block and get NULL you most probably have some free memory around 19:39:46 and then I'm talking of 100 kb or so 19:39:53 ais523, ^ 19:40:15 (of course it might be you don't, but it is rather likely) 19:42:49 http://www.endpcnoise.com/cgi-bin/e/index.html 19:42:54 people are as obsessed as me! 19:47:52 #define DIAG_OOM(m_reason) \ 19:47:53 do { \ 19:47:53 fputs("FATAL: Out of memory at " __FILE__ ":" CF_CPP_STRINGIFY(__LINE__) ": " m_reason "\n", stderr); \ 19:47:53 abort(); \ 19:47:53 } while(0) 19:47:54 odd 19:48:07 ais523, gcc compiled: DIAG_OOM() without complaining 19:48:10 that is a missing argument 19:48:17 the argument is the null string 19:48:19 AnMaster: empty argument is valid 19:48:23 hm 19:48:38 that doesn't make much sense though. 19:48:51 does too 19:49:41 just gets expanded to ... ": " /* empty string from argument m_reason */ "\n" 19:52:07 yes 19:52:10 still.. 19:52:59 nice output though: 19:53:00 FATAL: Out of memory at ../src/interpreter.c:630: 19:53:00 Couldn't create funge space!? 19:53:18 (changed a bit, and using ulimits to test this= 19:53:20 s/=/)/ 19:59:20 -!- kar8nga has quit (Read error: 131 (Connection reset by peer)). 20:13:28 -!- jix has quit ("..."). 20:28:29 -!- Sgeo has joined. 20:30:15 fizzie, there? 20:30:25 Here and there, everywhere. 20:31:05 fizzie, 1) where is fungot? 2) I found a solution to that "want %rsp for funge stack, but breaks in signal handlers" 20:31:45 1) Still offline, but since the interwebs seem to be working, I guess I could bring it back. 2) Oh, what's the solution? 20:32:04 fizzie, I suspect sigaltstack(2) is the solution 20:32:25 not totally sure 20:33:07 fizzie, possibly sigaction() with SA_ONSTACK 20:33:19 yeah 20:33:21 seems you need both 20:34:34 Yes, although I wonder if I only need them for signals I actually want handled. If it's a handle-as-default, die-or-whatever signal, maybe it won't crunch up with a very nonstandard %rsp. 20:34:36 What "want %rsp for funge stack, but breaks in signal handlers" 20:35:02 Ilari, in jitfunge 20:35:18 Ilari: I was just wondering if I could abuse the normal stack pointer register to work as the funge stack in jitfunge-generated code, at least in portions that don't call any external functions. 20:35:24 fizzie: WHERE IS FUNGOT 20:35:58 * AnMaster imagines a distributed fungot 20:36:03 -!- fungot has joined. 20:36:13 each part would monitor the others, and if one went down another would connect and replace it 20:36:20 boring 20:36:39 ehird, what do you suggest instead? 20:36:44 Nothing? 20:36:51 ehird, even more boring.. 20:37:10 Your idea lacks interest; mine requires much less effort for the same amount of interest. 20:37:35 and? 20:37:55 So, logically, mine is the better option. 20:38:02 why? 20:38:15 Because the interest level is the same and it has the advantage of requiring less effort. 20:38:18 This is rather trivial. 20:38:26 ehird, you forgot uptime advantage of mine 20:38:32 fizzie: If you could guarantee that code doesn't generate any hardware faults and that its quite quick (say, few cs at most) you could block signals and unblock them later. Also has advantage of not calling stuff in odd contexts. 20:38:37 Fungot has been down, oh, 3 times. 20:38:44 A distributed system would be down more. 20:38:47 Ilari, he depends on catching sigsegv... 20:38:48 They are brittle in small sizes. 20:39:12 ehird, it would be massively distributed of course, every person in here would run one of them 20:39:13 :D 20:39:19 No they wouldn't. 20:39:21 Well, Maybe have dedicated stack for SIGSEGV... 20:39:41 Yes, with the sigaltstack trickery. 20:39:54 fizzie, wonder if it breaks stuff though 20:40:45 I have not really seen much reliable documentation about how safe it is to mess around %rsp (well, %esp in my code). It certainly could break some types of interrupt-handling, but I guess in the sensible systems I target they use a different, kernel-side stack. 20:42:11 fizzie, you could ignore some signals you didn't care about, and provide dummy ones for the other ones 20:42:14 to cover all 20:42:44 fizzie, and you would still need to restore it whenever you go back to the C++ part of the program 20:48:20 Hrm. I guess I'll still have to try it, in the off chance I do get back to jitfunge mode some day. 20:54:41 fizzie, you basically gave it up? 20:54:43 :( 20:56:35 -!- atrapado has joined. 20:57:22 No, no, it's not yet that far gone; I would've moved it to my ~/src/abandoned/ in that case. 20:57:43 fizzie, :/ 20:57:50 get working on it 20:57:55 it was such a cool idea 20:58:48 no it wasn't 20:58:50 i mean 20:58:52 it's a nice thing 20:58:58 but jitting befunge has Been Done before 20:59:06 ehird, not correctly iirc 20:59:14 ehird, or, show me the source in question 20:59:24 Bitrotted. 20:59:32 It was on the wiki as a dead link. 20:59:42 well, then we don't really know 21:00:02 ... 21:00:05 I read about it. 21:00:07 You are wrong. 21:00:11 could be someone lying 21:00:26 >_< 21:00:29 It's certainly not a very original idea, that's for sure. A Mycology-okay jit-interpreter is something that should exist, anyway. 21:00:32 Could be pink fuckin' elephants, AnMaster. 21:00:38 I guess I should work on it, otherwise someone will STEAL it. But I have too much to do right now, with this AI tournament nonsense (them scripts are having some issues) and such. 21:00:50 ehird, well that would be how they reproduce 21:00:58 fizzie: are you participating in the tournament, or running it, or both 21:01:00 so what did you expect? 21:01:08 ais523: Just running it. 21:01:08 ais523: running 21:01:22 "39 bot(s) => 1482 match(es) -- so far played: 330" 21:01:37 It's proceeding reasonably, there have just been... issues. 21:02:00 fizzie: they got word you'd hyped them and wanted to discredit you <-- what was that about hm 21:02:06 it made no sense, no context 21:02:14 (and if it was private it shouldn't have been in channel duh) 21:02:17 AnMaster: Sure it made. 21:02:17 fizzie: what is the game? 21:02:29 AnMaster: sure it had context 21:02:32 fizzie, not to me... and I did look at your 20 last lines 21:02:32 it just went back further than 5 lines 21:02:34 before that 21:02:38 you should extend that buffer 21:02:48 AnMaster: but thanks for playing. 21:02:58 "fizzie> I seriously should not have hyped that ISP of mine, they went and broke the interwebs today. (First time in the 8 months I've been a customer, so it's not exactly *frequent*, but still.)" 21:03:16 1482? Isn't all pairs once would be 1481 matches? 21:03:27 fizzie, ah 21:03:34 it was only a few lines up that that line was repeated by ehird 21:03:49 a few hours 21:03:50 Robdgreat, I thought it was about the tournament you see 21:04:05 21:02 ehird: fizzie: what is the game? 21:04:10 Ilari: My count would put all-pairs-once as 741; but this is all-pairs-twice; each bot plays each other once as the "blue" player and once as the "red" player. 21:04:21 ehird: http://www.niksula.hut.fi/~svirpioj/hierarkia/ 21:04:43 fizzie: I was hoping something silly like iterated Prisoner's Dilemma 21:05:10 fizzie: Ah yes. 21:05:13 One of the tournament issues was caused by someone submitting a .jar file which had only the Java sources, no .class files at all. Even though I've told then in about thirteen different places to test the .jar file they submit with a script that runs it under the tournament mess. 21:05:31 note to self: never talk in here when malcontents are around 21:06:06 Robdgreat: which malcontents? 21:06:25 anyone who'll give me unwarranted grief about something that didn't even concern them 21:06:38 Robdgreat: ah, AnMaster. 21:06:46 that's an even harsher view of him than I have 21:06:46 * Robdgreat shrugs 21:06:52 I must applaud you 21:06:53 if the shoe fits 21:07:11 well i'm not sure I can applaud passive-agressiveness 21:07:17 you can have a one-handed clap 21:07:39 Robdgreat, then you can never talk I guess. since I never disconnect my client except for kernel upgrades on the system running the bouncer, and then I real log 21:07:41 :P 21:08:02 AnMaster: your bouncer isn't you. 21:08:22 and the day you are in #esoteric talking continuously is the day you die of starvation or w/e 21:08:23 ehird: Are you sure? Maybe AnMaster is just a very advanced piece of software. 21:08:31 fizzie: I dispute the advanced qualifier 21:08:37 ehird: beat me to it 21:08:44 Certainly it makes more sense than fungot. 21:08:45 fizzie: i'll take a look 21:08:50 Heh. 21:09:02 I'm pretty sure I could make a bot emulating AnMaster accurately about 60% of the time 21:09:38 Anybody want to tell me what's wrong with my ELF/program/section header that's making my process get SIGKILL'd immediately? 21:09:59 ehird, you told me to expand scrollback. :P 21:10:08 What? 21:10:37 you should extend that buffer <-- So I did (lazy evaluation though) 21:10:59 Deewiant: It contains something the kernel doesn't like... 21:11:16 Ilari: Yeah, any idea what it could be? 21:11:17 Deewiant: Your system has developed a sense of taste (probably due to exposure to Mycology) and dislikes your hacky binary. 21:11:19 I'm running out of ideas myself. 21:11:37 Deewiant, use a kernel level debugger 21:11:38 fizzie: Where's the sense of taste stored, so I can wipe it? 21:11:40 or something 21:11:46 Deewiant: Errors after exec has passed point of no return (old mm destroyed) and control being passed to interpretter/program cause SIGKILL to be sent. 21:11:48 AnMaster: Such as? How? 21:12:00 Deewiant, kgdb, serial cable 21:12:04 I guess 21:12:15 Deewiant: I'm sure the FHS has a well-defined place for that. 21:12:41 AnMaster: Too bad this machine doesn't even have a serial port :-P 21:12:42 Deewiant: you heartless monster 21:12:48 oklopol_: I know 21:12:50 Deewiant, you can use firewire too 21:12:51 iirc 21:13:01 Ilari: Well, it's happening before any code is executed 21:13:10 if you knew where my port is, would you make me forget? 21:13:19 I guess that the entry point might be somehow incorrect 21:13:34 You could take a peek at the Linux ELF-loading code. I assume it's not something ld-linux.so involves itself with? 21:13:35 AnMaster: I don't have a firewire cable :-P 21:13:55 Deewiant, well, check the relevant kernel code 21:14:03 Deewiant: Yes. Almost entiere ELF loading occurs when kernel can't abort exec anymore but needs to kill the process if it goes wrong. 21:14:27 Forsooth. 21:14:55 Deewiant, do a bisect of revision history to find what revision introduced the issue? 21:15:10 ... 21:15:18 Deewiant, add logging statements to the code to find what way it kills in? 21:15:21 or why rather 21:15:28 Another way of running kgdb is qemu, I guess. But that really might be more trouble than what it's wrong. 21:15:34 Do you honestly think I would'nt've noticed that my program doesn't even start, for many revisions? :-P 21:15:54 21:14 AnMaster: Deewiant, do a bisect of revision history to find what revision introduced the issue? 21:15:56 Deewiant, set up linux under bosch (sp?) and use it's built in debugger 21:15:58 QOTD 21:16:22 Deewiant, do you seriously not detect sarcasm. 21:16:48 AnMaster: If I detected sarcasm with you I'd laugh at half of what you say. 21:16:50 (and I think you did that) 21:17:01 Deewiant: First thing that can go wrong is that if BRK setting goes wrong when loading section. 21:17:04 AnMaster: the problem is that sarcasm has to convey a point 21:17:06 oh the irony... 21:17:07 or be humorous 21:17:15 if you got that, our meters would set off 21:17:19 as is it's indistinguishable from stupidity 21:17:30 Deewiant: The load_elf_binary function of Linux's fs/binfmt_elf.c is a very sequential piece of code, with SIGKILLs very visible; I guess you could read about the checks it makes, see if it gives you any inspiration. 21:17:47 ehird, no, this is post-nonsense sarcasmic art. 21:18:06 AnMaster: What you're saying is, "um... err... LA LA LA" 21:18:12 "You're wrong 'cuz I said so." 21:18:38 (It is, however, quite long, too.) 21:18:53 -!- neldoreth has joined. 21:19:42 ehird, that was the point all along. A post-modern social experiment over irc. You seriously claim you haven't understood that after these years... 21:20:19 AnMaster: You have been in here than less than a year. And I think you'd better know that I despise the common human excuse of papering over logical argument with bad jokes. 21:20:28 no, more than a year I'm pretty sure. 21:20:34 at least it feels like it. 21:20:39 No. 21:20:41 but I may be wrong. 21:20:44 You are. 21:20:53 ehird, what date did I first join then? 21:20:55 It feels like it because you slow time down by packing as much annoyance in to it as possible. 21:21:00 AnMaster: Watch as I magic grep: 21:21:21 Deewiant: If you want just to test the executable code, load aout module and use that. Aout is vastly simpler than ELF. 21:21:27 Hm. 21:21:28 actually cfunge is over a year old now. 21:21:29 [2007-11-05 04:03:25] ... AnMaster_ [n=AnMaster@unaffiliated/anmaster] has joined #esoteric 21:21:31 2007-10. 21:21:32 see 21:21:35 I told you so. 21:21:39 I distinctly recall 2008. 21:21:50 07.10.31:15:10:56 Or Rodger Tokigun Helios EgoBot Gregor-Reddak-Ehird-Anmaster-Tritonio, which would be very weird. <-- huh? 21:21:59 One day after joining, you establish your catchphrase. 21:22:00 Ilari: Nah, the program is fine, I want proper ELF. 21:22:01 I seem to be missing a bit there, since I don't have a 2007-10 mention. Might've been my "forgot to rejoin" period. 21:22:35 fizzie, interesting 21:23:23 Deewiant: 'objdump -x' on it says anything that could be hint? 21:23:54 Ilari: It and readelf dump the values that I expect; of course, I don't know what could be incorrect :-) 21:24:13 Deewiant: Can you pastebin such dump? 21:24:43 Sure 21:24:54 Deewiant, /usr/src/linux/fs/binfmt_elf.c and grep for KILL ? 21:25:07 it seems pretty easy to follow 21:25:21 AnMaster: Been there 10 minutes ago; nothing obvious jumps out 21:26:50 http://www.pastie.org/private/gaqgo3ngwfhpvcnattprkq 21:28:46 Er, are you sure Linux is happy to load stuff at 0? 21:29:05 -!- victor______ has left (?). 21:29:19 fizzie, hm that sounds right. It shouldn't be 21:29:21 My primary suspicion is that it doesn't like my virtual addresses, indeed 21:29:26 unless some compat flags 21:29:29 are set 21:29:39 Deewiant, try to change that then 21:29:54 I did, no difference 21:30:57 I'm also not sure if there was some funkitude about the file offset needing to be align-aligned (while 146 % 8 != 0), but that sounds a bit too picky. 21:31:18 that would make sense 21:31:37 Added 400000h (seems to be what /bin/ls uses) to the entry point + program header entry's virtual address + executable section's virtual address, still dies 21:31:45 Bit-C dies: http://www.coyotos.org/pipermail/bitc-dev/2009-April/001784.html 21:32:02 Changed alignment to 1: still dies 21:32:39 Deewiant, did you use a.out before or? When did it start dying? 21:33:00 It started dying when I started writing my own ELF data instead of using the assembler's 21:33:06 (Unsurprisingly enough) 21:33:16 Deewiant, compare it's and your own 21:33:20 see where they differ? 21:34:01 then start changing each of the assemblers ones to your until it breaks+ 21:34:03 s/+/?/ 21:34:14 They differ in many places because its headers are somewhat crap 21:34:25 Deewiant, crap, but working 21:34:41 For certain values of 'working', yes 21:35:11 Deewiant, being able to run the program is a quality of "working" to me 21:35:25 Indeed 21:37:34 Deewiant: ph vaddrs and paddrs seem to be the same in dumping working executable... 21:37:53 Ilari: According to the spec paddrs are ignored 21:38:31 Deewiant: Do you know if the loader looks at the section headers at all (if they happen to be there), or just the program headers? 21:38:45 Ilari: Just to humour you, doesn't make a difference 21:39:33 fizzie: I don't know how important it considers them, but looking at the code it does do something with them 21:40:21 Hmm, maybe my virtual address should start at 400000h + the header size 21:40:46 Deewiant: You could also try doing what most executables I've seen do, and just load the whole program starting from file offset 0. 21:40:51 fizzie: AFAIK, it only looks at program headers. 21:41:05 Into 400000h. And do remember to alter your entry point when you change the vaddr value. :p 21:41:31 From one test executable I made with NASM + LD: LOAD 0x000000 0x08048000 0x08048000 0x00064 0x00064 R E 0x1000 21:42:29 Okay, now I got past SIGKILL, yay 21:42:30 That is, file offset 0, virtaddr and physaddr 0x08048000, file and memory size 0x64, Readable Executable, alignment 0x1000 (1 page) 21:43:06 Making the virtaddr be 0x400000 + the size of the headers was what made it work 21:43:07 Using a page-sized alignment was another thing I was going to suggest in LOADed phdr entries, since that seems to be a habit of ld too. 21:43:40 Deewiant: It is really more common just to load from 0 and include the headers, but if it works... 21:44:58 fizzie: Oh, you mean include the headers in the area specified by the program header? 21:45:28 Seems weird to include them in the segment IMO :-P 21:46:29 Deewiant: Presumably yes. 21:47:50 That's what people do, though. 21:48:05 Hmm, but now it seems that all memory accesses are offset 21:48:23 By an amount of bytes equal to negative the virtual address, I suspect :-P 21:48:34 Are you sure your assembler knows where the code starts? 21:49:02 That's kind of why I wanted to specify a virtual address of zero 21:49:23 Deewiant: You would need to write relocations table in that case. 21:49:39 Deewiant, let it generate it's own ELF header instead? 21:49:40 :/ 21:49:51 AnMaster: And have objdump and other tools not work because they think it's borked? Nah. 21:50:03 meh 21:50:12 Deewiant, use a different assembler? 21:50:17 Nah. 21:50:25 which one did you use you said? 21:50:28 nasm? 21:50:29 yasm? 21:50:35 fasm. 21:50:41 Anyway, I suspect that they include the headers because it makes no difference whether you start from vaddr 0x400123 and file offset 0x123, or start from vaddr 0x400000 and file offset 0x0, it's not like it's leaving those 0x123 bytes of the start of the first page unallocated. 21:50:44 And it has an 'org' directive which allows me to tell it the virtual base address 21:50:47 So I'm good. 21:50:50 Deewiant, it isn't even in my package manager 21:50:51 Thanks for the help. 21:50:55 and why are you using fasm anyway 21:51:04 An assembler without a org-like directive would be a rather crappy assembler. 21:51:39 Currently I start from vaddr 0x146 and file offset 0x146. 21:51:48 Deewiant, is the code position independent? 21:51:48 And it works. 21:51:49 ;P 21:52:02 j/k 21:52:13 PIC code is a bit of a pain to code by hand 21:52:19 ah probably 21:52:21 Hmm, double C there 21:52:36 Deewiant, I have done that though in cfunge, have a pic and a non-pic variant 21:52:42 Deewiant: What ORG value you use? 21:52:47 though gcc handles most of it 21:52:53 Ilari: Size of the headers. 21:53:07 Deewiant: I think the correct one is loadbase + size of headers. 21:53:23 Well, this one seems to work. 21:53:47 Deewiant: Or actually, loadbase of program text. 21:53:48 I.e. printing string constants gives exactly the string. 21:54:53 The correct ORG value is (pretty much by definition) wherever the code ends up being. 21:55:14 This is a bit annoying though: I need to assemble my program to know its binary size for the headers, and I need to assemble my headers to know the ORG value for the program. 21:55:51 Is there a command-line tool I can use to write values into specified positions of a binary? 21:56:00 Aren't you just including the headers in the assembler file? 21:56:30 No; the final tool that compiles my program is 'cat' 21:56:31 I mean, you could use .ORG 0, then start writing ".db" pseudo-ops or whatever fasm uses, and then assemble as a "flat binary" file. 21:56:32 Deewiant: bvi 21:57:11 ehird: I'd rather not depend on non-coreutils stuff 21:57:29 I thought you meant manually 21:57:29 You can abuse dd for writing too; "echo | dd of=file bs=1 count=len skip=offset conv=notrunc". 21:57:39 No, not manually. 21:57:43 For my makefile. 21:57:48 Uh, s/skip/seek/ there of course. 21:57:57 fizzie: Heh, that's cute. 21:58:18 [this is for a puzzle] In trinary, if I have no access to "2", can I always express a number as a - b with a and b only containing 0s and 1s in their representation? 21:58:30 Sgeo, ternary* 21:59:02 AnMaster: Actually, trinary is a synonym of ternary. 21:59:17 Deewiant, yes but I just strongly prefer ternary. And so do wikipedia. 21:59:26 Sgeo: yes. 21:59:29 * Sgeo hms at http://en.wikipedia.org/wiki/Balanced_ternary 21:59:30 That's balanced ternary. 21:59:32 Prefer what you will but it wasn't incorrect. 21:59:32 The one time I manually did an ELF file, I found it very pleasant to include the headers in the assembler file, a bit like the teensy-elf-executable-guy is doing. 22:00:14 Deewiant, Ternary numeral system (Redirected from Trinary) 22:00:15 fizzie: I just expect to have to write non-ELF headers as well, which means I need to keep the headers separate from my code. 22:00:21 It *is* balanced ternary. 22:00:23 AnMaster: Yes? 22:00:29 ..and that page basically says that it's the solution for the puzzle 22:00:36 >.> 22:01:19 After the winner wins, tell me what the puzzle is... 22:01:50 kerlo, it's the Enigma puzzle 22:02:08 Deewiant, write a tool to generate elf headers 22:02:18 and hot patch code 22:02:26 AnMaster: It's called a 'compiler' :-P 22:02:35 Deewiant, or assembler 22:02:43 Deewiant, exactly! 22:02:46 Oh, wait. 22:02:51 They're all compilers to me 22:03:52 I've seen that puzzle before at least twice, I believe. 22:05:41 "Your password has been emailed to your address on record." 22:05:47 hm gcc has __float128 on x86_64 too.. 22:05:49 This, coming from a security site 22:06:16 Sgeo, engima as in the game? 22:06:32 AnMaster, Enigma as in the contest in Agora 22:06:37 oh 22:12:51 One from context of one custom level Enigma (the game): How to draw random nxn matrix over GF(2) that is invertible at uniform (assuming ideal RNG is available)? 22:17:38 hm 22:17:44 I got gdb to "Bus error" 22:17:51 anyone want to know how? 22:18:11 -!- ais523 has quit. 22:18:39 start program which will call abort(), do: display errno, do: r (answer yes to question about restarting), wait for abort() call 22:18:50 gdb "Bus error"s 22:19:14 night 22:28:33 -!- atrapado has quit ("quita"). 22:31:37 -!- Sgeo_ has joined. 22:31:59 What did I miss? 22:35:26 cocks. 22:44:11 fizzie: you thar? 22:44:14 What missed me? 22:44:31 Shur. 22:45:06 (Though not for long.) 22:46:36 -!- Sgeo has quit (Read error: 110 (Connection timed out)). 22:50:27 fizzie: I was wondering if you could share your supar-secret DPI calculation formula. 22:53:10 What is such a thing? I just did {X,Y}-resolution/{X,Y}-visible-size-in-inches. I don't think that's much of a formula. 22:54:04 Well, yes. That could work. 22:54:07 I was thinking more the diagonal DPI. 22:54:12 15:24:53 oerjan, there is no strip on the page? 22:54:12 15:24:54 ?? 22:54:14 15:25:00 or do I have to enable java script 22:54:16 15:25:02 I hope not 22:54:18 How little things change 22:55:13 ty 22:55:34 Uh. 22:55:38 You're welcome, Sgeo_? 22:55:40 What did I do? 22:56:08 n/m 22:56:16 Sgeo_: do tell. 22:56:17 I thought you were pasting what I missed? 22:56:20 -!- psygnisf_ has joined. 22:56:55 no. 22:56:57 this is from 2007. 22:57:27 I might have missed stuff from 2007 22:57:28 lol 22:57:45 Conceivable. 22:57:53 Sgeo_: do you want all the logs of before you came in here? 22:57:58 05.09.17:14:16:35 --- join: Sgep (n=sgeo@ool-182e9882.dyn.optonline.net) joined #esoteric 22:58:00 So, just a few years. 22:58:16 05.09.18:15:10:28 n00b's (read:my) attempt to design something: http://esolangs.org/wiki/User:Sgeo/binbf 22:58:17 -!- psygnisf_ has changed nick to psygnisfiv. 22:58:18 I puked 22:58:21 -!- psygnisfiv has changed nick to psygnisfive_. 22:58:27 (Well okay it's not that bad) 22:58:28 >.< 22:58:46 If you want some sort of diagonal DPI, you can compute sqrt(xres^2+yres^2)/sqrt(xsize^2+ysize^2), but I assume in most cases the pixels tend to be quite square. In which case xres=k*xsize and yres=k*ysize and the diagonal-DPI sqrt(xres^2+yres^2)/sqrt(xsize^2+ysize^2) = sqrt(k^2) = k. 22:59:18 fizzie: Yes, well, diagonal-DPI is quite the standard, since nobody buys narrowscreens any more. 23:00:12 Anyhoos. 23:09:59 -!- FireFly has quit (Excess Flood). 23:10:38 -!- FireFly has joined. 23:14:53 -!- psygnisfive has quit (Read error: 110 (Connection timed out)). 23:16:07 printf "0: %016x" $$sz | xxd -r | od -vAn -tdL | xargs printf "0: %016x" | xxd -r | dd of=$$tmp bs=1 count=8 seek=$$(($$o)) conv=notrunc 2>/dev/null 23:16:10 Muah 23:42:10 -!- olsner has quit ("Leaving"). 23:43:57 ehird 23:44:16 what 23:44:19 do you know of any app that does actual analysis of musical structure beyond just, say, trying to find its "musical fingerprint" 23:45:03 what, from pcm data? 23:45:07 that sounds kind of difficult 23:45:08 as in AI-hard 23:45:13 there is a thing which purports to separate all the notes 23:45:14 so you can tweak them 23:45:15 i recall telling somewhere it would be cool to have a thingie you could give a melody to, and it would tell you the song 23:45:18 well, there is the whole music genome project 23:45:18 but apparently it doesn't work 23:45:21 and apparently it works 23:45:22 and someone said there is one 23:45:24 and so on 23:45:26 oklopol_: shazam? 23:45:27 it's shit 23:45:28 it doesn't work 23:45:29 ehird sounds like someone who'd say that 23:45:35 well there you go 23:45:47 ehird: what do you mean it doesn't work? 23:45:52 what does it do? 23:46:21 well you are meant to give it to a recording of a song 23:46:22 lastfm unfortunately doesnt organize artists based on their musical similarities 23:46:25 and then excels in the area of failing to recognize the song you play it 23:46:29 i mean it's not like it's possible to fail at what i'm talking about, you'd just need to actually have such a system 23:46:40 ehird: well that's absolutely useless, trivial and stupid 23:46:41 but rather based on their genre similarities 23:46:45 and not what i want 23:46:49 :-P 23:46:52 i mean even if it worked 23:46:56 psygnisfive_: actually it categorizes them based on 23:46:57 (1) tags 23:47:00 (2) who listens to both artists 23:47:04 so it's pretty, um, shit 23:47:12 yeah 23:47:28 but also genre i think 23:47:39 does it track genre 23:47:40 I don't think so 23:47:43 I think you do that via trags 23:47:43 tags 23:47:46 also: I am king of the world. 23:47:51 maybe 23:48:00 ehird: i mean just give it 7773....5552.... and it'd say ...well umm whatever that piece is some famous beethoven thing 23:48:07 micky erbe and maribeth solomon, tho, show similar artists as being other soundtrack artists, especially scifi soundtracks 23:48:12 um it must be noted that I'm doing that thing where I write in a specific style that doesn't come naturally because I can' tnot 23:48:12 There was a music analysis workshop at Nokia Research Centre around two years ago, but I've forgotten most of what was presented there. 23:48:13 and i dont want that 23:48:13 i want fuckin musical similarity 23:48:21 so if that happens welp watch out oky 23:48:22 ay 23:48:44 psygnisfive_: well you could compare musical fingerprints i mean that might work acceptably for the amount of work it'd take which is roughly none i mean if you use one of those library things to do it and do it in chunks and stuff you know? 23:49:01 makes sense. 23:49:19 ehird, what sort of of library things? 23:49:35 psygnisfive_: errrrrrrrrrrrrrmmmmmmmmm like that foosic site has an open source thing for musical fingerprinting I think? ? ? 23:50:24 hey talking like this is fun wish it came naturally 23:50:33 you can't categorize music music are an individual.......... 23:50:34 As I recall, most papers there were about things like query-by-humming-a-melody and such. 23:50:39 ehird, talking like what 23:50:58 yeah ehird isn't that how you always talk! 23:51:04 psygnisfive_: have you like not noticed how I am talking super weird on purpose 23:51:12 no 23:51:14 because I can't talk if I don't don't don't talk this way? 23:51:17 how is what you're saying super weird 23:51:29 well then it is clear you have a low perception like of my talkingnessbecause if you were paying attention i think you would notice it okay 23:53:42 -!- BeholdMyGlory has quit (Remote closed the connection). 23:57:25 There's at least one paper about using HMM-style statistical models on MFCC features to analyse musical similarity of (here classical) sampled music. 23:58:08 has anyone read music and probability? 23:58:27 i performed some glancing upon it, and looked pretty neat 23:59:02 Given how hip and pop recommendation systems are, I'm sure there are a lot of them, and not *all* of them can be trivial wrt. the similarity measuring side. 23:59:16 ehird