Parrot 3.9.0 "Archaeopteryx" | parrot.org | Log: irclog.perlgeek.de/parrot | #parrotsketch meeting Tuesday 19:30 UTC
Set by moderator on 19 October 2011.
dalek nxed: 5e66514 | NotFound++ | winxedst1.winxed:
simplify warning emision
00:01
soh_cah_toa NotFound: ooc, why doesn't winxed support inline pir blocks? is it just something you haven't gotten around to or is it forbidden for a reason? 00:08
NotFound soh_cah_toa: because it will be too difficult to check for unreasonable uses and because people may use it without reporting the problem or even without knowing there is a better way. 00:10
The nqp guys can tell you that this things happened a lot. 00:11
soh_cah_toa ok, i can understand that
NotFound: also, i've always wanted to know why you chose to write winxed in c++ and generate pir yourself instead of using the pct toolkit 00:12
NotFound soh_cah_toa: several reasons: I like hand-written recursive descent parsers, I failed to made even toy languages with pct, and I'm much more fluent with C-family syntax than with perl-alikes. 00:14
soh_cah_toa ok, cool 00:15
NotFound Last but not least, Stroustrup says in "The Design and Evolution of C++" that people convinced him to implement it using yacc and family but in restrocpetive he thinks it will be better his first idea of a recursive descent parser. 00:18
And I'm a Stroustrup fan.
And a last point: is easier to generate yourself the pir you want than figuring how to tell pct to generate it. 00:19
soh_cah_toa eh...college has destroyed any appreciation of c++ i could have hade
NotFound soh_cah_toa: try to rewrite winxed stage 0 in C ;) 00:20
soh_cah_toa god no ;)
whiteknight C is not the only other possible alternative 00:21
NotFound whiteknight: try Pascal, then ;)
soh_cah_toa ew
whiteknight if I were doing it today, I would do it in C#
NotFound Is not a bad language, but I don't use windows and I don't like mono. 00:23
soh_cah_toa concurs
00:26 NotFound_b joined
NotFound Anyway, I managed to go from zero to a useful self-compiling stage 1 in a short time, so the decisions were not too bad ;) 00:28
00:30 Themeruta joined 00:43 Themeruta joined 01:14 jsut_ joined
cotto This is the same thing I'm thinking about for Mole. 01:40
01:56 benabik joined
cotto ~~ 02:19
02:43 alester joined
alester seen dukeleto 03:02
aloha dukeleto was last seen in #perl6 9 hours 17 mins ago saying "[~~]".
04:48 jsut joined
dukeleto alester: pong 04:57
alester Let's discuss TWM 05:04
I don't know the state of it.
I haven't pulled any changes of yours. 05:05
cotto TWM?
dukeleto Test::WWW::Mechanize
alester: i thought i saw you merge my custom_linter branch? 05:06
alester oh, long ago 05:07
dukeleto alester: do you want me to add some more tests before a release?
alester hold on, checking
dukeleto alester: i only wrote a very basic test
sorear I feel old, I guessed /usr/bin/X11/twm at first. 05:08
opbots trust alester 05:09
slavorg Ok
alester OK, so I need a Changes update
writing that 05:10
where do \tMYMETA.json come frmo? 05:17
dukeleto: any guess where github.com/petdance/test-www-mechanize/issues/4 is? 05:19
nm 05:24
I found the MYMETA.*
dukeleto MYMETA.json is generated by newer Module::Build's 05:37
alester: i add it to .gitignore , since it is a generated file. But you could commit it. Doesn't really matter.
slavorg, where does your code live? 05:39
alester I just uploaded TWM 1.36 05:40
dukeleto alester++ 05:42
sorear good question, nobody really knows. 05:43
maybe asking #london.pm would be a good idea; it seems one of them runs slavorg
alester ok, g'night 05:48
06:20 schmooster joined 06:26 mj41 joined, mj41_nb joined 06:48 mj41_nbx joined 06:51 SHODAN joined 07:00 contingencyplan joined 08:34 alvis joined 10:27 Hunger joined 10:29 lucian joined, lucian_ joined 10:45 ambs joined 11:39 Psyche^ joined 11:50 whiteknight joined 11:51 benabik joined
whiteknight good morning, #parrot 11:51
nine good morning, whiteknight 11:53
benabik good morning!
whiteknight hello nine, benabik. how are you two doing this morning?
nine fine, fine 11:54
benabik Pretty good, other than forgetting to eat breakfast on my way out the door.
whiteknight benabik: it's the most important meal of the day!
benabik whiteknight: Yup. I made lunch and forgot to grab a breakfast. Bought a bagel at school though.
benabik digs into his cream cheese. 11:55
nine whiteknight: is it? I find it's the meal I can skip most easily
benabik nine: Skipping breakfast has been shown to slow your metabolism for the rest of the day. Less energy, easier to gain weight, etc etc.
benabik apparently still has flashbacks to working at a vitamin store. 11:56
nine benabik: I think the verdict is still open on that one... www.fitnesscontrarian.com/conventio...breakfast/ 11:58
benabik nine: Large breakfasts aren't really a great idea either. The best advice I've seen (and was most effective for me) wasn't to skip meals but to eat more. Four or five small meals tended to be easier for me. 12:00
nine benabik: yep. I think that's a proven truth by now. But also quite difficult to follow 12:02
benabik has lots of stuff in his desk to eat.
I will admit I was on that schedule when I was working from home. 12:03
nine Oh at home it's easy :) I usually work from home on Fridays. There I usually have two small breakfasts and a snack for lunch before heading out to the university. 12:06
whiteknight nine: I was playing with your branch last night, but I don't think I pushed the newest version to parrot/parrot/green_threads. I'm going to do that now and then I'm going to open a pull request 12:11
nine whiteknight: as nice as the DVCS stuff is, it can make things quite complicated as well :) 12:12
whiteknight yeah, pros and cons 12:13
at least it's *possible* in git. svn we would be shit out of luck
not that you could have easily cloned the repo with svn anyway
12:15 bluescreen joined
dalek rrot/green_threads: b5ee6aa | (Stefan Seifert)++ | src/scheduler.c:
Clean a nested comment start
12:17
rrot/green_threads: f1329e5 | (Stefan Seifert)++ | src/scheduler.c:
Reworked the zero overhead patch to reduce overhead

  moritz++ reported a 6 % performance loss with green_threads. Suspect it
to be the enabled scheduler timer tick as soon as some alarm is active.
whiteknight nine: after the merge here, what's the next thing you want to work on? 12:22
nine There's still the open issue of passing in a nested runloop. Personally I would like bailing out with a usefull error message most, since it would not affect the API 12:32
tadzik can we make a thread, which will block on IO, so scheduler will not run it until IO happens, so we get async IO? 12:33
whiteknight tadzik: I'm planning AIO in my head right now 12:34
moritz tadzik: I think that requires OS level threads so far
whiteknight I'm that's the next project for me, unless nine wants it :) 12:35
moritz: it might require an OS-level worker thread, but doesn't require interpreter-level concurrency
tadzik moritz: ah, I'm reading too much Tanenbaum recently :)
whiteknight moritz: and most modern OSes have asynch IO APIs available to use. All we would need to do is upgrade the scheduler to handle callbacks and schedule tasks with the results 12:36
tadzik but that's right, the os scheduler will block the whole process in this case
moritz whiteknight: I'm aware of that part, yes
nine whiteknight: on my personal schedule, I need to have hybrid threads up till end of the year latest to be able to finish my paper in time... 12:39
on the other hand async I/O would make tasks much more useful quickly
whiteknight nine: end of calendar year? 12:40
nine whiteknight: yep
whiteknight nine: Not a moment to spare! Okay, we can focus our attention on that. AIO is going to require a little bit a cleanup work first anyway, which I can do on the side 12:42
benabik At some point, I'm going to have to implement a mini-SML in Parrot. 12:44
Coke SML? 12:46
moritz surface modeling language? 12:47
benabik Standard ML, one of the more theory-based functional languages.
moritz likes the term "theory-based"
benabik One of the first languages to have rigorous semantics. It's something akin to a less pure haskell. 12:48
(And less lazy)
12:50 jsut_ joined
benabik Mostly I want a strong functional language in Parrot and since my thesis involves working on a SML compiler, I'm going to be very familiar with it soon. :-D 12:51
moritz just note that we don't have tools for static analysis, type inference etc. 12:52
oh well, you know what our compiler tools are geared towards :-)
benabik :-D
One of my goals with PACT is widening the scope of the compiler tools. :-D 12:53
Really it's pattern matching that I want in Parrot. Tends to be very useful when writing compilers.
whiteknight nine: so what do you think we need next? I think we're going to need an API for a simple low-level threading compatibility layer to gloss over the differences between Posix and Win32 12:55
Coke benabik: nqp* aren't good enough?
nine whiteknight: exactly. Since we already had that at some point this shouldn't be too difficult. 12:56
whiteknight nine: no, not at all 12:57
nine: the hardest part is really answering the basic architectural questions about how we want to handle data integrity, how we want to handle multi-threading with GC, etc
nine whiteknight: I think one of the most important next steps is you explaining to me how you imagine the whole "represent variables owned by other threads as proxies" thing.
benabik Coke: Not really. NQP is designed to have P6 semantics rather than Parrot semantics, so there's a distinct mismatch when writing other things.
Coke: Winxed is a nice system level language, exposing the capabilities more directly. 12:58
whiteknight nine: We have two PMCs: One is the original PMC, the other is a proxy. We overload the vtables on the proxy to schedule requests to the original, instead of performing them directly
benabik Coke: Also I mean pattern matching of data structures, not strings.
whiteknight nine: we combine that maybe with a simple mailbox-like thread-safe queue and I think we can ignore the rest of the dirty details
nine whiteknight: that's the part I understand easily. What I have not found out yet is where exactly the proxy PMC gets created. Simply create a proxy for every known PMC when moving a task to a different thread? 12:59
whiteknight The way I see it, assuming GC can be magically thread-safe, we can put a lock on the scheduler task queues, and we can put a lock on the mailbox type, and the rest of the system can be essentially lock-free so long as we follow the approved interfaces
nine: No, that would be the task of the mailbox. We would have a mailbox between two threads. MailBox.send_object(my_object) would create a proxy on the target thread for the my_object variable 13:00
so when you did "var foo = MailBox.receive_object()" or whatever, you would be receiving a proxy 13:01
...unless you were receiving from the same thread, then I suppose you could be getting a reference to the original
so a Mailbox type is really the crux of the idea
nine whiteknight: so it's more a task for the HLL compiler to generate the code to share variables between threads? Like Perl 5's my $foo : shared?
whiteknight nine: I think so, yes. So long as you pass data around in a consistent way, you can avoid data corruption 13:02
that's what I really want most: a system which makes it almost impossible to corrupt data internally
13:04 pbaker joined
whiteknight if cross-thread data updates are basically scheduled tasks, then we can implement critical sections easily by disabling green thread task preemption on a given thread 13:05
then when we exit the critical section, the scheduler can run through and play out all the update tasks
nine aaah....and so the picture comes together. Now I can easily explain tomorrow, why green threads are actually useful for a full threads implementation 13:07
benabik green_threads needs a reconfigure, doesn't it? 13:08
whiteknight that's the trade-off I'm making with this design. We don't really need locks at the PIR/HLL level, because cross-thread data writes are disabled by default. Use message-passing to schedule tasks across threads instead, and make modifications in-band 13:09
that means writing multi-threaded code is exactly the same as writing green_threaded code, so long as you make proper use of the scheduler and mailboxes
nine regarding GC: since every thread has it's own interpreter, I think it should also have it's own GC. MailBox could contain a list of referenced objects so the GC would not kill an object that's still used in other threads. 13:10
whiteknight yes, that's what I think will be the easiest to do first
Eventually, I have a paper at home about a concurrent GC which operates on a separate thread and requires no global stops
nine that would be a fascinating read
whiteknight but I don't think we need that for the first draft 13:11
nine and one that FlightGear people would probably like to read as well... they have big problems with GC stopping the sim for very noticable amounts of time
whiteknight here's the link, but you need ACM membership to get the paper: dl.acm.org/citation.cfm?id=286878 13:13
you can probably get a copy through university library or whatever 13:14
benabik whiteknight: Just being on campus does it for me. :-D
Probably free link: doc.cat-v.org/inferno/concurrent_gc/
whiteknight ah, yes 13:15
nine benabik: thanks :)
whiteknight benabik++. I don't think I've had a digital copy of that link for a year or more. I printed it out a long time ago and keep it by the side of my bed
(sadly, that's true) 13:16
benabik Heh. I've found that more and more researchers are posting their papers themselves.
nine Open Access++
13:17 mtk joined
benabik For example, the research I'm basing my thesis on: cseweb.ucsd.edu/~rtate/publications/eqsat/ 13:18
I guess I have to rebuild NQP after installing green_threads? "Failed allocation of 7166182913849190824 bytes" 13:20
whiteknight benabik: yeah, probably
moritz nine: just re-benchmarked rakudo on the latest green_threads branch: Patched version is faster than the original by 0.02%, signficance 0.1σ
so no measurable difference 13:21
whiteknight moritz: so it's equivalent to master?
nine moritz: wow...so I guess the overhead is witin the error margin?
moritz whiteknight, nine: yes to both
whiteknight okay, let's ship that sucker
moritz (on this benchmark; not sure how others perform :-)
nine moritz: my benchmark yesterday was conducted with an older Rakudo version. Noticed that I forgot to pull when I ran spectests
moritz and all spectests pass
whiteknight moritz: besides scheduling overhead, the simple single-threaded case should be identical 13:22
benabik I'm running a rebuild to compare setting time on my machine.
moritz nine: depending on how old it was, that might have made a difference
benabik whiteknight: Isn't the idea that there's little to no scheduling overhead in the single-tasked case?
whiteknight benabik: and that's what moritz++ just demonstrated
nine benabik: there is _no_ scheduling overhead when only a single task is running.
benabik ponders using Scala's model of extractor objects for pattern matching in Parrot. www.scala-lang.org/node/112 13:23
nine the scheduler alarm is only set if there are other tasks in the queue. The previous version just had a bug where the scheduler alarm would get set if any alarms were active.
moritz thinks he should should turn his small stats script into a module
nine moritz: if you're thinking that, you really should :) 13:24
PerlJam benabik: that equality saturation stuff looks interesting. 13:28
benabik PerlJam: I thought so too, otherwise I wouldn't be so eager to spend the next 6-8 months working on it. :-D 13:29
PerlJam benabik: seems to me that alot of the work got moved from individual optimizations to the global probability heuristic. 13:30
benabik PerlJam: The conversion to/from PEGs also does a scary amount of work. 13:31
nine whiteknight: tomorrow I'll report about my progress to my professor. This will include some demonstration. Any idea for that other than printing As and Bs? :) 13:33
whiteknight nine: unfortunately, not really. Rosella has an Event library that I need to update to use tasks (once we merge to master), and I've been kicking around the idea of writing an IRC client that uses task-based eventing, but I don't have it yet 13:34
moritz nine: randomly walking turtles?
benabik PerlJam: The global profitability heuristic both does and doesn't do a lot of work. To some extent it's a simple idea: assign costs to nodes and pick the lowest. But solving that problem is in NP. So I really doubt EqSat is going to be the _fastest_ optimizer.
whiteknight nine: ah yes, we do have a conio wrapper library somewhere, you could do something graphical like that 13:35
PerlJam benabik: indeed. 13:36
benabik: one of the interesting things to me is that you can move the "hardware tunability" to one place (the GPH) 13:37
heh ... I just noticed that I said "global *probability* heuristic" earlier :-)
benabik PerlJam: The further work they're doing on learning optimizations is also _very_ interesting. 13:39
whiteknight nine: do we have an operator to kill a task, or kill the current task?
benabik PerlJam: Basically run it with the simple axioms over a program and then it can learn the kind of meta-axioms that your program ends up with. 13:40
nine whiteknight: t/pmc/task.t tests it, yes
whiteknight nice
okay, we really aren't far away from basic AIO. We could teach the Select PMC how to use callbacks instead of returning descriptors very easily 13:41
that actually might make a great demonstration, if you want to play with it :)
benabik Select PMC bleh.
nine whiteknight: the current task is killed simply by ending
whiteknight nine: okay, but is there an explicit kill_me operation?
or is that just a return?
benabik whiteknight: return?
jinx 13:42
nine whiteknight: just return
whiteknight okay. We might want to add an explicit kill operation too, for cases where we are in a task but nested down a call chain
13:42 JimmyZ joined
whiteknight but that's a detail 13:42
nine whiteknight: seems like the end op does exactly that. Description says it halts the interpreter, but actually it ends just the current task. 13:44
13:47 mtk joined
whiteknight okay, that's all we need then 13:53
benabik That description should be updated then. 13:54
whiteknight especially for AIO, we're going to want the ability to launch a request and terminate the current task, so we can resume in the callback task
benabik Callback = current continuation?
whiteknight benabik: basically, yes
benabik callback/cc
whiteknight or a task constructed by it
benabik Probably more along the lines of "the return continuation given to the supposedly synchronous IO function". But eh. 13:55
nine whiteknight: for AIO a simple call to Parrot_cx_preempt_task should suffice. That and some runnable flag in the task pmc that gets set by the AIO callback. 14:00
a flag or a separate queue for inactive tasks. But that's an implementation detail that should be hidden by the API anyway. Like the enable_preemption flag that will be moved to interp 14:01
14:07 SHODAN joined
whiteknight The Select PMC should be easy to update with tasks. For asynchronous operations on FileHandle, for instance, it's going to be a little bit more involved. We're going to need to add some kind of "scheduleable" role for FileHandles and the like that the scheduler can test for readiness and extract a callback from when it is ready 14:11
at least, that seems like the best way to me
so we can do filehandle.dispatch_operation(), scheduler.wait_for(filehandle, callback)
or something like that
filehandle.dispatch_operation(callback), scheduler.wait_for(filehandle), end
dalek p: 1f3891e | moritz++ | t/p6regex/01-regex.t:
work around hang of p6regex tests at end of file
14:12
whiteknight msg arvis the Scala docs just got upgraded to a new look: docs.scala-lang.org/ 14:13
aloha OK. I'll deliver the message.
benabik whiteknight: Snazzy 14:14
whiteknight benabik: I haven't looked too deep, but it is pretty 14:15
dalek href="https://parrot.github.com:">parrot.github.com: da44683 | Whiteknight++ | _layouts/site.html:
try to fix a few links
14:19
href="https://parrot.github.com:">parrot.github.com: 3fd3de5 | Whiteknight++ | _layouts/site.html:
re-fix links
14:22
Coke benabik: so you want something more like XPath ? 14:26
nine Should this make me nervous? src/gc/gc_gms.c:2223: failed assertion 'Dead object found!'
Running paste.scsys.co.uk/154238
moritz in PIR, if obj and foo are PMCs, what does obj.foo() do? 14:27
benabik Coke: Not familiar with XPath. Thinking of case statements from Haskell or ML.
moritz assume that foo is a code object, and invoke it with obj as invocant?
benabik moritz: Probably the same as foo(obj), but not sure.
Coke benabik: are you familiar with xml?
benabik Coke: Vaugely. 14:28
NotFound moritz: I think it sets obj as current object an vtable-invoke foo 14:34
s/an/and 14:35
moritz NotFound: thanks
dalek p: fa9f991 | moritz++ | src/QRegex/Cursor.nqp:
try to implement <before>

It seems a bit wrong since it never captures, but it does look-ahead
14:36
NotFound And invoke usually pass the curent object as invocant to the overriden method, if any.
14:38 contingencyplan joined
dalek p: 9ce492d | benabik++ | t/p6regex/01-regex.t.old:
Remove t/p6regex/01-regex.t.old

It's not being used and if someone wants to refer to it, it's still available in the git history.
14:39
p: d24711b | benabik++ | t/ (2 files):
Fix TAP parsing error with plan at end of tests

prove doesn't like a plan at the end. Instead just emit the 1..N done testing marker.
p: c73056a | benabik++ | t/ (5 files):
TODO regex test regressions from -rx

We know these tests are going to fail, so let's just mark that to be the case. They're marked regression so that we know which ones to focus on.
One test description got altered since using # for the issue number prevented prove from seeing the # TODO later in the line.
NotFound I'm thinking about a PMC that implements all vtables by dumping its arguments and aborting, or throwing a fatal exception.
p: f858b3a | benabik++ | t/ (7 files):
UnTODO passing regex tests

It appears that NQP has several more features than its test suite thinks it does.
NotFound It can be a nice debugging tool. 14:40
(all but init, of course) 14:41
whiteknight NotFound: null already does something similar 14:42
NotFound whiteknight: it doesn't show its arguments, nor pass them to the exeception thrown. 14:43
whiteknight okay, I see what you are saying
yes, that would be an interesting debugging tool. Maybe make a dynpmc library for debugging tools like that?
NotFound That's the idea, yes, dynamica loadable so we don't pay for it when not used. 14:44
nine Whiteknight: would you mind having a look at the assertion failure running paste.scsys.co.uk/154238 14:45
whiteknight nine: sure, I can take a look in a few minutes 14:54
nine whiteknight: thanks 14:57
15:00 dmalcolm joined
dalek href="https://parrot.github.com:">parrot.github.com: 4ac9d37 | Whiteknight++ | / (8 files):
Port over a few of the recent release announcements to the new format for an example. Update the index page to list them (needs CSS help badly). Add a .gitignore file to ignore jekyll generated files
15:05
whiteknight nine: I'm building green_threads now. I'll test it when it's ready 15:07
nine: what error are you seeing? 15:14
nine whiteknight: src/gc/gc_gms.c:2223: failed assertion 'Dead object found!'
whiteknight okay, that's what I see
nine whiteknight: you may have to run it a couple of times
whiteknight lousy
nine Any idea what kind of problem I'm looking for? 15:15
benabik Probably something forgot to mark() a PMC its using.
whiteknight yeah, that's what I'm thinking
Task->code is being prematurely collected somewhere 15:17
where is the current task stored while it's executing? 15:18
nine whiteknight: interp->cur_task = task; 15:21
whiteknight yeah, I see that 15:22
hold on, I'm testing a fix now
...nope, that didn't work 15:23
bleh, I suspect we're missing a GC write barrier somewhere 15:24
nine whiteknight++ # answering my questions in blog posts before I even have them 15:28
whiteknight ...okay, I think I fixed it 15:35
I'll push as soon as this program exits 15:36
man, it really does start to slow down around 2000 tasks for me
benabik O.o
nine yeah! You just saved me a couple of hours of head scratching
whiteknight of course, I'm on a 1-core virtual machine here, so everything is a little slow 15:37
nine multiple cores would probably not help you much yet ;)
dalek rrot/green_threads: e212575 | Whiteknight++ | src/ (2 files):
Make sure to GC mark interp->cur_task. Add GC write barriers in scheduler.c where the internals of Tasks et al. are modified directly instead of going through safe vtable wrappers.
15:38
benabik nine: It would help let things other than parrot run while testing.
whiteknight nine: they help when I'm not running all background OS utilities, the console, the text editor, etc on the same core while debugging
plus, the host machine is running VisualStudio and a few other things, so I'm generally pretty bogged down 15:42
nine: for future reference, whenever we modify the contents of a PMC we need to set a write barrier flag so the GC picks up the changes. most of the setter VTABLEs automatically generate code to do that, so if you use vtables you're usually safe 15:47
nine: but in scheduler.c where we modify the struct contents directly, we need to manually set the write barriers. it's tricky
15:49 iana joined
whiteknight nine: if you see similar gc-related errors, like a !Dead object found assertion, or some other issue where it looks like a PMC of one type is being accessed as if it were another type, that's probably the cause 15:51
cotto ~~ 16:10
whiteknight msg dukeleto I made a few changes/additions to parrot.github.com. Take a look and see if it's heading in the direction you envision 16:27
aloha OK. I'll deliver the message.
16:35 fperrad joined
nine whiteknight: many thanks. Your patch is very instructive 17:08
whiteknight nine: good! Glad to help 17:13
dukeleto ~~ 17:14
17:24 SHODAN joined
nine Seems like parrot needs 41KiB of RAM per task 17:28
whiteknight that seems like a lot 17:30
nine for supposedly ultra light green threads 17:31
whiteknight that doesn't make a lot of sense to me. The size needed should be the size of a single PMC 17:32
plus bookkeeping 17:33
nine and the continuation
no idea about those
whiteknight okay, two pmcs. Continuations don't cost much
where are you getting that number from? 17:34
I'll need to look, but it didn't look like the system was doing anything stupid like trying to clone bytecode or anything 17:35
nine letting moretasks.pir create 6000 tasks and looking at top
after startup parrot took 6MiB. With 6000 tasks it's 249MiB
whiteknight That seems off 17:36
let me give it a try here
it might be doing something stupid internally
which column in top is the amount of mem used? VIRT? 17:39
nine RES 17:41
as long as it's not swapping. Then it's nearly impossible to tell since VIRT contains memory mapped files as well
Interesting: task.pmc has a completely unused Parrot_jump_buff abort_jump. There's a setjmp call but no corresponding longjmp. But removing abort_jump does not reduce memory consumption. 17:44
whiteknight okay, each Task represents 4 PMCs. If you take out the schedule op, it creates 4 pmcs each loop 17:46
gist.github.com/1320270 17:47
with the schedule op, it's a lot more than that
4930 pmcs total 17:48
no, wrong
it goes up each time
each time we schedule a task, it allocates more PMCs than the time before 17:49
nine that doesn't sound good
whiteknight aloha: 96063 - 91133
aloha whiteknight: 4930
whiteknight aloha: 91133 - 85285 17:50
aloha whiteknight: 5848
whiteknight okay, maybe not
aloha: 85285 - 81213
aloha whiteknight: 4072
whiteknight okay, so it's a weirdly random number
nine wtf? 17:51
Parrot_cx_schedule_task looks pretty innocent to me. If you give it a task, all it does is call VTABLE_push_pmc 17:52
17:55 bluescreen joined
whiteknight nine: you have valgrind installed? 17:59
nine yes 18:00
those pmc numbers seem totally random at times. Especially if I raise the task count 18:01
whiteknight I hope the GC is keeping accurate tally 18:02
tadzik oh wtf
I just measured rakudo spectest on green_threads
make spectest 1428.83s user 117.25s system 94% cpu 27:20.81 total
now guess the yesterday's result
whiteknight ?
tadzik 2011-10-19 22:55:32 tadzik make spectest 2210.87s user 148.94s system 95% cpu 41:04.40 total 18:03
nine wtf?
tadzik I don't believe time anymore
(yesterday's results = parrot master)
must be my cpu acting silly or something 18:04
whiteknight nine: I think that GC number is accurate. If you backscroll you can clearly see places where GC sweep is picking them up
or, if not accurate, then close enough
moritz tadzik: do you have two different shell environments, one where TEST_JOBS is set and one where it is not?
tadzik moritz: no, I never messed with TEST_JOBS 18:05
whiteknight bleh, I have to install kcachegrind here 18:06
nine whiteknight: looks very random to me: scheduling 351 pmcs: 567557, scheduling 352 pmcs: 9592, scheduling 353 pmcs: 15040
whiteknight nine: that small number is where a GC collect run takes place
tadzik moritz: that may be my CPU going into powersave state (1.2 GHz instead of 2.1) when it's not in the mood 18:08
I'll pay double attention to that from now on
that's my only sensemaking guess
whiteknight tadzik: the only thing that should change in green_threads for current rakudo is a little bit of startup overhead 18:09
tadzik anyway, spectest passes and it doesn't seem to be slower :P
whiteknight so any numbers that look wildly different are probably erroneous
tadzik yeah
so, the only thing I can report is no failures on this machine
nine which is good news :) 18:10
tadzik I'll try nqp and parrot too, Justin Case
whiteknight nine: Parrot_cx_schedule_sleep is creating 29,013 PMCs
I lowered test.pir to schedule only 200 tasks 18:11
Task.invoke is creating 49,066 PMCs
Parrot_cx_stop_task is creating 48662 PMCs
so, there's the problem
if sleep is creating a PMC each time, and each task is in a tight loop around sleep, that's a lot of PMCs
10 per task per second 18:12
I assume that amount is being folded into the value of Parrot_Task_invoke
Coke without looking at the implementation, do we need those, what, 4 PMCs per task?
whiteknight Coke: I don't know, but I doubt that's the biggest part of the current problem 18:13
nine whiteknight: a lot of PMCs that should get garbage collected soon after
Coke wonder if chromatic is busy ;) 18:14
tadzik (:
whiteknight Coke: The 4 PMC attributes in a Task are the code (which is not created for the Task), the mailbox which we don't always need to use, the list of waiters which we don't usually need, and the user-supplied data
so we can create the mailbox and the waiters list lazily
nine so maybe it's no problem at all but just normal behaviour for a program generating lots and lots of short lived objects in a garbage collected runtime? 18:15
tadzik PASS on parrot, nqp, rakudo. Green threads, green light
whiteknight nine: maybe, but it seems weird to me that sleep would have to create a PMC. Maybe the interp can keep around a pre-allocated sleep/delay PMC that we reuse 18:16
moritz tadzik: you can log while true; do cat /proc/cpuinfo |grep 'cpu MHz'; sleep 5; done while running your spectests 18:18
dalek rrot/green_threads: d42dc2a | Whiteknight++ | src/pmc/task.pmc:
Don't create Task.waiters or Task.mailbox unless we need them. This saves us two PMCs for simple tasks
nine whiteknight: the pmc it creates is the alarm. I can't see how it could work without that. You'd need one of those per task which kind of defeates the purpose. 18:19
whiteknight nine: so what if we store the alarm in the Task, and cache it so we aren't creating one each time we sleep? 18:20
or, is that a solution which is only beneficial in the case of this synthetic benchmark?
nine whiteknight: that's what I think: we're talking about optimizing a very special case. And anyway "optimizing sleep performance" sounds kinda funny to me :) 18:21
NotFound To optimize sleep, buy a better bed.
whiteknight Parrot_cx_stop_task should take a third parameter, a flag which says whether we need to take a continuation or not 18:22
We don't need to create a continuation, and we don't need to keep the task if we don't expect it to ever be used again 18:23
tadzik moritz: well, it shouldn't go powersave if the power cable's in, and I never do anything Rakudo-y on battery :) but I'll probably try it next time, thanks
NotFound whiteknight: maybe better another function.
winxed examples/fly runs fine in the green_threads branch. 18:25
nine whiteknight: when would we expect the task to be not used again?
whiteknight nine: when the task completes 18:34
Coke oooh, I can finally sign up for google+. Too bad about the silly name policy, though.
nine whiteknight: when the task completex Parrot_cx_stop_task is not called. Parrot_cx_next_task simply returns to Parrot_cx_outer_runloop and the task is not put again into the queue 18:35
tadzik Coke: are you on Diaspora yet? :) 18:38
dukeleto we really need Google Code-In tasks 18:44
tadzik yep 18:45
dukeleto can somebody help me with that? I have absolutely no time for it
and we will not be accepted in our current state
tadzik what are we aiming for? Tests? Does moving TT to GH count?
documentation maybe? There's been talking about that
whiteknight dukeleto: when's the deadline?
tadzik Alvis is the new docuchief, maybe he can look through it and figure out some LHF for GCI students? 18:47
Coke tadzik: nope. 18:52
documentation /generation/ is tough. /reorganization/ would probably be a good task.
I wonder, will we have tasks that can be handled by students who have never done any coding before? 18:53
dukeleto whiteknight: yesterday
Coke (I know the tasks themselves don't have to be coding)
dukeleto github.com/parrot/parrot/wiki/Goog...Task-Ideas
whiteknight dukeleto: Well, that stinks
dukeleto everything is explained there
whiteknight: i don't know, but i shouldn't have applied us with 0 tasks listed, but I did 18:54
whiteknight yeah, I'm working on that page now
dukeleto whiteknight: they will look at them soon, and if they look at them when there are no tasks => no bueno
whiteknight: i applied us when i had the motivation and time to do it
whiteknight: what is your melange id? 18:59
whiteknight wknight8111, I think
dukeleto msg particle i put you as backup admin for Google Code-In, just as a temporary measure. No worries.
aloha OK. I'll deliver the message.
dukeleto whiteknight: i can never remember that 19:00
whiteknight: just made you backup admin, you cool with that? 19:01
whiteknight NO I DEMAND PRIMACY!
actually, that's cool
okay, we have 9 tasks 19:11
dukeleto whiteknight++ 19:13
whiteknight dukeleto: I don't see how we are supposed to have 5 tasks for each category. We don't have much in the way of user interfaces or training, and we are a little sour on translations 19:15
aloha: coverage
aloha: coverage?
aloha whiteknight: coverage is cv.perl6.cz or tapir2.ro.vutbr.cz/cover/cover-results/
Coke I didn't realize the reason we had so many translation tasks before was that google was pushing them. 19:16
dukeleto the rules changed 19:17
cotto I don't think that was the case last year.
dukeleto there was no "must have 5 tasks in each category" rule last year
NotFound User interfaces tasks? Easy: write a module for: gtk+, qt, gnome, kde, motif... ;) 19:18
atrodo Ahh, motif...
tadzik do we really want Translation tasks? We got a few last year, but it doesn't seem like they were found really useful 19:26
maybe "promote Perl somewhere in your local language" could be assigned to that
cotto tadzik: we might do better focusing on one language 19:28
whiteknight 16 tasks. Anybody with any ideas would be welcome 19:29
benabik Comparing our own documentation with the Parrot VM wikibook? Might be multiple tasks 19:31
whiteknight the wikibook is hella old 19:32
benabik but it was one of the first things I found for info back in the day 19:33
Find places in the documentation that say things like "documentation needed", TODO, or are just blank? 19:34
19:37 bluescreen joined 19:45 soh_cah_toa joined
whiteknight okay, I've put in all the tasks I can do right now. I can put in more tonight 19:51
20:05 ambs joined
tadzik "Outreach" section, how about "promote parrot $somewhere"? 20:15
whiteknight unfortunately, our code coverage is generally pretty high for most important files, and we don't have tools to measure coverage of PIR/Rakudo/HLL files yet
dukeleto tadzik++ # make promo posters, stickers, give talks about parrot at a local tech user group 20:18
NotFound Funny fact: I discovered an unused variable in winxed stage 1 in a C++ warning while testing winxedxx
dukeleto NotFound: why funny?
NotFound: did the variable tell a good joke? ;) 20:19
NotFound dukeleto: I've not expected such usefulness
Using a C++ compiler to find pitfalls in winxed sources sounds funny to me. 20:20
Try to do that with python ;)
tadzik dukeleto: should I add that? 20:22
nicely worded
ok, forgiveness > permission 20:23
dukeleto tadzik: don't ask permission! only forgiveness :) 20:24
NotFound "Promote Parrot in google, in order to stimulate them to give us generous donations" 20:25
dukeleto tadzik++
NotFound: they already do. It's called GSoC and GCI
NotFound dukeleto: politicallty correct fix: "Promote Parrot in google, in order to stimulate them to give us even more generous donations" 20:26
User interface: "Write one" 20:28
tadzik dukeleto: did you file me as a mentor? 20:32
dukeleto tadzik: mentors can volunteer if/when we get accepted
tadzik ok
dukeleto the UI task can be create.parrot.org, which I already started hacking on 20:33
to generate some new graphics and pretty CSS for it
cotto also, a clone of dddash.ep.io 20:39
20:43 alvis joined
alvis Hello, #parrot 20:51
tadzik hello alvis
alvis Just now got time to catch up. Fwiw, I agree with benabik:
benabik alvis: Whatnow? 20:52
alvis Wikibooks srsly burned away hours of my time on useless, out-of-date stuff.
benabik Ahhh...
alvis Btw, does anyone want to further respond to my post on parrot-dev before I reply? 20:57
I wanna give folks sufficient time. 20:58
NotFound: Game 6 was postponed, so I got pine up and running instead. :) 21:00
NotFound Game 6? 21:01
alvis NotFound: Sorry, the World Series.
NotFound alvis: I don't follow any USA sport 21:02
Almost any sport, in general.
alvis NotFound: I understand. Lotta folks don't. 21:04
dukeleto alvis: i don't think you need to wait for any more replies 21:09
alvis: people may add more suggestions, but run with what you have now
alvis dukeleto: agreed & ok 21:10
dukeleto can somebody add this as a task? github.com/letolabs/app-parrot-create
1 task is to finish the dancer app that runs it (coding) another is a UI task to create a cool logo and css for the website
tadzik: ^^^
tadzik sure
dukeleto tadzik: also, add a task (coding) that is adding tests + implementing functions in github.com/letolabs/libgit2 21:11
tadzik: just write a sentence like "since this is a large amount of potential work, it will be broken up into 10-20 tasks that are smaller chunks of work" 21:12
tadzik: blarg! wrong link i gave you 21:13
tadzik: github.com/letolabs/parrot-libgit2
tadzik dukeleto: done 21:15
dukeleto tadzik: we need to emulate structure here: wiki.wesnoth.org/GCI 21:34
tadzik: description, requirements, expected time, difficulty 21:35
tadzik: and deliverable
tadzik: like the task template. if you have time, could you please expand some of the task ideas?
NotFound Possible task: write a task editor for next year GCI ;) 21:51
benabik HEh. 21:52
22:12 jsut joined
dukeleto github.com/leto/gci 22:15
i made a repo of all the tasks i wrote for last years gci
feel free to use it
22:15 rfw joined
dukeleto rfw: oh noes! 22:15
rfw hi dukeleto 22:17
i've been lurking around here for the last few months :) 22:18
tadzik dukeleto: sorry, ran short of tuits, will have some tomorrow 22:22
cotto github.com/andreasgal/pdf.js/pull/603 22:43
I want one of those.
22:54 whiteknight joined
whiteknight good evening, #parrot 22:55
23:19 jsut_ joined