<|jemc|>
chrisseaton: that makes sense; thanks for the expansion
<|jemc|>
on both points
<|jemc|>
it makes sense that smaller methods would be easier for a JIT to "reason" about
<chrisseaton>
|jemc|: because JITs have a time and space budget, they tend to give up early and silently, which isn't always helpful
<|jemc|>
and it also makes sense that you may be able to make some extra guarantees about a method table compared to a switch table in certain circumstances
<|jemc|>
I bring this up because I'm trying to strategize about my own parser generator
<|jemc|>
trying to weigh the cost of method dispatch when I have the option of "inlining" some of the methods in my preprocessor
<|jemc|>
the best data about what is the most performant obviously comes from trying it and benchmarking it, but some of these changes take a while to implement
<|jemc|>
so I'm trying to hypothesize a bit ahead of time (and often being wrong :P)
<|jemc|>
but it's good to figure out *why* I'm wrong instead of just *that* I'm wrong so I can make better hypotheses in the future
havenwood has quit [Remote host closed the connection]
havenwood has joined #rubinius
|jemc| has quit [Ping timeout: 244 seconds]
arrubin has joined #rubinius
amsi has quit [Quit: Leaving]
|jemc| has joined #rubinius
prontotest has joined #rubinius
prontotest has left #rubinius [#rubinius]
diegoviola has quit [Quit: WeeChat 1.0.1]
houhoulis has joined #rubinius
Bwild has joined #rubinius
arrubin has quit []
josh-k has joined #rubinius
josh-k_ has quit [Ping timeout: 264 seconds]
dimday has joined #rubinius
|jemc-bot| has quit [Ping timeout: 240 seconds]
Liothen has quit [Remote host closed the connection]
diegoviola has joined #rubinius
Liothen has joined #rubinius
|jemc|_ has joined #rubinius
|jemc| has quit [Read error: Connection reset by peer]
|jemc|_ is now known as |jemc|
|jemc| has quit [Quit: WeeChat 1.0.1]
|jemc| has joined #rubinius
|jemc| has quit [Client Quit]
|jemc| has joined #rubinius
diegoviola has quit [Ping timeout: 260 seconds]
josh-k has quit [Remote host closed the connection]
pietr0 has quit [Quit: pietr0]
flori has quit [Remote host closed the connection]
|jemc-bot| has joined #rubinius
amclain has joined #rubinius
|jemc| has quit [Read error: Connection reset by peer]
amclain has quit [Quit: Leaving]
JohnBat26 has joined #rubinius
meh` has quit [Ping timeout: 245 seconds]
imajes has quit [Ping timeout: 255 seconds]
flavio has joined #rubinius
flavio has joined #rubinius
imajes has joined #rubinius
dimday has quit [Quit: Leaving.]
houhoulis has quit [Remote host closed the connection]
josh-k has joined #rubinius
josh-k has quit [Read error: Connection reset by peer]
josh-k has joined #rubinius
josh-k has quit [Remote host closed the connection]
<yorickpeterse>
mornign
noop has joined #rubinius
<yorickpeterse>
* morning
josh-k has joined #rubinius
goyox86 has joined #rubinius
goyox86_ has joined #rubinius
goyox86 has quit [Ping timeout: 264 seconds]
kagaro has joined #rubinius
kagaro has quit [Client Quit]
kagaro has joined #rubinius
kagaro has quit [Client Quit]
kagaro has joined #rubinius
craigp has joined #rubinius
craigp has quit [Remote host closed the connection]
craigp has joined #rubinius
Bwild has quit [Quit: leaving]
elia has joined #rubinius
havenwood has quit [Remote host closed the connection]
machete has quit [Ping timeout: 245 seconds]
machete has joined #rubinius
saline has quit [Max SendQ exceeded]
saline has joined #rubinius
houhoulis has joined #rubinius
josh-k has quit [Remote host closed the connection]
craigp has quit [Remote host closed the connection]
craigp has joined #rubinius
enebo has joined #rubinius
geekbri has joined #rubinius
houhoulis has quit [Remote host closed the connection]
craigp has quit [Ping timeout: 245 seconds]
geekbri has quit []
noop has quit [Ping timeout: 252 seconds]
josh-k has joined #rubinius
dzhulk has joined #rubinius
diegoviola has joined #rubinius
havenwood has joined #rubinius
heftig has quit [Ping timeout: 260 seconds]
heftig has joined #rubinius
josh-k has quit [Read error: Connection reset by peer]
josh-k has joined #rubinius
asarih has quit [Ping timeout: 272 seconds]
cpuguy83 has quit [Ping timeout: 258 seconds]
jeregrine has quit [Ping timeout: 272 seconds]
chrisseaton has quit [Ping timeout: 260 seconds]
flavio has quit [Quit: WeeChat 1.0]
pietr0 has joined #rubinius
josh-k_ has joined #rubinius
asarih has joined #rubinius
jeregrine has joined #rubinius
josh-k has quit [Ping timeout: 258 seconds]
houhoulis has joined #rubinius
dzhulk has quit [Quit: Leaving.]
DanielVartanov has joined #rubinius
DanielVartanov has quit [Remote host closed the connection]
cpuguy83_ has joined #rubinius
elia has quit [Quit: Computer has gone to sleep.]
goyox86_ has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
pietr0 has quit [Quit: pietr0]
josh-k_ has quit [Remote host closed the connection]
pietr0 has joined #rubinius
pietr0 has quit [Client Quit]
chrisseaton has joined #rubinius
elia has joined #rubinius
pietr0 has joined #rubinius
noop has joined #rubinius
JohnBat26 has quit [Ping timeout: 244 seconds]
elia has quit [Quit: Computer has gone to sleep.]
lbianc has quit [Ping timeout: 240 seconds]
amsi has joined #rubinius
|jemc| has joined #rubinius
meh` has joined #rubinius
* yorickpeterse
is reading mkmf
* yorickpeterse
is a bit late with Halloween stories
<|jemc|>
heh
goyox86 has joined #rubinius
<yorickpeterse>
ok well I got what I came for: mkmf can compile C++
<yorickpeterse>
That means I have a date with C++ and Java tonight
<yorickpeterse>
lets retry when we don't have access, surely the system will give us access right?
<yorickpeterse>
|jemc|: looking at the code, all you need to do is name your files .cpp/.hpp instead of .c/.h
<headius>
jruby will optimize some homogeneous case/when expressions to be a test and jump rather than O(n)
<headius>
in 1.7...haven't done that optimization yet in 9k
dzhulk has joined #rubinius
goyox86_ has joined #rubinius
<headius>
chrisseaton: eventual native code size can be a problem too, right?
goyox86 has quit [Ping timeout: 252 seconds]
<chrisseaton>
Yeah - it's also just not where JIT authors focus on optimisation - method dispatch is going to be as good as it can possibly be - switch will often have less attention
<headius>
it certainly could use some work in hotspot
goyox86 has joined #rubinius
<yxhuvud>
I'm guessing here, but wouldn't high code size be a problem due to cache contention in the instruction pipeline?
<headius>
yxhuvud: yes, that's my understanding
<headius>
JIT size limits are there for good reasons...they're not just "hacks"
<yxhuvud>
well, being able to chop up something big into pieces that can be handled could be possible?
goyox86_ has quit [Ping timeout: 260 seconds]
<headius>
you mean...methods? :-)
<yxhuvud>
they are not automatically extracted from large pieces of code are they?
<headius>
no JIT I know of "outlines" pieces of a large body of code to get more of it to compile
<headius>
I'm sure it would be possible, but you'd need a balance between code size and adding a bunch of indirect calls
<chrisseaton>
I can't say I've ever seen that done, but interesting idea
<headius>
we've had to do it manually in a few cases, and will likely use IR compiler to do it for really large bodies
noop has quit [Ping timeout: 264 seconds]
dzhulk has quit [Quit: Leaving.]
jnh has joined #rubinius
|jemc| has quit [Ping timeout: 258 seconds]
amsi has quit [Ping timeout: 252 seconds]
pietr0_ has joined #rubinius
pietr0 has quit [Ping timeout: 264 seconds]
pietr0_ is now known as pietr0
pietr0 has quit [Remote host closed the connection]
<yorickpeterse>
brixen: random thought, would it be possible to take the bytecode from a proc, and turn that into an actual method?
<brixen>
yes
<yorickpeterse>
So basically using define_method to define a method (heh) exactly like the def keyword does
<brixen>
probably
<yorickpeterse>
hmm
<brixen>
CompiledCode don't care
<brixen>
but if the proc closes over a local from a surrounding scope, that wouldn't work
<brixen>
you can check for that, though
<yorickpeterse>
ah, hm
<headius>
procs close over a lot more than locals
<headius>
we have prototyped turning define_method into a normal method, though, and it works ok
<yorickpeterse>
headius: yeah, but it should be fine as long as the method is defined in the same scope
<headius>
methods instantiate their own frames, procs don't
<headius>
I'm not sure how that maps to rbx, but it required some trickery to change it so it didn't use parent scope/frame at al
<headius>
it's obviously possible, though
<goyox86>
brixen Why do you think JIT metrics are not getting set? I've been looking today with no luck in make them work :s
havenwood has quit [Ping timeout: 250 seconds]
<brixen>
goyox86: unsure, I'd have to look
<brixen>
goyox86: but meetings :p
<goyox86>
xd
<yorickpeterse>
as far as I can tell they're simply never used
<yorickpeterse>
That is, they are defined initially but never updated
<headius>
statsd is a node.js app?
sferik has joined #rubinius
<yorickpeterse>
Yes
<cremes>
goyox86: nice post. all those steps you outline are practically begging for someone to create a new docker image so it all works “out of the box"
<goyox86>
cremes indeed
<headius>
a docker image just to gather metrics?
<headius>
goyox86: you should add a screenshot
<cremes>
headius: did you see how many tools have to be installed? wrapping all of that up into a nice container would simplify matters for non-sysadmin people.
<goyox86>
But let me tell you: Trying to setup Graphite was/is pain in, well, a pain
<goyox86>
headius: I think I can add the screenshot
<headius>
cremes: yes, it seems very complicated
amsi has joined #rubinius
|jemc| has joined #rubinius
<|jemc|>
I was able to see metrics via graphite with an "out-of-the-box" docker container
<|jemc|>
it was as simple as using the command given in the readme to run the docker container, then running rbx pointed toward the correct statsd endpoint
<brixen>
goyox86: a docker container sounds awesome, I bet cpuguy83_ might agree :)
<cpuguy83_>
containerize all the things
sbryant has quit [Ping timeout: 258 seconds]
mjc_ has quit [Ping timeout: 258 seconds]
sbryant has joined #rubinius
mjc_ has joined #rubinius
cpuguy83_ is now known as cpuguy83
<|jemc|>
goyox86: I don't want to sound like I'm being negative - thanks for writing the blog post instead of sitting around like me telling people "oh, it's easy, just do X"
<|jemc|>
grafana looks prettier/more easy-to-touch than graphite anyway
<|jemc|>
if you want help putting together the docker container for what you did - let me know
<|jemc|>
I spent more time trying to figure out how to get the darn graphite UI to show what I want than I spent setting up the data flow :P
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
sferik has joined #rubinius
sferik has quit [Client Quit]
sferik has joined #rubinius
<goyox86>
<|jemc|>No problem at all I did the post and I still think it is tedious to setup all of that, and I'll probably endup by building the Docker image :)
sbryant has quit [Ping timeout: 258 seconds]
sbryant has joined #rubinius
sferik has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Bwild has joined #rubinius
_dyrim has quit [Remote host closed the connection]