←2010-05-16 2010-05-17 2010-05-18→ ↑2010 ↑all
00:01:48 <alise> http://fano.ics.uci.edu/ca/rules/b0236s2345/
00:01:49 <alise> all move at c
00:02:09 <alise> 32 rules, pretty good
00:04:08 <Sgeo> The "latest news" on the wiki is from 2009
00:08:02 <oerjan> so the news are late
00:20:03 -!- ws has joined.
00:20:32 <pikhq_> cachegrind is pretty amazing at making code run slow.
00:22:34 -!- BeholdMyGlory has quit (Remote host closed the connection).
00:22:37 <oerjan> hopefully it grinds exceedingly small
00:27:37 <pikhq_> Welp, that confirms my suspicions. This sucker runs entirely out of the cache.
00:27:49 <pikhq_> Including the instruction cache.
00:28:19 -!- FireFly has quit (Quit: null).
00:29:18 * oerjan thought that would be a good thing...
00:30:13 <pikhq_> 'Tis.
00:30:18 <pikhq_> Just curious.
00:30:30 <pikhq_> Cachegrind is *not* a thing you run to check for bugs. ;)
00:30:41 <oerjan> ah
00:31:22 <pikhq_> It checks for cache hits and misses, or branch prediction misses.
00:32:14 <pikhq_> And does so by compiling machine code to an intermediate code, adding profiling code, and then JITing.
00:32:20 <pikhq_> Valgrind is freaking crazy.
00:34:01 <olsner> valgrind is awesome :)
00:35:04 <pikhq_> It's crazy awesome.
00:43:22 -!- FreeNodeHelpBot has joined.
00:47:30 -!- pikhq has joined.
00:48:34 -!- FreeNodeHelpBot has quit (Remote host closed the connection).
00:49:44 -!- pikhq_ has quit (Ping timeout: 265 seconds).
00:51:03 -!- ballard45 has quit (Remote host closed the connection).
00:52:27 * Sgeo is so tempted to take his phone off the cable
00:53:24 -!- ws has quit (Quit: ...).
01:02:08 -!- pikhq has quit (Read error: Connection reset by peer).
01:02:26 -!- pikhq has joined.
01:03:05 <pikhq> ==20208== More than 10000000 total errors detected. I'm not reporting any more.
01:03:10 <pikhq> From valgrind.
01:08:23 <Sgeo> pikhq, is this your insane C thing?
01:09:18 <pikhq> Sgeo: Insane *assembly* thing.
01:15:01 <poiuy_qwert> I have a double that im using as an arg in a string (string.arg(double)), is there a way to have it omit the decimal if its just .000000?
01:15:35 -!- ballard14 has joined.
01:15:35 <ballard14> Hi! :)
01:15:49 <poiuy_qwert> heh, wrong channel :P
01:15:53 <Sgeo> Hi
01:16:09 <poiuy_qwert> Hi
01:17:29 -!- Sgeo has quit (Remote host closed the connection).
01:19:40 -!- ballard15 has joined.
01:19:43 <ballard15> Hi! :)
01:20:09 <pikhq> Bottastic?
01:21:42 -!- ballard15 has quit (Remote host closed the connection).
01:22:05 <poiuy_qwert> lol
01:22:13 <oerjan> bottastrophic more like
01:23:51 -!- ballard14 has quit (Remote host closed the connection).
01:23:59 -!- ballard15 has joined.
01:24:02 <ballard15> Hi! :)
01:26:40 <poiuy_qwert> [18:44] * ballard45 (~PircBot@cpe-74-71-95-160.twcny.res.rr.com) has joined #esoteric
01:26:41 -!- zzo38 has joined.
01:26:46 <zzo38> Do you know, how to read/write a Java stream on a network socket, without Java?
01:32:47 -!- oerjan has quit (Quit: Good night).
01:36:33 -!- Sgeo has joined.
01:47:51 -!- zzo38 has quit (Remote host closed the connection).
01:49:45 <poiuy_qwert> anyone ever played with the Gammaplex interpreter?
01:53:40 <cheater2> hello friends
02:01:11 -!- ballard15 has quit (Max SendQ exceeded).
02:08:02 <Sgeo> Is alise still here?
02:08:04 <Sgeo> Ok
02:08:05 <alise> Yes
02:13:28 <Sgeo> [About Pure Glider Generators] "There was some interest in these early on, but they are no longer considered important. Here's a neat example: "
02:13:34 <Sgeo> What's "important"?
02:15:33 <alise> Useful
02:15:40 <alise> I guess
02:15:45 <Sgeo> There's no reason to use the pond over the beehive for 1-2-3-4's induction coil, is there?
02:15:54 <Sgeo> What's "useful" in GoL?
02:16:21 <alise> Useful for achieving things as parts of other things
02:16:24 <alise> *as a part of
02:16:32 <alise> Sgeo: Proof of c/4 maximum diagonal limit: http://www.conwaylife.com/forums/viewtopic.php?f=7&t=79#p248
02:16:46 <alise> Um, I think it's a c/2 proof as well...
02:16:51 <Sgeo> Saw that, was going to look at it again
02:17:00 <Sgeo> Yeah, uses c/4 proof as part of c/2 proof
02:17:34 <alise> Nice proof
02:18:01 <Sgeo> That.. seems to assume things about the shape of the spaceship
02:18:23 <Sgeo> Hm, maybe not
02:21:27 <alise> http://fano.ics.uci.edu/ca/rules/b3s24/g5.html c/3 diagonal spaceship
02:21:59 <Sgeo> "If you're still not convinced, then construct such a pattern for yourself."
02:22:13 <Sgeo> You don't even need to do that. Just decide "What is a spaceship in this location"
02:22:29 <Sgeo> You won't get consistently correct results faster than c
02:22:52 <Sgeo> erm, if you're looking sooner than the information can propagate at c
02:23:40 <alise> http://fano.ics.uci.edu/ca/rules/b3457s4568/g1.html This thing moves one cell downwards every 5648 generations in B3457/S4568.
02:23:40 <alise> Discuss.
02:24:49 <Sgeo> It will take forever for it to bring its passengers to the far side of the torus!
02:25:03 <alise> Still, not bad: in our world, it would be moving at 53,079 m/s.
02:25:51 <Sgeo> I suppose it's not possible to say what a cell, or what a generation, converted to our measurements would be
02:25:57 <Sgeo> Hm, maybe a cell == plank's length
02:26:13 <Sgeo> *planck?
02:26:40 <alise> Sgeo: CAs have discrete space and time so you cannot really compare them to fuzziness like planck length :)
02:26:59 <alise> Sgeo: cell != planck length
02:27:04 <alise> because then speed of light would be one planck length / s
02:27:36 <Sgeo> You're assuming that 1 generation = 1 second
02:27:47 <Sgeo> Assuming s == second
02:27:48 <alise> well
02:27:51 <alise> c = 1 cell / gen
02:28:06 <alise> c in our world = 299 792 458 m / s
02:28:14 <alise> I suppose you can tweak things to make tha twork
02:28:39 <alise> 1/299792458 seconds = ~3.33564095 nanoseconds
02:28:52 <alise> So it could be that one generation is ~3.33 nanoseconds.
02:29:06 <alise> Er, I think.
02:29:16 <alise> Then it'd be 1 meter / 3.33 nanoseconds
02:29:17 <alise> I think
02:29:18 <alise> Eh
02:29:31 <Sgeo> For some reason, I asssumed 1 gen = 1 planck time
02:29:38 <Sgeo> And c = 1
02:31:56 <uorygl> Well, the speed of light is one Planck length per Planck time.
02:31:58 <alise> So in our universe, c is however much light travels in one planck time.
02:32:00 <alise> So, what uorygl said.
02:32:08 <alise> 1 cell = 1 Planck length; 1 generation = 1 Planck time.
02:32:10 <uorygl> So if one cell is one Planck length and one generation is one Planck time, it all works out.
02:32:12 <alise> Now the issue with this is...
02:32:15 <uorygl> So, what alise said.
02:32:21 <alise> Cells behaviour is Too Fucking Complex for Planck length stuff!
02:32:25 <alise> *Cells'
02:32:44 <uorygl> Eh, particles' behavior is pretty complex, too.
02:33:10 <alise> that's particles
02:33:12 <alise> not planck lengths
02:35:55 <Sgeo> We should make a GoL program that speeds up the time between generations so that it properly matches the size of the cells
02:36:20 * Sgeo ponders
02:36:36 <Sgeo> Larger cells == more time between generations, right?
02:36:41 <Sgeo> Or less time?
02:37:22 * Sgeo ponderates
02:37:39 <Sgeo> Let's say plack length is l, plack time is t, and speed of light = c
02:37:55 <Sgeo> Then 1/t=c, and 2l/2t=c
02:38:00 <Sgeo> So why does it feel wrong?
02:41:01 <uorygl> The bigger something is, the more time it takes for light to travel across it.
02:41:24 <uorygl> That is the sole relevant fact you have utilized.
02:41:27 <alise> B01367/S012 is worthy of study; it has small replicators and glider guns.
02:42:14 <alise> Also, a breeder: http://www.ics.uci.edu/~eppstein/ca/replicators/b01367s012-breeder.lif which also renders the Sierpinski triangle as it goes.
02:43:23 -!- Oranjer has left (?).
02:44:35 <alise> & spaceships form naturally.
02:44:41 <alise> Looks very different to Life.
02:45:00 <uorygl> Gee, did I do that?
02:45:06 <alise> Cool -- I accidentally made a space filler.
02:45:07 <alise> uorygl: ?
02:45:13 <uorygl> Make you say "different to".
02:45:28 <alise> Howso
02:45:30 <alise> [[
02:45:31 <alise> x = 2, y = 3, rule = B01367/S012
02:45:31 <alise> 2o$2o$bo!
02:45:31 <alise> ]]
02:45:32 <alise> ^ spacefiller
02:45:40 <alise> A nice one at that
02:46:48 <alise> It seems many things become spacefillers
02:50:25 <alise> ##.
02:50:26 <alise> ..#
02:50:28 <alise> c/1 spaceship
02:50:35 <alise> no, wait, c/2
02:50:37 <alise> very nice though
02:51:07 <uorygl> That rule has B0; I don't really like that.
02:51:31 <uorygl> Especially since Golly can't do HashLife with it.
02:52:51 <alise> HashLife sucks for examining small patterns, because it's asynchronous.
02:53:21 <alise> Anyway, point is that it doesn't produce the "gobs of cellular goop" that things like Day & Night do; it's reasonably Life-like, but it seems distinctly different from Life in "style", having more blobs of flesh and the like.
02:53:31 <alise> And also having lots of random patterns spawn fast spacefillers.
02:53:41 <uorygl> This rule does not die down. Life does.
02:53:56 <alise> Define die down.
02:54:16 <uorygl> Randomly-created patterns tend to become essentially static.
02:54:26 <alise> Yes.
02:54:35 <alise> But at the same time, there are intricate patterns: glider guns, breeders, replicators.
02:54:39 <alise> Incidentally:
02:54:45 <alise> Philosopher: Can we ever be certain an observation is true?
02:54:45 <alise> Engineer: Yep.
02:54:45 <alise> Philosopher: How?
02:54:45 <alise> Engineer: Lookin'.
02:54:45 <alise> --Saturday Morning Breakfast Cereal
02:55:05 * uorygl agrees.
02:55:53 <alise> There is a difference between solid mathematical proof and extreme probability... it's just that, you know, at some point we have to consider the probability that there's an error in the mathematical proof that everyone missed
02:55:58 -!- Oranjer has joined.
02:56:04 <alise> and then realising that what we consider solid mathematical proof is actually quite fallible
02:56:24 <alise> If everyone used computerised proof verifiers, then there'd be a much larger gap between widely-accepted-mathematical-proof and tons-of-evidence.
02:57:07 <uorygl> Also, what SMBC is that?
02:57:58 <alise> http://www.smbc-comics.com/index.php?db=comics&id=1879#comic
02:58:01 <alise> The red button.
03:22:58 <Mathnerd314> is life is an esolang?
03:24:25 <alise> I have to be up in 5.5 hours.
03:24:37 <alise> Mathnerd314: I assume you know what Life is and are merely inquiring about its esolang status -- yes. But perhaps more of an esosimulation.
03:24:52 <alise> Certainly we can make things in it, things that compute, things that combine; certainly it is Turing-complete; and certainly it is esoteric.
03:24:57 <Mathnerd314> I was thinking RL
03:24:59 <alise> Make your own decision. Also, #b3s23 is lonely.
03:25:02 <alise> Oh, life itself.
03:25:03 <alise> No.
03:25:07 <alise> Not unless you use a horrible analogy.
03:25:27 <Mathnerd314> ok :-)
03:36:13 -!- augur has joined.
03:40:18 <alise> Sgeo: it's time.
03:40:24 <Sgeo> alise, Bye
03:40:37 <Sgeo> Hope you make more progress than has been visible
03:40:59 <alise> I haven't.
03:41:13 <Sgeo> Well, start making progress!
03:41:43 <alise> Sgeo: You try moving country.
03:42:26 <Sgeo> :/
03:43:16 <alise> Well, try.
03:43:20 <alise> Without moving.
03:43:28 <alise> Moving -- remotely.
03:43:31 <alise> Almost a contradiction.
03:45:00 -!- SgeoN1 has joined.
03:45:18 <alise> Thank you, everyone; and good night.
03:45:22 -!- alise has quit (Quit: Leaving).
04:20:56 -!- augur has quit (Ping timeout: 265 seconds).
04:40:42 <Mathnerd314> sleep? what's that? :p
04:51:46 -!- coppro has joined.
04:52:11 -!- Oranjer has left (?).
05:20:13 -!- poiuy_qwert has left (?).
05:20:38 -!- poiuy_qwert has joined.
05:33:34 <Mathnerd314> hmm, I wonder if a language could be both esoteric and have a readable "hello world" program
05:33:45 <coppro> certainly
05:34:29 <Mathnerd314> example?
05:34:50 <coppro> slashes
05:34:54 <coppro> befunge
05:35:50 <pikhq> HQ9+
05:37:31 <Mathnerd314> pikhq: HQ9+ fails at "Goodbye world"
05:37:41 -!- lament has joined.
05:38:52 <pikhq> Yes, yes it does.
05:46:55 <Gregor> Perl :P
05:47:36 <pikhq> Truth.
05:51:12 <Mathnerd314> I fail to see how Perl is an esolang
05:51:51 -!- gm|lap has joined.
05:55:06 <Mathnerd314> then again, I'm pretty blind
05:58:48 -!- myndzi\ has quit (Ping timeout: 246 seconds).
05:59:12 -!- myndzi has joined.
06:06:28 <coppro> Mathnerd314: Acme::Eyedrops
06:06:52 <Mathnerd314> ok, so it has an esoteric subset
06:08:37 <coppro> which overlaps significantly with the useful subset
06:08:47 <coppro> a lot like C++
06:08:49 <Sgeo> coppro, see my message in ##nomic ?
06:08:54 <coppro> yes
06:09:08 <Sgeo> Am I paranoid?
06:09:32 <pikhq> Depends. Is a demon about to eat your face off?
06:10:17 <Sgeo> A demon might, but probably won't, eat Agora
06:34:27 -!- FireFly has joined.
06:50:37 -!- gm|lap has quit (Read error: No route to host).
06:51:22 -!- augur has joined.
07:04:36 -!- Sgeo has quit (Remote host closed the connection).
07:04:58 -!- tombom has joined.
07:15:36 -!- SgeoN1 has quit (Ping timeout: 276 seconds).
07:17:51 -!- SgeoN1 has joined.
07:27:59 -!- Gracenotes has quit (Ping timeout: 265 seconds).
07:39:21 -!- Tritonio_GR has joined.
07:43:16 -!- FireFly has quit (Quit: null).
07:47:30 -!- Phantom_Hoover has joined.
07:53:36 -!- Tritonio_GR has quit (Ping timeout: 265 seconds).
07:57:10 -!- tombom has quit (Ping timeout: 264 seconds).
07:59:59 -!- clog has quit (ended).
08:00:00 -!- clog has joined.
08:01:46 -!- SgeoN1 has quit (Quit: Bye).
08:13:06 -!- Tritonio_GR has joined.
08:13:21 -!- Gracenotes has joined.
08:22:50 -!- Tritonio_GR has quit (Ping timeout: 240 seconds).
08:47:45 -!- lament has quit (Ping timeout: 276 seconds).
09:08:54 -!- Phantom_Hoover has quit (Remote host closed the connection).
09:34:23 -!- oerjan has joined.
09:47:32 -!- oerjan has quit (Quit: leaving).
09:47:37 -!- oerjan has joined.
10:05:17 -!- lereah_ has joined.
10:17:03 -!- oerjan has quit (Quit: leaving).
10:29:39 -!- MizardX has quit (Ping timeout: 248 seconds).
11:00:16 -!- Mathnerd314 has quit (Quit: ChatZilla 0.9.86-rdmsoft [XULRunner 1.9.2.2/20100316074819]).
11:15:21 -!- ais523 has joined.
11:25:03 -!- ais523_ has joined.
11:26:45 -!- ais523 has quit (Ping timeout: 265 seconds).
11:27:13 <ais523_> gah, why does my client nickping me in every channel simultaneously when that happens?
11:27:16 -!- ais523_ has changed nick to ais523.
11:55:44 -!- fungot has quit (*.net *.split).
12:19:49 -!- Phantom_Hoover has joined.
12:27:09 -!- ais523 has quit (Ping timeout: 240 seconds).
12:32:36 -!- ais523 has joined.
12:34:58 -!- Tritonio_GR has joined.
12:57:11 -!- ais523 has quit (Ping timeout: 245 seconds).
12:58:05 -!- FireFly has joined.
12:59:35 <AnMaster> fizzie, there?
13:00:44 <fizzie> Well, sort-of, but still busy.
13:00:57 <AnMaster> fizzie, do you want a cheap panoramic head?
13:01:16 <AnMaster> fizzie, it does require some bit of work. It is kind of DIY but it is programmable
13:01:30 <fizzie> I would like to hear about it, yes, but do not count on many comments back.
13:01:33 <AnMaster> and if you already have the parts (which seems plausible)...
13:01:39 <AnMaster> fizzie, lego. Let me find the link
13:01:51 <AnMaster> http://www.philohome.com/panobot2/panobot2.htm
13:02:18 <AnMaster> fizzie, there is a link somewhere there to someone who did manage to rotate it around the nodal point (the model on that page isn't front-heavy enough)
13:02:28 <AnMaster> (so it is just behind the nodal point iirc)
13:03:02 <AnMaster> fizzie, of course it need to be adapted to the camera model in question but I think it would be feasible for me to make something like that for my camera. :)
13:03:35 <AnMaster> I even have an RCX so a nice automatic rotate-take-photo would work
13:03:45 <fizzie> I was sort of guessing it was about lego; after all, what can't you do with that stuff?
13:03:52 <AnMaster> fizzie, :D
13:04:22 <AnMaster> fizzie, heck I found a webpage with someone who made an mobile crane in lego. Able to lift 1 kg...
13:04:31 <AnMaster> which is quite impressive.
13:05:26 <fizzie> There's that "lego auto factory" video, which might not be mind-blowingly "wow", but still a nice watch.
13:05:29 <AnMaster> fizzie, it did use two non-standard parts though... the model that didn't was still able to lift about 250 g but beyond that it started buckling considerably iirc. So that gal (!) who made it added some metal reinforcement to the boom
13:05:33 <AnMaster> let me find the link(s)
13:05:56 <AnMaster> http://www.jenniferclarkbass.com//lego/demag_crane.htm <-- reinforced
13:06:05 <AnMaster> http://www.jenniferclarkbass.com//lego/crane.htm <-- previous non-reinforced
13:07:06 -!- ais523 has joined.
13:07:33 <AnMaster> fizzie, it is some heavy duty lego. Able to actually drive over rather uneven terrain (most "official" lego models tend to be about looks rather than actual functionality when it comes to stuff like lego technic offroad models, IME)
13:08:06 <AnMaster> fizzie, btw do you have the required stuff to build a turn table like that? I seem to have most (and quite a bit more)
13:08:14 <AnMaster> was some time ago I last used lego though
13:09:29 -!- Phantom_Hoover has quit (Remote host closed the connection).
13:10:07 <AnMaster> fizzie, and a panoramic head should be considerably simpler than an "as accurate as possible" scale model of an "all-terrain" mobile crane... :P
13:10:31 <AnMaster> (so what if some reinforcement sticks out? it doesn't need to look like anything in specific
13:10:31 <fizzie> I don't really own anything recent; I had few bits from the old "Technic" era, but nothing programmable. I do have some friends that are more lego-enthusiastic, though.
13:10:32 <AnMaster> )
13:10:49 <AnMaster> fizzie, if you have a motor and one of those battery packs it should be doable still
13:10:53 <AnMaster> even if non-programmable
13:10:55 <ais523> technic is out of date? what a pity
13:11:09 <ais523> and the motors were awful, they weren't powerful enough to do very much at all
13:11:21 <AnMaster> ais523, the ones from the RCX era and later were powerful
13:11:27 <AnMaster> slower but more powerful
13:11:48 <ais523> hmm, the technic ones, if you tried to gear them down to be more powerful, tended to just not move at all because of the friction in the gears
13:11:52 <AnMaster> saw some page (web archive :/) that measured their relative strength
13:12:02 <AnMaster> ais523, do you mean the fast spinning long grey box ones?
13:12:17 -!- hiato has joined.
13:12:17 <AnMaster> with power attachment below
13:12:29 <fizzie> I don't know where my lego bits are; it's possible they're all in some unlabeled box at my father's storage room thing.
13:12:29 <ais523> AnMaster: yes, and later the shorter grey box ones with attachment above, which were much the same
13:12:36 <AnMaster> ais523, or the newer, cubish ones? with power atop
13:12:40 <ais523> I meant both
13:12:48 <AnMaster> ais523, the cubish ones are more powerful but they came in two variants
13:12:55 <ais523> fizzie: I know mine are all in one of about 100 unlabeled boxes at my house
13:12:57 <AnMaster> ais523, the modern one is lighter and weaker
13:13:04 <ais523> ugh
13:13:06 <AnMaster> ais523, only outside difference is the number iirc.
13:13:31 <fizzie> There were some cat-related complications in all lego projects anyway. I doubt the new model (of cat, I mean) would be any less... "helpful".
13:13:37 <AnMaster> ais523, but yeah less mass acting as a fly-wheel, you can hear the difference when turning them by hand (if you have one of each to compare)
13:14:16 <AnMaster> ais523, also higher friction at "free floating" mode with the newer power-above variant than the older power-above
13:14:48 <AnMaster> ais523, oh and I have too much lego to fit it in one box :D
13:14:50 <ais523> wow, you really analysed this a lot
13:14:54 <ais523> AnMaster: it's a very large box
13:15:03 <AnMaster> ais523, I have two RCX sets. One 1.5 and one 2.0
13:15:07 <fizzie> Maybe I could train that Roomba to be a robotic panorama head. It'd just need some sort of portable table to get high enough. :p
13:15:17 <AnMaster> ais523, the 2.0 ones came with the worse motors. the 1.5 one had the better motors
13:15:27 <fizzie> (With an added bonus that it'd be cleaning places while taking pictures.)
13:15:28 <AnMaster> I believe I have 3 or 4 better and about as many worse ones
13:15:33 <AnMaster> not sure of exact count
13:16:15 <AnMaster> ais523, but see this url, really worth the picture. It is a panoramic head for a camera built with lego. And can be programmed to take a 360° shot
13:16:17 <AnMaster> http://www.philohome.com/panobot2/panobot2.htm
13:16:18 <AnMaster> ^
13:16:30 <AnMaster> I know you filter urls but yeah check logs
13:16:38 <ais523> hmm, I can imagine what it would look like
13:16:49 <AnMaster> ais523, it is for one of them old nikon coolpix or whatever
13:17:07 <AnMaster> I plan doing one of those thus summer (adapting for the dimensions of my camera of course)
13:17:28 <AnMaster> since I have a zoom lens I think I need some sort of movable camera "grip"
13:17:39 <AnMaster> so I can adjust it for the nodal point of a given zoom level
13:17:43 <AnMaster> fizzie, doesn't it vary iirc?
13:18:05 <fizzie> I would assume so.
13:18:23 <AnMaster> fizzie, well with zoom level, how could the nodal point *not* vary?
13:18:40 <AnMaster> fizzie, also http://www.philohome.com/legophoto.htm has some other interesting photo stuff for lego
13:18:41 <AnMaster> err
13:18:42 <AnMaster> with lego
13:18:44 <fizzie> You could design the sensor to move so that it's compensated. :p
13:19:07 <AnMaster> fizzie, eh, it would need to look at photos and process the data
13:19:12 -!- augur has quit (Remote host closed the connection).
13:19:13 <AnMaster> I doubt I could do that in an RCX
13:19:29 <AnMaster> what with no camera stuff for it
13:19:42 <AnMaster> and very limited processing capabilities
13:19:46 <fizzie> No, I mean, the camera could do that, to make it independent of zoom level. Of course they don't. But they could.
13:19:52 <AnMaster> hah
13:20:29 <fizzie> Speaking of panoramas, here's a 360-degree one with the N900 not-quite-a-camera, with no tripod or anything, horrible parallax on the pier part and even worse white-balance/exposure problems for the part taken directly against sunlight: http://zem.fi/~fis/siikajarvi.jpg
13:20:49 <AnMaster> oh for a phone it would be trivial to design a working such lego pano head
13:20:52 <AnMaster> after all it is light
13:20:58 <AnMaster> my camera is rather heavier
13:21:21 <AnMaster> would need some counter balance to not tip (so yeah going to be careful when testing it initially!)
13:21:26 <AnMaster> fizzie, nice!
13:21:53 <AnMaster> fizzie, a bit less crop on that pier(?) would have been nice
13:22:14 <AnMaster> or are you standing on it?
13:22:16 -!- ais523 has quit (Ping timeout: 265 seconds).
13:22:21 <fizzie> Yes, I am. Well, was.
13:22:43 <fizzie> Had to crop quite heavily since I couldn't quite keep the horizon at the same level while turning around.
13:23:01 <AnMaster> fizzie, well okay, it kind of looked like a short pier and you were standing on opposite shore. It looks kind of less than 360
13:23:04 -!- ais523 has joined.
13:23:07 <AnMaster> probably due to the low height?
13:23:51 <ais523> ugh, connection trouble
13:24:14 <fizzie> Could be. It's also scaled to pretty low resolution because there was a piece of debris on the lens, making the middle regions of all shots pretty blurry, which I noticed only at home.
13:24:28 <AnMaster> ah
13:25:26 <fizzie> Hrm, for some reason the images don't seem to contain GPS tags. I must also have turned that off at some point. Aw.
13:25:41 <ais523> because you don't want us knowing where you live?
13:26:20 <AnMaster> fizzie, anyway you could build less advanced pano heads even without an rcx. two motors (one to turn, one to drive shutter arm) would be best I guess. One motor to rotate and then manual shutter might still work if the design is heavy enough. And even manual rotation with a heavy design should offer some improvement compared to ball head or no tripod
13:26:39 <AnMaster> I think this would be best to put on a table or such though. I doubt I could mount it on my tripod
13:29:02 <AnMaster> hm also my memory card is rather slow, I would need some way to set the time delay between shots...
13:29:48 <AnMaster> wth, I'm still logged in after not using that site for several years
13:29:54 <AnMaster> some long lived cookie certainly
13:30:26 <fizzie> That particular photo is not exactly from where I live, anyway: http://maps.google.com/maps?ll=60.277494,24.512987&spn=0.040257,0.104456&z=14
13:30:34 <ais523> hmm, I wonder if a site can detect a browser's saved-password and automatically click submit?
13:31:57 <fizzie> I would think the saved-form-information, after being filled in to the fields (and visible to the user), would be accessible to the scripts too. You might not get a change notification on the field, but you could poll.
13:32:55 <AnMaster> ais523, I hope not. Some js to check time it took to type it in
13:33:12 <AnMaster> ais523, anyway it said logged in and such already on the main page so it wasn't that
13:33:23 <ais523> I know, just thought it would be an interesting concept
13:35:05 <fizzie> I think there's been at least one case of a web developer wanting fancy form-validation insta-feedback, and made the password field have a green/red background based on whether what's written in the field so far was a prefix of the correct password or not, and updating that after each keypress.
13:36:03 -!- tombom has joined.
13:36:49 <AnMaster> ais523, very nice site that one: http://peeron.com/inv/parts/5306b for example, I can see on that url how many of that parts I have (since I added lego sets list to my account).
13:37:12 <AnMaster> iirc you can upload an ldraw file (a lego cad format) and it can tell if you have the needed parts
13:37:15 <AnMaster> very nice feature :)
13:37:22 <AnMaster> and I can get a listing of all parts too
13:37:36 <AnMaster> as a .tsv.
13:37:42 <fizzie> But isn't it a well-known truth that there's never enough parts?
13:37:43 <AnMaster> s/\.$//
13:38:56 <AnMaster> fizzie, sure but this can tell you like "sorry, not enough parts" or "sorry, not enough in the right colours, but if you use other colours you will have enough" or "yay, enough parts".
13:39:09 <AnMaster> (listing which parts you are missing, of course and so on)
13:39:19 <fizzie> ais523: Completely coincidentally, does your URL filtering block whole comments that happen to contain URLs, or just remove/replace the URL part?
13:39:20 <AnMaster> (and I don't remember the actual wording, was years ago I used it)
13:39:26 <ais523> just the URL part
13:39:28 <AnMaster> since well, there are very few ldraw tools for linux
13:39:48 <AnMaster> ais523, does it mark it in some way so you can see "url removed"
13:39:53 <ais523> yep
13:40:05 <AnMaster> ah, so we can't use that for secret info passing
13:40:13 <AnMaster> like passing fake urls to hide the info from you
13:40:19 <AnMaster> well, not as easily then
13:40:19 <fizzie> ais523: Does it leave the domain name in place so that you can make educated guesses as to whether it would be worth the hassle?
13:40:50 <AnMaster> fizzie, like http://ais523.org/loves/talk/behind/his/back, very nice site ;P
13:40:51 <fizzie> http://example.com/ais523_is_a_boogerhead.am_I_not_right.html
13:41:06 <fizzie> It seems we may have had a rather similar idea there.
13:41:10 <AnMaster> yes
13:41:28 <AnMaster> ais523, you might want to check the logs there for a good laugh ;P
13:41:53 <fizzie> Well, it's not an especially unexpected thing.
13:42:02 <AnMaster> true
13:42:07 -!- ais523 has quit (Read error: Operation timed out).
13:42:16 <AnMaster> fizzie, what does that word even mean?
13:42:19 <AnMaster> boggerhead I mean
13:42:48 <fizzie> Boogers are what come out of your nose. You know, snot.
13:43:16 -!- ais523 has joined.
13:43:22 <AnMaster> fizzie, ah
13:43:25 <AnMaster> ais523, you might want to check the logs there for a good laugh ;P
13:43:35 <AnMaster> (not sure if that went through first time)
13:44:05 <ais523> it didn't, but they don't look particularly amusing
13:44:13 <ais523> if you want to talk behind someone's back, you can always use /msg
13:44:16 <ais523> or even create a new channel
13:44:27 <fizzie> Oh, but that's not the same at all.
13:44:34 <AnMaster> fizzie, the main issue I see [with the lego panohead] is the rather small turn table size. and that the camera if centered on the nodal point will have it's weight distributed far from the center above the turn table
13:44:49 <AnMaster> fizzie, which means I need some counter weight plus a very wide base below the turn table
13:45:01 <ais523> besides, talking behind someone's back in a publically logged channel seems likely to backfire by accident
13:45:07 <AnMaster> fizzie, see http://home.arcor.de/markus.matern/Robotics/PanoBotCoolPix995/PanoBotCoolPix995_23.gif for turn table size
13:45:17 <AnMaster> ais523, sure
13:45:29 <fizzie> ais523: It's the audacity of it.
13:46:03 <ais523> besides, if you're not an op, if someone's firing insults at you pretty much all you can do is /ignore them
13:46:12 <ais523> if you're hiding the insults, then it saves someone the trouble of ignoring
13:46:22 <AnMaster> fizzie, also those instructions on that page are better than lego's own. These highlight new pieces in each step. Meaning an end to the search of "hm so where do all the bits listed as needed for this step go?"
13:46:54 <AnMaster> fizzie, the effect is rather visible in http://home.arcor.de/markus.matern/Robotics/PanoBotCoolPix995/PanoBotCoolPix995_30.gif
13:48:44 <fizzie> It looks nice, yes, if not quite as polished as the official instructions tend to be.
13:49:47 <AnMaster> fizzie, depends on how old the set in question is
13:49:58 <AnMaster> fizzie, also I saw some better renderings with more recent ldraw tools
13:50:10 <AnMaster> also ldraw + povray = wow
13:50:16 <AnMaster> (there is some tool for that yes)
13:50:35 <fizzie> Right, I was going to say they could spend a few bit-bucks on some anti-aliasing.
13:51:39 <AnMaster> hm I wonder if I could build something to vary the exposure? I do have a micromotor iirc
13:51:43 <AnMaster> so it might be possible
13:51:50 <AnMaster> that way I HDR will be easy
13:52:25 <AnMaster> that uses the 3 outputs then of one RCX, and I'd rather not need to use 2. would be too bulky
13:52:46 <fizzie> A bit of remote-controllability in the camera would be nice, too. Though a robot pressing buttons always gets some spare awesomeness-points.
13:52:51 <AnMaster> well one on the base to stabilise it and one as part of the counterweight
13:52:52 <AnMaster> maybe
13:53:12 <AnMaster> fizzie, I have one of those RCX IR-remote-controls
13:53:20 <AnMaster> it lets you manually run motors and also start programs
13:53:24 <AnMaster> plus shut off things
13:53:36 <AnMaster> only issue is that with two RCX it would be... messy
13:53:50 <AnMaster> sure they can use IR themselves to talk between each other but the remote would drive both
13:53:53 <AnMaster> I think
13:54:37 <AnMaster> and yeah that brickos custom firmware is a dead project. And the required cross compiler was never ported to anything newer than GCC 2.9x iirc
13:55:08 <AnMaster> so I'd probably prefer NQC with lego's own firmware, even though it has a lot of restrictions...
13:56:45 <fizzie> Somewhat relatedly, the N900 has an IR led, but none of the official software uses it for anything, and it's not listed in any of the marketing material; I think some maemo.org wiki page mentions it, but that's pretty unofficial. I haven't yet found out any use for it, but I'd like to. There's an irreco port so you can make it emulate just about any IR-based remote control, but I don't have anything that would be controllable that way.
13:57:46 -!- tombom has quit (Ping timeout: 264 seconds).
14:04:10 -!- tombom has joined.
14:04:29 <AnMaster> fizzie, for RCX it doesn't use the "standard" data IR freq iirc
14:05:49 <AnMaster> hm another issue with the base of that panohead is that it must not be wide enough to show up in the image
14:13:30 <AnMaster> fizzie, oh I just realised another thing. If possible the panohead should be somewhat modular and easy to take apart/reassemble. Since you will probably end up moving it quite a lot
14:16:49 <AnMaster> hm it would be nice with ability to rotate up/down too... but I doubt I could pull that off
14:17:59 <AnMaster> I mean, sure I can see how can be done in theory but not with lego
14:30:05 -!- MigoMipo has joined.
14:33:42 <fizzie> The N900 lirc_rx51 module seems to support setting the carrier frequency to anything between 20 kHz ... 500 kHz. A bit of a moot point since I don't have RCX remote-control-receivers either, though.
14:34:35 <AnMaster> fizzie, hm iirc 75 kHz for RCX
14:36:29 <AnMaster> eh seems to vary with versions
14:36:44 <fizzie> It seems to be software-driven, so higher frequencies == more interrupts, but I guess it doesn't really matter for short bursts of signals.
14:36:56 <AnMaster> as in firmware
14:37:15 <AnMaster> RCX 1.x used 38.5 kHz and RCX 2.x used 75 kHz
14:37:25 <AnMaster> or uses I assume
14:37:59 <AnMaster> fizzie, can you set 2400 baud?
14:38:01 <fizzie> 38 kHz is the "standard" one. Makes one wonder why they bothered changing it.
14:38:37 <AnMaster> fizzie, since it seems that it simply uses light on/off for one period to represent 1/0
14:42:05 <AnMaster> fizzie, eh 76 kHz not 75
14:42:24 <AnMaster> "The IR interface on the RCX is able to communicate with Spybots, Scout Bricks, Lego Train, and the NXT (using a third-party infrared link sensor.) The RCX 1.0 IR receiver carrier frequency is 38.5 kHz, while the RCX 2.0 IR carrier frequency is 76 kHz. Both versions can transmit on either frequency.[6] The carrier signal is generated by one of the RCX's internal timers. The RCX communicates with a co
14:42:25 <AnMaster> mputer using a Serial or USB IR tower."
14:42:27 <AnMaster> says wikipedia
14:44:46 <fizzie> I am under the impression that the lirc interface is flexible enough for any sort of low-enough-data-rate signals, but I've never used it. The kernel driver side seems to take just a list of timings when to turn the light on/off. (And when on, it independently flickers it at that configurable carrier frequency, but that's of course not related to data rates.)
15:02:34 <AnMaster> hm
15:06:58 <AnMaster> ARGH tar bomb
15:06:59 <AnMaster> :(
15:19:12 -!- coppro has quit (Quit: I am leaving. You are about to explode.).
15:23:59 <fizzie> Tar-and-feathers bomb.
15:25:04 <ais523> AnMaster: hmm, I wonder why tar hasn't been extended to detect tarbombs?
15:25:18 <ais523> it could have a --no-tarbomb command line option that you could add to your shell aliases
15:25:57 -!- BeholdMyGlory has joined.
15:26:21 * ais523 downloads tar source
15:27:10 <ais523> first, let's see if I can build this without changes, shouldn't be too hard
15:28:12 <ais523> of course, there's something sort-of weird about tar searching for tar as part of its configure
15:28:19 <ais523> but hey, there's autotools for you
15:28:37 <ais523> strangely, the autotools configuration here, at first sight, seems to be /correct/, which is bizarre for a GNU application
15:30:06 <ais523> hmm, this is strange, and really confusing; I do the standard autoreconf, configure, make, make install, and everything works perfectly the first time
15:30:13 <ais523> there is something wrong with the world
15:32:54 * ais523 vaguely wonders why GNU tar has an option to specify your favourite rsh implementation
15:33:04 <AnMaster> ais523, heh
15:33:14 <AnMaster> would have been nice
15:33:27 <AnMaster> ais523, but what about large tar archives?
15:33:40 <ais523> /obviously/, if I'm going to add a new and crusty yet useful feature to tar, it should be GNU tar I add it to
15:33:42 <AnMaster> ais523, I remember an uncompressed tar archive where tar -tf took a lot of time
15:33:50 <ais523> because that's where you add crufty features
15:33:59 <AnMaster> ais523, so I guess there is no file index at the start
15:34:02 <ais523> AnMaster: that's a different problem, you can just control-C there
15:34:28 <AnMaster> ais523, yes but the no-tar-bomb option shouldn't need to read the archive twice.
15:34:38 <ais523> hmm
15:34:42 <AnMaster> once for checking of tar bomb, once for actual expansion
15:34:57 <AnMaster> rather, be optimistic and if you detect a tar bomb midway, abort
15:35:13 <ais523> let's see, currently I think the ideal semantics would be "error out if trying to expand a tar file containing more than one file/directory in . when the current directory contains any files/directories but . and .."
15:35:14 <AnMaster> that way only one of the expanding dirs have been created
15:35:18 <AnMaster> which seems reasonable
15:35:34 <ais523> oh, I thought you meant tar bomb in the sense of "drops loads of files into the current directory", that's what people normally mean
15:35:34 <fizzie> You can't depend on reading the stream twice anyway, I do tar-netcat-tar sometimes.
15:35:34 <AnMaster> ais523, basically that tar archive in question was larger than ram iirc
15:35:40 <ais523> rather than along the lines of zipfiles
15:35:41 <AnMaster> ais523, yes indeed it does
15:35:44 <AnMaster> that is what I meant
15:35:44 <AnMaster> ...
15:35:49 <ais523> *zipbombs
15:35:50 <AnMaster> ais523, dropping all those files
15:36:32 <AnMaster> ais523, as fizzie said: "<fizzie> You can't depend on reading the stream twice anyway, I do tar-netcat-tar sometimes." and I dealt with tar files larger than ram recently
15:36:50 <ais523> this isn't meant to be protection against malicious tarfiles, rather protection against mistakes in creating tarballs
15:36:57 <ais523> and yes, I'd need to look into how the TOC works
15:37:10 <ais523> it should be noted that Emacs can write just the TOC of a tarfile without problems, so presumably it does come first
15:37:17 * ais523 man 5 tar
15:37:23 <ais523> people should read section 5 of the manual more often
15:37:47 -!- Phantom_Hoover has joined.
15:38:00 <ais523> hmm, seems to alternate between filenames and data
15:38:14 <AnMaster> fizzie, I just realised how to make that auto pano head be able to handle almost all exposure lengths and flash card speeds.
15:38:26 <ais523> so you'd have to abort at the second offending filename, and delete whatever files had been created in the meantime
15:38:29 <AnMaster> fizzie, can you guess if I say that I have lego light sensors (light level only)
15:38:41 <AnMaster> fizzie, :D
15:38:57 <ais523> anyway, if you wanted to make a /malicious/ tarfile, you'd just make a normal one with a .bashrc file in as well (and counterparts for other common shells)
15:39:22 <AnMaster> ais523, well for that tar file it seemed to read the whole tar to be able to list everything in it
15:39:29 <AnMaster> unless tar -tf does more than just listing
15:39:51 <ais523> oh, I've got it
15:39:59 <ais523> you can do tar -t very quickly on a /seekable/ file
15:40:06 <ais523> because each header lets you know how much data to skip
15:40:11 <ais523> if the file's nonseekable, though, you have to read the whole thing
15:40:13 <AnMaster> ais523, it was a 2.6 GB uncompressed tar file
15:40:33 <ais523> presumably tar isn't intelligent enough to seek over the uninteresting bits, but emacs is
15:40:46 <AnMaster> ais523, it contained some interesting files in it... Like .zip.xz unless I misremembered
15:41:02 <AnMaster> ais523, it was downloaded from Xilnix (sp? those who make FPGAs...)
15:41:11 <ais523> ah
15:41:12 <AnMaster> and well, I did want to check for tar bomb
15:41:17 <ais523> and "Xilinx"
15:41:28 <AnMaster> ais523, yeah I wouldn't trust a company with doing it right
15:41:29 <ais523> yep, they certainly do make interesting tarballs
15:41:49 <AnMaster> ais523, but this tar bomb I ran into today was from sourceforge. And I didn't expect a tarbomb there...
15:42:38 <ais523> OpenCores is worse, many people just check tarballs into svn rather than checking in the directory tree
15:42:44 <AnMaster> ugh
15:42:47 <ais523> thus making it almost useless for anything but backup-over-time
15:43:00 <AnMaster> don't they provide any guidelines for this?
15:43:42 <AnMaster> ais523, and I presume you also ran into Xilinx tarballs from that comment above?
15:44:15 <AnMaster> ais523, I was hoping to somehow extract timing data on the gates from that to use with ghdl
15:44:32 -!- ais523 has quit (Remote host closed the connection).
15:44:52 -!- ais523 has joined.
15:46:48 <AnMaster> <ais523> thus making it almost useless for anything but backup-over-time
15:46:48 <AnMaster> <AnMaster> don't they provide any guidelines for this?
15:46:48 <AnMaster> <AnMaster> ais523, and I presume you also ran into Xilinx tarballs from that comment above?
15:46:48 <AnMaster> <AnMaster> ais523, I was hoping to somehow extract timing data on the gates from that to use with ghdl
15:46:52 <AnMaster> ais523, anything missed?
15:46:59 <AnMaster> (in either direction)
15:47:12 <ais523> the last three, I missed
15:47:23 <ais523> yes, I have run into xilinx tarballs
15:47:46 <ais523> most notably, when they sent me some stuff in a tarball intended to run on a Windows system that didn't have tar
15:47:53 <AnMaster> XD
15:48:08 <ais523> I don't think they quite "get" Windows
15:48:14 <ais523> which is an unusual situation for a big company to be in
15:48:20 <AnMaster> indeed...
15:48:43 <AnMaster> and what are the chances to manage that timing data thing? I read somewhere about someone managing to do that from the downloads of some other manufacture...
15:49:22 <ais523> I have no idea, but my guess is that if something's a free download, it isn't going to help with it
15:51:57 <ais523> normally they charge for information that precise
15:53:55 <AnMaster> fizzie, no guesses for how?
15:54:07 <AnMaster> ais523, :/
16:00:18 -!- Phantom_Hoover has quit (Ping timeout: 265 seconds).
16:01:48 -!- Tritonio_GR has quit (Read error: Connection reset by peer).
16:06:21 <fizzie> I was in a bus, going from work to home.
16:09:44 <AnMaster> fizzie, ah
16:09:48 <AnMaster> fizzie, forgot /away ;P
16:09:54 -!- kar8nga has joined.
16:09:55 <fizzie> It should've been automatic.
16:10:02 <AnMaster> fizzie, anyway can you guess now?
16:10:03 <fizzie> Maybe my automatic thing is borken, wouldn't surprise me.
16:10:05 <AnMaster> <AnMaster> fizzie, I just realised how to make that auto pano head be able to handle almost all exposure lengths and flash card speeds.
16:10:06 <AnMaster> <AnMaster> fizzie, can you guess if I say that I have lego light sensors (light level only)
16:10:28 -!- Phantom_Hoover has joined.
16:10:29 <fizzie> I would guess some sort of "currently working" LED in the camera, at least mine has something that blinks as long as it is working. (And blanks the camera screen too, I think.)
16:11:06 <AnMaster> fizzie, yes there is a LED for compact flash card activity :)
16:11:36 <AnMaster> but yeah sure the monitor... well it would be kind of annoying to have sensors obscuring it. Plus there could be black stuff anyway
16:12:23 <fizzie> Right, the "this was what you got" preview might confuse it too. But there is the led.
16:12:41 <AnMaster> fizzie, so what is needed is simply: 1) press shutter and release (after suitable time, will have to figure such details out)... 2) wait until led turns on. 3) wait until it turns off again
16:13:53 <AnMaster> fizzie, plus for long exposures my camera does something funny when taking that "black frame" after to remove the heat noise or whatever from the CCD...
16:14:06 <AnMaster> so probably a bit more complex than that for the LED stuff
16:14:38 <AnMaster> also who knows, if it blinks. (it usually doesn't but it might be too fast for a human but still possible to measure with such a sensor)
16:18:10 <AnMaster> hm... I wonder what the best way is to adjust the camera position (wrt nodal point)... probably a lego engine the thing on some sort of "flat cogwheel" rail
16:19:41 <AnMaster> ah... "Technic Gear Rack 1 x 4"
16:19:42 <AnMaster> bbl food
16:19:49 <fizzie> Steal a stepper motor from a HD, for the ultimate in precise positioning.
16:20:59 <ais523> are they more or less accurate than those in CNC machines?
16:24:18 <fizzie> I have no real clue. Could be less. I don't think they rely on the usual boring stepper motors any more.
16:24:26 <fizzie> "The arm is moved using a voice coil actuator or in some older designs a stepper motor."
16:25:17 <fizzie> I have a habit of hyperbole, just downgrade all my statements a few notches in general.
16:28:38 <AnMaster> fizzie, how are they controlled btw?
16:29:03 <AnMaster> fizzie, as I *do* happen to have an old non-working HD in some box somewhere
16:29:24 <AnMaster> fizzie, so this sounds entirely possible if it is possible to control it from a RCX :D
16:29:34 <AnMaster> (and interface it with lego somehow)
16:29:41 <ais523> AnMaster: stepper motors have four input wires
16:29:46 <ais523> and power input
16:29:53 <ais523> you need to control two of the wires at a time in a pattern
16:29:56 <ais523> AB BC CD DA etc
16:30:02 <ais523> each time round the pattern it moves four steps
16:30:09 <ais523> you can do the pattern in reverse to move in the other direction
16:30:22 <ais523> and if you need a half-step, you can do just B to be halfway between AB and BC, for instance
16:30:30 <AnMaster> ais523, does it have some turning limit? Or can it turn 360° forever?
16:31:02 <ais523> forever
16:31:07 <AnMaster> also what are typical voltages/currents of them?
16:31:24 <ais523> hmm, it was something around 9V last time I used one, can't remember the current
16:31:42 <ais523> I wouldn't be surprised if hard drive ones used lower voltages, though
16:32:05 <AnMaster> hm right
16:32:17 <AnMaster> hm the RCX uses PWM to control the motor unless I misremember... might be hard to interface that... Oh wait I think it is done in software. Maybe
16:32:45 <AnMaster> well yeah it probably is
16:33:11 <AnMaster> ais523, for 4 wires I would need more outputs than the RCX has...
16:33:53 <AnMaster> (it has 3 PWM controlled motor outputs, where the PWM is done in software by the ROM iirc. I don't think it was the firmware that did it...)
16:34:50 <AnMaster> ais523, wait, why does it use 4 wires? That is just 4 states. Couldn't it be done with 2 wires?
16:34:56 <AnMaster> and gray code of course
16:35:08 <ais523> AnMaster: because it doesn't do calculation internally
16:35:16 <AnMaster> hm
16:35:29 <ais523> that's just the sequence you activate the electromagnets in
16:35:44 <AnMaster> ah
16:35:55 <AnMaster> how small are the steps?
16:36:08 <ais523> pretty small, normally, you need loads for a full revolution
16:36:35 <AnMaster> ais523, so how fast is that done in a harddrive. I suspect an RCX couldn't drive it at full speed anyway...
16:36:50 <ais523> the faster you drive them, the less torque you get
16:36:54 <ais523> likewise, if you slow down, it's stronger
16:37:11 <ais523> but for something that's easy to turn anyway, like a harddrive that has already spun up, you can cycle through the steps really fast
16:37:34 <ais523> Wikipedia says 200 steps per revolution, that seems reasonable
16:37:51 <AnMaster> ais523, seems very few for a harddrive...
16:37:59 <AnMaster> unless there is some gearbox
16:38:08 <ais523> presumably harddrives have more steps
16:38:10 <AnMaster> which would reduce accuracy...
16:38:25 <ais523> but it seems that by using more complicated patterns than just 0 and 1, you can get arbitrary fractions of a step
16:38:28 <ais523> which also makes sense
16:38:44 <AnMaster> hm
16:39:11 <AnMaster> ais523, as in +4V and +2V for the ones next to each other? Instead of same for both?
16:39:19 <ais523> yep, that sort of thing
16:41:42 <fizzie> A hard-drive stepper motor controls the "lateral" position of the read-head on the disk, it doesn't rotate the disk itself.
16:42:03 <AnMaster> fizzie, well yes I do realise that easily...
16:42:23 <AnMaster> fizzie, it would however be used to seek
16:42:28 <AnMaster> and seeks should be fast and precise
16:42:36 <ais523> fizzie: what sort of motor rotates the disk? just a regular one?
16:42:50 <fizzie> Just a regular one; I don't know what they use for decoding the current angle of the disk.
16:43:03 <ais523> probably the read head itself
16:43:12 <ais523> you could determine where you were from what you were reading
16:43:38 <AnMaster> ais523, I assume there is some sort of flywheel or such on the spinning disk to make it rotate at a stable speed?
16:43:49 <ais523> I have no idea
16:43:54 <AnMaster> well, fizzie then
16:44:40 <fizzie> I'm no HD engineer either. Not sure how stable it needs to be, though I guess compensating for some wibble there would presumably make the reading circuitry somewhat more complicated.
16:45:39 <fizzie> Given how small the single storage regions are nowadays, I'm sure it's not completely simple.
16:45:58 <AnMaster> fizzie, plus (desktop) harddrives at least tend to be rather heavy
16:46:04 <AnMaster> not sure what bit causes it
16:46:41 <fizzie> The platters contribute a reasonable fraction of the weight, at least comparing a 2-platter terabyte disk with a 4-platter 2-terabyte disk that otherwise share identical hardware.
16:46:42 <AnMaster> I mean, as far as I remember my current SATA disk is about the same weight as the larger dvd drive
16:46:55 <AnMaster> and it is 350 GB
16:47:02 <AnMaster> a bit older in other words
16:47:16 <AnMaster> anyway laptop drives can't be very heavy presumably
16:47:47 <AnMaster> fizzie, larger platters in one? Or different packing density?
16:47:51 <AnMaster> (of the bits)
16:48:00 <AnMaster> and if so, why make both variants
16:48:49 <fizzie> Given that they want to optimize the capacity, I'd guess they use the same ("as much as we can cram in there with our tech") or at least similar packing density in all disks.
16:50:02 <fizzie> Anyway, adding weight means more energy wasted in keeping all that weight rotating, so if you want to optimize power usage too, you'd want to make things lighter. (Of course it's relatively easy to keep all that mass spinning when you've spun it up in the first place, but there's still friction.)
16:50:32 <fizzie> At least I've seen the weight argument in some drive-power-usage-analysis-review thing.
16:51:00 <AnMaster> oh wait... 2 terrabytes for the second
16:51:01 <AnMaster> right
16:51:06 -!- Zuu has joined.
16:51:08 <AnMaster> misread it as both being 1 terrabyte
16:52:10 <fizzie> Oh. Yes, they commonly put half a terabyte per (3.5" HD) platter nowadays. Or did a while ago; I'm sure someone's done more than that already.
16:52:30 -!- Phantom_Hoover has quit (Ping timeout: 265 seconds).
17:01:06 <fizzie> Twungot says: "About NetHack: the other hand, is necessary for a charm of powerful trouble, though they are the fairest in the middle of her spear, ..."
17:02:11 <AnMaster> fizzie, still done by a perl script instead of befunge98 program?
17:02:25 <ais523> I like the concept of a charm of powerful trouble
17:03:52 <AnMaster> fizzie, where are the parts from?
17:04:07 -!- ais523 has quit (Remote host closed the connection).
17:04:09 <fizzie> AnMaster: Unfortunately, yes. And before you ask, I also haven't had any jitfunge time lately, and won't in a month or so. (Still a week of exams and then two weeks of Europe.)
17:04:51 <AnMaster> I have a few weeks ahead at university still
17:06:54 <fizzie> "middle of her [Aegis]" from the end of the Medusa desc.
17:07:28 <fizzie> "her spear" from shrieker.
17:08:12 <Deewiant> I've started that subset-of-Befunge static compiler
17:08:25 <fizzie> "fairest in" from "Who is the fairest in the land?", a Snow White quote.
17:08:41 <fizzie> Deewiant: You did notice my one, right?-)
17:09:07 <Deewiant> Don't think I did
17:09:59 <fizzie> It compiles and runs fungot, to some extent. Babbling probably won't work, and persistence had some issues, but I did get it to come here on-channel.
17:10:29 <Deewiant> When was this? Does it exist somewhere?
17:10:50 <Deewiant> Or did you just hack jitfunge a bit
17:11:15 <fizzie> Hrm, I'll have to grep for that. And no, it's almost completely separate from jitfunge.
17:11:31 <fizzie> It's in Java, for example. :p
17:11:37 <Deewiant> Argh >_<
17:11:41 <Deewiant> What does it emit?
17:11:52 <Deewiant> x86 for GNU as? :-P
17:11:55 <fizzie> LLVM assembly, I think.
17:12:02 <fizzie> As text.
17:12:05 <Deewiant> Are there bindings?
17:12:06 <Deewiant> Yeah :-P
17:12:39 <Deewiant> Mine is in Haskell and uses the LLVM bindings so it's thrice as awesome
17:12:48 <fizzie> Yes, well, I wasn't so taken by LLVM's IRBuilder, or the whole mess of classes there.
17:13:11 <Deewiant> Just use the C API if you find the C++ to be too much of a mess
17:15:03 -!- lereah_ has quit (Remote host closed the connection).
17:15:03 -!- Phantom_Hoover has joined.
17:15:05 <fizzie> Possibly I should've. Instead I ended up with a Java reimplementation of the type system thing, except a lot smaller, of course.
17:15:20 <Deewiant> Gah >_<
17:15:23 -!- oerjan has joined.
17:15:35 <fizzie> Anyway, it was more of a proof-of-concept thing; I think I did it in less than a week. And possibly I'll use it to run fungot permanently at some point.
17:15:47 <Deewiant> Use mine instead :-P
17:15:53 <Deewiant> Which I've thus far done in less than a couple of hours
17:15:56 <fizzie> Nah, it's not invented here. :p
17:16:04 <Deewiant> And can do a hello-world but not much more
17:16:21 <Deewiant> You and your NIH syndrome :-P
17:16:32 <oerjan> the fizzie who says NIH
17:18:14 <fizzie> How's your code generation? Completely mechanistic translation of the Befunge-98 code, trusting LLVM to fold all stack manipulation away; a "intermediate stack operands turn into values, LLVM does the rest" thing; or something else?
17:19:10 <Deewiant> I took CCBI's stack, translated it to C (because I didn't think it through properly; that was pointless but oh well), and emit calls to it for stack manipulation
17:19:30 <Deewiant> No "stack overflow" errors for me :-P
17:19:57 <fizzie> Oh, okay. I do a reasonable amount of "from stack to a register thing" translation, for no particular reason.
17:20:15 <Deewiant> LLVM does optimize it well enough
17:20:18 <Deewiant> At least when MODE isn't used
17:20:36 <fizzie> Probably. For some reason silly-looking code, even temporary such, irritates me.
17:20:51 <Deewiant> What's silly-looking
17:21:19 <Deewiant> And how'd you do Funge-Space in your thing
17:21:48 <fizzie> Something like &&+. involving "push to stack, push to stack, pop, pop, sum, push to stack, pop, print" is silly to me.
17:22:41 <Deewiant> Meh; at least it's easy to debug
17:23:10 <Deewiant> I also tend to emit a bunch of basic blocks which do nothing but br to another
17:23:23 <fizzie> I cull those out, for the same reason.
17:23:31 <Deewiant> I let LLVM do that :-P
17:23:43 <Deewiant> I don't see much point in duplicating LLVM functionality
17:23:54 <fizzie> Yes, well, I guess it's a matter of taste.
17:23:56 <Deewiant> It's just more LOC for no gain
17:24:20 <fizzie> I don't see much "point" in the whole endeavour, and I did it mostly for playing-around reasons, as well as the irrational irritation -reasons.
17:24:22 <Deewiant> If you want "better looking" code, compile with -O. The problem is that while it removes silliness it can also introduce complexity :-P
17:25:46 <Deewiant> Anyway, you've yet to tell me what you did about Funge-Space
17:26:45 <fizzie> Oh, I just took jitfunge's hash-based fungespace for that; at least there's a bit of reuse. And I have a static funge-space box the size of the progarm source code, since I'll need that data anyway for g'ing the right "static data" in.
17:27:57 <Deewiant> So essentially what cfunge does; one static box + hash table
17:28:19 <fizzie> Right.
17:29:42 <Deewiant> How far does it get in Mycology?
17:30:28 <fizzie> Still on the stack-to-register translation; I just don't completely trust LLVM to remove all the stack underflow tests when inlining the stack ops. I guess it's quite probable it does just fine, I just feel like since I know more about the case I'm code-generating in than LLVM does, I might as well do sensible things from the get-go.
17:30:43 <fizzie> I'm not sure I've tested.
17:30:57 <fizzie> I'll try to check when I have time; now I really need to prepare some food.
17:31:04 <fizzie> I should've been doing that for the last half an hour already.
17:31:23 <Deewiant> Doing some higher-level optimization is not wrong, of course
17:32:15 <Deewiant> I plan to do some early folding already at the parsing stage, to allow handling only one direction of a branch
17:32:42 <Deewiant> (Although probably the only kind of code that does that is self-modifying anyway)
17:33:14 <fizzie> I use _|s somewhat often as a combination of one of v<>^ and a $, when trying to size-optimize things.
17:33:25 <fizzie> I think I and mooz used to call those things "discard-ifs", even.
17:33:36 <Deewiant> heh
17:34:14 <fizzie> There's even one case in fungot, I believe. Or I might be confusing that with a single case of [ or ], which I'm not in the habit of using, due to some Befunge93 roots.
17:34:57 -!- fizzie has quit (Quit: jumpin' jumpin').
17:35:00 -!- fizzie has joined.
17:35:12 <Deewiant> What is it with you and your hostname?
17:35:30 -!- fungot has joined.
17:36:12 <fizzie> Deewiant: I have left one of freenode's servers with an IPv6 entry in my bouncer configuration, and my IPv6 reverse-DNS setup is broken, and I always forget it some three seconds after doing this jumpery.
17:36:23 <fizzie> ^source
17:36:23 <fungot> http://git.zem.fi/fungot/blob/HEAD:/fungot.b98
17:36:25 <Deewiant> >_<
17:36:38 <fizzie> (This was one roundabout way of locating that URL.)
17:37:12 <fizzie> There on line 109 is a case of using a _ instead of $<.
17:37:20 <fizzie> It's even documented; it says "d-if" right next to it.
17:37:28 <fizzie> Granted, "d-if" might not mean much to most.
17:38:20 <Deewiant> Too bad the _ is also used as a real if :-P
17:38:41 <fizzie> Not that particular _, it goes always to the left.
17:38:50 <Deewiant> Even from the | above it?
17:39:17 <Deewiant> That one's not compiler-obvious even if it does
17:39:34 <fizzie> Yes, I believe it does. But it's not very clear to a compiler.
17:39:47 <Deewiant> It uses a fingerprint instruction so it's practically invisible
17:40:03 <fizzie> In general, I use a discard-if after a loop that does ":|" style stuff has terminated, and I need to get rid of the known-zero below.
17:40:12 <fizzie> That's not compiler-obvious, but I guess it's compiler-knowable.
17:40:54 <Deewiant> That's the kind of thing I leave to LLVM :-P
17:44:16 <Deewiant> Did you handle x at all?
17:44:29 <Deewiant> (And how much)
17:48:01 <fizzie> Uh, there's a "todo" comment for it.
17:48:29 <Deewiant> That's a "no", then :-P
17:49:37 <fizzie> I was thinking of handling it pretty minimally. I'm a bit wary on doing things during parsing, since you can then hit the same thing with a different sort of stack context, and then you'll need to reconsider the earlier bits. (Or do code duplication and consider the new case a different thing, which I guess might be more reasonable.)
17:50:30 <Deewiant> I'm not sure what you mean by a different sort of stack context
17:51:44 <fizzie> Well... if there's something like "1>1x", I can handle that x pretty easily when parsing; but currently my strategy is that if I see a cell that's been gone through with the same delta, I can always just generate a branch there. Here if someone hits the > with a 2 on the stack, it changes the whole meaning of the "1x" bit, assuming "whole meaning" has been "change delta to (1,1).
17:52:43 <Deewiant> Recommendation: check the delta as it would be /after/ the instruction, not before
17:53:46 <fizzie> I don't see how that help. The bit of code that hits the > hits the "1x" part with exactly the same delta, it's just the context that differs; yet I need to reanalyze it because the x will go a different way. Currently I'd just say "okay, this just jumps to the 1 and I can stop parsing here".
17:53:58 <Deewiant> Oh, right, the > fails.
17:54:02 <Deewiant> My bad.
17:56:36 -!- Gregor has quit (Ping timeout: 252 seconds).
17:57:14 <fizzie> I guess it's not a terrible problem, I just like the current way that when I see a (position, delta) that's already been seen before, I can be sure that it can't lead to anything new.
17:57:22 <fizzie> Anyway, I need to eat that food I made now, away for a while.
17:58:12 <Deewiant> If you make basic-block type things like I do you can just add a check for if the terminator is an x
18:05:53 <AnMaster> <fizzie> Anyway, it was more of a proof-of-concept thing; I think I did it in less than a week. And possibly I'll use it to run fungot permanently at some point. <-- fungot is no fun without self modification
18:05:54 <fungot> AnMaster: haven't tried the code? or are you still dead? :)
18:06:18 <Deewiant> It doesn't self-modify, does it?
18:06:23 <oerjan> even fungot is being snarky these days
18:06:24 <fungot> oerjan: what was that forth called you where talking about the binary level, then.
18:09:03 -!- kar8nga has quit (Remote host closed the connection).
18:28:31 <fizzie> It doesn't, no. And I still think it's at least a bit fun.
18:30:58 <fizzie> Deewiant: Yes, you could test for x-termination; though if you want to determine if an "if" always goes to a particular direction, you'd then still need to break a basic block there, and potentially re-examine all basic blocks you have that terminate into an if that's been short-cutted, if you encounter that block from some other way.
18:32:06 <Deewiant> I don't get it, gimme an example
18:33:29 -!- kar8nga has joined.
18:33:47 <fizzie> Uh, well... if you have a 1>[...lots of code with no final stack effect...]| you can (on the first parse through it) deduce that the | at the end always goes up, but when you re-enter that block by hitting the > from some other place, you'll need to notice that "hey, this means I have a new potential branch to parse".
18:33:59 <fizzie> Granted, this isn't a big hassle if you build those basic blocks while parsing.
18:34:15 <Deewiant> I'm not planning on doing that kind of optimization myself across basic blocks
18:34:42 <Deewiant> As far as I'm concerned, when I hit a >, I don't know what's on the stack any more.
18:35:07 <fizzie> Okay, if you do it like that, then it will be easier. But it's a bit of a shame that simple direction-modification has that sort of an effect.
18:35:45 <Deewiant> No it's not, because LLVM can compute the dominator tree and do the partial redundancy elimination and whatnot that's required to figure it out later on :-P
18:36:34 <Deewiant> I'm not very concerned about the unoptimized code quality
18:37:15 <fizzie> My parser is a two-stage thing, where I first build a graph that contains a "basic block" for each single cell, then I merge those into actual basic blocks. So it's not so easy to look at a single node and know that it will be terminated by an 'x' in the end. I could've done it so that it built real blocks, and then split those when necessary, of course. Or, like you apparently do, make every <>v^ start a new block?
18:37:46 <Deewiant> Yes, that's what I do.
18:38:16 <Deewiant> And as a bit of a hack, a new block at (0,0) so that code that infinite-loops on the first line doesn't cause the parser to infinite-loop
18:39:08 <fizzie> I had earlier some sort of overly complicated static-analysis incomplete Funge thing (I think the earlier fungot graphs were from that) which tried to do that sort of analysis; it kept track of known stack cells, and even "known to be nonzero but not exactly what" cells, and "unknown but there's still something known below it" cells, and kept a record of that sort of "stack context" at each point, and when I encountered some code from a new direction, tried to
18:39:08 <fizzie> merge those stacks by keeping the "compatible" information there.
18:39:08 <fungot> fizzie: i guess it's not as much as the name might be too complicated i think
18:39:24 <fizzie> It started to become a bit overcomplicated at some point.
18:39:33 <fizzie> Can't rely on LLVM for that sort of use, unfortunately.
18:40:18 <Deewiant> Why not? That's exactly what it tries to figure out when optimizing away loads and phis
18:40:40 -!- MigoMipo has changed nick to migomipo.
18:40:44 <fizzie> I mean, if your desired end result is human-readable graphs that still contain recognizable Befunge code, only the code flow part represented by a graph.
18:40:48 <fizzie> Certainly if you want executable code...
18:41:24 <Deewiant> Ah, yes. :-)
18:42:31 <fizzie> "git log" says I started on a Thursday and stopped the same week's Sunday, so you could call that compiler a bit of a small-scale experiment.
18:43:05 <Deewiant> heh
18:43:32 -!- zzo38 has joined.
18:44:33 <zzo38> I cannot figure out the short solution in dc
18:44:47 <zzo38> I did 17 bytes long
18:45:38 <zzo38> I don't know whether or not you care, but: I have upgraded 888ASM, now it supports macros and a few other things
18:48:00 <zzo38> I have never won at any anarchy golf problem that I invented. But I have won at some other ones
18:54:34 <zzo38> Do you go to anime convention this year?
18:58:07 <pikhq> http://sprunge.us/iWKX
18:58:30 <pikhq> This is what happens when you take Internet from me. I produce silly, not-needed code.
18:58:39 <Deewiant> >_<
18:58:47 <pikhq> ... That has a bug I just noticed.
18:59:47 <pikhq> Now, minus the obvious bug: http://sprunge.us/ahDN
19:01:49 <zzo38> Can you please tell me what this program is for?
19:02:40 <pikhq> It compiles Brainfuck to 386 assembly.
19:03:13 <zzo38> OK. I suppose it is obvious now
19:03:22 <zzo38> Which assembler?
19:03:49 <pikhq> nasm
19:03:54 <zzo38> OK
19:03:59 <pikhq> And Linux-only.
19:04:51 <zzo38> OK
19:05:14 -!- uorygl has quit (Ping timeout: 240 seconds).
19:06:12 <pikhq> The data pointer is in ecx so that I have to do 0 work to make it the argument for the system calls, and the code pointer is in esp so I don't have to move it anywhere when making system calls.
19:07:19 <zzo38> The other assembler is 888ASM. It doesn't yet have full support for protected mode commands yet
19:09:28 -!- MizardX has joined.
19:13:28 <zzo38> Have you ever written a assembler?
19:15:40 <pikhq> Nope.
19:15:57 <zzo38> Why?
19:16:11 <pikhq> Never felt like it is all.
19:16:37 <zzo38> OK
19:17:13 <zzo38> Do you like the one I wrote, did you think is good?
19:17:30 <pikhq> Dunno, not looked at it much.
19:18:15 <zzo38> sprunge seems the good pastebin
19:18:30 <zzo38> I looked at the instructions
19:18:59 <zzo38> The only thing is I don't have curl installed
19:19:03 -!- uorygl has joined.
19:21:44 <zzo38> Perhaps if I write GNU/Linux distribution, I might include a shell-script for "sprunge" in the EXTRA packages set.
19:22:10 <pikhq> How can you not have curl?
19:22:23 <pikhq> It's freaking curl!
19:22:41 <zzo38> I probably should install curl
19:22:43 <zzo38> http://zzo38computer.cjb.net/prog/888ASM/888asm.c
19:22:59 <zzo38> I do have wget
19:23:02 <zzo38> And netcat
19:24:27 <zzo38> Now perhaps you can see if the improvements to 888ASM is any good
19:28:05 <fizzie> pikhq: Do you have some reliable information on how much you're allowed to play games with the stack pointer? I was considering that for the Befunge stack in an earlier jitfunge, and I think in that Scheme compiler, but got sidetracked while hunting for documentation. What little I did find is that you could perhaps make it signal-safe with sigaltstack stuff, but beyond that I'm not so sure. X86-64 ABI (my target) for example has that "red zone" thing... w.r.t.
19:28:05 <fizzie> syscalls it seemed reasonably safe on Linux, for both interrupts and the SYSCALL way, but no-one was exactly claiming so.
19:29:02 <Deewiant> Using the system stack is lame, it limits the size too much
19:29:22 <fizzie> Deewiant: Sure, but using the ESP/RSP register to point at wherever you want doesn't.
19:29:54 <Deewiant> Right, I just got that from reading "stack" and "jitfunge" :-P
19:30:09 <fizzie> You should've also read the "playing games" part. :p
19:31:10 <pikhq> fizzie: The esp is a general purpose register.
19:31:58 <pikhq> It just happens to contain a pointer to a stack under pretty much every ABI, and "call" and "ret" manipulate aforementioned stack.
19:32:38 <pikhq> So, there's a *lot* of games you can play with that.
19:32:40 <fizzie> That doesn't mean the syscall interface couldn't require you to have a "nice" stack.
19:33:08 <Deewiant> "Pretty much every ABI" of which syscall may or may not be one
19:33:16 <pikhq> The kernel entry point *by necessity* starts by saving all registers and using its own stack.
19:33:48 <fizzie> And why would that be a necessity? You already need to prepare registers for the syscall parameters.
19:34:35 <pikhq> There's the floating point registers, syscall parameters that aren't being used, the base pointer, the stack pointer, the SSE registers, and the MMX registers.
19:35:29 <pikhq> Pretty much every kernel, upon being entered, just saves all the registers. And it almost certainly must use its own stack.
19:36:56 <Deewiant> Why?
19:37:47 <pikhq> The kernel damned well does not want to assume correctness of anything that it gets passed by userspace.
19:38:03 <Deewiant> Ah, fair enough.
19:38:24 <pikhq> If it used the process's stack, you could, for instance, set it up so the kernel will return to a rootkit.
19:38:32 <Deewiant> So you can exploit the fact that you're considered malicious :-P
19:38:41 <pikhq> Yes.
19:38:42 <fizzie> Can't say I've inspected the internals of so many kernels I'd feel comfortable relying on that; and I found it pretty hard to find good-looking documentation on Linux. I did look at the sources, and it certainly seemed to be pretty conservative like that, but still.
19:39:28 -!- zzo38 has quit (Remote host closed the connection).
19:39:35 <pikhq> fizzie: Linux ABI in particular saves all registers upon entry, even the ones that are just syscall parameters.
19:40:03 <fizzie> Yes, well, do you happen to have handy a reference work for this?
19:40:15 <pikhq> Let's find the entry in /usr/src/linux
19:41:13 <fizzie> If you mean the code, I think it's arch/x86/kernel/entry_{32,64}.S; but I'd prefer a statement of intent instead of reading the particulars for each architecture that sounds interesting.
19:41:46 <fizzie> (It's also rather macro-heavy code.)
19:42:14 <fizzie> I vaguely recall looking at Documentation/, but nothing immediately sprang up. I don't think I used a lot of time for this, though.
19:44:31 <fizzie> (The register setup is fortunately very cleanly explained in the comment above ENTRY(system_call), that was a nice touch.)
19:51:11 -!- Sgeo has joined.
19:54:03 <fizzie> Anyway, sure, it does "start" with
19:54:04 <fizzie> movq %rsp,PER_CPU_VAR(old_rsp)
19:54:04 <fizzie> movq PER_CPU_VAR(kernel_stack),%rsp
19:54:04 <fizzie> ... after some less clean stuff, but the comment also says "if we had a free scratch register we could save the RSP into the stack frame and report it properly in ps. Unfortunately we haven't", which I might even think would refer to cobblering something in the userspace's stack frame.
19:56:43 <AnMaster> does anyone here have any experience with building cross compilers?
19:56:51 <Phantom_Hoover> I wish alise turned up on weekdays...
19:57:04 <AnMaster> debian used to provide a package for it during woody. but hasn't since
19:57:06 <Deewiant> Cross compilers are not very different from any other kind of compilers
19:57:07 <oerjan> so does alise
19:57:08 <AnMaster> (to this arch)
19:57:21 <Deewiant> Oh, you meant "building" as in "compiling"
19:57:26 <AnMaster> Deewiant, well... I need to use outdated binutils and gcc versions for the thing to even support this arch...
19:57:32 <Deewiant> Or "setting up"
19:57:39 <AnMaster> Deewiant, getting a working toolchain
19:57:45 <AnMaster> from a bunch of gcc/binutils tarballs
19:57:47 <AnMaster> and patches
19:57:49 <AnMaster> is what I mean
19:58:12 <fizzie> I've used that tool for it. Or two tools, in fact. I just can't ever remember the names.
19:58:23 <AnMaster> Deewiant, I'm stuck at binutils 2.16.1 and gcc 3.4.6 as the last versions supporting this arch
19:58:54 <AnMaster> and I have no idea where to start with building a cross toolchain
19:59:19 <AnMaster> documentation is very bad and bitrot ensures that I'm very unlikely to find anyone to update it
19:59:44 <AnMaster> the entire community on this arch is half-404 nowdays
19:59:46 <AnMaster> :/
20:00:26 <AnMaster> upstream vendor? No longer has any info on this product at all...
20:00:27 <fizzie> I think I used http://www.kegel.com/crosstool/ several years ago, but it might be somewhat out of date, and probably won't cover your particular situation out-of-the-box.
20:00:59 <Deewiant> What arch?
20:01:09 <AnMaster> Deewiant, RCX
20:01:22 <AnMaster> atm I'm trying to figure out target triplet
20:01:31 -!- ais523 has joined.
20:01:36 <Deewiant> Why are you interested in it
20:01:36 <fizzie> And then there's buildroot, which is mainly interesting if you want a uClibc-based toolchain for a Linux system, but could do some other useful things too.
20:01:45 <AnMaster> Deewiant, it is either h8300-hitachi-hms or h8300-hitachi-coff
20:01:53 <AnMaster> there is some contradiction on it
20:02:01 <AnMaster> ah didn't ais523 mess with cross compiling before?
20:02:09 <ais523> yep
20:02:15 <ais523> I have an ARM toolchain on here right now
20:02:21 <ais523> and ofc gcc-bf is a crosscompiler
20:02:22 <AnMaster> ais523, what is the basic steps required in setting up a cross toolchain from a binutils and gcc source tarball
20:02:30 <ais523> because it would be ridiculous to make it native
20:02:42 <AnMaster> ais523, oh and I need to use old versions... since the arch is no longer supported
20:02:47 <ais523> let's see, I've never actually set up a cross /toolchain/ by hand before, just the individual compiler
20:03:02 <ais523> the ARM toolchain was generated via a rather complicated makefile
20:03:04 <AnMaster> ais523, I need linked and C compiler at least.
20:03:05 <ais523> which had wget commands in it
20:03:15 <AnMaster> C++ might be needed later on (ugh)
20:03:23 <ais523> for the compiler, if it's gcc, you just need a weird set of configure options
20:03:43 <AnMaster> ais523, I need to use binutils 2.16.1 and gcc 3.4.6. Last versions supporting h8300-hitachi-hms
20:04:00 <AnMaster> and I need to apply a bunch of patches
20:04:24 <ais523> sounds fun
20:04:31 <ais523> you are aware that gcc's build system is insane, right?
20:04:46 <AnMaster> ais523, yes and I do know how to handle it for "normal" native builds
20:04:50 <AnMaster> but that is out of question here
20:05:06 <AnMaster> ais523, h8300-hitachi-hms is the triplet for the RCX you see
20:05:28 <ais523> anyway, in theory the only change you have to make is to give configure options like this: --build=i686-linux-gnu --host=i686-linux-gnu --target=h8300-hitachi-hms
20:05:41 <AnMaster> half of the relevant pages are 404 or "see relevant links for <not very relevant part of domain name>" nowdays...
20:06:03 <ais523> you need to give all three when doing any sort of cross-compilation, whether you're crosscompiling gcc or straightcompiling a crosscompiler or even crosscompiling a crosscompiler
20:06:13 <AnMaster> ais523, I don't have any libc for this btw... As in, the OS I will cross compile will provide a very stripped down set of header files
20:06:28 <ais523> you could use newlib
20:06:49 <AnMaster> ais523, well why? I already get stdlib.h and a few more...
20:06:51 <AnMaster> and
20:06:52 <ais523> which implements the whole libc in terms of about 15 system calls, which you need to give by hand if the OS doesn't do them itself
20:06:58 <AnMaster> it isn't like there is any console IO on it
20:07:07 <ais523> well, it depends on how much libc you need
20:07:07 <AnMaster> ais523, I'm very limited in RAM on the RCX...
20:07:14 <ais523> does it have sprintf, for instance? and do you need it?
20:07:21 <AnMaster> ais523, no I don't need that :P
20:07:31 <AnMaster> ais523, I don't need any string handling at all in fact
20:07:47 <pikhq> So, what *do* you need?
20:07:59 <AnMaster> pikhq, floating point emulation, which is provided.
20:08:11 <AnMaster> pikhq, and bare access to the hardware
20:08:18 <AnMaster> which is also provided
20:08:25 <AnMaster> there is no MMU or such on this thing after all
20:08:29 <AnMaster> and it is 16 bit. not 32-bit
20:08:43 <AnMaster> (or 8-bit perhaps... it is somewhat unclear...)
20:09:18 <AnMaster> ais523, what about gcc prefix and such for a cross toolchain?
20:09:40 <ais523> it tries to find the binutils by executable name
20:09:58 <ais523> as in, it'll look for h8300-hitachi-hms-ld for the linker
20:10:03 <ais523> and complain if it can't find it
20:10:10 <AnMaster> ais523, lets assume I want to put it in /home/local/lego... My experience of gcc seems to show it takes lot of effort to make gcc use rpath or such... I have a stored command line for the make call for llvm gcc somewhere iirc...
20:10:36 <ais523> gcc mostly hardcodes configure info into the resulting executable
20:10:46 <ais523> and then does insane stuff with collect2
20:11:09 <ais523> which you may be able to stub out for something like bf-gcc, but which is needed if you want to do C++
20:11:16 <AnMaster> well I think some of this is from bootstrapping...
20:11:19 <ais523> gcc also provides an alternative method
20:11:28 <ais523> (and ofc, cross-compilers aren't bootstrapped)
20:11:29 <AnMaster> ais523, there is the risk I will need to do C++.... as much as it pains me
20:11:54 <ais523> the alternative method for getting C++ constructors working, though, I sort-of understand the principle of it but not how it works in practice or how to get gcc to do it
20:12:13 <AnMaster> oh yeah a bash script generating the gcc build commands...
20:12:14 <AnMaster> make LDFLAGS="-Wl,-O1,--hash-style=gnu,-rpath,${BASEDIR}/lib" LDFLAGS_FOR_TARGET="-Wl,-O1,--hash-style=gnu,-rpath,${BASEDIR}/lib" BOOT_LDFLAGS="-Wl,-O1,-rpath,${BASEDIR}/lib"
20:12:21 <AnMaster> is what the line from the heredoc looks like
20:12:29 <AnMaster> because the relevant configure flags aren't used
20:13:00 <AnMaster> ais523, I will be doing freestanding development anyway
20:13:03 <AnMaster> no hosted
20:13:04 <ais523> incidentally, the documentation for the way gcc's build system works is a FIXME
20:13:45 <AnMaster> ais523, I assume I should compile binutils first?
20:13:51 <AnMaster> ais523, how does one go about that?
20:13:52 <ais523> I think you compile them simultaneously, somehow
20:14:00 <AnMaster> same target/build/host flags?
20:14:02 <AnMaster> ais523, what?
20:14:05 <ais523> there's something about the build system for one involving the other
20:14:23 <AnMaster> ais523, eh... where is this documented?
20:14:28 <AnMaster> or how do I do it at least
20:14:41 <ais523> I'm trying to find where it's documented
20:14:51 <ais523> binutils-doc is a promisingly /named/ package, at least
20:14:56 <AnMaster> XD
20:15:07 <AnMaster> ais523, I'm not on a debian system
20:15:12 <AnMaster> so that isn't very helpful
20:15:24 <ais523> yep, but I can read it and tell you what it says
20:15:36 <AnMaster> right, or point me to upstream
20:15:42 <AnMaster> ais523, I just thought you knew how since you had been messing with it
20:15:59 <ais523> not with binutils
20:16:03 <ais523> I wrote them myself for gcc-bf
20:16:56 <AnMaster> ais523, some of the docs relating to the stuff I want to use this for says stuff like "this need at least gcc 2.95, egcs will not work"
20:16:59 <AnMaster> stuff like that
20:17:04 <AnMaster> really brings you back a lot of years
20:17:40 <ais523> but gcc /is/ egcs
20:18:28 <AnMaster> ais523, oh it said "you'll have to build and compile gcc 2.95 instead of the older egcs" to be specific
20:18:50 <ais523> $ ls -1 /usr/src/binutils/patches/ | wc -l
20:18:52 <ais523> 23
20:18:57 <ais523> not a good sign...
20:19:22 <AnMaster> ais523, ouch
20:19:33 <AnMaster> ais523, I need very very specific patches myself here so...
20:19:59 -!- impomatic has joined.
20:20:03 <impomatic> Hi :-)
20:20:08 <oerjan> hi impomatic
20:20:11 * ais523 untars
20:20:14 <ais523> oh, hi impomatic
20:20:17 <ais523> haven't seen you around for a while
20:20:43 <AnMaster> ais523, btw this cross compiler had a package back in either woody or the version before woody. I haven't been able to find out which. It no longer has such a package though...
20:20:52 <impomatic> I've been here a few times recently :)
20:21:03 <AnMaster> ais523, which one was debian 2.x?
20:21:29 <ais523> no idea
20:21:36 <AnMaster> ah seems to have been pre-woody
20:21:37 <AnMaster> ouch
20:21:37 <ais523> impomatic: yep, but I haven't been here all the time
20:21:41 <ais523> we must have kept missing each other
20:21:46 <ais523> either that, or I wasn't paying attention
20:21:58 <impomatic> I didn't say anything worth paying attention to!
20:22:02 <ais523> AnMaster: what were its dependencies like?
20:22:41 <AnMaster> ais523, hm I haven't been able to find package, just mention on web.archive.org that such a package existed on that debian version
20:23:13 <AnMaster> ais523, and it is supposed to work with a newer gcc. I don't think it is feasible to compile gcc 2.x without bootstrapping nowdays
20:23:23 <AnMaster> while I'm pretty sure 3.x isn't too bad
20:23:48 <ais523> earlier gccs combined just fine on the compilers of the day; modern compilers are more standards-compliant and so should have an easier time
20:24:03 <fizzie> You could poke at the crosstools scripts, I think they were pretty comprehensible.
20:24:14 <AnMaster> ais523, anyway I need to figure out how on earth you build binutils for h8300-hitachi-hms. And gcc
20:24:32 <AnMaster> all I want for now is binutils and gcc. I don't care about newlib, g++ or anything like that for now
20:24:40 <AnMaster> fizzie, *googles*
20:24:51 <fizzie> AnMaster:
20:24:51 <fizzie> <fizzie> I think I used http://www.kegel.com/crosstool/ several years ago, but it might be somewhat out of date, and probably won't cover your particular situation out-of-the-box.
20:25:27 <fizzie> The "Links" section in the crosstool howto might be useful too.
20:25:37 <impomatic> Does anyone know the difference between the different editions of Programming Pearls?
20:25:41 <AnMaster> fizzie, yes found it
20:25:48 <impomatic> Same question, The Little LISPer?
20:27:23 <fizzie> AnMaster: As for the second suggestion (buildroot), it does build an embedded-linux toolchain, but if it happens to work (a big if), you can mostly just yoink the GCC out of it and use it for freestanding compiling with the usual -nostdlibs and perhaps other flags. You might run into problems in that it really wants to build a C library too.
20:27:37 <AnMaster> fizzie, no it won't. This is not ELF
20:27:58 <AnMaster> this is coff. And definitely not linux in any way. No MMU, < 32 bits and so on
20:28:46 <fizzie> The ELFness doesn't matter; it's not like Linux's somehow restricted to ELF binaries. And in any case, it doesn't matter that you can't actually build the linux parts for it, the cross-toolchain parts might still work. Still, it's a bit of an abuse.
20:29:08 <AnMaster> fizzie, indeed...
20:29:40 <fizzie> To be honest, I think the GCC build process sort of expects to have some sort of C library for your target too. I'm not sure why, and how badly; at least the existing cross-compiler-compilation instructions tend to assume so.
20:30:07 <AnMaster> ah found something maybe useful here...
20:30:16 <AnMaster> newlib seems to feature... which is confusing
20:31:11 <AnMaster> oh wait " You may also want to download newlib, though it's not required for BrickOS."
20:32:14 <AnMaster> and this guide, while not targeting C in the end, (but some language called cyclone) seems to at least discuss a recent gcc version
20:32:27 <fizzie> http://gcc.gnu.org/wiki/Building_Cross_Toolchains_with_gcc is also there, I remember seeing it before when googling, but it's far from comprehensive or conclusive or other c-words.
20:32:56 <fizzie> You might even call it completely content-free.
20:33:01 <ais523> AnMaster: buildroot's what I used for the arm-linux toolchain, but it was massively complex and confusing
20:33:08 <ais523> I don't really understand how it worked
20:33:25 <oerjan> fizzie: well at least it has one c-word then
20:33:28 <AnMaster> ais523, I have high hopes for http://www.cs.utah.edu/~regehr/research/BrickOS-Cyclone/INSTALL.html
20:33:28 <fizzie> There are a couple of links, anyhow.
20:34:11 <fizzie> A separate cross-binutils is generally easy to compile, though -- possibly because the build system is not terrible? But if you want C and not just an assembler...
20:34:57 <AnMaster> ais523, at least these instructions doesn't a) discuss cygwin b) refer to outdated, no longer existing debian packages as the only described way of getting the toolchain
20:35:16 <fizzie> ais523: Buildroot tries to be very automatic; I built something with it, too, and I don't have any clue what happened, except that there was a faint smell of ozone at the end.
20:35:21 <AnMaster> <oerjan> fizzie: well at least it has one c-word then <-- which one?
20:35:29 <fizzie> "content-free", I think.
20:35:36 <AnMaster> ah
20:36:47 <AnMaster> oh btw I saw some wonderful build system yesterday. Custom makefiles broken at make -j2, oh and looked for a specific file in /usr/local/include and another one in /home/<developer's user name presumably>/somepath
20:37:21 <AnMaster> sad thing is that the actual software is nice and well documented in general (not the code though, many files with no comments at all)
20:40:15 <pikhq> I'm going to presume he knows absolutely nothing about how to do makefiles.
20:41:35 <AnMaster> <ais523> anyway, in theory the only change you have to make is to give configure options like this: --build=i686-linux-gnu --host=i686-linux-gnu --target=h8300-hitachi-hms
20:41:45 <AnMaster> ais523, how do I figure out the native triplet
20:41:54 <AnMaster> there is some confusion for x86_64 linux
20:42:08 <AnMaster> x86_64-unknown-linux-gnu vs. x86_64-gnu-linux-gnu
20:42:09 -!- FIQ has joined.
20:42:18 <AnMaster> both are seen, so it is unclear which to use
20:42:21 <ais523> let me check, I'm pretty sure there's a simple way
20:44:12 <ais523> gcc -dumpmachine
20:44:15 <ais523> on a native compiler
20:44:58 <AnMaster> heh
20:45:05 <AnMaster> desktop:
20:45:07 <AnMaster> $ gcc -dumpmachine
20:45:07 <AnMaster> x86_64-unknown-linux-gnu
20:45:16 <AnMaster> laptop:
20:45:17 <AnMaster> $ gcc -dumpmachine
20:45:17 <AnMaster> x86_64-linux-gnu
20:45:27 <AnMaster> ais523, is that a quadraplet on my desktop?
20:45:36 <ais523> it's a triplet no matter /how/ many parts it is
20:45:41 <ais523> along the same lines as an ETLA
20:45:46 <AnMaster> ais523, ETLA?
20:45:54 <ais523> extended three-letter acronym
20:45:55 <ais523> like "ETLA"
20:45:58 <AnMaster> ah
20:46:02 -!- augur has joined.
20:46:25 <AnMaster> so... lets see.. ah this gcc is so old it uses PREFIX/man instead of PREFIX/share/man
20:46:34 <AnMaster> even though that was only fixed quite recently
20:46:52 -!- augur has quit (Remote host closed the connection).
20:47:00 -!- augur has joined.
20:47:02 -!- augur has quit (Remote host closed the connection).
20:47:07 -!- augur has joined.
20:49:06 <AnMaster> ais523, for gcc:
20:49:07 <AnMaster> --x-includes=DIR X include files are in DIR
20:49:07 <AnMaster> --x-libraries=DIR X library files are in DIR
20:49:09 <AnMaster> any idea why?
20:49:31 <ais523> I can't tell if it's using X as a variable there, or referring to X the windowing system
20:49:39 <ais523> but no
20:50:12 <AnMaster> hm
20:50:50 <AnMaster> ais523, so does this look reasonable to you (yeah it seems you should co-build indeed...):
20:50:52 <AnMaster> ../gcc-3.4.6/configure --prefix=/home/arvid/local/lego --infodir=/home/arvid/local/lego/share/info --mandir=/home/arvid/local/lego/share/man --enable-languages=c --target=h8300-hitachi-hms --build=x86_64-unknown-linux-gnu --host=x86_64-unknown-linux-gnu
20:51:15 <ais523> that looks plausible
20:51:55 <AnMaster> now lets hope it doesn't complain about no newlib (haven't been able to find right version of newlib, and I don't need it for the stuff I'm doing it seems)
20:53:09 <fizzie> It working just like that sounds unlikely.
20:53:22 <AnMaster> fizzie, which bit?
20:53:36 <AnMaster> fizzie, I followed http://www.cs.utah.edu/~regehr/research/BrickOS-Cyclone/INSTALL.html basically
20:53:55 <fizzie> Yes, but where would we be if you could just follow instructions and have stuff work?
20:53:56 <AnMaster> anyway it is doing the second runs of configure, that is after you type make
20:53:56 <AnMaster> atm
20:54:17 <AnMaster> fizzie, believe me if I had been able to locate those instructions earlier I wouldn't have asked here....
20:54:26 <AnMaster> it was quite hard to find
20:54:30 <ais523> fizzie: that happened when I compiled tar from source earlier today, it shocked me
20:54:43 <AnMaster> checking assembler for .balign and .p2align... /home/arvid/src/lego/brickOS/toolchain/gcc-3.4.6/gcc/configure: line 10246: test: -ge: unary operator expected
20:54:44 <AnMaster> no
20:54:44 <AnMaster> checking assembler for .p2align with maximum skip... /home/arvid/src/lego/brickOS/toolchain/gcc-3.4.6/gcc/configure: line 10284: test: -ge: unary operator expected
20:54:44 <AnMaster> no
20:54:44 <AnMaster> checking assembler for working .subsection -1... no
20:54:46 -!- FIQ has left (?).
20:54:46 <AnMaster> checking assembler for .weak... /home/arvid/src/lego/brickOS/toolchain/gcc-3.4.6/gcc/configure: line 10370: test: -ge: unary operator expected
20:54:49 <AnMaster> no
20:54:51 <AnMaster> argh
20:54:53 <AnMaster> that looks nasty
20:54:57 <AnMaster> it did just continue anyway
20:55:23 <AnMaster> and my /bin/sh is bash... so no idea
20:55:35 <fizzie> An empty something there, I'd guess.
20:55:45 <AnMaster> yeah... but that looks quite bad though
20:55:51 <AnMaster> pretty sure .p2algin does work...
20:56:01 <AnMaster> /home/arvid/src/lego/brickOS/toolchain/build-h8300/bfd/../../gcc-3.4.6/bfd/cache.c:440: undefined reference to `unlink_if_ordinary'
20:56:03 <AnMaster> sigh
20:58:15 <ais523> AnMaster: which assembler is this?
20:58:45 <AnMaster> gcc -W -Wall -Wstrict-prototypes -Wmissing-prototypes -g -O2 -o size size.o bucomm.o version.o filemode.o ../bfd/.libs/libbfd.a ../libiberty/libiberty.a
20:58:45 <AnMaster> bucomm.o: In function `make_tempname':
20:58:45 <AnMaster> /home/arvid/src/lego/brickOS/toolchain/build-h8300/binutils/../../gcc-3.4.6/binutils/bucomm.c:425: warning: the use of `mktemp' is dangerous, better use `mkstemp'
20:58:45 <AnMaster> ../bfd/.libs/libbfd.a(cache.o): In function `bfd_open_file':
20:58:46 * ais523 wonders which solution for cross-compiles is neater; rewriting half of configure.in by hand, or calling configure.ac-generated configures recursively
20:58:51 <ais523> they're the gcc and ick solutions, respectively
20:58:52 <AnMaster> ais523, must be host I think
20:59:04 <ais523> and I'm pretty sure the ick solution is the best one there to make it work with autotools
20:59:24 <AnMaster> ais523, google indicates it is related to mixing versions of libiberty
20:59:31 <AnMaster> (maybe)
20:59:52 <ais523> hmm, I can believe that
20:59:59 <ais523> link a static libiberty.a and use that?
21:00:19 <AnMaster> ais523, well it tries to link the one it built it seems
21:00:28 <AnMaster> why it is using a version that lacks that I don't know
21:00:36 <ais523> then how are you mixing versions?
21:01:44 <AnMaster> ah missed the step about rm -rf libiberty from gcc and ln -s binutils versions
21:01:51 <AnMaster> grep indicates that the binutils one has it
21:01:59 <AnMaster> lets try again
21:02:25 <AnMaster> ais523, at least gcc 3.x doesn't take quite as long to compile :D
21:06:26 -!- Gracenotes has quit (Ping timeout: 240 seconds).
21:06:47 <AnMaster> ais523, the lines I get those "quote issue" warnings from are like:
21:06:53 <AnMaster> cat >>confdefs.h <<_ACEOF
21:06:54 <AnMaster> #define HAVE_AS_GOTOFF_IN_DATA `if test $gcc_cv_as_ix86_gotoff_in_data = yes; then echo 1; else echo 0; fi`
21:06:54 <AnMaster> _ACEOF
21:11:59 <AnMaster> another one:
21:12:02 <AnMaster> if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 6 \) \* 1000 + 0`
21:12:02 <AnMaster> then gcc_cv_as_balign_and_p2align=yes
21:12:02 <AnMaster> fi
21:12:10 <AnMaster> ais523, that has some horrible formatting
21:20:08 -!- hiato has quit (Quit: underflow).
21:20:27 <AnMaster> ais523, ah tracked it down to the line: checking what assembler to use... expr: syntax error
21:21:29 <ais523> I'm not surprised, given the formatting
21:22:22 <AnMaster> ais523, well it was a different expr
21:22:37 <AnMaster> ais523, and now I know how it checks unbuilt gas version
21:22:48 <AnMaster> ais523, by grepping the configure of it
21:22:53 * ais523 facepalms
21:22:54 <AnMaster> which fails here for some reason
21:23:08 <AnMaster> as in, it gets an empty string for all the files it tries
21:23:18 <AnMaster> for f in $gcc_cv_as_bfd_srcdir/configure \
21:23:18 <AnMaster> $gcc_cv_as_gas_srcdir/configure \
21:23:18 <AnMaster> $gcc_cv_as_gas_srcdir/configure.in \
21:23:18 <AnMaster> $gcc_cv_as_gas_srcdir/Makefile.in ; do
21:23:18 <AnMaster> gcc_cv_gas_version=`grep '^VERSION=[0-9]*\.[0-9]*' $f`
21:23:21 <ais523> is it a \r\n vs \n problem?
21:23:28 <AnMaster> [logic to test for found string]
21:23:35 <AnMaster> ais523, I doubt that in this case
21:23:38 <ais523> hmm, apparently not given that grep string
21:24:11 <AnMaster> ais523, oh there is an extra space in this version
21:24:12 <AnMaster> at the start
21:24:16 <AnMaster> like:
21:24:20 <AnMaster> VERSION=...
21:24:37 <AnMaster> ais523, I can't even imagine why anyone would break it like that
21:24:40 <ais523> you have the wrong version of VERSION?
21:24:50 <AnMaster> ais523, XD
21:25:01 <AnMaster> configure-# Define the identity of the package.
21:25:01 <AnMaster> configure- PACKAGE=bfd
21:25:01 <AnMaster> configure: VERSION=2.16.1
21:25:30 <AnMaster> ais523, oh and I'm editing configure directly. I don't think I want to try autogen.sh in gcc...
21:25:47 <Phantom_Hoover> I am of the opinion that the normal usage of quote marks needs revision.
21:25:57 <ais523> Phantom_Hoover: what new usage would you suggest?
21:26:09 <ais523> hmm, what about this
21:26:15 <ais523> instead of `quoting' words `like this'
21:26:26 <ais523> let's $(quote' words $)like this'
21:27:02 <Phantom_Hoover> Well, in English at least, quotation marks change the context in which a sentence is interpreted, rather than changing its interpretation altogether,
21:27:53 <AnMaster> gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([0-9]*\)"`
21:27:57 <AnMaster> ais523, tell me how this works
21:28:04 <AnMaster> I can't figure out what the syntax is even
21:28:06 <AnMaster> expr? : ?
21:28:28 <ais523> maybe it's a string compare?
21:28:32 <ais523> in some really old expr?
21:30:17 <AnMaster> ais523, not the one I have here
21:31:22 <AnMaster> ais523, btw need to do the same fix for ld
21:31:27 <AnMaster> it checks that version the same way
21:31:34 <AnMaster> now this might compile. Lets hope
21:33:58 <AnMaster> and it is still broken
21:34:01 <AnMaster> not quite as badly
21:37:50 <AnMaster> ais523, what do you think of this:
21:37:51 <AnMaster> gcc_cv_gas_version=`grep '^ *VERSION=[0-9]*\.[0-9]*' $f | sed 's/^ //'`
21:38:01 <AnMaster> yes it breaks with space at start
21:38:04 <AnMaster> in the line after
21:39:48 <AnMaster> it seems to work
21:40:39 * AnMaster starts make again and goes to eat something
21:41:09 <AnMaster> ais523, I will notify you of any more wtf when I get back (and I did check all configure for similar greps... only in two places, both in same file)
21:41:40 <ais523> I'm well aware that the gcc build system is wtf
21:43:17 <AnMaster> ais523, well first time I seen you facepalm
21:43:28 <ais523> I actually did so in RL
21:43:30 <AnMaster> ais523, anyway aren't more modern ones, 4.4 and later slightly saner?
21:43:34 <ais523> no
21:43:41 <ais523> well, maybe, they're insane enough though
21:43:45 <AnMaster> ais523, at least it installs man pages in the right dir by default
21:43:54 <AnMaster> not in PREFIX/share any more
21:43:56 <ais523> sufficiently so that comparison becomes meaningless
21:44:03 <AnMaster> err
21:44:05 <ais523> I don't see why manpage location is worrying at all compared to the other stuff it does
21:44:07 <AnMaster> not in PREFIX/man any more
21:44:09 <AnMaster> but DATAPREFIX/man
21:44:11 <AnMaster> which is better
21:44:19 <AnMaster> ais523, it isn't tidy :/
21:44:47 <ais523> AnMaster: actually, this system /has/ a manpage in /usr/man
21:44:48 <ais523> for gocr
21:44:53 <AnMaster> ais523, for what?
21:44:54 <ais523> it looks like the package got lost somehow
21:44:57 <AnMaster> also mine has none
21:45:06 <ais523> well, confused
21:45:15 <AnMaster> ais523, what is gocr?
21:45:33 <ais523> an OCR program, I think
21:45:35 <ais523> I've never used it
21:46:27 -!- augur has quit (Ping timeout: 248 seconds).
21:51:00 <AnMaster> ais523, I got an ICE now
21:51:18 <AnMaster> I don't know which compiler
21:51:28 <AnMaster> wait
21:51:29 <AnMaster> xgcc?
21:51:32 <AnMaster> what the fuck is it doing
21:51:35 <AnMaster> cross compiling!?
21:51:38 <AnMaster> ais523, ^
21:53:09 <ais523> AnMaster: it's building libgcc
21:53:13 <ais523> you wanted floating-point emulation, right?
21:53:13 -!- hiato has joined.
21:53:19 <ais523> it has to compile that somehow
21:53:24 <AnMaster> ais523, well no that is done in the OS -_-
21:53:28 <ais523> ah
21:53:32 <AnMaster> ais523, why is it called xgcc?
21:53:33 <ais523> well, 64-bit multiply then
21:53:41 <Phantom_Hoover> Floating-point is for cissies.
21:53:42 <ais523> AnMaster: to avoid nameclashes, I think
21:53:44 <ais523> it's the new one
21:53:52 <AnMaster> ais523, this would need a helper for 32-bit addition...
21:54:00 <ais523> that too
21:54:39 <AnMaster> ais523, _muldi3.o ?
21:55:28 <ais523> AnMaster: muldi3 is (uint32_t)a = (uint32_t)b * (uint32_t)c
21:55:36 <ais523> one of the primitives that GCC breaks programs down into
21:55:49 <ais523> apparently the operation doesn't exist on the target platform, so gcc's making emulation code for it
21:56:01 <AnMaster> I see
21:56:14 <AnMaster> ais523, but I'm not going to work with numbers wider than 16 bits anyway
21:56:45 <AnMaster> ais523, how comes you know what _muldi3 is?
21:56:46 <ais523> well then that bit of libgcc won't be linked
21:56:53 <ais523> AnMaster: because I've written a gcc backend?
21:57:00 <AnMaster> and you remember them all?
21:57:02 <ais523> if muldi3 wasn't implemented, it just wouldn't work
21:57:10 <ais523> AnMaster: the names follow a pretty consistent pattern
21:57:26 <Deewiant> MULtiply Doublewidth Integers
21:57:36 <AnMaster> ah
21:57:39 <ais523> wait, di is 64, not 32
21:57:44 <AnMaster> Deewiant, and the 3 is for?
21:57:46 <ais523> si is 32, hi is 16, qi is 8
21:57:48 <ais523> and 3 is 3 params
21:57:54 <ais523> two input, one output
21:58:13 <AnMaster> ais523, well 64 bit math is just out of question on this thing anyway
21:58:20 <AnMaster> float will probably be 32 bit at most
21:58:27 <ais523> AnMaster: so that's the 64-bit multiply I mentioned earlier
21:58:31 <AnMaster> and I may develop 16 bit float libs instead of using the OS
21:58:44 <AnMaster> since space is really at a premium here...
21:59:03 <AnMaster> ais523, I have no idea what do do about the ICE though...
21:59:12 <ais523> debug it?
21:59:18 <ais523> I had to debug loads of those things
21:59:28 <ais523> more annoying was when I got the compiler into an infinite loop
21:59:30 <AnMaster> ais523, well gcc 3.x is hardly supported any longer
21:59:33 -!- Tritonio_GR has joined.
21:59:43 <ais523> you wouldn't believe how easy it is to define something in terms of itself
21:59:54 <AnMaster> heh
22:00:00 <AnMaster> ais523, in that RTL language or such?
22:00:08 <ais523> or even in C
22:00:12 <ais523> which is what libgcc is written in
22:00:15 <AnMaster> ais523, in C I don't believe it
22:00:22 <ais523> imagine trying to implement a = b * c
22:00:25 <AnMaster> ah
22:00:27 <AnMaster> yeah
22:00:28 <AnMaster> right
22:00:29 <ais523> but not in terms of multiplication
22:00:47 <ais523> and you can't just use a loop because that would be inefficient
22:00:55 <ais523> so you use narrower multiplies, and bitshifts all over the place
22:01:08 <AnMaster> ais523, if we assume c >= 0 atm: a=0; while(c--) a+=b; ?
22:01:15 <AnMaster> you need similar code for c<0
22:01:21 <ais523> AnMaster: massively inefficient
22:01:22 <AnMaster> but with some stuff changed
22:01:26 <AnMaster> ais523, well okay
22:01:27 <ais523> you wouldn't want every multiplication in a whole program to compile into that
22:01:49 <ais523> I implemented a 32-bit unsigned integer multiply in JavaScript a while back
22:02:09 <AnMaster> ais523, I don't want 64 bit arithmetics on a system which is this cramped anyway!
22:02:13 <ais523> (the fun bit there: JavaScript's only numeric type is the double-precision float, and it can't store all 64-bit integers accurately)
22:02:25 <ais523> AnMaster: they don't cost if you don't use them
22:02:32 <AnMaster> true
22:02:34 <Phantom_Hoover> Ugh, JS.
22:02:42 <Phantom_Hoover> I hatehatehatehatehate JS.
22:02:57 <AnMaster> I didn't hate js before. Now I do
22:03:08 <ais523> I rather like it; its library support, OTOH, is awful
22:03:16 <ais523> let me find a snippet of source code
22:03:16 <AnMaster> I just disliked it before
22:03:43 <Phantom_Hoover> I hatehatehatehatehate JS because some idiot in my school decided it was a good language in which to teach programming.
22:03:51 <Phantom_Hoover> On IE 5, no less!
22:04:10 <AnMaster> ouch
22:04:19 <AnMaster> doesn't make js itself as bad though
22:04:27 <AnMaster> it is the fault of that idiot
22:04:43 <Phantom_Hoover> Yeah, but I'm extremely soured on it.
22:05:33 <Phantom_Hoover> The weak typing is probably the bit I find most jarring, though.
22:05:36 <ais523> function arraysort(a) { /* Can we use a built-in sort method? */ if (Array.sort) return Array.sort(a); /* If not, use quicksort. */ if (a.length <= 1) return a; var pivot = a[0]; var b = new Array; var c = new Array; for (var i = 1; i < a.length; i++) { if (a[i] < pivot) b[b.length] = a[i]; else c[c.length] = a[i]; } b = arraysort(b); c = arraysort(c); b[b.length] = pivot; for (var i = 0; i < c.length; i++) b[b.length] = c[i]; return b; }
22:06:03 <AnMaster> hm... weak static typing is that possible?
22:06:06 <AnMaster> well I guess it is
22:06:09 <AnMaster> but has it been done?
22:06:21 <ais523> obviously a quicksort isn't quite optimal, but it was easy to write and I know the data it runs on isn't quicksort-pathological
22:06:24 <AnMaster> much weaker than C that is
22:06:26 <Phantom_Hoover> And when we write programs to verify that an input is in a range of numbers, *we don't need to verify the number*.
22:06:31 <ais523> AnMaster: Perl
22:06:34 <AnMaster> ais523, heh
22:06:37 <ais523> statically typed scalar/array/hash
22:06:45 <AnMaster> ais523, too strongly typed
22:06:52 <Phantom_Hoover> My teacher has accepted programs that will take "a fish" as a valid voting age.
22:06:54 <ais523> simultaneously, it has strong dynamic typing
22:06:57 <AnMaster> ais523, bash is dynamically typed but very weakly typed
22:07:00 <AnMaster> ais523, oh?
22:07:41 <ais523> AnMaster: at any given moment, a scalar is, say, a string, or a reference to a hash, or a reference to an IO::Handle object, or whatever
22:07:44 <ais523> hmm, semi-strong
22:08:14 <ais523> and it doesn't help that most built-in operators force contexts on things
22:08:28 <AnMaster> ais523, everything is a string... that would work for very weak static typing
22:08:41 <AnMaster> wait no
22:08:44 <AnMaster> it wouldn't
22:08:45 <ais523> well, with that reasoning, Unlambda
22:08:48 <AnMaster> it would be painful
22:08:50 <ais523> that's statically typed
22:08:53 <ais523> because it only has one type
22:09:03 <ais523> thus you can type-check it at compile time
22:09:08 -!- hiato has quit (Quit: brb restart for net issues).
22:09:09 <Phantom_Hoover> AnMaster: Tcl represents everything as a string, doesn't it?
22:09:11 <AnMaster> ais523, "everything is an 2D array of integers"
22:09:13 <AnMaster> what about that
22:09:18 <AnMaster> Phantom_Hoover, not internally iirc
22:09:41 <ais523> AnMaster: that's just an optimisation, it doesn't affect language semantics
22:09:51 <AnMaster> indeed
22:09:52 <oerjan> in unlambda, characters are second-class values
22:10:07 <ais523> if a Haskell implementation chooses to store "1024" as the number 1024 with some sort of "this is a string" tag, it doesn't make it any less strongly typed
22:10:52 <AnMaster> ais523, major wtf of gcc: fixincludes
22:11:12 <ais523> AnMaster: it tries to make platform include files more standards-compliant
22:11:15 <AnMaster> ais523, especially since it doesn't just do std* headers but all headers for god knows what
22:11:27 <AnMaster> ais523, well since when is X11 includes "platform includes"?
22:11:34 <Phantom_Hoover> According to WP, JS has weak typing?
22:11:41 <AnMaster> /home/arvid/src/lego/brickOS/toolchain/build-native/binutils/ranlib ./libgcc.a
22:11:41 <AnMaster> /lib/libc.so.6: file not recognized: File format not recognized
22:11:43 <AnMaster> okay
22:11:43 -!- kar8nga has quit (Read error: Connection reset by peer).
22:11:46 <Sgeo> Is it just me, or are the ConwayLife forums broken?
22:11:53 <AnMaster> now that was cryptic (trying to build a native one atm)
22:11:58 <AnMaster> (since that was recommended somewhere)
22:12:41 <AnMaster> oh duh huge if block
22:12:56 <Phantom_Hoover> Sgeo: Fine for me.
22:13:15 -!- Phantom_Hoover has set topic: For Game of Life discussion go to #b3s23 | http://tunes.org/~nef/logs/esoteric/?C=M;O=D.
22:13:33 <Phantom_Hoover> And please come back to #b3s23, it's lonely.
22:14:02 * Sgeo accidentally joined #b2s23
22:14:11 <ais523> AnMaster: try to run file on it
22:14:53 <AnMaster> ais523, on what? libc.so.6=
22:14:57 <AnMaster> s/=/?/
22:15:13 <ais523> ranlib, probably
22:15:15 <AnMaster> $ file /lib/libc.so.6
22:15:15 <AnMaster> /lib/libc.so.6: symbolic link to `libc-2.11.1.so'
22:15:21 <AnMaster> $ file -L /lib/libc.so.6
22:15:21 <AnMaster> /lib/libc.so.6: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.18, not stripped
22:15:28 <ais523> if your libc got overwritten, you're in really serious trouble
22:15:51 <AnMaster> ais523, it wasn't ranlib
22:15:55 <AnMaster> it just looked like it
22:16:07 <AnMaster> /lib/libc.so.6: file not recognized: File format not recognized
22:16:07 <AnMaster> collect2: ld returned 1 exit status
22:16:11 <AnMaster> ais523, that may tell more
22:16:28 <AnMaster> I don't know which ld
22:16:40 <ais523> or which collect2?
22:16:50 <pikhq> AnMaster: Try executing libc.so.6
22:17:17 <AnMaster> pikhq, well duh that works... yes
22:17:21 <ais523> what would executing a libc even /do/?
22:17:30 <pikhq> ais523: Call its main() function.
22:17:31 <AnMaster> ais523, the usual version info
22:17:37 <ais523> ah, ok
22:17:43 <AnMaster> $ /lib/libc.so.6
22:17:43 <AnMaster> GNU C Library stable release version 2.11.1, by Roland McGrath et al.
22:17:44 <pikhq> All shared libraries on Linux are executables which happen to export functions.
22:17:47 <AnMaster> [a lot more]
22:17:55 <ais523> GNU C Library (EGLIBC) stable release version 2.10.1, by Roland McGrath et al.
22:18:01 <ais523> pikhq: on Windows too
22:18:07 <pikhq> Some of them don't happen to have a main function, so they crash.
22:18:12 <ais523> 'cept you can't run them normally
22:18:27 <AnMaster> pikhq, s/some/most/
22:18:40 <AnMaster> pikhq, only one I know that has it is some glibc ones
22:18:45 <pikhq> ais523: Yeah, but Windows doesn't have shared libraries. More of a on-demand statically-linked-at-runtime thing. :P
22:18:56 <AnMaster> pikhq, and that is libc and ld iirc
22:19:00 <pikhq> AnMaster: Typically, just libc and bizarre things.
22:19:07 <AnMaster> pikhq, other ones, like libm segfault
22:19:07 <ais523> pikhq: that's a bizarre way to put it
22:19:14 <ais523> you can load DLLs at runtime, without issue
22:19:16 <AnMaster> pikhq, which bizarre ones?
22:19:41 <pikhq> ais523: It does this by relocating the libraries. The whole thing.
22:20:08 <ais523> that seems sufficiently insane for Windows
22:20:11 -!- migomipo has quit (Read error: Connection reset by peer).
22:20:48 <AnMaster> new idea: static only compiler
22:21:05 <Phantom_Hoover> Just pass -static to GCC.
22:21:12 <AnMaster> Phantom_Hoover, --disable-shared you mean
22:21:19 <AnMaster> Phantom_Hoover, I'm *trying to compile gcc*
22:21:22 <AnMaster> and it isn't working
22:21:23 -!- impomatic has left (?).
22:21:31 <Phantom_Hoover> Ooj.
22:21:37 <Phantom_Hoover> s/Ooj/Ooh.
22:21:57 -!- augur has joined.
22:22:01 -!- pikhq has quit (Read error: Connection reset by peer).
22:22:18 -!- pikhq has joined.
22:22:27 -!- FireFly has quit (Quit: null).
22:22:53 <AnMaster> Phantom_Hoover, it is a very old gcc. I'm not really surprised
22:23:05 <pikhq> What was the last thing I said?
22:23:17 <AnMaster> pikhq, <pikhq> ais523: It does this by relocating the libraries. The whole thing.
22:23:27 <pikhq> If the library is in memory but not at a usable address, it will load another copy of the library into memory and relocate it.
22:23:28 <AnMaster> <ais523> that seems sufficiently insane for Windows
22:24:08 <AnMaster> pikhq, even on 64-bit? Where you have cheap RIP relative addressing
22:24:26 <pikhq> Linux does this, but only for non-PIC libraries. Which straight-up do not work not-x86.
22:24:40 <pikhq> AnMaster: Pretty sure it does that on 64-bit too.
22:24:45 <AnMaster> pikhq, -_-
22:25:02 <AnMaster> pikhq, also this could work on other platforms for linux too. Would be insane however
22:25:18 <AnMaster> bbl
22:25:52 <pikhq> It was only ever supported on x86 because a) PIC code is slower on x86, b) a.out shared libraries couldn't handle PIC code.
22:26:12 <pikhq> Such a legacy thing.
22:26:21 -!- tombom has quit (Quit: Leaving).
22:26:58 <Sgeo> PIC?
22:27:05 <Sgeo> That sounds .. COBOL-esque
22:27:14 <Sgeo> I'm sure you're referring to something else
22:27:15 <Phantom_Hoover> Position-Independent Code.
22:27:37 <Phantom_Hoover> I.E. it can be loaded anywhere in memory.
22:27:42 <Sgeo> Did I ever share the story of why I learned COBOL?
22:27:52 <pikhq> Very easy on x86_64.
22:27:55 <Sgeo> (well, if reading a book on == learning)
22:28:01 <pikhq> As you can just address relative to the instruction pointer.
22:28:48 <pikhq> Ends up eating another register on x86.
22:28:48 <Phantom_Hoover> Sgeo: I haven't heard it
22:29:09 <Sgeo> For some reason, some book I read mentioned CORBA, which I knew nothing [and still know nothing] about
22:29:27 <Sgeo> So, some time later, I'm by a bookstore, and I see a book, COBOL For Dummies
22:29:33 <pikhq> Gah; how many registers end up being useful on x86 for shared library code?
22:29:35 <pikhq> Hmm.
22:29:39 <pikhq> eax, ebx, ecx.
22:29:47 <Sgeo> So I buy it, not realizing that what I wanted was CORBA, not COBOL
22:30:12 <oerjan> CORBA for dyslexics
22:30:29 <Phantom_Hoover> http://en.wikipedia.org/wiki/Common_Object_Request_Broker_Architecture
22:30:37 <Phantom_Hoover> The magic of Google.
22:31:11 -!- sshc has quit (Ping timeout: 260 seconds).
22:32:42 -!- pikhq has quit (Read error: Connection reset by peer).
22:33:03 -!- pikhq has joined.
22:55:27 <AnMaster> so
22:55:32 <AnMaster> static build did not help
22:55:33 <AnMaster> sigh
22:59:13 -!- augur has quit (Ping timeout: 264 seconds).
23:02:39 -!- ws has joined.
23:05:01 -!- BeholdMyGlory has quit (Read error: Connection reset by peer).
23:05:09 -!- Phantom_Hoover has quit (Ping timeout: 265 seconds).
23:06:57 -!- pikhq_ has joined.
23:09:10 -!- pikhq has quit (Ping timeout: 264 seconds).
23:12:56 -!- Oranjer has joined.
23:16:04 -!- pikhq_ has quit (Read error: Connection reset by peer).
23:22:03 -!- pikhq has joined.
23:29:21 -!- calamari has joined.
23:34:20 -!- pikhq has quit (Read error: Connection reset by peer).
23:34:45 -!- pikhq has joined.
23:34:56 * Sgeo should probably attempt to understand DVCS
23:46:16 -!- sshc has joined.
23:51:04 -!- calamari has left (?).
23:54:02 <ais523> Sgeo: DVCSes are amazing
23:54:47 <Ilari> DVCS has to take relativity of events into account. :-)
←2010-05-16 2010-05-17 2010-05-18→ ↑2010 ↑all