rdubya has quit [Ping timeout: 264 seconds]
rdubya has joined #jruby
rdubya has quit [Ping timeout: 252 seconds]
rdubya has joined #jruby
rdubya has quit [Ping timeout: 264 seconds]
Puffball_ has quit [Read error: Connection reset by peer]
KeyJoo has joined #jruby
drbobbeaty has quit [Ping timeout: 252 seconds]
drbobbeaty has joined #jruby
drbobbeaty has quit [Ping timeout: 252 seconds]
drbobbeaty has joined #jruby
rdubya has joined #jruby
rdubya has quit [Ping timeout: 252 seconds]
rdubya has joined #jruby
isavin has joined #jruby
<isavin> older downloads seems to be unavailable (e.g. https://s3.amazonaws.com/jruby.org/downloads/1.6.8/jruby-bin-1.6.8.tar.gz). can someone have a look? or does anyone know an alternate source for this official releases?
<isavin> *release
eregon has joined #jruby
isavin has quit [Remote host closed the connection]
Crocket has joined #jruby
<headius> isavin: this is unfortunately true...the S3 bucket we kept them in was wiped out mistakenly by the company hosting us and we have only restored builds going back a certain amount of time
<headius> do you need the full tarball or could you make do with just the "complete" jar file?
<headius> enebo: ^^
<headius> since JRuby 1.7.6 (I think) we started pushing the tarball to Maven Central so newer releases are all available that way
<headius> prior to that the tarballs only existed on our bucket, which was not properly set up and then got nuked
<headius> in other news...good morning all!
<enebo> I do have 1.6.8 on the nas
<enebo> so I will restore that one
<headius> 👍
<headius> don't want to just restore everything you have on the NAS?
<headius> at least we have a guarantee now they won't wipe it out
<enebo> headius: yeah probably should now...having it wiped out a second time made me not want to go through it all again
rtyler has quit [Remote host closed the connection]
xardion has quit [Remote host closed the connection]
xardion has joined #jruby
<headius> enebo: I don't blame ya
<headius> grrr
<headius> I can't get this interrupt test to fail locally and don't see why it would fail on travis
Puffball has joined #jruby
<subbu> 1.6.8 seems like ... what ... a decade old?
<headius> prehistoric
<headius> wow, 2012
<headius> it's over 6 years
subbu is now known as subbu|lunch
kares has quit [*.net *.split]
kares has joined #jruby
subbu|lunch is now known as subbu
Puffball_ has joined #jruby
Puffball has quit [Ping timeout: 272 seconds]
Puffball has joined #jruby
Puffball_ has quit [Ping timeout: 272 seconds]
<headius> ok, master is green again with some timeout tweaks
<headius> if anything goes red spuriously we'll deal with it immediately...these flaky results need to end
<xardion> Man, I feel your pain.
<xardion> I've been trying to run the same test quite for a couple hours now.
<xardion> suite*
<xardion> Our chef repo is set up to run manadatory Travis CI builds of the chef spec
<xardion> and one of the specs keeps failing because yum repository mirrors are being flaky today
<xardion> I got it to pass once, but somebody had merged while my specs were running so I had to re-run them *rage*
<xardion> To be fair, this repository is too goddamn big and needs to be broken up, but nobody wants to put in the time to deal with the cross-cookbook dependency headache that breaking up this repo would require.
<headius> xardion: yeah I just had one job completely fail to start on travis and I regularly see our maven builds stall for no obvious reason
<headius> I mean, you get what you pay for, but these failures are confusing and infuriating
<headius> I've been trying to break up our longer suites also
<ChrisBr> headius: ever thought switching to CircleCi?
<ChrisBr> we recently did and I don't look back ... altough everything needs to run in a container there!
<headius> is there a free option?
<headius> we are not exactly a rich project
<ChrisBr> yup
<headius> well that's definitely worth investigating then
<ChrisBr> there is a free option and if you're an open source project you get some more containers even
<headius> travis has served us well but these spurious unexplanable failures are really frustrating
<ChrisBr> yup
<ChrisBr> and Circle has live debugging
<ChrisBr> so you can login via SSH to the contaienr
<ChrisBr> I didn't use it very often but is a nice option if you dont cant reproduce it locally
<ChrisBr> and they have uploading assets included (e.g. logs, screenshots ...)
<ChrisBr> so you're running Travis on the free plan then?
<ChrisBr> btw: I think e.g. rails runs Travis & Circle in parallel
<headius> yeah we are just free plan
<headius> Travis guys might have bumped up our job count but I dunno
<headius> they did run a bunch of stuff on JRuby for a long time
<ChrisBr> headius: I would think so, IIRC with the basic plan you can only run two jobs in parallel
<headius> ah sure
<headius> I think we have 5
<ChrisBr> yeah, otherwise that would take forever ...
<ChrisBr> "We offer a total of four free linux containers ($2400 annual value) for open-source projects. Simply keeping your project public will enable this for you!" https://circleci.com/pricing/
<ChrisBr> but the pricing model is quite untransparent to be honest ...
<headius> lopex: we could have a different ByteCodeMachine for regionless matching that's a little smaller, right?
<headius> I'm not sure alloc is what's keeping us from matching MRI but making a smaller object would help if so
<headius> "This application will be able to read and write all public and private repository data." 😬
<headius> I mean I get that it needs access but I'd love to see this a bit finer-grained :-)
<lopex> headius: you mean the "match?"
<headius> yeah I was looking at it in passing
<lopex> headius: there's one more alloc for repeat stack
<headius> I suspect maybe this is back to big switches optimizing poorly
<headius> but if it's alloc we can make some stuff smaller
<lopex> headius: but then you'd have to account for (.)\1 and the like
<lopex> headius: whole "region" range update is tiny little thing there
<lopex> headius: do you profile it ?
<lopex> *did
<headius> I did an alloc profile
<headius> it's nothing we don't know...all ByteCodeMachine and int[]
<lopex> so the int come from that repeat stack alloc
<lopex> *comes
<headius> ah, I see
<headius> hmm
<headius> lazy?
<lopex> no
<headius> ah
<lopex> mri does that too
<headius> yeah but MRI probably alloca's it
<lopex> they also dont pool stacks
<headius> I suppose lazy wouldn't help here if it's usually going to be needed when it's present
<lopex> headius: and sampling profile tells anything ?
<headius> I'll do a run
<headius> I'm guessing it's not going to be much new info either
<lopex> headius: I know joni has some trouble wth chars class perf
<lopex> headius: whast about match? against a single char ?
<headius> well enebo said we suffer most for small strings
<headius> longer strings I think we make up the difference or beat MRI
<headius> that makes it seem like the alloc
<lopex> headius: so in this case the match method in matcher is kind of big
<headius> yes
<lopex> headius: forwardSearchRange
<headius> hmm yeah
<headius> I should check jit logs and see if some of these are getting kicked out
<lopex> er searchCommon
<headius> I don't see any significant number of ticks in interpreted code though
<headius> 66.3% 10507 + 1 org.joni.ByteCodeMachine.executeSb
<headius> 27.6% 4372 + 0 org.joni.Matcher.searchCommon
<headius> that's sampled
<lopex> is that the regexp from the issue ?
<headius> yeah
<headius> they both jit
<lopex> I'll show you the execution
<headius> ok
<headius> ok
<lopex> headius: I'd check how it compares against empty regexp and empty string
<headius> with both empty it's all executeSb
<lopex> it executes only end opcode
<lopex> and mri ?
<headius> perf? I'll check
<headius> 10M match? of empty/empty is 0.60s in JRuby and 0.78s in MRI
<headius> some of that is the loop itself
<headius> Graal JIT in 11 lowers JRuby to 0.48
<lopex> afaik we are slower for char class execution
<lopex> thats a lot of array hopping
<headius> maybe we should be using Unsafe to skip the bounds checks
<headius> "should"
<lopex> both the bitset and CodeRange
drbobbeaty has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<lopex> er
<lopex> hmm I dont believe return ((code[ip + (c >>> BitSet.ROOM_SHIFT)] & (1 << c)) != 0); is the fault
<lopex> headius: I dunno, the switch has dense values, the order shouldnt matter if there's breaks in all cases right ?
<headius> oh god I figured out why this autoload test fails
<headius> it's a bad test
<headius> it spins up ten threads and uses a global to choose one to sleep and the others to execute
<headius> but we run it all at once and so more than one sleeps
<headius> 🙄
<headius> lopex: it shouldn't but C2 is notoriously bad at optimizing big switches
<headius> that's why the parser uses a command pattern
<lopex> yeah, I remember you mentioning that wrt joni
<headius> I think all those branches mucks up the profiling
<lopex> it shouldnt be hard to convert at first thought
<headius> it might be worth a try...it had a large impact on parser perf
<enebo> My memory was bad we do not make up much with larger strings
<enebo> but with that said we are executing a single match in a block which did the results no favors
<headius> ok
<enebo> If this is in a method we no doubt look a bit better
<enebo> but I still expect/hope joni can beat oni even with the block overhead
<headius> this test is gross
<lopex> enebo: then EXACT_BM might be the fault
<lopex> and almost nothing in the interpreter for those longer cases
<enebo> lopex: what is regex.intMap
<lopex> enebo: skip map for map search
<enebo> lopex: I am partially surprised if this a if/else with that check vs something calling two methods which don't have this check (e.g. make a smaller method)
<lopex> it forwards faster
<headius> I have no idea what this test is supposed to do
<headius> hmm
<lopex> what test ?
<lopex> ah
<headius> autoload thing, pay no attention
<headius> multitasking
<enebo> doh
<lopex> enebo: there's regexp.map and intMap
<enebo> lopex: map and intMap is the same type right?
<lopex> enebo: but those are tight inner loops
<lopex> both should be int[]
<enebo> this could be a single set of whiles if you save proper int[] to a local variable
<lopex> enebo: no, map is byte[]
<lopex> enebo: yeah this is very old code, I havent paid attention for a long time
<enebo> lopex: I don't know if size matters but I was thinking about notion of two search methods where you call one depending on which one you work with
<lopex> aaah
<enebo> I guess this method calls no methods and even with half the whiles it maybe would not inline
<lopex> enebo: oni has a new variation called sunday search
<headius> screw it, I'm going to quarantine this test and open an issue
<enebo> when we call match? which path are we going done?
<enebo> down
<lopex> depends on the regexp
<enebo> lopex: ok but what feature triggers intMap vs map
<enebo> this method is pretty damn irreducible other than the if/else making the method larger
<lopex> enebo: fixed parts in the regexp
<lopex> like /foo..bar/
<lopex> foo will trugger that since thet fast skip want for find the interesting part using that
<lopex> *trigger and *wants
<enebo> so foo uses which one?
<enebo> intMap or map
<lopex> two answers
<enebo> oh I see
<lopex> so if >= 3 the ma[
<lopex> ma[
<lopex> er, map
<enebo> so map is used if it is small enough and intMap for codepoint matching
<lopex> er intMap
<lopex> if fixed part exceeds 256 then map
<headius> ok sorry, I'm back to joni stuff
<enebo> 256 distinct characters it can match?
<lopex> enebo: it's the length of exact part
<lopex> aka fixed
<enebo> oh so foo is 3
<enebo> which would use map
<lopex> yes
<lopex> so I'm almost sure we're loosing here
<lopex> since the execution of this is:
<enebo> lopex: so we could make BM_EXACT_SMALL and BM_EXACT_LARGE but that would not only eliminate a single if and reduce the algo size
<enebo> s/not//
<enebo> fwiw those benchmarks are a bit stupid and highly contrived
<lopex> enebo: we should port sunday search from them
<enebo> no doubt I just exposed BM_EXACT being slower and not overall why match? is slower
<enebo> lopex: sounds good to me
<enebo> lopex: how big is it?
<lopex> enebo: because almost nothing is done in ther interpreter in this case
<lopex> enebo: so that search seems to dominate
<enebo> did the 9:30 string match? we were looking at earlier also do exact_bm?
<lopex> enebo: but it still doesnt explain our perf for the example from thata issue
<enebo> seems like a lot of char ranges
<enebo> lopex: ok so my made up longer strings would get helped and would help regexp with static text in them converting to sunday search
<enebo> lopex: but the bench in the issue is unrelated
<headius> I have to leave cafe, bbiab
<lopex> enebo: agreed
<enebo> lopex: ok the issue reported one I think happens as part of common Rails activity
<enebo> I think kares came up with that regexp as being hit
<enebo> lopex: the ones I added was just to see how overhead of regexp changed as the match string got longer
<enebo> lopex: so not important although knowing a better algo exists is probably important
<enebo> lopex: since I think some of the date processing regexps do matches like (sun|mon|tue...)
<enebo> lopex: ^ is this alternation still a collection of exact_bm?
<lopex> enebo: almost, different skip map algo
<lopex> for sun|mon|tue
<lopex> enebo: it will have a skip map [m, s, t]
<lopex> so for /sun|mon|tue/ =~ "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaasunbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbfoobar"
<lopex> enebo: I forgot how it worked though
<lopex> ah
<enebo> lopex: so it is like switch(first) case 'm': match_exact 'mon' ...
<lopex> yes
<enebo> lopex: but it starts on the 'o' in match_exact right?
<enebo> since it knows from first instr that m matched?
<lopex> what 'o' ?
<enebo> 'mon' 'm' was determined by the skip map
<enebo> so the second character of mon
<lopex> enebo: hmm, the order might not matter
<lopex> since it's and alteration
<lopex> *anm
<lopex> enebo: oh, it's sorted
<enebo> lopex: but regardless of order if it determines first character in skip map then second char in where it jumps next should be next thing looked at
<enebo> lopex: I guess I am saying after skip map determines it might be 'mon' because it saw 'm' does it actually look at 'm' again in exact?
<lopex> yes
<lopex> ah
<lopex> yeah
<lopex> enebo: it always reassure in the interpreter if that what you mean
<lopex> *reassures
<enebo> lopex: well I am just wondering if one less compare would make a difference
<enebo> seems like exact3:on would be better bytecode if you know m will match from skip map
<lopex> enebo: but it need to build a backtrack first
<lopex> cant have it both ways
<lopex> enebo: that's why you have push first
<enebo> lopex: well I clearly don't understand this
<enebo> lopex: and unfortunately I need to go now :P
<lopex> enebo: or we're missunderstanding each other
<enebo> lopex: but I should maybe hang with you and try and learn basics of oni/joni bytecode one of these days
<enebo> I think if I did I would not ask so many long questions
<enebo> lopex: but I will talk to you later buddy
<lopex> enebo: yeah, I'm off the steam now too
<lopex> and also forgot lots of that parts of code
rtyler has joined #jruby
drbobbeaty has joined #jruby
drbobbeaty has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]