code logs -> 2013 -> Thu, 07 Mar 2013< code.20130306.log - code.20130308.log >
--- Log opened Thu Mar 07 00:00:07 2013
00:31 Haeroe [ap@297948.F70DAA.120876.F7563D] has quit [Ping timeout: 121 seconds]
00:55 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.896A0B] has quit [Client closed the connection]
00:56 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.896A0B] has joined #code
00:57 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.896A0B] has quit [Client closed the connection]
01:10 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has joined #code
01:10 VirusJTG [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has joined #code
01:16 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has quit [Ping timeout: 121 seconds]
01:16 Derakon[AFK] is now known as Derakon
01:25 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.37458D] has joined #code
01:27 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.37458D] has quit [Client closed the connection]
01:28 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.37458D] has joined #code
01:46 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.37458D] has quit [Client closed the connection]
02:17 Attilla [chatzilla@Nightstar-87646183.range86-143.btcentralplus.com] has quit [Ping timeout: 121 seconds]
02:20 VirusJTG [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has quit [[NS] Quit: Program Shutting down]
02:22 Azash [ap@297948.F70DAA.120876.F7563D] has joined #code
02:22 mode/#code [+o Azash] by ChanServ
02:22 * Azash curses VPS reboots
02:48 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has joined #code
02:54 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has joined #code
02:54 mode/#code [+qo Vornicus Vornicus] by ChanServ
03:08 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has quit [Client closed the connection]
03:12 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has joined #code
03:14 ToxicDroid2 [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has joined #code
03:14 ToxicDroid2 [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has quit [Client closed the connection]
03:14 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has quit [Client closed the connection]
03:14 Kindamoody[zZz] is now known as Kindamoody
03:16 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has joined #code
03:18 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has quit [Client closed the connection]
03:18 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has joined #code
03:20 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has quit [Client closed the connection]
03:21 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has joined #code
03:27 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.057BAB] has quit [Ping timeout: 121 seconds]
03:49 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has joined #code
03:52 * celticminstrel vaguely wonders whether a language is possible in which you can take the inverse of a function.
03:53
<&Derakon>
I think "inverse" is poorly-defined in many languages.
03:53
<@celticminstrel>
Huh?
03:54
<&Derakon>
Well, what would be the inverse of a function that sorts its inputs?
03:55
<@celticminstrel>
I dunno.
03:55
<@celticminstrel>
Sorting doesn't seem like an invertible operation.
03:56
<&Derakon>
Exactly.
04:01
<@Namegduf>
celticminstrel: It'd only be possible for bijective functions, probably pure ones.
04:01
<@Namegduf>
celticminstrel: But it could be done for those.
04:01
<@Namegduf>
That does not essentially make it easily computable.
04:01
<@Namegduf>
You could require that the function be built of things which are easily invertible as well.
04:07 sshine [simon@Nightstar-2aa33f9d.pronoia.dk] has quit [Ping timeout: 121 seconds]
04:10 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has quit [Connection reset by peer]
04:11 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has joined #code
04:15 Kindamoody is now known as Kindamoody|afk
04:19
<~Vornicus>
celmin: mathematica and friends can invert things that are invertible.
04:19
<~Vornicus>
Well, can invert most such things.
04:20
<~Vornicus>
I can certainly come up with an invertible function whose inverse is practically impossible to calculate.
04:21 sshine [simon@Nightstar-2aa33f9d.pronoia.dk] has joined #code
04:32 Kindamoody|afk is now known as Kindamoody
05:34 himi [fow035@D741F1.243F35.CADC30.81D435] has quit [Operation timed out]
05:41 syksleep is now known as Syk
06:19 Courage [Moltare@583787.FF2A18.190FE2.4D81A1] has quit [Ping timeout: 121 seconds]
06:21 Courage [Moltare@583787.FF2A18.190FE2.4D81A1] has joined #code
06:21 mode/#code [+o Courage] by ChanServ
06:24 Derakon is now known as Derakon[AFK]
06:52 Kindamoody is now known as Kindamoody|afk
07:05 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has quit [Connection reset by peer]
07:05 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has joined #code
07:07 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has quit [Client closed the connection]
07:07 ToxicDroid2 [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has joined #code
07:09 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has joined #code
07:09 ToxicDroid2 [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has quit [Client closed the connection]
07:10 ToxicDroid2 [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has joined #code
07:10 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has quit [Client closed the connection]
07:36 You're now known as TheWatcher
07:38 himi [fow035@Nightstar-5d05bada.internode.on.net] has joined #code
07:38 mode/#code [+o himi] by ChanServ
07:44 Rhamphoryncus [rhamph@Nightstar-f8b1f87b.abhsia.telus.net] has quit [Ping timeout: 121 seconds]
07:45 Rhamphoryncus [rhamph@Nightstar-f8b1f87b.abhsia.telus.net] has joined #code
07:45 mode/#code [+o Rhamphoryncus] by ChanServ
07:56 celticminstrel [celticminst@Nightstar-e83b3651.cable.rogers.com] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!]
09:02 Attilla [chatzilla@Nightstar-87646183.range86-143.btcentralplus.com] has joined #code
09:12 You're now known as TheWatcher[afk]
09:16 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has quit [Operation timed out]
09:42 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has joined #code
09:42 mode/#code [+qo Vornicus Vornicus] by ChanServ
10:28 RichyB [richardb@Nightstar-228a334c.plus.com] has joined #code
11:11 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has quit [[NS] Quit: Leaving]
11:18 VirusJTG [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has joined #code
12:31 ToxicDroid2 [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has quit [Client closed the connection]
12:32 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has joined #code
12:33 Kyte|Work [c80e6b02@Nightstar-992d69e3.mibbit.com] has joined #code
13:06 Kindamoody|afk is now known as Kindamoody
13:43 thalass [thalass@Nightstar-f97b970e.bigpond.net.au] has joined #code
14:54 Kindamoody is now known as Kindamoody|afk
14:55 celticminstrel [celticminst@Nightstar-e83b3651.cable.rogers.com] has joined #code
14:55 mode/#code [+o celticminstrel] by ChanServ
15:01 Derakon [Derakon@Nightstar-a3b183ae.ca.comcast.net] has joined #code
15:01 mode/#code [+ao Derakon Derakon] by ChanServ
15:02 Derakon[AFK] [Derakon@Nightstar-a3b183ae.ca.comcast.net] has quit [Operation timed out]
15:05 Derakon [Derakon@Nightstar-a3b183ae.ca.comcast.net] has quit [Ping timeout: 121 seconds]
15:05 Derakon [Derakon@Nightstar-a3b183ae.ca.comcast.net] has joined #code
15:05 mode/#code [+ao Derakon Derakon] by ChanServ
15:53 Syk is now known as syksleep
15:57 You're now known as TheWatcher
16:10 ToxicDroid [ToxicFrog@Nightstar-a32124f8.ca.comcast.net] has quit [Ping timeout: 121 seconds]
16:10 d4de [olorin@687AAB.1E386D.C668E8.B4D874] has quit [Ping timeout: 121 seconds]
16:43 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.A39092] has joined #code
16:52 thalass [thalass@Nightstar-f97b970e.bigpond.net.au] has quit [Ping timeout: 121 seconds]
17:12 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.A39092] has quit [Client closed the connection]
17:13 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.A39092] has joined #code
17:17 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.A39092] has quit [Ping timeout: 121 seconds]
17:19 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.642961] has joined #code
17:21 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.642961] has quit [Client closed the connection]
17:22 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.642961] has joined #code
17:26 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.642961] has quit [Ping timeout: 121 seconds]
17:27 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.642961] has joined #code
19:06
< Xires>
should pthread_cond_timedwait() be more CPU-intensive than pthread_cond_wait()?
19:10
<&ToxicFrog>
I wouldn't expect so, unless you're doing something that generates a lot of wakeups like setting a short timeout and then re-waiting on ETIMEDOUT (don't do this)
19:11
< Xires>
no, I'm not doing that
19:12
< Xires>
the thread pool is performing a staggering schedule for the different threads..if any thread ends up having to wait longer than a 'max' amount of time, it just lets the thread die instead since it's not going to be useful in any reasonable period of time and those resources could be better spent elsewhere...
19:14
< Xires>
it's definitely not timing out too often but the wait time is variable so now I wonder if my CPU usage is in the wait time calculation and not on pthread_cond_timedwait() itself
19:15
< RichyB>
That sounds perfectly reasonable. pthread_cond_timedwait() is at worst going to have to be implemented as something like a heap with like ten extra branches and swaps to extract_min from it. I wouldn't worry about the cost of it too much.
19:15
<@Rhamphoryncus>
My gut is that you've got too many threads waking up on the condition, only to find out they're not wanted and going back to sleep
19:15
< RichyB>
How much work do you have to do for wait-time calculation?
19:16
< Xires>
RichyB; more than I'd like to
19:17
< RichyB>
How many words of memory do you touch while calculating it?
19:19
< RichyB>
Does it do anything nuts like walk a long linked list, or is it just 1-100 lines of C code with no external function calls or loops in it that looks kind of gnarly?
19:20
< RichyB>
Hell, if you're on Linux then I'd just say try your program out, run it with "perf" a few times and see where your CPU-cycles *really* get spent.
19:21
< Xires>
get current time, calculate an absolute time from a relative 'wait' time, calculate offset given thread ID & last amount of wait, check the offset against the 'max' offset and possibly free thread..
19:21
< Xires>
that doesn't seem very efficient
19:22
< RichyB>
That sounds like fuck all. The most expensive things in there will be getting your own thread id and a clock_gettime() syscall.
19:22
< Xires>
unfortunately, since I'm forced to use the company's proprietary infrastructure/framework library, it ends up making several external function calls and I can't guarantee what those are doing
19:24
< RichyB>
Benchmark the thing when you've got it working.
19:24
<@TheWatcher>
Make it work, make it work better, make it work faster~
19:24
< RichyB>
er, benchmark? I mean profile.
19:24
< Xires>
13.05 1.58 0.56 15062248 0.00 0.00 _chkPkt
19:24 * RichyB gestures at the speech bubble next to TheWatcher's head.
19:24
< RichyB>
What that guy said.
19:25
< Xires>
that's the current state
19:28 Netsplit *.net <-> *.split quits: @iospace, KarmaBot, ToxicDroid, @pandemic, Xires, @Zemyla, @froztbyte, AnnoDomini, VirusJTG, @Reiv, (+11 more, use /NETSPLIT to show all of them)
19:28 Netsplit over, joins: @PinkFreud, &jerith, @pandemic, VirusJTG, @Tamber, @iospace, @himi, @Reiv, ToxicDroid, &McMartin (+11 more)
19:43 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.642961] has quit [Client closed the connection]
19:44 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.642961] has joined #code
20:02 Reiv [NSwebIRC@A3BDC3.5BE3EC.B8847E.5ADB9D] has quit [Ping timeout: 121 seconds]
20:13 ToxicDroid [ToxicFrog@1AB00B.00D4F0.621482.642961] has quit [Client closed the connection]
20:33 Reiv [NSwebIRC@A3BDC3.5BE3EC.B8847E.5ADB9D] has joined #code
20:33 mode/#code [+o Reiv] by ChanServ
20:40 VirusHome [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has joined #code
20:42 pandemic [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has quit [Ping timeout: 121 seconds]
20:46 himi [fow035@Nightstar-5d05bada.internode.on.net] has quit [Ping timeout: 121 seconds]
20:51 Kindamoody|afk is now known as Kindamoody
20:53 Derakon_ [chriswei@Nightstar-a3b183ae.ca.comcast.net] has joined #code
20:54 * Derakon_ generates a 615-line diff by changing all instances of "devices.depot" to just "depot".
20:54
< Derakon_>
Turns out an awful lot of my code needs to interact with the device depot.
20:57 Orthia [orthianz@3CF3A5.E1CD01.5A78C0.03128C] has quit [Ping timeout: 121 seconds]
20:58 Kindamoody is now known as Kindamoody[zZz]
20:59 Orthia [orthianz@3CF3A5.E1CD01.5A78C0.03128C] has joined #code
20:59 mode/#code [+o Orthia] by ChanServ
21:10
<@Rhamphoryncus>
mmm siglongjmp
21:21 * Derakon_ hrms at his code.
21:21
< Derakon_>
One annoyance of my current setup is that I can't reload modules on the fly, so whenever I make a change to the code, I have to shut the program down and then re-start it to get the changes to be represented.
21:22
< Derakon_>
reload() doesn't help because the program state is all in instances of classes, not in the modules themselves.
21:23
< Derakon_>
To do it properly, I have to reload the module, and then re-create the associated class while handing it all the state that other bits of the program know about so it can insert them into itself.
21:23
< Derakon_>
This is ugly.
21:23
< Derakon_>
(Of course, it's debugging functionality, so it's allowed to be a bit ugly, but still this is pretty bad)
21:29
<@Rhamphoryncus>
yeah. It's not a winnable situation
21:29
<&ToxicFrog>
Death to Java
21:30
<@Rhamphoryncus>
In a broader sense there's no guarantee that the state of those instances will even match what the new classes would have created
21:30 * TheWatcher hands out the pitchforks and torches
21:30
<&jerith>
Derakon_: Code reloading in Python isn't really feasible.
21:30
<@Rhamphoryncus>
(erlang is a *very* specialized language in that it allows reloading)
21:31
<&jerith>
Even Erlang needs you to jump through some hoops.
21:31
<@Rhamphoryncus>
For regular languages the trick is not in reloading. It's in unloading the old so that loading the new becomes trivial
21:32
<&ToxicFrog>
All I want to do is (map #(str "word: " %1 "\noccurs: " %2 "\n\n") results), I should not need a bunch of loops and method calls for this
21:33
<&ToxicFrog>
Rhamphoryncus: lots of languages support reloading and can even do it Erlang-style (load new code "in parallel", tail call new mainloop) without much trouble.
21:33
< Derakon_>
Jerith: oddly enough, this is one thing that the old cockpit did well, since most modules maintained all their state very "primally" as basic types stored in module scope.
21:33
<&ToxicFrog>
OTOH, not many let you do that over the network "for free" the way erlang does by just sending the new mainloop to a remote node.
21:33 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has joined #code
21:33 mode/#code [+qo Vornicus Vornicus] by ChanServ
21:34
< Derakon_>
So you could reload an individual module and run its initialization routine and all the other modules that needed state would magically get the new stuff.
21:34
< Derakon_>
Of course, it was utter shit in most other aspects.
21:35
< Derakon_>
Anyway, I've done a proof-of-concept on my simulation devices that seems to work, but it requires the device code to implement the "initialize from known state" function.
21:36
<&jerith>
Surely that's a thing they should have anyway?
21:36 * Rhamphoryncus looks for evil macro trickery that he can use for wrapping sigsetjmp
21:36
<&ToxicFrog>
Also, death to statically typed languages with type inference SUCH AS JAVA
21:36
< Derakon_>
Jerith: no, I mean "here's some state that the previous version of you created. Insert it into yourself, updating its function pointers so they go to the right place."
21:37
<&jerith>
Ah.
21:37
<~Vornicus>
Wait, statically typed language, with type inference?
21:37
<&ToxicFrog>
Er
21:37
<&ToxicFrog>
Without
21:37
< Derakon_>
Also, when the old version destroys itself it needs to unsubscribe from events so the event handler doesn't try to call functions that no longer exist.
21:37
<~Vornicus>
oh.
21:37
< Derakon_>
And the new version has to resubscribe.
21:37
<&jerith>
Vornicus: You don't really need type inference in a dynamically typed language.
21:38
<~Vornicus>
also apparently having just woken up I confused static with manifest
21:41
<@Rhamphoryncus>
Hrm. Safer if I explicitly provide a wrapper function for each of the cancellable functions rather than provide a generic macro that has to be used just-so
21:41
<@Rhamphoryncus>
(also lets me compile that file in C rather than C++)
21:49 Kyte|Work [c80e6b02@Nightstar-992d69e3.mibbit.com] has quit [[NS] Quit: http://www.mibbit.com ajax IRC Client]
22:14 * Vornicus pokes at love2d. well. more pokes at his brain, trying to figure out what he wanted to do in love2d
22:18
< Derakon_>
Physics!
22:19 * Derakon_ sighs at his event-processing code.
22:19
< Derakon_>
The problem with subscribing to an event using a lambda function is that you have to keep that lambda around if you want to unsubscribe.
22:34 himi [fow035@D741F1.243F35.CADC30.81D435] has joined #code
22:34 mode/#code [+o himi] by ChanServ
22:41
< Derakon_>
Ugh, yeah, I don't know the best way to handle this.
22:41
< Derakon_>
events.subscribe('camera enable', lambda camera: self.toggleCamera(camera, True))
22:42
< Derakon_>
The event publication just passes the camera along, no indication of if it's been turned on or off. I could change that, I guess, though then I'd have to modify all the other subscribers to the function.
22:42
< Derakon_>
Or I could generate the lambdas and store them, but then this gets significantly clunkier just to support some debugging code (so I can more easily unsubscribe later).
22:50 VirusJTG_ [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has joined #code
22:53 VirusJTG [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has quit [Ping timeout: 121 seconds]
22:54 VirusJTG_ [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has quit [Ping timeout: 121 seconds]
23:04 VirusNotAtWork [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has joined #code
23:05 VirusNotAtWork [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has quit [[NS] Quit: shutting down!]
23:06 VirusHome [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has quit [Ping timeout: 121 seconds]
23:15 Pandemic [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has joined #code
23:15 mode/#code [+o Pandemic] by ChanServ
23:23 thalass [thalass@Nightstar-f97b970e.bigpond.net.au] has joined #code
23:27 You're now known as TheWatcher[T-2]
23:34 You're now known as TheWatcher[zZzZ]
23:36 VirusHome [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has joined #code
23:39 Pandemic [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has quit [Ping timeout: 121 seconds]
23:42 VirusHome [VirusJTG@Nightstar-09c31e7a.sta.comporium.net] has quit [Ping timeout: 121 seconds]
23:59 Derakon_ [chriswei@Nightstar-a3b183ae.ca.comcast.net] has quit [[NS] Quit: leaving]
--- Log closed Fri Mar 08 00:00:21 2013
code logs -> 2013 -> Thu, 07 Mar 2013< code.20130306.log - code.20130308.log >

[ Latest log file ]