antocuni changed the topic of #pypy to: PyPy, the flexible snake (IRC logs: https://botbot.me/freenode/pypy/ ) | use cffi for calling C | "PyPy: the Gradual Reduction of Magic (tm)"
amaury has quit [Quit: Konversation terminated!]
amaury has joined #pypy
<abrown> ok, thanks
<abrown> another one if you have time: in https://travis-ci.org/abrown/dynsem-rpython/jobs/324466675#L3795 you can see that even in the optimized loop RPython thinks we need to check self.debug; however, it should know that this field is immutable due to https://github.com/abrown/dynsem-rpython/blob/master/src/meta/interpreter.py#L55--why don't these instructions disappear?
<simpson> Well, for starters, it says that that read is "pure" in the descr, which means that it should only be read once per trace.
<simpson> And we won't be able to remove p328 entirely, since at least .environment is read later.
<simpson> ...Hm. Is it possible that one needs `_immutable_ = True` as well? I'm honestly not sure.
<abrown> ok, I'll mess around with that
<simpson> Oh! I just realized: Is your goal to be able to avoid compiling intense debug information into the hot loops?
<abrown> yes
<simpson> Okay, then there's a really easy way to do this. Guard your debugging routines with `if we_are_jitted():`
<simpson> from rpython.rlib.jit import we_are_jitted
<simpson> This'll return True while the JIT is tracing and False otherwise.
<simpson> Oh, then `if not we_are_jitted()` sorry.
<abrown> that's a good idea
<simpson> Example usage here, skipping a single-entry method cache during tracing: https://github.com/monte-language/typhon/blob/master/typhon/nano/interp.py#L166-L181
<abrown> I'm trying to get a better understanding of how RPython decides to do what it does, though; in my mental model, I thought it would get rid of the `if self.debug` entirely but that was not the case
<simpson> Since the interpreter is a red, the JIT doesn't know. Reds are like parameters passed into the JIT's generated programs; even if a red has an immutable member, the JIT won't assume that it's got a reliably-special value. You could promote(), I think, without any danger of code explosion, since .debug only has two possible values.
dcrosta has quit [Ping timeout: 252 seconds]
mvantellingen has quit [Ping timeout: 252 seconds]
<abrown> perhaps the interpreter should be a green; it never changes from iteration to iteration... what I struggle with there is that it contains fields that CAN change from iteration to iteration (e.g. nesting and the contents of environment)
Cheery has quit [Ping timeout: 252 seconds]
Cheery has joined #pypy
<simpson> You can take the interpreter as red and then promote() the code object within. This will compile to code which takes the interpreter as input and then case-switches on the code object.
<simpson> Or you can move your JIT entrance to be a little more directly calling the code object, and then pass the code object as a green directly.
<simpson> We ended up doing the latter for Typhon, since it was faster. The downside is that we can't JIT certain kinds of loops, but those loops are extremely rare (our optimizer can't emit them in any case!) so I'm willing to take that hit. For now.
mvantellingen has joined #pypy
<abrown> makes sense; thanks for all your help
<abrown> I have glanced at Typhon a few times in the last few weeks and it has been pretty helpful
<simpson> Yeah, it's relatively readable for what it does.
amaury has quit [Quit: Konversation terminated!]
ndash has quit [Ping timeout: 248 seconds]
ronan has quit [Ping timeout: 252 seconds]
tbodt has joined #pypy
lapinot has joined #pypy
marr has quit [Ping timeout: 240 seconds]
ronan has joined #pypy
lapinot has quit [Quit: Bye!]
lapinot has joined #pypy
Hotpot33 has quit [Ping timeout: 265 seconds]
Hotpot33 has joined #pypy
cjwelborn has quit [Ping timeout: 276 seconds]
lritter_ has joined #pypy
lritter has quit [Ping timeout: 265 seconds]
dddddd has quit [Remote host closed the connection]
cjwelborn has joined #pypy
cjwelborn has quit [Changing host]
cjwelborn has joined #pypy
cjwelborn has joined #pypy
abrown has quit [Ping timeout: 265 seconds]
drolando has quit [Remote host closed the connection]
drolando has joined #pypy
abrown has joined #pypy
danchr has quit [Quit: ZNC - http://znc.sourceforge.net]
danchr has joined #pypy
ArneBab_ has joined #pypy
ArneBab has quit [Ping timeout: 264 seconds]
abrown has quit [Quit: Leaving]
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
forgottenone has joined #pypy
Hotpot33 has quit [Ping timeout: 252 seconds]
Hotpot33 has joined #pypy
Hotpot33 has quit [Ping timeout: 248 seconds]
Hotpot33 has joined #pypy
lritter_ has quit [Remote host closed the connection]
pilne has quit [Quit: Quitting!]
Hotpot33 has quit [Ping timeout: 264 seconds]
Hotpot33 has joined #pypy
lazy1 has joined #pypy
lazy1 has quit [Ping timeout: 276 seconds]
marr has joined #pypy
amaury has joined #pypy
antocuni has joined #pypy
dddddd has joined #pypy
antocuni has quit [Ping timeout: 265 seconds]
igitoor_ is now known as igitoor
forgottenone has quit [Quit: Konversation terminated!]
Hasimir has quit [Read error: Connection reset by peer]
Hasimir has joined #pypy
amaury has quit [Quit: Konversation terminated!]
amaury has joined #pypy
amaury has quit [Quit: Konversation terminated!]
forgottenone has joined #pypy
igitoor has quit [Ping timeout: 255 seconds]
igitoor has joined #pypy
igitoor has quit [Changing host]
igitoor has joined #pypy
amaury has joined #pypy
marr has quit [Ping timeout: 260 seconds]
pilne has joined #pypy
LarstiQ has quit [Quit: ZNC - http://znc.in]
LarstiQ has joined #pypy
bgola_ is now known as bgola
jamesaxl has quit [Ping timeout: 260 seconds]
marr has joined #pypy
jamesaxl has joined #pypy
irclogs_io_bot has quit [Remote host closed the connection]
irclogs_io_bot has joined #pypy
jtl_ has joined #pypy
forgottenone has quit [Quit: Konversation terminated!]
forgottenone has joined #pypy
mattip has joined #pypy
tbodt has joined #pypy
forgottenone has quit [Quit: Konversation terminated!]
dpn`- has joined #pypy
agronholm_ has joined #pypy
ssbr` has quit [*.net *.split]
untitaker has quit [*.net *.split]
rguillebert has quit [*.net *.split]
Hexxeh____ has quit [*.net *.split]
jiffe has quit [*.net *.split]
dpn` has quit [*.net *.split]
agronholm has quit [*.net *.split]
dpn`- is now known as dpn`
Graypup_ has quit [Ping timeout: 260 seconds]
Graypup_ has joined #pypy
tav has quit [Read error: Connection reset by peer]
tav has joined #pypy
untitaker has joined #pypy
Hexxeh____ has joined #pypy
rguillebert has joined #pypy
jiffe has joined #pypy
jiffe has quit [Max SendQ exceeded]
<kenaan> mattip py3.5 0c5a75555005 /rpython/rlib/rdynload.py: fix for issue #2716
<kenaan> mattip py3-winreg c4c33df88de7 /: close py3-winreg branch to be merged
<kenaan> mattip py3.5 7b9edeb55281 /: merge py3-winreg which uses unicode strings in winreg module
<kenaan> mattip py3.5 2f203c291e34 /pypy/doc/: restart whatsnew-pypy3-head.rst part 1
<kenaan> mattip py3.5 15ab2cc81a0c /pypy/doc/whatsnew-pypy3-head.rst: restart whatsnew-pypy3-head.rst part 2 and document merged branches
jiffe has joined #pypy
jamesaxl has quit [Quit: WeeChat 1.9.1]
tbodt has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Hasimir has quit [Read error: Connection reset by peer]
Hasimir has joined #pypy
tbodt has joined #pypy
zmt00 has joined #pypy
tbodt has quit [Read error: Connection reset by peer]
jtl_ has quit [Quit: jtl_]
amaury has quit [Quit: Konversation terminated!]
amaury has joined #pypy
fryguybob has quit [Remote host closed the connection]
<amaury> branch py3.5 does not translate
tbodt has joined #pypy
ssbr` has joined #pypy
dddddd has quit [Remote host closed the connection]
amaury has quit [Ping timeout: 240 seconds]