<headius>
the cuplrit is the RECache in BuildDynRegExpInstr... it is caching even when it isn't a "once" dregex
<headius>
this code goes back to 2015 so this bug has been out there for a long time
<enebo[m]>
ah I marked for 9.3 but I guess it will be fixed on both
<headius>
I don't think it can cache anything if it is not /o
<enebo[m]>
I think this also changes for 3.0
<enebo[m]>
but this is obviously broken for 2.5/2.6
<enebo[m]>
The cache could see if it is the same source string and keep caching it perhaps?
subbu has joined #jruby
<headius>
enebo: I don't see much value in that
<headius>
typically a dregexp should not be the same string repeatedly so it wouldn't help many cases, and we'd need to cache the strings and do a comparison every time
<headius>
the simple fix is to align with jit and just skip cache for non-once regexps
<headius>
ok I guess we are way ahead of the curve now... the FFI gem does not build properly for darwin-arm64 and I'm not sure how to fix it
<headius>
I don't grok extconf
<headius>
so they may or may not pass this spec but as near as I can tell it has never been tested on M1 properly
<headius>
enebo: I'm inclined to skip these two specs on M1 since it will take some research to figure out how to support C function callbacks from Java/Ruby
<headius>
I don't believe any Ruby functionality we ship depends on the feature
<enebo[m]>
sure it is several steps forwards in any case
<headius>
looks like some finesse required to disable write protections to executable memory when generating the stubs, and god knows how that will work across threads
<headius>
so yeah, I think this is ok to punt for now and maybe add some logic to FFI::Function failing fast if you try to use it on darwin-aarch64
<enebo[m]>
MRI does it for their FFI and JIT right?
<headius>
I doubt it
<enebo[m]>
not for mjit and yjit does not run on M1 so not the jits
<headius>
I don't think fiddle supports callbacks and they probably aren't testing the jits on M1 yet
<enebo[m]>
mjit loads a dll
<enebo[m]>
oh ok
<headius>
and the FFI gem doesn't even build right for M1
<headius>
we're on our own
<enebo[m]>
well if they don't have it yet then maybe it is not a big issue
<headius>
GraalVM doesn't support this platform yet either
<headius>
JRuby blazing the trail again
<enebo[m]>
Adding that rocket felt funny inside
<headius>
hahah
<headius>
enebo: when you get a change try to run spec:ffi for me
<headius>
I'm getting weird errors locally
<enebo[m]>
jruby-9.3 ran it fine
<headius>
ok something must be messed up in my local copy, rubygems complains about some file being "owned by" my OS and not by rubygems
<headius>
the fs mode and owner looks fine
<headius>
it's working fine on M1 so 🤷♂️
<headius>
mvn -Ptest is green on M1 CI
<headius>
spec:ffi is green as well, minus those two skipped specs
<headius>
weird noise out of the spec:ruby:fast job but it hasn't failed yet
<headius>
if that passes we will have three key runs green on M1 and I will merge the branch into 9.3
<headius>
this should be green but the closest it got had some really weird failure in a Hash#hash spec
<headius>
something is weird about the spec:ruby:fast run via CI... it shows way more failures than running in a terminal and doesn't complete
<headius>
there's definitely some networking oddities on MacOS instances because now a UDP spec is hanging there
<headius>
could be some multicast that isn't supported or just isn't working with this cloud network
<enebo[m]>
yeah I could see a network limit multicast
<headius>
I'm going to tag it off like the hanging unix socket specs but we'll want to revisit these
<headius>
I did get a green spec run on my personal M1 machine so this seems specific to the macstadium env
<headius>
enebo: same question as last week... what's our plan for 9.2 vs 9.3 branches?
<headius>
this dregexp thing affects both
<headius>
normally I'd do a PR to 9.2 and merge down but 9.2 has no CI currently
<enebo[m]>
9.2 can just be cp'd back from 9.3
<enebo[m]>
we decided to not merge forward on 9.2 any more right?
<enebo[m]>
but we will to master from 9.3
<headius>
that's fine with me, I wasn't sure we'd decide
<headius>
decided
<headius>
fixes to 9.2 have reduced to a trickle at this point
<enebo[m]>
I think we did. I think the conclusion is 9.2 is low risk and its own thing now
<headius>
ok I got a completed spec run on this M1 CI instance with four other network fails (looks like port permissions etc)
<headius>
so it does appear to be greenish when run directly, modulo env weirdness
<headius>
oh this local issue running specs is due to my regexp patch, I guess it's not right