Perl 6 - the future is here, just unevenly distributed

IRC log for #moarvm, 2014-08-19

| Channels | #moarvm index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:40 avuserow_ joined #moarvm
01:17 jnthn brrt++ # blog post
01:22 FROGGS_ joined #moarvm
01:48 ilbot3 joined #moarvm
01:48 Topic for #moarvm is now https://github.com/moarvm/moarvm | IRC logs at  http://irclog.perlgeek.de/moarvm/today
01:57 lue joined #moarvm
02:20 jnap joined #moarvm
03:08 avuserow_ joined #moarvm
03:34 dalek MoarVM/const_storage_spec: 60ad5d9 | jimmy++ | src/ (46 files):
03:34 dalek MoarVM/const_storage_spec: make get_storage_spec returns const MVMStorageSpec *
03:34 dalek MoarVM/const_storage_spec: review: https://github.com/MoarVM/MoarVM/commit/60ad5d9f29
05:32 colomon joined #moarvm
07:03 zakharyas joined #moarvm
07:47 sergot o/
07:52 moritz serg\ot
07:54 klaas-janstol joined #moarvm
08:11 woolfy left #moarvm
08:13 Ven joined #moarvm
08:14 brrt joined #moarvm
08:15 woolfy joined #moarvm
08:15 woolfy left #moarvm
08:20 sergot mo/ritz
08:21 brrt \o sergot
08:23 FROGGS_ morning _ 'VB FTW
08:24 woolfy joined #moarvm
08:26 brrt VB?
08:43 klaas-janstol joined #moarvm
08:44 FROGGS visual basic
08:47 brrt oh
08:47 brrt why is VB ftw?
08:47 nwc10 brrt++ # good blog post
08:47 brrt oh thanks :-)
08:47 jimmyz joined #moarvm
08:48 brrt i've corrected the interator error :-)
08:48 jimmyz jnthn/brrt: would you mind if I push const_storage_spec branch to master?
08:48 brrt does it work and pass spectests?
08:48 nwc10 it worked for me. However, I was using gcc.
08:48 FROGGS brrt: that was ironic :o)
08:48 brrt i don't. but how did you handle the fact that the repr_data storage spec is'nt quite const
08:48 brrt ooh
08:49 nwc10 what does MSVC think of it?
08:49 jimmyz works here
08:49 FROGGS I mean, everything that "unspaces" with _ and escapes quotes with more quotes is plain stupid
08:50 jimmyz I didn't get a chance to test it with msvc
08:51 nwc10 I've not looked at the code, so I can't say "yes, it makes sense", but if you're changing const, I think it would be a good idea to be sure that something more picky than gcc is happy with it
08:51 jimmyz aye
08:53 * brrt will check msvc
08:54 brrt or, i won't, because virtualbox is angry at me
08:54 jimmyz for another info, it reduces libmoar.so size about 100 bytes :P
08:55 brrt o.O
08:55 brrt why would that be
08:57 brrt reboot, bbiab
08:59 brrt joined #moarvm
09:00 brrt VirtualBox, y u uninstalled
09:03 woolfy left #moarvm
09:07 brrt joined #moarvm
09:07 brrt i'mma be reporting bugs to fedora it seems
09:09 brrt jimmyz: can't vet for your commit yet
09:10 jimmyz brrt: no hurry
09:10 brrt oh bloody, rebooting killed my work in the evaluation form :-(
09:11 brrt that's pretty dumb of me
09:11 brrt clang is slohooow
09:12 brrt although we should probably fix all its warnings
09:13 brrt idiotically slow, i might add
09:16 brrt but it seems it compiles OK
09:16 brrt anyway, bbi3h
09:30 woolfy joined #moarvm
09:30 woolfy left #moarvm
09:37 woolfy joined #moarvm
09:38 woolfy left #moarvm
09:47 timotimo "be back in 3h, when my moarvm compilation has finished"
10:07 Ven joined #moarvm
10:37 Ven joined #moarvm
11:41 brrt joined #moarvm
11:44 itz_ joined #moarvm
12:19 brrt not that long timo :-)
12:20 brrt oh in response to your question
12:20 brrt what happens really often in code is that we take an iterator of a hash or array
12:20 brrt and then check if it's value is true
12:20 brrt and then shift a value from it
12:20 brrt but these operations are never invokish
12:20 brrt and could in fact easily be inlined without any form of dispatch
12:21 brrt at least, if you know whether you are dealing with a hash iterator or an array iterator
12:21 brrt which you probably do because spesh
12:21 nwc10 I was about to type your last line for you
12:22 timotimo that does sound kinda interesting
12:22 brrt anyway, iterator true is never invokish, so just speshing that into it's own op will save some
12:22 timotimo fwiw, the boolification spec may be "ELEMENTS"
12:22 timotimo in which case, there's a piece of code in spesh that almost does what you want already
12:22 timotimo oh
12:23 timotimo we only do that on KNOWN_VALUE at the moment, which is far from helpful
12:23 timotimo which kind of check-for-truth are we using in the iterator case?
12:23 timotimo if_o/unless_o?
12:23 brrt unless_o most of the time
12:25 brrt basically for @foo -> $bar { } makes an iterator out of @foo, jumps after our block unless the iterator is true, shifts from the iterator, enters the block, and jumps back at the end
12:26 timotimo OK, i can whip something up now that we have a way to allocate temporary registers
12:26 timotimo (which is what blocked the previous attempt at this feature)
12:27 timotimo src/spesh/optimize.c:202 does it for known values, for just known type, it'll turn into unbox_i, unbox_n, isnull_s, ...
12:27 timotimo not 100% sure if we have a proper op yet for the iterator case, may just have to build an sp_istrue_iter or something
12:27 timotimo today may end up a busy day for me for other things, though, so maybe it'll happen tomorrow
12:28 brrt yeah, i'd say that we have 16 bits of space for ops
12:29 brrt which is? 1024 * 64 ops? plenty space to add special ops for special situations
12:31 nwc10 "Special Circumstances"
12:42 FROGGS[mobile] joined #moarvm
12:44 timotimo "OpenBSD Ports Change" tweeted that moarvm b0rks with "error: unsupported platform" for dyncall_callvm.c
12:47 jnthn Um...did we actually upgrade it?
12:47 * jnthn didn't recall doing that for a while
12:49 timotimo no clue
12:49 timotimo maybe someone put the port in there for the first time or something
13:06 JimmyZ joined #moarvm
13:10 JimmyZ const_storage_spec branch builds with MSVC
13:10 JimmyZ so I will push it to master :)
13:11 jnap joined #moarvm
13:12 ggoebel11111112 joined #moarvm
13:13 dalek MoarVM: 60ad5d9 | jimmy++ | src/ (46 files):
13:13 dalek MoarVM: make get_storage_spec returns const MVMStorageSpec *
13:13 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/60ad5d9f29
13:14 brrt much approve
13:14 jnthn Such const
13:14 JimmyZ :/
13:16 moritz 46 files changed, 103 insertions(+), 103 deletions(-)
13:16 moritz wow
13:16 moritz erm
13:16 moritz such wow
13:16 nwc10 (correct) const is good, because it tells both the compiler and humans things
13:17 nwc10 it's better to get it right early, because it's hard to retrofit
13:17 JimmyZ yeah, at least it's good for GCC
13:21 moritz ftr I'm not against consting anything, I was just surprised how many lines it touched
13:21 nwc10 I still haven't looked at it, but I'm not surprised
13:21 moritz (but that's just because I don't know the code base at all)
13:21 jnthn I guess const is somewhat viral.
13:21 nwc10 ayre
13:21 nwc10 aye
13:22 nwc10 I *have* now skimmed it, and it doesn't surprise me
13:27 [Coke] brrt++ # one of the more successful GSOC programs (most stuff already integrated into master!)
13:28 brrt \o/ yay
13:28 brrt yes, that is very nice
13:28 nwc10 that's somewhat an understatement
13:28 [Coke] nwc10: was hedging my bet.
13:28 nwc10 :-)
13:28 nwc10 wise
13:28 jnthn Is there anything that isn't integrated into master by now? :)
13:28 jnthn And yes, brrt++
13:28 jnthn I'll be filing my eval later today :)
13:28 nwc10 jnthn: I don't know. There are a lot of branches still
13:29 brrt not in the way of branches, i think
13:29 jnthn nwc10: Yes, I meant of brrt++'s work :)
13:29 nwc10 oh, his work - he still has to drink the beer that we're going to buy him.
13:29 jnthn :)
13:30 brrt and for the time being, i'd like to keep moar-jit arround so we have a place to stuff the the breaking jit stuff
13:30 jnthn +1
13:30 FROGGS +1
13:30 FROGGS :o)
13:30 [Coke] is he even old enough for bier?
13:30 JimmyZ brrt++   # indeed
13:30 FROGGS *g*
13:31 brrt oh, can you all help me out a bit? what would be the most colourful thing to tell on my eval form about the past few months?
13:31 brrt there are plenty of things of course that happened
13:32 nwc10 [Coke]: oh, most curious. For the purposes of YAPC::Europe, everyone is: http://en.wikipedia.org/wiki/Legal_drinking_age#Europe
13:33 brrt lol
13:33 brrt well that wouldn't be a problem for me anyway :-)
13:33 [Coke] nwc10: bulgaria++
13:33 jnthn brrt: Well, I most remember staying up until 3am fixing deopt all + JIT :P
13:33 brrt oh yes, that was a story
13:34 [Coke] Question for the .eu crowd here; would you travel to Belarus?
13:34 brrt ... i doubt it
13:34 jnthn [Coke]: Yes, if I had a good reason to.
13:35 brrt why ask?
13:35 jnthn [Coke]: And next time I won't try taking a building of "that hilarious ugly building", only to find I have a policeman telling me that it's the presidential palace and I should delete my photos of it. :)
13:35 brrt whut :-o
13:36 [Coke] (my father's family is from belarus)
13:37 jnthn Police guy spoke no English. My Russian is awful. His attempt to write my name and address in Cyrillic was hilarious. I'm not sure they'd have found me with that info if they tried. :)
13:38 nwc10 your Russian was good enough to deal with the Ukrainian taxi drivers
13:39 jnthn Taxi drivers have a simpler interaction model than police. :)
13:40 jnthn Anyway, I don't really consider Belarus a dangerous place to go. It does need some paperwork/prior arrangements that are a small nuisance. Brest is a LOT nicer than Minsk.
13:41 brrt i consider belarus a slightly politically unfriendly place to go
13:42 brrt although that's probably not that relevant for foreigners
13:42 [Coke] yah, I'd mainly go to consider hitting up town halls for birth records, I think.
13:42 [Coke] ... it occurs to me it'd be much cheaper to pay for jnthn to go!
13:44 jnthn Hm, that'd mean dealing with administrationy folks = *certainly* could use a native (or fluent) speaker.
13:45 * brrt regrets not learning russian when it was offered
13:46 brrt anyway, cyrillic isn't all that complex if you know the greek alphabet
13:47 jnthn I didn't, but still didn't find it too complete :)
13:47 jnthn uh, complex
13:49 [Coke] I tried bulgarian briefly; seemed doable, but I stopped working with the offshore bulgarian team before I could do more than say "hello, please a beer give me."
13:50 woolfy joined #moarvm
13:50 brrt the yapc::eu wiki tells me sofia is 7000 years old... that's pretty amazing i think
13:50 woolfy left #moarvm
14:02 brrt oh, timotimo: i'd meant to say that the MVMJitCode structure has both the pointer to and the size of the code, as well as the pointer to the static frame (so you have its' name)
14:05 woolfy joined #moarvm
14:05 woolfy left #moarvm
14:15 woolfy joined #moarvm
14:15 woolfy left #moarvm
14:24 brrt submitted
14:24 brrt pfew
14:24 brrt that was a bit of work
14:42 [Coke] brrt++
14:54 cono joined #moarvm
15:32 TimToady that was the hard part :)
15:41 brrt evaluations aren't easy, that's for sure
15:47 FROGGS joined #moarvm
15:48 japhb self-evaluations particularly so
16:28 klaas-janstol joined #moarvm
16:56 ggoebel11111113 joined #moarvm
17:26 Ven joined #moarvm
17:26 brrt left #moarvm
17:44 tgt joined #moarvm
17:47 Ven joined #moarvm
18:17 timotimo i'll spend a bit of time on the iterator boolification optimization in spesh now
18:19 klaas-janstol joined #moarvm
18:32 timotimo should i put sp_ ops at the very end when i add new ones or should i just put them where i think they fit?
18:32 timotimo as the order of sp ops doesn't matter for serialized bytecode
18:33 jnthn Yeah, the oder doesn't matter
18:33 jnthn uh, order
18:33 jnthn I'm sure the Oder is a very important river indeed.
18:35 timotimo :)
18:35 timotimo welcome to the new world Order
18:47 Ven joined #moarvm
19:33 timotimo huh.
19:33 timotimo sadly, the spesh_diff script is in somewhat bad repair :\
19:43 timotimo jnthn: is there a reason why MVM_spesh_manipulate_insert_ins(tc, bb, ins->prev, new_ins); could end up not putting the new_ins in?
19:44 jnthn In my experience, normally 'cus I did something silly on the calling side :)
19:45 jnthn (Passed the wrong basic block, or tried to insert the wrong thing, or into the wrong thing, or onto a deleted thing, or... :))
19:45 timotimo don't think i did anything like that
19:46 timotimo however, i may have put a "isconcrete" in and that turned into a guardconc, but not a const_i64_16
19:46 timotimo https://gist.github.com/timo/1f1ba5dd12f1748e56b2 - but i don't even know if this is what blows up
19:48 timotimo would ins->prev work even if the instruction is at the very beginning of a basic block?
19:49 jnthn Yeah, it knows what to do with NULL
19:49 timotimo i can clearly see the temp register being used in the if_i/unless_i that is the result of my optimization
19:49 timotimo but i never see the op i insert before that that is supposed to put an actual value in
19:49 timotimo oh.
19:49 timotimo dead code elimination
19:49 timotimo forgot to up the usages of the temp register ... again.
19:50 jnthn :)
19:51 jnthn Yes, the dead code elim is quite efficient :)
19:51 timotimo yup.
19:52 timotimo it seems like boolify_iter doesn't get used a single time in nqp's build process
19:52 jnthn Did you do some facts on iter?
19:53 timotimo probably not
19:55 timotimo i'll have to check if it gets a MVMList repr'd object, a MVMHash repr'd object or a MVMContext repr'd object and then handle each individually ... hmm.
19:55 timotimo it'll probably be fine to replicate the type selection logic from MVM_iter in spesh ...
19:57 jnthn Yes, I think that's the kinda thing to do
19:59 timotimo this'll better be worth it :P
20:07 timotimo cool, seems to work
20:08 timotimo i'll strip the debug messages and commit + push if it survives spectests
20:09 woolfy joined #moarvm
20:11 timotimo oh damn
20:11 timotimo spectests are quite unhappy
20:14 timotimo unbox_i makes things unhappy
20:14 timotimo hmm.
20:33 timotimo of course.
20:34 timotimo it's supposed to return a falsy result if the value is a type object
20:34 timotimo and unbox_i will blow up instead
20:34 timotimo jnthn: what's the best suggestion you can come up with to get around this problem?
20:35 timotimo except for "don't turn iffy ops into unbox_*"
20:37 timotimo trying to bool_I on a type object will violently explode ...
20:38 * timotimo puts a KNOWN_CONCRETE check in there to guard the optimization
20:38 jnthn Yes, chekcing it's concrete is the way to go
20:38 jnthn You need to know an opt is valid before doing it :)
20:38 timotimo oh!
20:38 timotimo actually
20:39 timotimo ... how does the SSA form react if i put another goto in there?
20:39 timotimo because i can just turn an if_o into an isconcrete + if_i + unbox_i + if_i for example
20:39 timotimo er ... not quite
20:40 timotimo it'd have to be an unless_i and then it'd have to jump to the BB's successor :\
20:41 timotimo can i be sure that iter will return something that is concrete?
20:42 jnthn Yes, iter always will returna  concrete MVMIter
20:42 timotimo OK
20:42 jnthn Uh
20:42 jnthn But you don't know the type
20:42 jnthn MVMIter is a repr
20:42 jnthn You need to look at the RHS to know the type
20:42 jnthn But I guess you are already :)
20:42 timotimo yes, i am
20:43 timotimo strange. i have a FACT_CONCRETE guarding my iffy opt, but i still get an "cannot unbox type object" error in many, many spec tests
20:48 timotimo but maybe it just means i'm accidentally letting a branch happen that shouldn't
20:48 timotimo like ... an isconcrete was guarding an unbox and i'm accidentally blowing that up
20:51 timotimo but an isconcrete that is guarded by FACT_CONCRETE should turn into a const and then into a goto
20:51 timotimo hmm.
20:54 timotimo if the spec tests are clean for boolify_iter, i'll push and you can have a little look
20:59 tgt joined #moarvm
20:59 timotimo does t/spec/S32-list/uniq.t fail usually?
20:59 timotimo it segfaults here
21:01 timotimo #0  0x00007fcacf9dc146 in scan_registers (frame=0x6ae1fd0, worklist=0x677bdb0, tc=0x19af650) at src/gc/roots.c:373
21:01 timotimo maybe i'm doing dumb things with the registers i'm throwing around?
21:05 timotimo SPESH_DISABLE=1 makes it pass >_>
21:06 timotimo er, whaaaaat
21:06 timotimo #25 0x0000000000000004 in ?? ()
21:06 timotimo No symbol table info available.
21:06 timotimo that can't be right
21:09 timotimo at least with disable_jit, the stack doesn't explode as hard
21:14 brrt joined #moarvm
21:15 timotimo oh!
21:15 timotimo it also crashes without my changes!
21:15 timotimo thta's
21:15 timotimo that's fine, then
21:18 dalek MoarVM: c89d083 | (Timo Paulssen)++ | / (6 files):
21:18 dalek MoarVM: we can have a sp_boolify_iter op to boolify iters quickly
21:18 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/c89d0837d0
21:18 dalek MoarVM: 586e4ce | (Timo Paulssen)++ | src/spesh/ (2 files):
21:18 dalek MoarVM: facts for iter, spesh iffy into boolify_iter
21:18 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/586e4ce0a1
21:18 timotimo jnthn: if you could have a look at the other modifications in iffy...
21:33 brrt timotimo: that's not ifne :-)
21:34 timotimo uh? ifne?
21:34 timotimo oh
21:34 timotimo fine. yeah, i get it
21:37 jnthn timotimo: Still working hard on my talk at the moment... :/
21:37 timotimo OK
21:37 timotimo that's a bit more important
21:37 timotimo now i have brrt to bother! :D
21:37 jnthn Well, more urgent at least :)
21:37 jnthn brrt will probably be at my talk, so will be quite bothered if it sucks :P
21:38 brrt i very much intend to be, yes :-)
21:38 jnthn Did you work something out for not missing your plane? :)
21:39 timotimo heh :)
21:39 brrt yeah, we're staying at my in-laws
21:39 brrt which live quite a bit closer
21:39 jnthn Ah, cool
21:40 japhb "we"?  Who else is going with you?
21:40 brrt but anyway, i haven't seen uniq.t fail
21:41 brrt my gf :-)
21:41 japhb Ah!  Also a hacker?
21:42 timotimo brrt: did you see my problem? i guard tha iffy changes with FACT_CONCRETE, but i get lots and lots of spectests failing with "cannot unbox type object"
21:42 timotimo but the op that'd try to unbox would be unboxing the thing that's FACT_CONCRETE
21:42 brrt no hacker (yet) :-)
21:43 japhb Let the immersion training commence!  ;-)
21:43 brrt timotimo: i don't really understand what you do yet in your code
21:45 brrt maybe a hacker in non computer related senses, though :-)
21:45 timotimo brrt: if we know the type of the flag used for the if_o/unless_o, we can have a look at what its boolification spec's mode is
21:45 brrt i see
21:45 timotimo so i'm trying to turn, for example, unless_o on an MVMIter into a sp_boolify_iter that generates an int64 and then unless_i
21:46 japhb Oh, brrt, I forgot to say way back when you mentioned you were getting a degree in energy and environmental science, and someone said that gets used by anyone who has a datacenter ... they're not only right, that's not the half of it.  At the scale of e.g. Google, there's a LOT of work going on to deal with the externalities of vast energy and equipment usage in concentrated areas.  So please apply here when you get your degree.  :-)
21:46 timotimo in the spectests i get lots and lots of "cannot unbox type object"
21:46 * brrt nods and thinks that is the right approach
21:47 timotimo but i'm already checking the flag for FACT_CONCRETE
21:47 timotimo so no type object should land in my unbox_i (for example) operation
21:48 timotimo so i have to guess i'm causing a branch to be evaluated that shouldn't have been evaluated
21:48 timotimo :\
21:48 brrt japhb: yeah, it's something i'm actually very excited about
21:48 Ven joined #moarvm
21:49 brrt part of my motive for making a JIT compiler is that compiled code is more efficient = more energy efficient as well
21:49 brrt i'm looking at the spesh diff you posted, it looks quite different
21:49 timotimo oh, yeah
21:49 timotimo that was before i added the usages++ to the temporary register
21:49 timotimo so the dead code eliminator killed the inserted instruction immediately :)
21:50 brrt nice
21:50 [Coke] uniq.t fails all the time.
21:50 brrt hmm
21:50 timotimo OK, that's good to know
21:50 timotimo i was worried i had screwed something up there
21:50 brrt basically, do you know what out_facts->flags held before you did anything with it?
21:50 [Coke] https://github.com/coke/perl6-roast-data/blob/master/log/rakudo.moar_summary.out#L2381
21:51 [Coke] it's been segfaulting for some time.
21:51 timotimo you mean in the facts discovery for the iter op?
21:52 brrt yeah
21:52 * brrt hadn't seen that yet (uniq.t bustage)
21:52 timotimo i don't, actually
21:52 timotimo why should that asplode?
21:52 timotimo oh, i forgot to say:
21:53 timotimo the "can't unbox type ojbect" only occurs if you remove the return in front of, for example, MODE_UNBOX_INT
21:53 timotimo so it's nothing to do with the iter facts i'd think
21:56 timotimo brrt: the out_facts flags are 0 before the iter_facts runs through
21:58 brrt hmm ok
21:58 * brrt is trying to understand what's going on and not quite succeeding yet
21:58 timotimo what's going on or what's going wrong? :)
21:59 klaas-janstol joined #moarvm
21:59 brrt both :-)
22:03 timotimo i thought the code ended up somewhat straight-forward %)
22:04 timotimo but i can explain it point for point if you'd like
22:04 timotimo maybe that'll help us stumble over the mistake
22:07 brrt lets say it in another way
22:07 timotimo at least "uncommenting" a few more boolification specs doesn't seem to break spectests
22:09 brrt i have no idea what the code does with the changes you made :-)
22:11 dalek MoarVM: 50edccc | (Timo Paulssen)++ | src/spesh/optimize.c:
22:11 dalek MoarVM: these speshes don't break spec tests
22:11 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/50edccc788
22:11 timotimo here's more changes to make it easier!
22:11 timotimo please ask more specific questions?
22:16 * brrt is reading :-)
22:26 dalek MoarVM: d27d560 | jnthn++ | src/math/bigintops.c:
22:26 dalek MoarVM: Fix nqp::isbig_I to not consider so much big.
22:26 dalek MoarVM:
22:26 dalek MoarVM: This should fix the weird drop-offs in the native benchmarks on native
22:26 dalek MoarVM: int loops, where we prematurely switched to bigints even though we were
22:26 dalek MoarVM: well within a 64-bit register.
22:26 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/d27d560270
22:26 timotimo er, huh, what.
22:27 timotimo now the spec tests seem much, much cleaner even after enabling UNBOX_INT again
22:30 brrt uhm, it seems many many more need isconcrete first
22:30 brrt but that's just me
22:30 timotimo yes. that's why i guarded against FACT_CONCRETE
22:31 timotimo well ... it works now ... for some reason ...
22:31 timotimo not sure how often it still triggers for ints now ...
22:31 brrt yeah, mode unbox_int requires to check for concretishness
22:31 timotimo yes.
22:32 timotimo so ... if i want to put an isconcrete check in, i'd need to emit a jump directly to the BB that's the successor after the isconcrete and then the check for the unboxed int
22:32 timotimo will that be terribly, tèrribly bad for consumers of the SpeshGraph datastructure?
22:32 timotimo i.e. having a goto that's not at the exact end of the BB?
22:32 brrt worst case we add a manipulate api to split bbs
22:33 brrt but i'm not sure what effect this has on the SSA computation?
22:33 timotimo soudns very finnicky
22:33 klaas-janstol joined #moarvm
22:34 brrt yeah, i agree
22:36 timotimo i have a pretty good-looking spectest run right now with more modes activated
22:39 dalek MoarVM: d5045ec | (Timo Paulssen)++ | src/spesh/optimize.c:
22:39 dalek MoarVM: MODE_UNBOX_INT and MODE_BIGINT seem to be safe according to the spec tests
22:39 dalek MoarVM: review: https://github.com/MoarVM/MoarVM/commit/d5045ec2bb
22:39 timotimo can you test this? spec tests are clean with it on my machine
22:41 brrt tell you something strange. on this laptop i can actually hear the CPU working :-o
22:42 timotimo it's probably the powersaving jumping between frequencies
22:42 brrt hmm i imagine so
22:44 timotimo and now i should implement sp_boolify_iter
22:45 brrt yeah :-)
22:45 brrt actually, can't we do sp_boolify_iterhash and sp_boolify_interarray directly
22:46 timotimo we could. do you suggest i do that?
22:46 brrt i.e. look at the structure as if encapsulation doesn't exist
22:46 timotimo well, in that case it could turn into a sp_get_i
22:46 brrt hmm... i suggest that i myself won't do it tonight, yet
22:46 timotimo :)
22:46 brrt i'm going to sleep in a few minutes
22:47 timotimo oh
22:47 timotimo sadly, the calculation isn't quite as simple
22:47 brrt let me see how MVM_iter_istrue is done
22:47 timotimo for hash, it's a check for a null in the iter_state.next
22:47 timotimo but for the array it's a index + 1 < array_state.limit
22:48 brrt uhuh
22:48 brrt which is why you have the different ops for them :-)
22:48 timotimo it'd seem like we could want to do loop hoisting if we pull the array_state.limit out in one spot and check against the index in another
22:48 timotimo if we can prove the length of the array we're iterating over doesn't change
22:48 timotimo which we probably can't do very often
22:48 brrt hmm
22:49 brrt no, wouldn't bother with that yet
22:49 timotimo right; but at some point we could
22:49 timotimo maybe next year ;)
22:51 timotimo oh damn it
22:51 timotimo it seems like i'm getting worse spec test results on my desktop machine as compared to my laptop
22:53 brrt yeah, i get not-entirely-clean spectest either
22:54 timotimo socket-async and lock on my laptop
22:54 timotimo quite a few more on my desktop
22:54 timotimo damn it :(
22:55 timotimo i think the boolify_iterarray vs boolify_iterhash won't be worth as much as the if_o -> boolify_iter + if_i transformation
22:55 timotimo the body.mode is probably so close to body.array_state.index and hash_state.next that it'll all be fetched at once
22:55 brrt i do think it will, because it completely erases a function call
22:55 brrt which means pipeline luv
22:55 brrt and code cache hapinness
22:56 brrt happiness
22:56 timotimo oh
22:56 timotimo i hadn't considered that
22:56 brrt well, i had, and it was my main motivation :-)
22:56 brrt but you spesh the actual type as a fact, right?
22:57 brrt i.e. the facts thingy already differentiates between hash iterator and array iterator
22:58 timotimo yes
22:58 timotimo https://gist.github.com/timo/d2968def5690342270d1 - this is on my desktop >_<
22:59 timotimo MVMArray: Can't resize to negative elements - what.
22:59 timotimo in xx, apparently?!
23:00 timotimo that happens when you xx -1
23:00 brrt yeah, that happens when you bug
23:00 timotimo but it also happens with MVM_SPESH_DISABLE=1
23:01 timotimo so ... wth.
23:01 brrt compiler failure effect?
23:01 timotimo oh
23:02 brrt i dunno, just suggesting :-)
23:02 timotimo i actually didn't get some changes of rakudo on my laptop
23:04 brrt ah
23:05 timotimo i didn't break stuff!
23:05 timotimo TimToady did! :)
23:06 brrt well then
23:06 brrt everything is just fine isn't it :-)
23:06 timotimo \o/
23:18 timotimo oh, actually ... do i know the type of the iter at that point?
23:18 timotimo i'd have to actually look at the type of the thing that gets thrown into the iter
23:19 brrt well
23:19 brrt yeah
23:19 timotimo i could be mean and put the type into the decont_type
23:19 timotimo that's *kind of* correct even :P
23:19 brrt hmm
23:20 jnthn There's flag bits; you could have flag for IS_ARRAY_ITER and IS_HASH_ITER
23:20 jnthn In facts
23:20 jnthn Please don't dual-purpose decont_type :)
23:20 timotimo hmm, seems wasteful, no?
23:20 jnthn I think we've plenty of bits free in the bit field.
23:21 timotimo OK
23:21 jnthn Just out of padding reasons I don't think it makes sense for it to be smaller than 32 bits, iirc.
23:24 * brrt is testing that suggestion right now
23:24 timotimo ah, of course
23:24 timotimo chat suggestion?
23:25 timotimo what*
23:25 timotimo i'm already compiling the boolify_iter_{arr,hash} change
23:25 brrt oh really? :-)
23:25 brrt then hopefully yours works a little better than mine
23:25 timotimo heh. hopefully.
23:25 timotimo building nqp with it right now
23:26 timotimo you know what
23:26 timotimo i'll push it directly and you can implement the jit version of that
23:26 brrt ehm, test if it also works with rakudo
23:26 brrt but yeah, i'll do that
23:27 dalek MoarVM/split_iter_boolification: ca7615e | (Timo Paulssen)++ | / (9 files):
23:27 dalek MoarVM/split_iter_boolification: split boolify_iter into two ops, for hash and array.
23:27 dalek MoarVM/split_iter_boolification: review: https://github.com/MoarVM/MoarVM/commit/ca7615ee52
23:27 timotimo ^- hence the branch
23:28 brrt not trying to be rude, but aren't iterating over a hash and iterating over an array mutually exclusive? :-)
23:28 timotimo looking good so far
23:28 timotimo yeah, well ...
23:28 timotimo what if we have an iter that's neither? :D
23:29 timotimo we can just define the HASH_ITER as 0 instead %)
23:29 brrt hmm yeah either of them
23:29 timotimo spec tests look good at the moment
23:30 timotimo well, ideally the bigger one :)
23:32 brrt i'm really going to sleep now
23:32 brrt :-)
23:32 TimToady o/
23:32 brrt see you tomorrow (and on friday :-))
23:32 brrt o/
23:32 brrt left #moarvm
23:32 timotimo oh
23:32 timotimo in that case, i'll have to implement these ops in the jit apparently :(
23:34 jnthn timotimo: Do you have that link to all the Rakudos over time benchmark you did? And do you mind if I use one or two of the graphs in my talk?
23:35 timotimo no problem
23:35 FROGGS http://www.reddit.com/r/perl6/comments/2cozob/week_31_rakudos_speedram_performance_improves_at/cjs4rpv
23:35 timotimo i'll make another addition to that graph as soon as we release, sound good?
23:35 timotimo oh, yeah, there, too
23:36 timotimo oh
23:36 timotimo i have even more benchmarks, jnthn
23:37 timotimo http://t.h8.lv/p6bench/2014-08-18-longterm_rakudo_history.html  /  http://t.h8.lv/p6bench/2014-08-18-longterm_nqp-moar.html  /  http://t.h8.lv/p6bench/2014-08-18-longterm_rakudo-moar.html
23:37 timotimo those have a moar-jit in them, too
23:42 jnthn Thanks
23:47 japhb Hmmm, those scores look really nice ... when comparing with rakudo 2014.01 instead of perl5.
23:49 jnthn japhb: http://jnthn.net/perl6/bench/2014-08-20.html is my run on a latest Moar built on MSVC, and with JIT
23:49 jnthn japhb: See the natvie ones :)
23:49 jnthn *native
23:55 japhb woah
23:57 japhb Hmmm, while_int2str_concat* is unhappy
23:57 jnthn Yeah. That graph is the wrong shape.
23:58 timotimo also we regressed, didn't we?
23:58 * japhb wonders why perl5 doesn't scale as flatly as rakudo in the hash tests, despite being faster overall still.
23:59 jnthn timotimo: Regressed on what?
23:59 japhb Wondering if the perl5 version of reduce_int_comb_range is incorrect, since it's scaling particularly badly on that test.

| Channels | #moarvm index | Today | | Search | Google Search | Plain-Text | summary